mirror of
				https://github.com/gnss-sdr/gnss-sdr
				synced 2025-10-31 07:13:03 +00:00 
			
		
		
		
	Check if the compiler has the <span> header
This commit is contained in:
		| @@ -92,7 +92,15 @@ else() | ||||
|     target_link_libraries(algorithms_libs PRIVATE Boost::filesystem Boost::system) | ||||
| endif() | ||||
|  | ||||
| if(NOT (CMAKE_CXX_STANDARD VERSION_LESS 20)) | ||||
| include(CheckCXXSourceCompiles) | ||||
| check_cxx_source_compiles(" | ||||
|     #include <span> | ||||
|     int main() | ||||
|     { std::span<float> sv; }" | ||||
|     has_span | ||||
| ) | ||||
|  | ||||
| if(${has_span}) | ||||
|     target_compile_definitions(algorithms_libs PUBLIC -DHAS_SPAN=1) | ||||
| else() | ||||
|     target_include_directories(algorithms_libs | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Carles Fernandez
					Carles Fernandez