mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 20:02:44 +00:00 
			
		
		
		
	 483c18437b
			
		
	
	
		483c18437b
		
	
	
	
	
		
			
			This prevents ccache from being invoking itself. Icecc fails to ran this way because of recursion detection.
		
			
				
	
	
		
			18 lines
		
	
	
	
		
			542 B
		
	
	
	
		
			CMake
		
	
	
	
	
	
			
		
		
	
	
			18 lines
		
	
	
	
		
			542 B
		
	
	
	
		
			CMake
		
	
	
	
	
	
| #
 | |
| # ccache setup
 | |
| #
 | |
| 
 | |
| list(APPEND COMPILERS
 | |
|     "CMAKE_C_COMPILER"
 | |
|     "CMAKE_CXX_COMPILER"
 | |
| )
 | |
| find_program(CCACHE_PROGRAM ccache)
 | |
| if(CCACHE_PROGRAM)
 | |
|     foreach(compiler ${COMPILERS})
 | |
|         get_filename_component(compiler_path "${${compiler}}" REALPATH)
 | |
|         get_filename_component(compiler_name "${compiler_path}" NAME)
 | |
|         if (NOT ${compiler_name} MATCHES "ccache")
 | |
|             set("${compiler}_LAUNCHER" "${CCACHE_PROGRAM}" CACHE FILEPATH "Path to a compiler launcher program, e.g. ccache")
 | |
|         endif()
 | |
|     endforeach()
 | |
| endif()
 |