-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Cannot build on Windows using GNUMake #4978
Comments
Please use Docker, when building on Windows. Only Linux is supported as a build environment.
|
Theoretically it should be possible to build on Mac, or by using MSYS2/WSL when on Windows. But it is not officially supported. |
Hmm, this might actually be a problem even before docker is started. Just guessing, haven't tried. CMD_SOURCE_DIRS = cmd pkg
out/minikube-%: pkg/minikube/assets/assets.go pkg/minikube/translate/translations.go $(shell find $(CMD_SOURCE_DIRS) -type f -name "*.go")
ifeq ($(MINIKUBE_BUILD_IN_DOCKER),y)
$(call DOCKER,$(BUILD_IMAGE),/usr/bin/make $@)
else Access denied - CMD So we might have to wrap that Because this happens all over the place: PYTHON := $(shell command -v python || echo "docker run --rm -it -v $(shell pwd):/minikube -w /minikube python python") 'command' is not recognized as an internal or external command, operable program or batch file. BUILD_OS := $(shell uname -s) process_begin: CreateProcess(NULL, uname -s, ...) failed. Fortunately, |
ping @tstromberg |
I think we should just document that building minikube requires GNU bash and GNU make ? It should not be a problem on the other platforms, so it mostly affects any Windows developers. https://minikube.sigs.k8s.io/docs/contributing/building/
Wonder if building the out/minikube.exe itself works without Docker ? Can't see why it shouldn't. Basically all it does is call |
It isn't ideal, but in the short term, we may have to require running builds under FWIW, I would rather not run builds through Docker if I can avoid it. |
Assigning this to myself. Let me see what can be if this can run directly from Bash for Windows. /assign |
@blueelvis we could also update the documentation for contributing |
@medyagh - Right now, I am using WSL on Windows 10 to do the compilation. I run tests and everything inside the WSL environment only. Should we add that as well to the documentation? |
|
@tstromberg - I just tried on my machine and this is still an issue. I am not able to |
@blueelvis - Do you mind sharing the result? I believe @sharifelgamal may have been using git-bash. Do you mind sharing the error message you are hitting? |
@tstromberg - I think it is the same as above -
|
This doesn't look like a bash shell. What version of make is this ? Maybe it has some weird setting for the Might have to add some basic sanity checking to the Makefile, perhaps even set the shell. SHELL = /bin/sh |
yeah make doesn't currently work in powershell, only in something that can run bash commands, and is documented as such. |
@sharifelgamal @blueelvis is there any update on this issue, |
Yeah this is documented as needing a bash shell, we can close this. |
The exact command to reproduce the issue:
make windows
** Version of Make**:
The full output of the command that failed:
PS D:\dev\minikube> make windows The syntax of the command is incorrect.
process_begin: CreateProcess(NULL, pwd, ...) failed.
make: Makefile:59: pipe: Bad file descriptor
'command' is not recognized as an internal or external command,
operable program or batch file.
process_begin: CreateProcess(NULL, uname -s, ...) failed.
make: Makefile:60: pipe: Bad file descriptor
Access denied - CMD
Access denied - PKG
File not found - -TYPE
File not found - F
File not found - -NAME
FIND: Parameter format not correct
FIND: Parameter format not correct
FIND: Parameter format not correct
FIND: Parameter format not correct
FIND: Parameter format not correct
FIND: Parameter format not correct
make: Nothing to be done for 'windows'.
The operating system version: Windows 10 Enterprise
The text was updated successfully, but these errors were encountered: