diff options
author | Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com) <spamtrap@nedprod.com> | 2020-03-20 14:25:48 +0300 |
---|---|---|
committer | Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com) <spamtrap@nedprod.com> | 2020-03-20 14:25:48 +0300 |
commit | c095cf676a544aac002dcabbfcd1cbc038a9c80b (patch) | |
tree | a67980cd9ea881511f28a63044cf8a16ef803eed | |
parent | fa0a14d203c2673a814a77209dae8c045c68c193 (diff) |
Figured out libc++ support. Added to Travis CI.
-rw-r--r-- | .travis.yml | 30 | ||||
-rw-r--r-- | CMakeLists.txt | 2 | ||||
-rw-r--r-- | cmake/toolchain-linux-libc++.cmake | 6 | ||||
-rw-r--r-- | include/llfio/revision.hpp | 6 |
4 files changed, 28 insertions, 16 deletions
diff --git a/.travis.yml b/.travis.yml index 71c8cc50..34f9cc2d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,6 +3,7 @@ language: cpp compiler: - g++ - clang++ + - clang++-10 sudo: false os: - linux @@ -18,9 +19,14 @@ notifications: addons: apt: + sources: + - llvm-toolchain-bionic-10 packages: - g++ - clang + - clang-10 + - libc++-10-dev + - libc++abi-10-dev - g++-arm-linux-gnueabihf - python3 - cmake @@ -52,28 +58,28 @@ matrix: # - os: osx # env: __="ARM32 cmake tests (status_code)" NAME=ARM32_SC CMAKE_CONFIGURE_OPTIONS=-DLLFIO_USE_EXPERIMENTAL_SG14_STATUS_CODE=ON - os: linux - compiler: clang++ + compiler: + - clang++ + - clang++-10 env: __="ARM32 cmake tests (error_code)" NAME=ARM32_EC CMAKE_CONFIGURE_OPTIONS= - os: linux - compiler: clang++ + compiler: + - clang++ + - clang++-10 env: __="ARM32 cmake tests (status_code)" NAME=ARM32_SC CMAKE_CONFIGURE_OPTIONS=-DLLFIO_USE_EXPERIMENTAL_SG14_STATUS_CODE=ON - os: linux - compiler: g++ + compiler: + - g++ + - clang++-10 env: __="Documentation" NAME=Documentation cache: apt: true before_install: - - - if [ "${TRAVIS_OS_NAME}" = "osx" ]; then - if [ "$CXX" = "g++" ]; then export NAME=MacOSGCC$NAME; fi; - if [ "$CXX" = "clang++" ]; then export NAME=MacOSClang$NAME; fi; - fi - - - if [ "${TRAVIS_OS_NAME}" = "linux" ]; then - if [ "$CXX" = "g++" ]; then export NAME=LinuxGCC$NAME; fi; - if [ "$CXX" = "clang++" ]; then export NAME=LinuxClang$NAME; fi; + - export NAME=$TRAVIS_OSNAME_$TRAVIS_COMPILER_$NAME + - if [ "$TRAVIS_COMPILER" = "clang++-10" ]; then + export CMAKE_CONFIGURE_OPTIONS="$CMAKE_CONFIGURE_OPTIONS -DCMAKE_TOOLCHAIN_FILE=../cmake/toolchain-linux-libc++.cmake"; fi - git checkout develop - git submodule update --init --recursive diff --git a/CMakeLists.txt b/CMakeLists.txt index acd2bc85..cd6eeca6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -242,7 +242,7 @@ int main() { endif() function(check_stl_filesystem_link_flags) indented_message(STATUS "NOTE: Using STL link flags '${ARGN}'") - set(CMAKE_REQUIRED_LINK_OPTIONS ${ARGN}) + set(CMAKE_REQUIRED_LIBRARIES ${ARGN}) check_cxx_source_runs(" #include <filesystem> int main() { diff --git a/cmake/toolchain-linux-libc++.cmake b/cmake/toolchain-linux-libc++.cmake new file mode 100644 index 00000000..ef63d6de --- /dev/null +++ b/cmake/toolchain-linux-libc++.cmake @@ -0,0 +1,6 @@ +set(CMAKE_C_COMPILER clang-10) +set(CMAKE_CXX_COMPILER clang++-10) +set(CMAKE_CXX_STANDARD 17) +set(CMAKE_CXX_FLAGS "-stdlib=libc++ -fchar8_t") +set(CMAKE_EXE_LINKER_FLAGS -stdlib=libc++) + diff --git a/include/llfio/revision.hpp b/include/llfio/revision.hpp index 9d454907..24ced699 100644 --- a/include/llfio/revision.hpp +++ b/include/llfio/revision.hpp @@ -1,4 +1,4 @@ // Note the second line of this file must ALWAYS be the git SHA, third line ALWAYS the git SHA update time -#define LLFIO_PREVIOUS_COMMIT_REF 8e02b46999597bb9eb414b09def487a599c28c0f -#define LLFIO_PREVIOUS_COMMIT_DATE "2020-03-19 09:14:59 +00:00" -#define LLFIO_PREVIOUS_COMMIT_UNIQUE 8e02b469 +#define LLFIO_PREVIOUS_COMMIT_REF fa0a14d203c2673a814a77209dae8c045c68c193 +#define LLFIO_PREVIOUS_COMMIT_DATE "2020-03-20 10:57:36 +00:00" +#define LLFIO_PREVIOUS_COMMIT_UNIQUE fa0a14d2 |