i'm trying cross-compile libdsm ios, starting arm64.
i've pulled down source code , have been trying configure using following:
export xcodedir=$(xcode-select -p) export devroot=${xcodedir}/platforms/iphoneos.platform/developer export sdkroot=$devroot/sdks/iphoneos.sdk export cflags="-arch arm64 -pipe -no-cpp-precomp -isysroot $sdkroot -mios-version-min=10.0 -i$sdkroot/usr/include/" export ldflags="-mthumb -arch arm64 -isysroot $sdkroot -mios-version-min=10.0" ./configure --host arm-apple-darwin --prefix $pwd/build/arm64
it stops error:
configure: error: c preprocessor "/lib/cpp" fails sanity check
the error in configure.log is:
configure:4504: checking how run c preprocessor configure:4535: gcc -e conftest.c in file included conftest.c:14: in file included /users/pmacro/downloads/xcode-beta.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../lib/clang/8.0.0/include/limits.h:37: in file included /users/pmacro/downloads/xcode-beta.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos10.0.sdk/usr/include/limits.h:63: /users/pmacro/downloads/xcode-beta.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos10.0.sdk/usr/include/sys/cdefs.h:761:2: error: unsupported architecture #error unsupported architecture ^
a possibly related message earlier in configure.log is:
configure:3752: ./conftest ./configure: line 3754: ./conftest: bad cpu type in executable
note compiles fine x86_64 (the platform i'm building on), arm architecture fails.
i've looked @ examples of cross compiling ios , seem following these steps. running pre-release software (macos sierra , xcode 8), same issue when running xcode 7 on sierra. help.
the problem needed specify architecture (-arch arm64) in cppflags cflags.
Comments
Post a Comment