<commit_before>PACKAGE=	novaprova
VERSION=	0.1

prefix=		/usr/local
exec_prefix=	$(prefix)
includedir=	$(prefix)/include
libdir=		$(exec_prefix)/lib
mandir=		$(prefix)/share/man
pkgdocdir=	$(prefix)/share/doc/$(PACKAGE)
configdir=	$(libdir)/pkgconfig

CC=		g++
CXX=		g++
CDEBUGFLAGS=	-g
COPTFLAGS=	-O0
CDEFINES=	-D_GNU_SOURCE -I. \
		$(shell pkg-config --cflags libxml++-2.6)
CWARNFLAGS=	-Wall -Wextra
CFLAGS=		$(CDEBUGFLAGS) $(COPTFLAGS) $(CWARNFLAGS) $(CDEFINES)
CXXFLAGS=	$(CFLAGS)
INSTALL=	/usr/bin/install -c
RANLIB=		ranlib
depdir=		.deps

SUBDIRS_PRE=
SUBDIRS_POST=	tests

all clean distclean check install:
	@for dir in $(SUBDIRS_PRE) ; do $(MAKE) -C $$dir $@ ; done
	@$(MAKE) $@-local
	@for dir in $(SUBDIRS_POST) ; do $(MAKE) -C $$dir $@ ; done

install check: all

all-local: libnovaprova.a novaprova.pc

libnovaprova_SOURCE= \
		np.c \
		isyslog.c iassert.c icunit.c iexit.c uasserts.c \
		np/child.cxx \
		np/classifier.cxx \
		np/event.cxx \
		np/job.cxx \
		np/junit_listener.cxx \
		np/plan.cxx \
		np/proxy_listener.cxx \
		np/runner.cxx \
		np/spiegel/dwarf/abbrev.cxx \
		np/spiegel/dwarf/compile_unit.cxx \
		np/spiegel/dwarf/entry.cxx \
		np/spiegel/dwarf/enumerations.cxx \
		np/spiegel/dwarf/reference.cxx \
		np/spiegel/dwarf/state.cxx \
		np/spiegel/dwarf/string_table.cxx \
		np/spiegel/dwarf/value.cxx \
		np/spiegel/dwarf/walker.cxx \
		np/spiegel/intercept.cxx \
		np/spiegel/mapping.cxx \
		np/spiegel/platform/linux.cxx \
		np/spiegel/spiegel.cxx \
		np/testmanager.cxx \
		np/testnode.cxx \
		np/text_listener.cxx \
		np/types.cxx \
		np/util/common.cxx \
		np/util/filename.cxx \
		np/util/tok.cxx \

libnovaprova_PRIVHEADERS= \
		np/spiegel/common.hxx \
		np/spiegel/dwarf/abbrev.hxx \
		np/spiegel/dwarf/compile_unit.hxx \
		np/spiegel/dwarf/entry.hxx \
		np/spiegel/dwarf/enumerations.hxx \
		np/spiegel/dwarf/reader.hxx \
		np/spiegel/dwarf/reference.hxx \
		np/spiegel/dwarf/section.hxx \
		np/spiegel/dwarf/state.hxx \
		np/spiegel/dwarf/string_table.hxx \
		np/spiegel/dwarf/value.hxx \
		np/spiegel/dwarf/walker.hxx \
		np/spiegel/intercept.hxx \
		np/spiegel/mapping.hxx \
		np/spiegel/platform/common.hxx \
		np/spiegel/spiegel.hxx \
		np/util/common.hxx \
		np/util/filename.hxx \
		np/util/tok.hxx \
		np_priv.h \

libnovaprova_HEADERS= \
		np.h \
		np/child.hxx \
		np/classifier.hxx \
		np/event.hxx \
		np/job.hxx \
		np/junit_listener.hxx \
		np/listener.hxx \
		np/plan.hxx \
		np/proxy_listener.hxx \
		np/runner.hxx \
		np/testmanager.hxx \
		np/testnode.hxx \
		np/text_listener.hxx \
		np/types.hxx \

libnovaprova_OBJS= \
	$(patsubst %.c,%.o,$(filter %.c,$(libnovaprova_SOURCE))) \
	$(patsubst %.cxx,%.o,$(filter %.cxx,$(libnovaprova_SOURCE)))
#
# Automatic dependency tracking
libnovaprova_DFILES= \
	$(patsubst %.c,$(depdir)/%.d,$(filter %.c,$(libnovaprova_SOURCE))) \
	$(patsubst %.cxx,$(depdir)/%.d,$(filter %.cxx,$(libnovaprova_SOURCE))) \

-include $(libnovaprova_DFILES)

%.o: %.cxx
	$(COMPILE.C) -o $@ $<

$(depdir)/%.d: %.cxx
	@[ -d $(@D) ] || mkdir -p $(@D)
	$(COMPILE.C) -MM -MF $@ -MT $(patsubst %.cxx,%.o,$<) $<

$(depdir)/%.d: %.c
	@[ -d $(@D) ] || mkdir -p $(@D)
	$(COMPILE.c) -MM -MF $@ -MT $(patsubst %.c,%.o,$<) $<

libnovaprova.a: $(libnovaprova_OBJS)
	$(AR) $(ARFLAGS) libnovaprova.a $(libnovaprova_OBJS)

MARKDOWN= \
    PYTHONPATH=$(PWD)/../markdown-2.1.1/Markdown-2.1.1 \
    python -m markdown.__main__
# MARKDOWN=   python -m markdown
MDFLAGS=    -x codehilite

documentation:
	$(RM) -r doc/api-ref doc/man
	doxygen
	cd doc ;\
	    ln -s api-ref api-ref-$(VERSION) ;\
	    tar -chjvf api-ref-$(VERSION).tar.bz2 api-ref-$(VERSION) ;\
	    rm -f api-ref-$(VERSION)
	$(MARKDOWN) $(MDFLAGS) doc/get-start/index.md -f doc/get-start/index.html

install-local: documentation
	$(INSTALL) -d $(DESTDIR)$(includedir)/novaprova/np
	for hdr in $(libnovaprova_HEADERS) ; do \
	    $(INSTALL) -m 644 $$hdr $(DESTDIR)$(includedir)/novaprova/$$hdr ;\
	done
	$(INSTALL) -d $(DESTDIR)$(libdir)
	$(INSTALL) -m 644 libnovaprova.a $(DESTDIR)$(libdir)/libnovaprova.a
	$(RANLIB) $(DESTDIR)$(libdir)/libnovaprova.a
	$(INSTALL) -d $(DESTDIR)$(mandir)/man3
	$(INSTALL) doc/man/man3/*.3 $(DESTDIR)$(mandir)/man3
	$(INSTALL) -d $(DESTDIR)$(pkgdocdir)/api-ref
	$(INSTALL) doc/api-ref/* $(DESTDIR)$(pkgdocdir)/api-ref
	$(INSTALL) novaprova.pc $(DESTDIR)$(configdir)

clean-local:
	$(RM) libnovaprova.a $(libnovaprova_OBJS)

distclean-local: clean-local
	$(RM) -r doc/api-ref doc/man
	$(RM) -r $(depdir)
	$(RM) novaproca.pc

check-local:

%: %.in
	sed \<commit_msg>Split documentation: target into two<commit_after>PACKAGE=	novaprova
VERSION=	0.1

prefix=		/usr/local
exec_prefix=	$(prefix)
includedir=	$(prefix)/include
libdir=		$(exec_prefix)/lib
mandir=		$(prefix)/share/man
pkgdocdir=	$(prefix)/share/doc/$(PACKAGE)
configdir=	$(libdir)/pkgconfig

CC=		g++
CXX=		g++
CDEBUGFLAGS=	-g
COPTFLAGS=	-O0
CDEFINES=	-D_GNU_SOURCE -I. \
		$(shell pkg-config --cflags libxml++-2.6)
CWARNFLAGS=	-Wall -Wextra
CFLAGS=		$(CDEBUGFLAGS) $(COPTFLAGS) $(CWARNFLAGS) $(CDEFINES)
CXXFLAGS=	$(CFLAGS)
INSTALL=	/usr/bin/install -c
RANLIB=		ranlib
depdir=		.deps

SUBDIRS_PRE=
SUBDIRS_POST=	tests

all clean distclean check install:
	@for dir in $(SUBDIRS_PRE) ; do $(MAKE) -C $$dir $@ ; done
	@$(MAKE) $@-local
	@for dir in $(SUBDIRS_POST) ; do $(MAKE) -C $$dir $@ ; done

install check: all

all-local: libnovaprova.a novaprova.pc

libnovaprova_SOURCE= \
		np.c \
		isyslog.c iassert.c icunit.c iexit.c uasserts.c \
		np/child.cxx \
		np/classifier.cxx \
		np/event.cxx \
		np/job.cxx \
		np/junit_listener.cxx \
		np/plan.cxx \
		np/proxy_listener.cxx \
		np/runner.cxx \
		np/spiegel/dwarf/abbrev.cxx \
		np/spiegel/dwarf/compile_unit.cxx \
		np/spiegel/dwarf/entry.cxx \
		np/spiegel/dwarf/enumerations.cxx \
		np/spiegel/dwarf/reference.cxx \
		np/spiegel/dwarf/state.cxx \
		np/spiegel/dwarf/string_table.cxx \
		np/spiegel/dwarf/value.cxx \
		np/spiegel/dwarf/walker.cxx \
		np/spiegel/intercept.cxx \
		np/spiegel/mapping.cxx \
		np/spiegel/platform/linux.cxx \
		np/spiegel/spiegel.cxx \
		np/testmanager.cxx \
		np/testnode.cxx \
		np/text_listener.cxx \
		np/types.cxx \
		np/util/common.cxx \
		np/util/filename.cxx \
		np/util/tok.cxx \

libnovaprova_PRIVHEADERS= \
		np/spiegel/common.hxx \
		np/spiegel/dwarf/abbrev.hxx \
		np/spiegel/dwarf/compile_unit.hxx \
		np/spiegel/dwarf/entry.hxx \
		np/spiegel/dwarf/enumerations.hxx \
		np/spiegel/dwarf/reader.hxx \
		np/spiegel/dwarf/reference.hxx \
		np/spiegel/dwarf/section.hxx \
		np/spiegel/dwarf/state.hxx \
		np/spiegel/dwarf/string_table.hxx \
		np/spiegel/dwarf/value.hxx \
		np/spiegel/dwarf/walker.hxx \
		np/spiegel/intercept.hxx \
		np/spiegel/mapping.hxx \
		np/spiegel/platform/common.hxx \
		np/spiegel/spiegel.hxx \
		np/util/common.hxx \
		np/util/filename.hxx \
		np/util/tok.hxx \
		np_priv.h \

libnovaprova_HEADERS= \
		np.h \
		np/child.hxx \
		np/classifier.hxx \
		np/event.hxx \
		np/job.hxx \
		np/junit_listener.hxx \
		np/listener.hxx \
		np/plan.hxx \
		np/proxy_listener.hxx \
		np/runner.hxx \
		np/testmanager.hxx \
		np/testnode.hxx \
		np/text_listener.hxx \
		np/types.hxx \

libnovaprova_OBJS= \
	$(patsubst %.c,%.o,$(filter %.c,$(libnovaprova_SOURCE))) \
	$(patsubst %.cxx,%.o,$(filter %.cxx,$(libnovaprova_SOURCE)))
#
# Automatic dependency tracking
libnovaprova_DFILES= \
	$(patsubst %.c,$(depdir)/%.d,$(filter %.c,$(libnovaprova_SOURCE))) \
	$(patsubst %.cxx,$(depdir)/%.d,$(filter %.cxx,$(libnovaprova_SOURCE))) \

-include $(libnovaprova_DFILES)

%.o: %.cxx
	$(COMPILE.C) -o $@ $<

$(depdir)/%.d: %.cxx
	@[ -d $(@D) ] || mkdir -p $(@D)
	$(COMPILE.C) -MM -MF $@ -MT $(patsubst %.cxx,%.o,$<) $<

$(depdir)/%.d: %.c
	@[ -d $(@D) ] || mkdir -p $(@D)
	$(COMPILE.c) -MM -MF $@ -MT $(patsubst %.c,%.o,$<) $<

libnovaprova.a: $(libnovaprova_OBJS)
	$(AR) $(ARFLAGS) libnovaprova.a $(libnovaprova_OBJS)

MARKDOWN= \
    PYTHONPATH=$(PWD)/../markdown-2.1.1/Markdown-2.1.1 \
    python -m markdown.__main__
# MARKDOWN=   python -m markdown
MDFLAGS=    -x codehilite

documentation: doxygen markdown

doxygen:
	$(RM) -r doc/api-ref doc/man
	doxygen
	cd doc ;\
	    ln -s api-ref api-ref-$(VERSION) ;\
	    tar -chjvf api-ref-$(VERSION).tar.bz2 api-ref-$(VERSION) ;\
	    rm -f api-ref-$(VERSION)

markdown:
	$(MARKDOWN) $(MDFLAGS) doc/get-start/index.md -f doc/get-start/index.html

install-local: documentation
	$(INSTALL) -d $(DESTDIR)$(includedir)/novaprova/np
	for hdr in $(libnovaprova_HEADERS) ; do \
	    $(INSTALL) -m 644 $$hdr $(DESTDIR)$(includedir)/novaprova/$$hdr ;\
	done
	$(INSTALL) -d $(DESTDIR)$(libdir)
	$(INSTALL) -m 644 libnovaprova.a $(DESTDIR)$(libdir)/libnovaprova.a
	$(RANLIB) $(DESTDIR)$(libdir)/libnovaprova.a
	$(INSTALL) -d $(DESTDIR)$(mandir)/man3
	$(INSTALL) doc/man/man3/*.3 $(DESTDIR)$(mandir)/man3
	$(INSTALL) -d $(DESTDIR)$(pkgdocdir)/api-ref
	$(INSTALL) doc/api-ref/* $(DESTDIR)$(pkgdocdir)/api-ref
	$(INSTALL) novaprova.pc $(DESTDIR)$(configdir)

clean-local:
	$(RM) libnovaprova.a $(libnovaprova_OBJS)

distclean-local: clean-local
	$(RM) -r doc/api-ref doc/man
	$(RM) -r $(depdir)
	$(RM) novaproca.pc

check-local:

%: %.in
	sed \
{'fraction_non_alphanumeric': 0.1895698096600286, 'fraction_numerical': 0.004841016613488833, 'mean_word_length': 3.261603375527426, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 3, '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': '5838987', 'n_tokens_mistral': 4435, 'n_tokens_neox': 4167, 'n_words': 618}