aboutsummaryrefslogtreecommitdiffstats
path: root/cmake/toolchain.gcc-armv6.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'cmake/toolchain.gcc-armv6.cmake')
-rw-r--r--cmake/toolchain.gcc-armv6.cmake13
1 files changed, 13 insertions, 0 deletions
diff --git a/cmake/toolchain.gcc-armv6.cmake b/cmake/toolchain.gcc-armv6.cmake
new file mode 100644
index 00000000..f09eae27
--- /dev/null
+++ b/cmake/toolchain.gcc-armv6.cmake
@@ -0,0 +1,13 @@
+# For normal gcc compilation, but use static-libgcc
+
+set(CMAKE_C_FLAGS "-fpic -march=armv5te -marm -mfloat-abi=softfp -include ${CMAKE_MODULE_PATH}/glibc-compat-symbols.h -I/usr/include")
+
+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 "-fpic -march=armv5te -marm -mfloat-abi=softfp -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)
+