splitsh / lite: Error when build on Windows 10 - go

https://github.com/splitsh/lite/issues/58
Hello,
I am trying to install splitsh-lite in windows 10. I read #18 and followed the manual instructions until the last step when an error is thrown:
In cmd:
go get github.com/splitsh/lite
github.com/libgit2/git2go
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find -lgit2
collect2.exe: error: ld returned 1 exit status
In MINGW64:
$ go build -o splitsh-lite github.com/splitsh/lite
github.com/libgit2/git2go
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find -lgit2
collect2.exe: error: ld returned 1 exit status
Could you help me or give me some guidelines in order to build splitsh-lite?
Thank you!

Since I had issues on Windows, too, I used the Windows Linux Subsystem. There is no need to get that running in the native Windows command line anymore.
https://learn.microsoft.com/en-us/windows/wsl/install-win10
Install GO
wget -q https://dl.google.com/go/go1.12.6.linux-amd64.tar.gz
tar -C /usr/local -xzf go1.12.6.linux-amd64.tar.gz
export PATH=$PATH:/usr/local/go/bin
Install splitsh
wget -q https://github.com/splitsh/lite/releases/download/v1.0.1/lite_linux_amd64.tar.gz
tar -zxpf lite_linux_amd64.tar.gz --directory /usr/local/bin/
cp /usr/local/bin/splitsh-lite "$(git --exec-path)"/git-splitsh
The release versions in my commands might be outdated, I did this in November 2019. Please replace them if needed. Then you're ready to perform your repository modifications with splitsh.

Related

cocotb-modelsim error due to Illegal option -o pipefail

I am trying to run cocotb simulations with modelsim, however, I am getting an error and no success, in the last two days, fixing it.
I have installed cocotb using "pip3 install cocotb". The python version I am using is 3.7.0. I have installed the questa/modelsim Lite version 19.1 (which is free through Intel).
I am able to run cocotb simulations with icarus and verilator, however, with modelsim I run into following error:
mehdi#mehdi:~/Dropbox/Test_Tools/testcocotbVerilator$ make SIM=modelsim
make results.xml
make[1]: Entering directory '/home/mehdi/Dropbox/Test_Tools/testcocotbVerilator'
set -o pipefail; cd sim_build && LD_LIBRARY_PATH=/home/mehdi/Dropbox/Test_Tools/testcocotbVerilator/build/libs/x86_64::/usr/lib:/usr/lib:/usr/lib:/usr/lib MODULE=TB TESTCASE= TOPLEVEL="work.dff" COCOTB_SIM=1 \
GPI_EXTRA= TOPLEVEL_LANG=verilog PYTHONPATH=/home/mehdi/Dropbox/Test_Tools/testcocotbVerilator/build/libs/x86_64:/home/mehdi/Dropbox/Test_Tools/testcocotbVerilator:/home/mehdi/.local/lib/python3.5/site-packages: \
/home/mehdi/intelFPGA_lite/19.1/modelsim_ase/linuxaloem/vsim -c -64 -do runsim.do 2>&1 | tee sim.log
/bin/sh: 1: set: Illegal option -o pipefail
/home/mehdi/.local/lib/python3.5/site-packages/cocotb/share/makefiles/simulators/Makefile.questa:147: recipe for target 'results.xml' failed
make[1]: *** [results.xml] Error 2
make[1]: Leaving directory '/home/mehdi/Dropbox/Test_Tools/testcocotbVerilator'
/home/mehdi/.local/lib/python3.5/site-packages/cocotb/share/makefiles/Makefile.sim:79: recipe for target 'sim' failed
make: *** [sim] Error 2
I would appreciate it if someone could advise me how should I fix this problem
That "-o pipefail" option is only available in bash version 3 or later. So either you're running an older version of bash, or some other non-bash shell that doesn't support it.

Error when calling blogdown::build_site on Unix, command fails

I am using:
R 3.5.2
Blogdown (latest from CRAN)
Unix CentOS (Docker) on Windows host
Problem
I am trying to build a site in Blogdown. The site I am trying to build is Hugo XMin as it is with no modifications. I have:
Cloned the repository of the Hugo XMin site in my Unix system.
Installed all dependencies on Unix.
Ran command blogdown::build_site() inside the site root folder after entering R in interactive mode in Bash by just using command R.
The error I get is the following:
> blogdown::build_site()
Rendering content/_index.Rmarkdown
running: bash -c "cd ../..;
find . -not -path '*/exampleSite/*' \\( -name '*.html' -o -name '*.css' \\) | xargs wc -l"
pandoc: Error running filter pandoc-citeproc
pandoc-citeproc not found in path
Error: pandoc document conversion failed with error 83
Execution halted
Warning message:
In file.remove(intermediate_html) :
cannot remove file '_index.tmp.html', reason 'No such file or directory'
Error in render_page(f) : Failed to render 'content/_index.Rmarkdown'
On my Windows machine, this works fine.
I was tricked by the message and did not see that pandoc-citeproc is been required but not found. So the fix is easy:
yum install pandoc-citeproc

Compile cygwin1.dll from its source code

I want to edit some code in cygwin1.dll for my project. So, I clone git repository from these two url:
https://github.com/mirror/newlib-cygwin.git
git://sourceware.org/git/newlib-cygwin.git
I've gcc, g++, make installed with cygwin and mingw-w64 (and also in WSL). But none of them generate DLL file. I also follow the commands ./configure & make. Command generates only object files. Is it possible to compile cygwin1.dll from its source code?
I had two different problems.
First, I followed the steps in cygwin FAQ: How do I build Cygwin on my own?. I forget to install mingww64_x86_64-gcc-g++ package. So, I installed those with the following commands:
setup-x86_64.exe -q -P gcc-g++ -P make -P perl -P cocom -P gettext-devel -P libiconv-devel -P zlib-devel
setup-x86_64.exe -q -P mingw64-x86_64-gcc-core -P mingw64-i686-gcc-g++ -P mingw64-i686-zlib
setup-x86_64.exe -q -P mingw64-x86_64-gcc-g++ -P mingw64-x86_64-zlib
Second, I logged the output from make command with make |& tee make.log. Thanks, #matzeri for the logging tip. Then I followed an error in make.log file as below:
../../.././winsup/cygwin/cygmagic: line 25: /usr/bin/awk: cannot
execute binary file: Exec format error
*** WARNING WARNING WARNING WARNING WARNING ***
*** ../../.././winsup/cygwin/child_info.h: magic number for
CHILD_INFO_MAGIC changed old 0xc96f5e9U != new
Somehow, the awk (hard linked with gawk) does not work in cygwin. So I installed awk package with setup-x86_64.exe. And now I can easily compile cygwin.dll.

Error running bash script

Trying to run the following bash script but get the below error message(s) - any ideas how to correct?
You don't have a wget program on Your mac. The fastest way to get it is via cURL.
curl -O http://ftp.gnu.org/gnu/wget/wget-1.15.tar.gz
Extract cURL:
tar -zxvf wget-1.15.tar.gz
open folder:
cd wget-1.15/
And run installer
./configure

patching bash shell shock bug from source

I am running a non-standard version of Ubuntu and I tried to patch the shell shock bug by downloading and recompiling from the source, following the instructions from https://news.ycombinator.com/item?id=8364385 . After make install, running bash --version shows 4.3.24(2). But when running the bug test:
env var='() { :;}; echo vulnerable' bash -c /bin/true
is still printing vulnerable . Am I doing something wrong?
4.3.24 is from August 2014; you need 4.3.25.
It's most likely that you didn't install the new bash in the right place. Or that you didn't manage to install it at all.
make install will only work if you're running as root. Normally, you would need to do
sudo make install
If you don't, you'll see an error message:
$ make install
***********************************************************
* *
* GNU bash, version 4.3.25(1)-release (x86_64-unknown-linux-gnu)
* *
***********************************************************
mkdir -p -- /usr/local/share/doc/bash
mkdir: cannot create directory ‘/usr/local/share/doc/bash’: Permission denied
make: *** [installdirs] Error 1
which means that the software wasn't installed. (You only need to redo the install step.)
Also, by default, the bash build files will install your new bash as /usr/local/bin/bash, while your old bash will continue to exist in /usr/bin/bash. Check which bash is being run by typing:
which bash

Resources