<commit_before>.PHONY: all clean

RE2C := ../ext/re2c/re2c/re2c

SRC := \
	cli.cc \
	parser.cc \
	lexer.cc.re \
	lex-util.cc \
	value.cc \
	type.cc \
	type-array.cc \
	type-function.cc \
	type-reference.cc \
	type-scalar.cc \
	context.cc \
	type-derived.cc \
	module.cc \
	constant.cc \
	immediate.cc \
	immediate-number.cc \
	immediate-string.cc \
	aruab.cc

CCSRC := $(SRC:.cc.re=.cc)
OBJS := $(CCSRC:.cc=.o)
DEPS := $(CCSRC:.cc=.d)

CPPFLAGS := -g3 -O0 -Wall -Wextra -Werror -std=c++11 -pedantic -I../ext/xopt -I../ext/filesystem -I../ext/bsdnt

all: aruab

clean:
	rm -rf aruab
	rm -rf lexer.cc
	rm -rf $(DEPS)
	rm -rf $(OBJS)

aruab : $(OBJS)
	$(CXX) -o $@ $^ -g3 -O0 -lxopt -lbsdnt -L../ext/xopt -L../ext/bsdnt

%.o : %.cc
	$(CXX) -c -o $@ $< $(CPPFLAGS)

%.cc : %.cc.re
	$(RE2C) -s8 -W -Werror -o $@ $<

%.d : %.cc
	set -e; rm -f $@; \
	$(CXX) -M $(CPPFLAGS) $< | sed 's,\($*\)\.o[ :]*,\1.o $@ : ,g' > $@;

-include $(DEPS)
<commit_msg>append CPPFLAGS instead of overwrite them<commit_after>.PHONY: all clean

RE2C := ../ext/re2c/re2c/re2c

SRC := \
	cli.cc \
	parser.cc \
	lexer.cc.re \
	lex-util.cc \
	value.cc \
	type.cc \
	type-array.cc \
	type-function.cc \
	type-reference.cc \
	type-scalar.cc \
	context.cc \
	type-derived.cc \
	module.cc \
	constant.cc \
	immediate.cc \
	immediate-number.cc \
	immediate-string.cc \
	aruab.cc

CCSRC := $(SRC:.cc.re=.cc)
OBJS := $(CCSRC:.cc=.o)
DEPS := $(CCSRC:.cc=.d)

CPPFLAGS += -g3 -O0 -Wall -Wextra -Werror -std=c++11 -pedantic -I../ext/xopt -I../ext/filesystem -I../ext/bsdnt

all: aruab

clean:
	rm -rf aruab
	rm -rf lexer.cc
	rm -rf $(DEPS)
	rm -rf $(OBJS)

aruab : $(OBJS)
	$(CXX) -o $@ $^ -g3 -O0 -lxopt -lbsdnt -L../ext/xopt -L../ext/bsdnt

%.o : %.cc
	$(CXX) -c -o $@ $< $(CPPFLAGS)

%.cc : %.cc.re
	$(RE2C) -s8 -W -Werror -o $@ $<

%.d : %.cc
	set -e; rm -f $@; \
	$(CXX) -M $(CPPFLAGS) $< | sed 's,\($*\)\.o[ :]*,\1.o $@ : ,g' > $@;

-include $(DEPS)

{'fraction_non_alphanumeric': 0.2507836990595611, 'fraction_numerical': 0.013584117032392894, 'mean_word_length': 2.1705298013245033, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5951833', 'n_tokens_mistral': 989, 'n_tokens_neox': 933, 'n_words': 193}