diff options
author | Johannes Stoelp <johannes.stoelp@gmail.com> | 2023-08-27 21:19:41 +0200 |
---|---|---|
committer | Johannes Stoelp <johannes.stoelp@gmail.com> | 2023-08-27 21:19:41 +0200 |
commit | 486d6fdd590270c925b4306096ba8bf6d69125ef (patch) | |
tree | 0435a869414ea9a9668dbd5d719cdc977d5270fd /Makefile | |
parent | f396fab26611d6107e223a6a3f41c9dff3e2ee9e (diff) | |
download | sysc-playground-486d6fdd590270c925b4306096ba8bf6d69125ef.tar.gz sysc-playground-486d6fdd590270c925b4306096ba8bf6d69125ef.zip |
make: rename build folder and use cmake cache files as make output/deps
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 18 |
1 files changed, 9 insertions, 9 deletions
@@ -6,7 +6,7 @@ export SYSTEMC_HOME := $(PWD)/INSTALL SRCS = $(wildcard src/*.cc) BINS = $(SRCS:src/%.cc=BUILD/PLAYGROUND/%) -# -- SYSTEMC UTILS ------------------------------------------------------------- +# -- SYSTEMC PLAYGROUND -------------------------------------------------------- run: build @for B in $(BINS); do \ @@ -14,11 +14,11 @@ run: build $$B; \ done -build: INSTALL/lib/libsystemc.a BUILD/UTIL $(SRCS) - ninja -C BUILD/UTIL +build: INSTALL/lib/libsystemc.a BUILD/PLAYGROUND/CMakeCache.txt $(SRCS) + ninja -C BUILD/PLAYGROUND -BUILD/UTIL: CMakeLists.txt - cmake -B $@ -S . \ +BUILD/PLAYGROUND/CMakeCache.txt: CMakeLists.txt + cmake -B BUILD/PLAYGROUND $@ -S . \ -G Ninja \ -DCMAKE_EXPORT_COMPILE_COMMANDS=1 \ -DCMAKE_BUILD_TYPE=DEBUG \ @@ -27,11 +27,11 @@ BUILD/UTIL: CMakeLists.txt # -- SYSTEMC ------------------------------------------------------------------- -INSTALL/lib/libsystemc.a: BUILD/SYSC +INSTALL/lib/libsystemc.a: BUILD/SYSC/CMakeCache.txt ninja -C BUILD/SYSC install -BUILD/SYSC: systemc - cmake -B $@ -S systemc \ +BUILD/SYSC/CMakeCache.txt: systemc + cmake -B BUILD/SYSC -S systemc \ -G Ninja \ -DCMAKE_EXPORT_COMPILE_COMMANDS=1 \ -DCMAKE_BUILD_TYPE=DEBUG \ @@ -50,7 +50,7 @@ fmt: # -- CLEAN --------------------------------------------------------------------- clean: - $(RM) -r BUILD/UTIL compile_commands.json + $(RM) -r BUILD/PLAYGROUND compile_commands.json distclean: clean $(RM) -r BUILD INSTALL systemc |