mirror of
				https://github.com/lov3b/Pong.git
				synced 2025-11-03 23:00:19 +01:00 
			
		
		
		
	Prevent terminal from launching on Windows under release
This commit is contained in:
		@@ -59,6 +59,13 @@ if (ENABLE_OPTIMIZATIONS)
 | 
				
			|||||||
    set(CMAKE_FIND_LIBRARY_SUFFIXES ".a")
 | 
					    set(CMAKE_FIND_LIBRARY_SUFFIXES ".a")
 | 
				
			||||||
    set(CMAKE_EXE_LINKER_FLAGS "-static-libgcc -static-libstdc++")
 | 
					    set(CMAKE_EXE_LINKER_FLAGS "-static-libgcc -static-libstdc++")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    # Make sure that a terminal window doesn't launch under Windows.
 | 
				
			||||||
 | 
					    # We will still launch the terminal if we haven't compiled with optimizations.
 | 
				
			||||||
 | 
					    # This is useful for debugging
 | 
				
			||||||
 | 
					    if (WIN32)
 | 
				
			||||||
 | 
					        set_target_properties(Pong PROPERTIES WIN32_EXECUTABLE TRUE)
 | 
				
			||||||
 | 
					    endif ()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if (MSVC)
 | 
					    if (MSVC)
 | 
				
			||||||
        target_compile_options(Pong PRIVATE /O2)
 | 
					        target_compile_options(Pong PRIVATE /O2)
 | 
				
			||||||
    else ()
 | 
					    else ()
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user