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

Failed to build on macOS mojave (10.14.1) #2455

Closed
wesleyarchbell opened this issue Jan 23, 2019 · 3 comments
Closed

Failed to build on macOS mojave (10.14.1) #2455

wesleyarchbell opened this issue Jan 23, 2019 · 3 comments

Comments

@wesleyarchbell
Copy link

wesleyarchbell commented Jan 23, 2019

I ran the following commands on mac running mojave (10.14.1)

code-select --install
brew install --with-toolchain llvm
brew install pkg-config
brew install openssl
git clone https://github.com/mimblewimble/grin.git
cd grin
cargo build --release

And it fails to build with errors:

error: failed to run custom build command for `croaring-sys v0.3.7`                                                          
process didn't exit successfully: `/Users/wesleyarchbell/stuff/crypto/grin/target/release/build/croaring-sys-20d6d5c35e3a436a/build-script-build` (exit code: 101)
--- stdout
TARGET = Some("x86_64-apple-darwin")
OPT_LEVEL = Some("3")
HOST = Some("x86_64-apple-darwin")
CC_x86_64-apple-darwin = None
CC_x86_64_apple_darwin = None
HOST_CC = None
CC = None
CFLAGS_x86_64-apple-darwin = None
CFLAGS_x86_64_apple_darwin = None
HOST_CFLAGS = None
CFLAGS = None
DEBUG = Some("false")
running: "cc" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-m64" "-Wall" "-Wextra" "-std=c11" "-march=native" "-O3" "-o" "/Users/wesleyarchbell/stuff/crypto/grin/target/release/build/croaring-sys-4f7af44253f571e8/out/CRoaring/roaring.o" "-c" "CRoaring/roaring.c"
exit code: 0
AR_x86_64-apple-darwin = None
AR_x86_64_apple_darwin = None
HOST_AR = None
AR = None
running: "ar" "crs" "/Users/wesleyarchbell/stuff/crypto/grin/target/release/build/croaring-sys-4f7af44253f571e8/out/libroaring.a" "/Users/wesleyarchbell/stuff/crypto/grin/target/release/build/croaring-sys-4f7af44253f571e8/out/CRoaring/roaring.o"
exit code: 0
cargo:rustc-link-lib=static=roaring
cargo:rustc-link-search=native=/Users/wesleyarchbell/stuff/crypto/grin/target/release/build/croaring-sys-4f7af44253f571e8/out

--- stderr
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/emmintrin.h:2145:10: error: invalid conversion between vector type '__m128i' (vector of 2 'long long' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/emmintrin.h:2165:10: error: invalid conversion between vector type '__m128i' (vector of 2 'long long' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/emmintrin.h:3280:10: error: returning 'int' from a function with incompatible result type '__m128' (vector of 4 'float' values)
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/smmintrin.h:146:10: error: invalid conversion between vector type '__m128i' (vector of 2 'long long' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/avxintrin.h:2087:10: error: invalid conversion between vector type '__m256' (vector of 8 'float' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/avxintrin.h:2914:10: error: invalid conversion between vector type '__m256d' (vector of 4 'double' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/avxintrin.h:2932:10: error: invalid conversion between vector type '__m256' (vector of 8 'float' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/avx2intrin.h:148:10: error: invalid conversion between vector type '__m256i' (vector of 4 'long long' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/avx2intrin.h:154:10: error: invalid conversion between vector type '__m256i' (vector of 4 'long long' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/avx2intrin.h:835:10: error: invalid conversion between vector type '__m256i' (vector of 4 'long long' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:61:10: error: invalid conversion between vector type '__m128' (vector of 4 'float' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:67:10: error: invalid conversion between vector type '__m128d' (vector of 2 'double' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:73:10: error: invalid conversion between vector type '__m128' (vector of 4 'float' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:79:10: error: invalid conversion between vector type '__m128d' (vector of 2 'double' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:85:10: error: invalid conversion between vector type '__m128' (vector of 4 'float' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:91:10: error: invalid conversion between vector type '__m128d' (vector of 2 'double' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:97:10: error: invalid conversion between vector type '__m128' (vector of 4 'float' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:103:10: error: invalid conversion between vector type '__m128d' (vector of 2 'double' values) and integer type 'int' of different size
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:109:10: error: invalid conversion between vector type '__m128' (vector of 4 'float' values) and integer type 'int' of different size
fatal error: too many errors emitted, stopping now [-ferror-limit=]
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/emmintrin.h:2145:10: error: invalid conversion between vector type '__m128i' (vector of 2 'long long' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/emmintrin.h:2165:10: error: invalid conversion between vector type '__m128i' (vector of 2 'long long' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/emmintrin.h:3280:10: error: returning 'int' from a function with incompatible result type '__m128' (vector of 4 'float' values), err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/smmintrin.h:146:10: error: invalid conversion between vector type '__m128i' (vector of 2 'long long' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/avxintrin.h:2087:10: error: invalid conversion between vector type '__m256' (vector of 8 'float' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/avxintrin.h:2914:10: error: invalid conversion between vector type '__m256d' (vector of 4 'double' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/avxintrin.h:2932:10: error: invalid conversion between vector type '__m256' (vector of 8 'float' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/avx2intrin.h:148:10: error: invalid conversion between vector type '__m256i' (vector of 4 'long long' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/avx2intrin.h:154:10: error: invalid conversion between vector type '__m256i' (vector of 4 'long long' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/avx2intrin.h:835:10: error: invalid conversion between vector type '__m256i' (vector of 4 'long long' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:61:10: error: invalid conversion between vector type '__m128' (vector of 4 'float' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:67:10: error: invalid conversion between vector type '__m128d' (vector of 2 'double' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:73:10: error: invalid conversion between vector type '__m128' (vector of 4 'float' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:79:10: error: invalid conversion between vector type '__m128d' (vector of 2 'double' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:85:10: error: invalid conversion between vector type '__m128' (vector of 4 'float' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:91:10: error: invalid conversion between vector type '__m128d' (vector of 2 'double' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:97:10: error: invalid conversion between vector type '__m128' (vector of 4 'float' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:103:10: error: invalid conversion between vector type '__m128d' (vector of 2 'double' values) and integer type 'int' of different size, err: true
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/9.0.0/include/fmaintrin.h:109:10: error: invalid conversion between vector type '__m128' (vector of 4 'float' values) and integer type 'int' of different size, err: true
fatal error: too many errors emitted, stopping now [-ferror-limit=], err: true
thread 'main' panicked at 'Unable to generate bindings: ()', libcore/result.rs:1009:5
note: Run with `RUST_BACKTRACE=1` for a backtrace.

Running following clang version:

$ clang --version
Apple LLVM version 9.0.0 (clang-900.0.39.2)
Target: x86_64-apple-darwin18.2.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
@wesleyarchbell
Copy link
Author

Uninstalling llvm fixed the issue:

brew uninstall llvm

@nutmegminer
Copy link

Uninstalling llvm fixed the issue:

brew uninstall llvm

THis worked for me as well. You do not know how much this drove me crazy. Thank you.

@tpkeeper
Copy link

worked for me as well

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

3 participants