adds fw builds to CMakeLists.txt
This commit is contained in:
		@@ -48,14 +48,14 @@
 | 
				
			|||||||
					<def name="CMAKE_BUILD_TYPE" type="STRING" val="${ConfigName}"/>
 | 
										<def name="CMAKE_BUILD_TYPE" type="STRING" val="${ConfigName}"/>
 | 
				
			||||||
				</defs>
 | 
									</defs>
 | 
				
			||||||
			</storageModule>
 | 
								</storageModule>
 | 
				
			||||||
			<storageModule buildDir="build/${ConfigName}" dirtyTs="1685097774834" moduleId="de.marw.cmake4eclipse.mbs.settings">
 | 
								<storageModule buildDir="build/${ConfigName}" dirtyTs="1692539890623" moduleId="de.marw.cmake4eclipse.mbs.settings">
 | 
				
			||||||
				<options/>
 | 
									<options/>
 | 
				
			||||||
				<defs>
 | 
									<defs>
 | 
				
			||||||
					<def name="CMAKE_BUILD_TYPE" type="STRING" val="Debug"/>
 | 
										<def name="CMAKE_BUILD_TYPE" type="STRING" val="Debug"/>
 | 
				
			||||||
					<def name="BUILD_SHARED_LIBS" type="BOOL" val="ON"/>
 | 
										<def name="BUILD_SHARED_LIBS" type="BOOL" val="ON"/>
 | 
				
			||||||
					<def name="CODEGEN" type="BOOL" val="OFF"/>
 | 
					 | 
				
			||||||
					<def name="CMAKE_INSTALL_PREFIX" type="FILEPATH" val="${ProjDirPath}/install"/>
 | 
										<def name="CMAKE_INSTALL_PREFIX" type="FILEPATH" val="${ProjDirPath}/install"/>
 | 
				
			||||||
					<def name="WITH_LLVM" type="BOOL" val="ON"/>
 | 
										<def name="WITH_LLVM" type="BOOL" val="ON"/>
 | 
				
			||||||
 | 
										<def name="FW_BUILD" type="BOOL" val="ON"/>
 | 
				
			||||||
				</defs>
 | 
									</defs>
 | 
				
			||||||
			</storageModule>
 | 
								</storageModule>
 | 
				
			||||||
		</cconfiguration>
 | 
							</cconfiguration>
 | 
				
			||||||
@@ -112,8 +112,8 @@
 | 
				
			|||||||
					<def name="CMAKE_BUILD_TYPE" type="STRING" val="Debug"/>
 | 
										<def name="CMAKE_BUILD_TYPE" type="STRING" val="Debug"/>
 | 
				
			||||||
					<def name="USE_CWR_SYSTEMC" type="BOOL" val="ON"/>
 | 
										<def name="USE_CWR_SYSTEMC" type="BOOL" val="ON"/>
 | 
				
			||||||
					<def name="BUILD_SHARED_LIBS" type="BOOL" val="ON"/>
 | 
										<def name="BUILD_SHARED_LIBS" type="BOOL" val="ON"/>
 | 
				
			||||||
					<def name="CODEGEN" type="BOOL" val="OFF"/>
 | 
					 | 
				
			||||||
					<def name="CMAKE_INSTALL_PREFIX" type="FILEPATH" val="${ProjDirPath}/install"/>
 | 
										<def name="CMAKE_INSTALL_PREFIX" type="FILEPATH" val="${ProjDirPath}/install"/>
 | 
				
			||||||
 | 
										<def name="FW_BUILD" type="BOOL" val="ON"/>
 | 
				
			||||||
				</defs>
 | 
									</defs>
 | 
				
			||||||
			</storageModule>
 | 
								</storageModule>
 | 
				
			||||||
		</cconfiguration>
 | 
							</cconfiguration>
 | 
				
			||||||
@@ -169,9 +169,9 @@
 | 
				
			|||||||
				<defs>
 | 
									<defs>
 | 
				
			||||||
					<def name="CMAKE_BUILD_TYPE" type="STRING" val="RelWithDebInfo"/>
 | 
										<def name="CMAKE_BUILD_TYPE" type="STRING" val="RelWithDebInfo"/>
 | 
				
			||||||
					<def name="BUILD_SHARED_LIBS" type="BOOL" val="ON"/>
 | 
										<def name="BUILD_SHARED_LIBS" type="BOOL" val="ON"/>
 | 
				
			||||||
					<def name="CODEGEN" type="BOOL" val="OFF"/>
 | 
					 | 
				
			||||||
					<def name="CMAKE_INSTALL_PREFIX" type="FILEPATH" val="${ProjDirPath}/install"/>
 | 
										<def name="CMAKE_INSTALL_PREFIX" type="FILEPATH" val="${ProjDirPath}/install"/>
 | 
				
			||||||
					<def name="WITH_TCC" type="BOOL" val="ON"/>
 | 
										<def name="WITH_TCC" type="BOOL" val="ON"/>
 | 
				
			||||||
 | 
										<def name="FW_BUILD" type="BOOL" val="ON"/>
 | 
				
			||||||
				</defs>
 | 
									</defs>
 | 
				
			||||||
			</storageModule>
 | 
								</storageModule>
 | 
				
			||||||
		</cconfiguration>
 | 
							</cconfiguration>
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -9,6 +9,7 @@ if(CMAKE_PROJECT_NAME STREQUAL "TGFS-ISS")
 | 
				
			|||||||
	# stand alone build settings
 | 
						# stand alone build settings
 | 
				
			||||||
	###########################################################################
 | 
						###########################################################################
 | 
				
			||||||
	set(CORE_NAME TGC_C CACHE STRING "The core to build the ISS for" )
 | 
						set(CORE_NAME TGC_C CACHE STRING "The core to build the ISS for" )
 | 
				
			||||||
 | 
						option(FW_BUILD "Enable the automatic download and build of some firmware to run on the ISS" OFF)
 | 
				
			||||||
	
 | 
						
 | 
				
			||||||
	set(CMAKE_CXX_STANDARD 14)
 | 
						set(CMAKE_CXX_STANDARD 14)
 | 
				
			||||||
	set(CMAKE_CXX_STANDARD_REQUIRED ON)
 | 
						set(CMAKE_CXX_STANDARD_REQUIRED ON)
 | 
				
			||||||
@@ -83,7 +84,7 @@ if(CMAKE_PROJECT_NAME STREQUAL "TGFS-ISS")
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
	if(${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
 | 
						if(${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
 | 
				
			||||||
	    list(APPEND CONAN_PACKAGE_LIST tcc/0.9.27)
 | 
						    list(APPEND CONAN_PACKAGE_LIST tcc/0.9.27)
 | 
				
			||||||
	     set(WITH_TCC ON)
 | 
							option(WITH_TCC "Build TCC backend" ON)
 | 
				
			||||||
	endif()
 | 
						endif()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	if(WITH_LLVM)
 | 
						if(WITH_LLVM)
 | 
				
			||||||
@@ -142,6 +143,20 @@ if(CMAKE_PROJECT_NAME STREQUAL "TGFS-ISS")
 | 
				
			|||||||
	if(USE_CWR_SYSTEMC)
 | 
						if(USE_CWR_SYSTEMC)
 | 
				
			||||||
		include(SystemCPackage)
 | 
							include(SystemCPackage)
 | 
				
			||||||
	endif()
 | 
						endif()
 | 
				
			||||||
 | 
						if(FW_BUILD)
 | 
				
			||||||
 | 
							include(FetchContent)
 | 
				
			||||||
 | 
							set(FETCHCONTENT_BASE_DIR ${CMAKE_CURRENT_BINARY_DIR}/..)
 | 
				
			||||||
 | 
							FetchContent_Declare(
 | 
				
			||||||
 | 
							  	riscvfw
 | 
				
			||||||
 | 
							  	GIT_REPOSITORY https://git.minres.com/VP/Firmwares.git
 | 
				
			||||||
 | 
							  	GIT_TAG        main
 | 
				
			||||||
 | 
							)
 | 
				
			||||||
 | 
							FetchContent_GetProperties(riscvfw)
 | 
				
			||||||
 | 
							if(NOT riscvfw_POPULATED)
 | 
				
			||||||
 | 
							  	FetchContent_Populate(riscvfw)
 | 
				
			||||||
 | 
							  	add_subdirectory(${riscvfw_SOURCE_DIR})
 | 
				
			||||||
 | 
							endif()
 | 
				
			||||||
 | 
						endif()
 | 
				
			||||||
endif()
 | 
					endif()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
add_subdirectory(dbt-rise-core)
 | 
					add_subdirectory(dbt-rise-core)
 | 
				
			||||||
@@ -151,4 +166,5 @@ if(IS_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/dbt-rise-plugins)
 | 
				
			|||||||
	add_subdirectory(dbt-rise-plugins)
 | 
						add_subdirectory(dbt-rise-plugins)
 | 
				
			||||||
endif()
 | 
					endif()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
include(CTest)
 | 
					include(CTest)
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user