diff options
author | Johannes Stoelp <johannes.stoelp@gmail.com> | 2023-07-02 22:33:19 +0200 |
---|---|---|
committer | Johannes Stoelp <johannes.stoelp@gmail.com> | 2023-07-02 22:33:19 +0200 |
commit | d9743696562fc85643e016d778ee994f0b9296db (patch) | |
tree | 4cf08da0eb8569e227a412a6da45d1c476ffff78 /Makefile | |
download | cpp-utils-d9743696562fc85643e016d778ee994f0b9296db.tar.gz cpp-utils-d9743696562fc85643e016d778ee994f0b9296db.zip |
add initial state of bitfield and option
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..3f0706e --- /dev/null +++ b/Makefile @@ -0,0 +1,36 @@ +TEST += bitfield +TEST += option + +# -- INTERNALS ----------------------------------------------------------------- + +BINS = $(TEST:%=build/%) +DEPS = $(TEST:%=build/%.d) + +# -- FLAGS --------------------------------------------------------------------- + +DEPS_GEN = -MMD +CXXFLAGS = -g -Wall -Wextra -Werror -I. -std=c++14 $(DEPS_GEN) + +# -- RULES --------------------------------------------------------------------- + +all: build $(BINS) + +bear: + bear intercept -- $(MAKE) all + bear citnames + +build/%: build/%.o + $(CXX) -o $@ $< + +build/%.o: test/%.cc + $(CXX) -c -o $@ $< $(CXXFLAGS) + +build: + mkdir -p build + +clean: + $(RM) -r build + $(RM) compile_commands.json events.json + +# Since DEPS files contain rules, include at the end. +-include $(DEPS) |