aboutsummaryrefslogtreecommitdiffstats
path: root/cmake/customconfig.gcc-default.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'cmake/customconfig.gcc-default.cmake')
-rw-r--r--cmake/customconfig.gcc-default.cmake14
1 files changed, 14 insertions, 0 deletions
diff --git a/cmake/customconfig.gcc-default.cmake b/cmake/customconfig.gcc-default.cmake
new file mode 100644
index 00000000..43294ab0
--- /dev/null
+++ b/cmake/customconfig.gcc-default.cmake
@@ -0,0 +1,14 @@
+# For normal gcc compilation, but use static-libgcc
+
+set(CMAKE_C_FLAGS "-include ${PROJECT_SOURCE_DIR}/cmake/glibc-compat-symbols.h")
+set(CMAKE_CXX_FLAGS "-include ${PROJECT_SOURCE_DIR}/cmake/glibc-compat-symbols.h")
+
+set(CMAKE_CXX_FLAGS "${CMAKE_C_FLAGS}" CACHE STRING "c++ flags")
+set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS}" CACHE STRING "c flags")
+
+set(LINKER_FLAGS "-static-libgcc")
+
+set(CMAKE_SHARED_LINKER_FLAGS "${LINKER_FLAGS}" CACHE STRING "linker flags" FORCE)
+set(CMAKE_MODULE_LINKER_FLAGS "${LINKER_FLAGS}" CACHE STRING "linker flags" FORCE)
+set(CMAKE_EXE_LINKER_FLAGS "${LINKER_FLAGS}" CACHE STRING "linker flags" FORCE)
+