Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows support #52

Closed
vmarkovtsev opened this issue Jan 19, 2018 · 12 comments
Closed

Windows support #52

vmarkovtsev opened this issue Jan 19, 2018 · 12 comments
Assignees

Comments

@vmarkovtsev
Copy link
Collaborator

E.g. hardcoded SHELL to /bin/bash and other things I have not checked yet.

Minimal requirement to consider this fixed: no errors in bblfsh/client-go.

@vmarkovtsev vmarkovtsev self-assigned this Jan 19, 2018
smola added a commit to smola/ci that referenced this issue May 10, 2018
* Fix Windows builds.
* Add Appveyor CI.

Signed-off-by: Santiago M. Mola <santi@mola.io>
smola added a commit to smola/ci that referenced this issue May 10, 2018
* Fix Windows builds.
* Add Appveyor CI.

Signed-off-by: Santiago M. Mola <santi@mola.io>
smola added a commit to smola/ci that referenced this issue May 10, 2018
* Fix Windows builds.
* Add Appveyor CI.

Signed-off-by: Santiago M. Mola <santi@mola.io>
smola added a commit to smola/ci that referenced this issue May 10, 2018
* Fix Windows builds.
* Add Appveyor CI.

Signed-off-by: Santiago M. Mola <santi@mola.io>
smola added a commit to smola/ci that referenced this issue May 10, 2018
* Add Appveyor CI, fix tests of src-d/ci itself to run on Appveyor.
* example: Avoid subshell on Makefile before including Makefile.main. This fixes the build for mingw32-make on Windows. Alternative might be setting SHELL=/bin/bash on Makefile, but avoiding the subshell is just simpler and works.

Signed-off-by: Santiago M. Mola <santi@mola.io>
smola added a commit to smola/ci that referenced this issue May 10, 2018
* Add Appveyor CI, fix tests of src-d/ci itself to run on Appveyor.
* example: Avoid subshell on Makefile before including Makefile.main. This fixes the build for mingw32-make on Windows. Alternative might be setting SHELL=/bin/bash on Makefile, but avoiding the subshell is just simpler and works.

Signed-off-by: Santiago M. Mola <santi@mola.io>
@smola
Copy link
Contributor

smola commented May 10, 2018

In the end, /bin/bash et al are staying. We'll support Windows, but a working version of GNU make, bash, grep, date, git, cat, rm and some other basic tools are required. I have tested this with msys2+MinGW.

test-coverage requires curl. Docker stuff requires a docker client (probably set up to use a Linux docker host).

@smola smola assigned smola and unassigned vmarkovtsev May 10, 2018
smola added a commit to smola/ci that referenced this issue May 10, 2018
* Add Appveyor CI, fix tests of src-d/ci itself to run on Appveyor.
* example: Avoid subshell on Makefile before including Makefile.main. This fixes the build for mingw32-make on Windows. Alternative might be setting SHELL=/bin/bash on Makefile, but avoiding the subshell is just simpler and works.

Signed-off-by: Santiago M. Mola <santi@mola.io>
@vmarkovtsev
Copy link
Collaborator Author

@smola How will it work if /bin/bash is an illegal path on Windows?..

@vmarkovtsev
Copy link
Collaborator Author

BTW now I remember that this is related to #56

smola added a commit to smola/ci that referenced this issue May 10, 2018
* Add Appveyor CI, fix tests of src-d/ci itself to run on Appveyor.
* example: Avoid subshell on Makefile before including Makefile.main. This fixes the build for mingw32-make on Windows. Alternative might be setting SHELL=/bin/bash on Makefile, but avoiding the subshell is just simpler and works.

Signed-off-by: Santiago M. Mola <santi@mola.io>
@smola
Copy link
Contributor

smola commented May 10, 2018

@vmarkovtsev Because we run this with mingw32-make, which uses path translation. I think /bin/bash becomes %PATH TO MINGW ROOT%/bin/bash. Honestly, I still don't get some of the details, since the solution mixes some binaries from msys2 and mingw 64bit... but I got a branch working with rovers on Appveyor.

noidea

smola added a commit that referenced this issue May 10, 2018
* Add Appveyor CI, fix tests of src-d/ci itself to run on Appveyor.
* example: Avoid subshell on Makefile before including Makefile.main. This fixes the build for mingw32-make on Windows. Alternative might be setting SHELL=/bin/bash on Makefile, but avoiding the subshell is just simpler and works.

Signed-off-by: Santiago M. Mola <santi@mola.io>
mcuadros added a commit that referenced this issue May 11, 2018
@vmarkovtsev
Copy link
Collaborator Author

@smola New shocking details of CI running on Windows. This is what i see in the logs:

make[1]: Entering directory 'C:/Users/User/go/src/gopkg.in/bblfsh/client-go.v2'
process_begin: CreateProcess(NULL, pwd, ...) failed.
make[1]: makefile:22: pipe: No error
process_begin: CreateProcess(NULL, pwd, ...) failed.
make[1]: makefile:24: pipe: No such file or directory
git clone --quiet --depth 1 https://github.com/src-d/ci.git /.ci;

And this is what I see in Explorer:

fail_win

That is, some terrible path issues.

@smola
Copy link
Contributor

smola commented Jun 26, 2018

@vmarkovtsev Could you post here your make --version?

Try with mingw32-make (part of mingw distribution) if you aren't already.

Also, define your CI_PATH just as .ci in your Makefile (not $(shell pwd)/.ci or $PWD/.ci or anything like that).

@vmarkovtsev
Copy link
Collaborator Author

@vmarkovtsev
Copy link
Collaborator Author

@smola
Copy link
Contributor

smola commented Jun 26, 2018

@smola
Copy link
Contributor

smola commented Jun 26, 2018

@vmarkovtsev For hercules, just do not install make, use mingw32-make which is available with set PATH=C:\mingw-w64\x86_64-7.2.0-posix-seh-rt_v5-rev1\mingw64\bin;C:\msys64\usr\bin;%PATH%

@vmarkovtsev
Copy link
Collaborator Author

OK, will try

@smola
Copy link
Contributor

smola commented Sep 6, 2018

Closing, since basic support is already there.
@vmarkovtsev Please, open a separate issue if there is any further problem, thanks!

@smola smola closed this as completed Sep 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants