mirror of
				https://github.com/PabloMK7/citra.git
				synced 2025-10-31 05:40:04 +00:00 
			
		
		
		
	Installer: Converted the build scripts to cmake and added an "installer" target
This commit is contained in:
		
							parent
							
								
									d11cf9a0a5
								
							
						
					
					
						commit
						709c89a1d8
					
				
					 8 changed files with 53 additions and 78 deletions
				
			
		
							
								
								
									
										22
									
								
								dist/installer/CMakeLists.txt
									
										
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										22
									
								
								dist/installer/CMakeLists.txt
									
										
									
									
										vendored
									
									
										Normal file
									
								
							|  | @ -0,0 +1,22 @@ | |||
| 
 | ||||
| if(WIN32) | ||||
|     set(PLATFORM "windows") | ||||
| elseif(APPLE) | ||||
|     set(PLATFORM "mac") | ||||
| elseif(LINUX) | ||||
|     set(PLATFORM "linux") | ||||
| endif() | ||||
| 
 | ||||
| set(BUILD_DIR "${CMAKE_BINARY_DIR}/installer") | ||||
| set(DIST_DIR "${BUILD_DIR}/dist") | ||||
| set(TARGET_FILE "${DIST_DIR}/citra-setup-${PLATFORM}") | ||||
| 
 | ||||
| # Adds a custom target that will run the BuildInstaller.cmake file | ||||
| # CMake can't just run a cmake function as a custom command, so this is a way around it. | ||||
| # Calls the cmake command and runs a cmake file in "scripting" mode passing in variables with -D | ||||
| add_custom_command(OUTPUT "${TARGET_FILE}" | ||||
|     COMMAND ${CMAKE_COMMAND} -DSRC_DIR=${CMAKE_CURRENT_SOURCE_DIR} -D BUILD_DIR=${BUILD_DIR} -D TARGET_FILE=${TARGET_FILE} -P ${CMAKE_SOURCE_DIR}/CMakeModules/BuildInstaller.cmake | ||||
|     WORKING_DIRECTORY ${BUILD_DIR} | ||||
| ) | ||||
| 
 | ||||
| add_custom_target(installer DEPENDS ${TARGET_FILE}) | ||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue