diff options
author | Willem Jan Withagen <wjw@digiware.nl> | 2018-11-25 15:38:54 +0100 |
---|---|---|
committer | Willem Jan Withagen <wjw@digiware.nl> | 2018-11-25 15:38:54 +0100 |
commit | 6ef950e8683c93c5b836d12ef5787fac39509ded (patch) | |
tree | f62a3c82e0ba4466ad4a7e7ddac2a8adea2e8c99 /do_freebsd.sh | |
parent | Merge pull request #25206 from dillaman/wip-36622 (diff) | |
download | ceph-6ef950e8683c93c5b836d12ef5787fac39509ded.tar.xz ceph-6ef950e8683c93c5b836d12ef5787fac39509ded.zip |
build: FreeBSD building needs the llvm linker
Signed-off-by: Willem Jan Withagen <wjw@digiware.nl>
Diffstat (limited to 'do_freebsd.sh')
-rwxr-xr-x | do_freebsd.sh | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/do_freebsd.sh b/do_freebsd.sh index 0e857570926..25dc2f5df65 100755 --- a/do_freebsd.sh +++ b/do_freebsd.sh @@ -14,6 +14,14 @@ fi # To test with a new release Clang, use with cmake: # -D CMAKE_CXX_COMPILER="/usr/local/bin/clang++-devel" \ # -D CMAKE_C_COMPILER="/usr/local/bin/clang-devel" \ +COMPILE_FLAGS="-O0 -g" +if [ `sysctl -n kern.osreldate` -le 1102000 ]; then + # We need to use the llvm linker for linking ceph-dencoder + COMPILE_FLAGS="$COMPILE_FLAGS -fuse-ld=/usr/bin/ld.lld" +fi +CMAKE_CXX_FLAGS_DEBUG="$CXX_FLAGS_DEBUG $COMPILE_FLAGS" +CMAKE_C_FLAGS_DEBUG="$C_FLAGS_DEBUG $COMPILE_FLAGS" + # # On FreeBSD we need to preinstall all the tools that are required for building # dashboard, because versions fetched are not working on FreeBSD. @@ -27,8 +35,8 @@ fi ./do_cmake.sh "$*" \ -D WITH_CCACHE=ON \ -D CMAKE_BUILD_TYPE=Debug \ - -D CMAKE_CXX_FLAGS_DEBUG="$CXX_FLAGS_DEBUG -O0 -g" \ - -D CMAKE_C_FLAGS_DEBUG="$C_FLAGS_DEBUG -O0 -g" \ + -D CMAKE_CXX_FLAGS_DEBUG="$CXX_FLAGS_DEBUG" \ + -D CMAKE_C_FLAGS_DEBUG="$C_FLAGS_DEBUG" \ -D ENABLE_GIT_VERSION=OFF \ -D WITH_SYSTEM_BOOST=ON \ -D WITH_SYSTEM_NPM=ON \ |