-
Notifications
You must be signed in to change notification settings - Fork 270
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
Invalid configuration: machine not recognized (x86_64 Alpine Linux in Docker) #118
Comments
I tried using a prebuilt gcc from https://musl.cc/#binaries instead of gcc from Alpine and that fails in the same way. |
Are you using a weird shell or shell config that affects non-interactive shells? I'm not sure where this is coming from but it looks like it might be from an expansion of |
I'm just running the Alpine docker image with bash from it's apk package manager. However I think I've found the culprit: I have I just tried this out: (with a clean checkout of
Success! Ideas: The makefile could check for environment variables known to affect the build and warn the user about any that are not "officially" part of musl-cross-make. Alternatively you could do something like this in an early script, to clean the env from anything but "official" variables: [ -z "$__CLEAN_ENV" ] && exec env -i __CLEAN_ENV=1 \
HOME="$HOME" \
PATH="$PATH" \
TARGET="$TARGET" \
BINUTILS_VER="$BINUTILS_VER" \
DL_CMD="$DL_CMD" \
"$0" "$@" Thank you for the quick response! |
It's intended that you can control these variables from the command line or environment, so scrubbing them would be breaking. |
Got it. I wonder if documenting the "BUILD" variable then would help? |
Yeah, I was just thinking the same - we should probably document the env/make vars that are used. |
:-) |
Attempting build in docker vm
alpine:3.12
,make
fails relatively early with:It appears as somehow
dirname $PWD
is being used for--build=/root/build --host=/root/build
, which isn't right.I've also tried passing
HOST
to make (make HOST=x86_64-linux-gnu
) which that yields a different error:checking for C compiler... ../src_musl/configure: cannot find a C compiler
Note that
gcc -print-multiarch
does not print anything (bug in Alpine Linux's GCC package?)Repro:
End of output from make:
The text was updated successfully, but these errors were encountered: