-
Notifications
You must be signed in to change notification settings - Fork 1.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
kiwisolver error ld: error: undefined symbol: main #3122
Comments
Did you get this working in the past or is it the first time you're trying? |
That's same error macos runner is having in github right now. |
if |
I think the recipe should have
Because the log error is due to trying to create an executable, so some compiler flags are wrong. And other recipes use |
Bump version, change depends to hostpython_prerequisites. Fix kivy#3122
I tried adding the above fix to a very loosely related PR #3124 |
I note the following warnings
These two options tell Clang to link as a The general form of the link on MacOS is (the
Linux replaces It looks like MacOS is picky about argument order. I suggest this will not be specific to this recipe. And will occur when CPPFLAGS is set in a recipe. The resolution is probably not to supply compile options to a link step. (And definitely not twice!). As far as I can see For the case of args supplied from a recipe, I think these should/could not be specified from a .toml file, so this is a |
Thank you for your input @RobertFlatt , yes that sounds reasonable, that could be it. |
@AndreMiras I did dig around in Don't really need a Mac initially, it is sufficient to look at the compile argument order on an Android build (assuming the reasoning in the previous post). The Android Clang, of course does not complain. Since |
So I got a macOS 13 (Ventura) setup working using dockur/macos to try to reproduce, but I can successfully build kiwisolver with it 🤷♂
It's weird that I'm trying to run it just like in the CI and it works for me 🤯
|
Fixed via #3128, I'll let the PR open until tomorrow and merge it if we don't get blocking comments. |
The condition I think will be |
🐛 Fix the kiwisolver build on macOS, fixes #3122
Thanks all for the fix. |
OS : mac
command: buildozer -v android debug
buildozer.spec : p4a.branch = develop
Can someone point why is this ld error caused while building 'kiwisolver._cext' extension
kiwisolver.error.txt
[DEBUG]: /Users/.buildozer/android/platform/android-ndk-r25b/toolchains/llvm/prebuilt/darwin-x86_64/bin/clang++ -target aarch64-linux-android24 -fomit-frame-pointer -march=armv8-a -fPIC -target aarch64-linux-android24 -fomit-frame-pointer -march=armv8-a -fPIC -I/Users/workspace/stocks/android/matplotlibapp/.buildozer/android/platform/build-arm64-v8a_armeabi-v7a/build/other_builds/python3/arm64-v8a__ndk_target_24/python3/Include -bundle -undefined dynamic_lookup -L/Users/workspace/stocks/android/matplotlibapp/.buildozer/android/platform/build-arm64-v8a_armeabi-v7a/build/libs_collections/matplotlibapp/arm64-v8a -L/Users/workspace/stocks/android/matplotlibapp/.buildozer/android/platform/build-arm64-v8a_armeabi-v7a/build/other_builds/python3/arm64-v8a__ndk_target_24/python3/android-build -lpython3.11 -target aarch64-linux-android24 -fomit-frame-pointer -march=armv8-a -fPIC -I/Users/workspace/stocks/android/matplotlibapp/.buildozer/android/platform/build-arm64-v8a_armeabi-v7a/build/other_builds/python3/arm64-v8a__ndk_target_24/python3/Include build/temp.macosx-15.3-arm64-cpython-311/py/src/constraint.o build/temp.macosx-15.3-arm64-cpython-311/py/src/expression.o build/temp.macosx-15.3-arm64-cpython-311/py/src/kiwisolver.o build/temp.macosx-15.3-arm64-cpython-311/py/src/solver.o build/temp.macosx-15.3-arm64-cpython-311/py/src/strength.o build/temp.macosx-15.3-arm64-cpython-311/py/src/term.o build/temp.macosx-15.3-arm64-cpython-311/py/src/variable.o -o build/lib.macosx-15.3-arm64-cpython-311/kiwisolver/_cext.cpython-311-darwin.so -stdlib=libc++
[DEBUG]: clang-14: warning: argument unused during compilation: '-bundle' [-Wunused-command-line-argument]
[DEBUG]: clang-14: warning: argument unused during compilation: '-undefined dynamic_lookup' [-Wunused-command-line-argument]
[DEBUG]: ld: error: undefined symbol: main
[DEBUG]: >>> referenced by crtbegin.c
The text was updated successfully, but these errors were encountered: