<commit_before>######################################################################
#  Makefile
######################################################################

include Makefile.incl
-include Makefile.tests

.SUFFIXES: .yacc .flex .cpp .hpp .adb

.yacc.cpp:
	$(YACC) -o $*.cpp --defines=$*.hpp $<

.flex.cpp:
	$(FLEX) --outfile=$*.cpp $<
#	$(FLEX) -d --outfile=$*.cpp $<

.adb:
	$(GNAT) $(GNATOPTS) $*.adb -o $* -L. -largs libadafpx.a

.cpp.o:
	$(CXX) -c -Wall -Wno-unused-function $(OPTZ) $(CSTD) $(INCL) $< -o $*.o

.c.o:
	$(CC) -c -Wall -Wno-unused-function $(OPTZ) $(INCL) $< -o $*.o

all:	main run atest

OBJS	= ansi-c-lex.o ansi-c-yacc.o pugixml.o main.o config.o utils.o comp.o \
	  macros.o types.o sect2.o btypes.o systypes.o structs.o

main:	ansi-c-lex.cpp ansi-c-yacc.cpp $(OBJS)
	$(CXX) $(OBJS) -o main
	rm -f atest atest.o *.ali b~* cglue.o

run:
	./main

atest::	libadafpx.a
	gnatmake -Wall atest.adb -o atest -largs libadafpx.a
	@echo "No you may 'make tests'"

libadafpx.a: adafpx.o
	ar r libadafpx.a adafpx.o

adafpx.c: posix.ads posix.adb
	cat cglue.c staging/*.cc >adafpx.c

adafpx.o: adafpx.c

atest.o: posix.ads posix.adb posix.o

retest:
	rm -f cglue.o atest atest.o 
	$(MAKE) -$(MAKEFLAGS) atest

clean:
	rm -f *.o *.ali core 
	rm -f t[0-9][0-9][0-9][0-9]

clobber: clean
	rm -fr ./staging adafpx.c
	rm -f b~* *.ali
	rm -f ansi-c-lex.cpp ansi-c-yacc.cpp ansi-c-yacc.hpp errs.t main core*
	rm -f posix.ads posix.adb
	rm -f Makefile.tests

ansi-c-lex.o: ansi-c-yacc.cpp ansi-c-yacc.hpp
<commit_msg>Fixed msg<commit_after>######################################################################
#  Makefile
######################################################################

include Makefile.incl
-include Makefile.tests

.SUFFIXES: .yacc .flex .cpp .hpp .adb

.yacc.cpp:
	$(YACC) -o $*.cpp --defines=$*.hpp $<

.flex.cpp:
	$(FLEX) --outfile=$*.cpp $<
#	$(FLEX) -d --outfile=$*.cpp $<

.adb:
	$(GNAT) $(GNATOPTS) $*.adb -o $* -L. -largs libadafpx.a

.cpp.o:
	$(CXX) -c -Wall -Wno-unused-function $(OPTZ) $(CSTD) $(INCL) $< -o $*.o

.c.o:
	$(CC) -c -Wall -Wno-unused-function $(OPTZ) $(INCL) $< -o $*.o

all:	main run atest

OBJS	= ansi-c-lex.o ansi-c-yacc.o pugixml.o main.o config.o utils.o comp.o \
	  macros.o types.o sect2.o btypes.o systypes.o structs.o

main:	ansi-c-lex.cpp ansi-c-yacc.cpp $(OBJS)
	$(CXX) $(OBJS) -o main
	rm -f atest atest.o *.ali b~* cglue.o

run:
	./main

atest::	libadafpx.a
	gnatmake -Wall atest.adb -o atest -largs libadafpx.a
	@echo "Apply 'make tests' to compile and run tests."

libadafpx.a: adafpx.o
	ar r libadafpx.a adafpx.o

adafpx.c: posix.ads posix.adb
	cat cglue.c staging/*.cc >adafpx.c

adafpx.o: adafpx.c

atest.o: posix.ads posix.adb posix.o

retest:
	rm -f cglue.o atest atest.o 
	$(MAKE) -$(MAKEFLAGS) atest

clean:
	rm -f *.o *.ali core 
	rm -f t[0-9][0-9][0-9][0-9]

clobber: clean
	rm -fr ./staging adafpx.c
	rm -f b~* *.ali
	rm -f ansi-c-lex.cpp ansi-c-yacc.cpp ansi-c-yacc.hpp errs.t main core*
	rm -f posix.ads posix.adb
	rm -f Makefile.tests

ansi-c-lex.o: ansi-c-yacc.cpp ansi-c-yacc.hpp

{'fraction_non_alphanumeric': 0.27107061503416857, 'fraction_numerical': 0.00585746827204686, 'mean_word_length': 3.1206434316353886, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, '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': '1125163', 'n_tokens_mistral': 1482, 'n_tokens_neox': 1435, 'n_words': 334}