Skip to content

Commit

Permalink
Use GSL's "span" implementation instead of Boost's
Browse files Browse the repository at this point in the history
Boost's "span.hpp" was added in b4a9a10.
The idea was to make sure it would be available (introduced in Boost 1.78).

Now that ~9 months have passed, boost::span should be widespread in repositories.
Unfortunately Debian (and in turn Ubuntu) is stuck with 1.74 for some reason.

Thus, let's just use GSL, which is intended to be used also as a submodule.

Co-authored-by: Robert Adam <[email protected]>
  • Loading branch information
davidebeatrici and Krzmbrzl committed Sep 27, 2022
1 parent 290ac7c commit c4bbe8b
Show file tree
Hide file tree
Showing 22 changed files with 57 additions and 440 deletions.
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
[submodule "3rdparty/gsl"]
path = 3rdparty/gsl
url = https://github.com/microsoft/GSL.git
[submodule "3rdparty/quickpool"]
path = 3rdparty/quickpool
url = https://github.com/tnagler/quickpool.git
Expand Down
1 change: 1 addition & 0 deletions 3rdparty/gsl
Submodule gsl added at 10df83
2 changes: 2 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ if(build-tests)
include(CTest)
endif()

option(bundled-gsl "Use the bundled GSL version instead of looking for one on the system" ON)

set(CMAKE_CXX_EXTENSIONS OFF)
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
Expand Down
4 changes: 4 additions & 0 deletions CMakePresets.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,10 @@
"CMAKE_TOOLCHAIN_FILE": {
"type": "FILEPATH",
"value": "$env{VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake"
},
"bundled-gsl": {
"type": "BOOL",
"value": "OFF"
}
}
}
Expand Down
Loading

0 comments on commit c4bbe8b

Please sign in to comment.