mirror of
				https://github.com/gnss-sdr/gnss-sdr
				synced 2025-10-31 07:13:03 +00:00 
			
		
		
		
	Regroup CMake options for testing
-DENABLE_UNIT_TESTING (defaults to ON): Builds unit tests -DENABLE_SYSTEM_TESTING (defaults to OFF): Builds system tests -DENABLE_SYSTEM_TESTING_EXTRA (defaults to OFF): Builds extra tools (a software-defined signal generator and GPSTk) and extra system tests -DENABLE_OWN_GPSTK (defaults to OFF): forces a local download and builds GPSTk even if it is already installed in your system. If ENABLE_SYSTEM_TESTING_EXTRA is set to ON, then ENABLE_SYSTEM_TESTING is also set to ON automatically. This commit removes the option ENABLE_SW_GENERATOR
This commit is contained in:
		| @@ -67,8 +67,13 @@ if(ENABLE_PACKAGING) | ||||
| endif(ENABLE_PACKAGING) | ||||
|  | ||||
| # Testing | ||||
| option(ENABLE_SYSTEM_TESTING "Builds system tests" OFF) | ||||
| option(ENABLE_UNIT_TESTING "Builds unit tests" ON) | ||||
| option(ENABLE_UNIT_TESTING "Build unit tests" ON) | ||||
| option(ENABLE_SYSTEM_TESTING "Build system tests" OFF) | ||||
| option(ENABLE_SYSTEM_TESTING_EXTRA "Download external tools and build extra system tests" OFF) | ||||
| if(ENABLE_SYSTEM_TESTING_EXTRA) | ||||
|     set(ENABLE_SYSTEM_TESTING ON) | ||||
| endif(ENABLE_SYSTEM_TESTING_EXTRA) | ||||
| option(ENABLE_OWN_GPSTK "Force to download, build and link GPSTk for system tests, even if it is already installed" OFF) | ||||
|  | ||||
|  | ||||
|  | ||||
|   | ||||
| @@ -136,8 +136,7 @@ endif(ENABLE_CUDA) | ||||
| ################################################################################ | ||||
| # Optional generator | ||||
| ################################################################################ | ||||
| option(ENABLE_OWN_GPSTK "Download, build and link GPSTk for system tests" OFF) | ||||
| if(ENABLE_SW_GENERATOR) | ||||
| if(ENABLE_SYSTEM_TESTING_EXTRA) | ||||
|    ExternalProject_Add( | ||||
|       gnss-sim | ||||
|       GIT_REPOSITORY https://bitbucket.org/jarribas/gnss-simulator | ||||
| @@ -186,7 +185,7 @@ if(ENABLE_SW_GENERATOR) | ||||
|        set(GPSTK_BINDIR ${GPSTK_LIBRARY}/../bin/ ) | ||||
|        add_definitions(-DGPSTK_BINDIR="${GPSTK_BINDIR}") | ||||
|    endif(NOT GPSTK_FOUND OR ENABLE_OWN_GPSTK) | ||||
| endif(ENABLE_SW_GENERATOR) | ||||
| endif(ENABLE_SYSTEM_TESTING_EXTRA) | ||||
|  | ||||
|  | ||||
| add_definitions(-DTEST_PATH="${CMAKE_SOURCE_DIR}/src/tests/") | ||||
| @@ -489,7 +488,7 @@ if(ENABLE_SYSTEM_TESTING) | ||||
|         ${CMAKE_SOURCE_DIR}/install/$<TARGET_FILE_NAME:ttff> | ||||
|     ) | ||||
|  | ||||
|     if(ENABLE_SW_GENERATOR) | ||||
|     if(ENABLE_SYSTEM_TESTING_EXTRA) | ||||
|         add_executable(obs_gps_l1_system_test ${CMAKE_CURRENT_SOURCE_DIR}/system-tests/obs_gps_l1_system_test.cc ) | ||||
|         if(NOT ${GTEST_DIR_LOCAL}) | ||||
|             add_dependencies(obs_gps_l1_system_test gtest-${gtest_RELEASE} ) | ||||
| @@ -507,5 +506,5 @@ if(ENABLE_SYSTEM_TESTING) | ||||
|                            COMMAND ${CMAKE_COMMAND} -E copy $<TARGET_FILE:obs_gps_l1_system_test> | ||||
|                                ${CMAKE_SOURCE_DIR}/install/$<TARGET_FILE_NAME:obs_gps_l1_system_test> | ||||
|         ) | ||||
|     endif(ENABLE_SW_GENERATOR) | ||||
|     endif(ENABLE_SYSTEM_TESTING_EXTRA) | ||||
| endif(ENABLE_SYSTEM_TESTING) | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Carles Fernandez
					Carles Fernandez