summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBond_009 <bond.009@outlook.com>2020-12-20 16:53:46 +0100
committerBond_009 <bond.009@outlook.com>2020-12-20 16:53:46 +0100
commit2ae23e1479e35815b51f6e155f61d97e137399a9 (patch)
tree14dcd8c841032ea6ae7a6245803d32bf9d6f1ea3
parent68f415926d8ef16b571b6be9692447e82efd101d (diff)
Add build configsHEADmaster
-rw-r--r--CMakeLists.txt10
1 files changed, 9 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5d92253..34c9fb7 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1,11 +1,19 @@
cmake_minimum_required(VERSION 3.1)
project(ifo_dump LANGUAGES C VERSION 1.0.0 DESCRIPTION "ifo_dump")
+if(NOT CMAKE_BUILD_TYPE)
+ set(CMAKE_BUILD_TYPE Release)
+endif()
+
+set(CMAKE_C_FLAGS "-std=c89 -Wall -Wextra -Wstrict-aliasing -pedantic -fstrict-aliasing")
+set(CMAKE_C_FLAGS_DEBUG "-g")
+set(CMAKE_C_FLAGS_RELEASE "-O3 -flto -s")
+
set(SOURCES ifo_dump.c)
# Add the executable
add_executable(ifo_dump ${SOURCES})
-target_compile_options(ifo_dump PUBLIC -std=c89 -Wall -Wextra -Wstrict-aliasing -pedantic -fstrict-aliasing)
+target_compile_options(ifo_dump PUBLIC)
# Include libdvdread
target_link_libraries(ifo_dump dvdread)