summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorgkostka <kostka.grzegorz@gmail.com>2013-11-11 13:36:02 +0000
committergkostka <kostka.grzegorz@gmail.com>2013-11-11 13:36:02 +0000
commit67234632535b947ed8430f8603052e6651bd1ec6 (patch)
treea2967f25bdbc0edb4f0820fb46a0056e4021746c /Makefile
parentd36c74f96ba22f58fb3ed11c19e3d6cb138e3224 (diff)
Update cmake generation setup.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile24
1 files changed, 15 insertions, 9 deletions
diff --git a/Makefile b/Makefile
index b2cfb49..a0dbfa7 100644
--- a/Makefile
+++ b/Makefile
@@ -1,28 +1,34 @@
+#Release
+#Debug
+BUILD_TYPE = Release
+
+#Check: http://www.cmake.org/Wiki/CMake_Generator_Specific_Information
+#"Unix Makefiles"
+#"Eclipse CDT4 - Unix Makefiles"
+PROJECT_SETUP = "Eclipse CDT4 - Unix Makefiles"
+
generic:
rm -R -f build_generic
mkdir build_generic
- cd build_generic && cmake -G"Unix Makefiles" ../
- cd build_generic && make
+ cd build_generic && cmake -G$(PROJECT_SETUP) -DCMAKE_BUILD_TYPE=$(BUILD_TYPE) ..
bf518:
rm -R -f build_bf518
mkdir build_bf518
- cd build_bf518 && cmake -G"Unix Makefiles" -DCMAKE_TOOLCHAIN_FILE=../toolchain/bf518.cmake ..
- cd build_bf518 && make
+ cd build_bf518 && cmake -G$(PROJECT_SETUP) -DCMAKE_BUILD_TYPE=$(BUILD_TYPE) -DCMAKE_TOOLCHAIN_FILE=../toolchain/bf518.cmake ..
cortex-m3:
rm -R -f build_cortex-m3
mkdir build_cortex-m3
- cd build_cortex-m3 && cmake -G"Unix Makefiles" -DCMAKE_TOOLCHAIN_FILE=../toolchain/cortex-m3.cmake ..
- cd build_cortex-m3 && make
+ cd build_cortex-m3 && cmake -G$(PROJECT_SETUP) -DCMAKE_BUILD_TYPE=$(BUILD_TYPE) -DCMAKE_TOOLCHAIN_FILE=../toolchain/cortex-m3.cmake ..
+
cortex-m4:
rm -R -f build_cortex-m4
mkdir build_cortex-m4
- cd build_cortex-m4 && cmake -G"Unix Makefiles" -DCMAKE_TOOLCHAIN_FILE=../toolchain/cortex-m4.cmake ..
- cd build_cortex-m4 && make
-
+ cd build_cortex-m4 && cmake -G$(PROJECT_SETUP) -DCMAKE_BUILD_TYPE=$(BUILD_TYPE) -DCMAKE_TOOLCHAIN_FILE=../toolchain/cortex-m4.cmake ..
+
all: generic bf518 cortex-m3 cortex-m4 generic