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

Build Error: clang: error: unknown argument: '-=' #28

Open
cmassoudi opened this issue Oct 15, 2022 · 1 comment
Open

Build Error: clang: error: unknown argument: '-=' #28

cmassoudi opened this issue Oct 15, 2022 · 1 comment

Comments

@cmassoudi
Copy link

hey @brian-armstrong, I'm running into an error while trying to build QM. I get the following error while running a carthage update command:

Run Build Command(s):/Applications/Xcode.app/Contents/Developer/usr/bin/make -f Makefile cmTC_2607f/fast && /Applications/Xcode.app/Contents/Developer/usr/bin/make  -f CMakeFiles/cmTC_2607f.dir/build.make CMakeFiles/cmTC_2607f.dir/build
Building C object CMakeFiles/cmTC_2607f.dir/INT.c.o
/usr/bin/clang   -=  -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.0.sdk  -arch arm64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.0.sdk -MD -MT CMakeFiles/cmTC_2607f.dir/INT.c.o -MF CMakeFiles/cmTC_2607f.dir/INT.c.o.d -o CMakeFiles/cmTC_2607f.dir/INT.c.o -c /Users/cmassoudi/Library/Caches/org.carthage.CarthageKit/DerivedData/14.0.1_14A400/QuietModemKit/v0.3.2/Build/Intermediates.noindex/ArchiveIntermediates/QuietModemKit/BuildProductsPath/Release-iphoneos/jansson/CMakeFiles/CheckTypeSize/INT.c
clang: error: unknown argument: '-='

That unknown arg error (clang: error: unknown argument: '-=') made it seem like some env variables might be missing. I took a peek at the apple.toolchain.make and I see the cmake flags have an arg APPLE_VERSION_FLAG- I think that's the culprit.

apple.toolchain.make L195

set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${APPLE_VERSION_FLAG} ${BITCODE_FLAG} -isysroot ${CMAKE_OSX_SYSROOT}" CACHE STRING "")

Any help would be much appreciated, thanks!
-Cam

@cmassoudi
Copy link
Author

I was able to get this to work by removing the APPLE_VERSION_FLAG args from the toolchain make file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant