<commit_before>.PHONY: crlibm crlibm-notest msys2 clean

crlibm: crlibm/crlibm_config.h
	$(MAKE) -C crlibm check install

crlibm-notest: crlibm/crlibm_config.h
	$(MAKE) -C crlibm SUBDIRS="scs_lib ." install

# Peculiarities:
# Pretend that msys2 is a BSD-type OS.
# Configure needs a working stdin, which is normally hijacked by appevyor.
# Ensure SSE2 are enabled also on 32bit builds.
msys2:
	(cd crlibm; exec 0</dev/null; CFLAGS='-DCRLIBM_TYPEOS_BSD' ./configure --prefix=$(abspath build/crlibm) --enable-sse2)
	exec 0</dev/null; $(MAKE) crlibm-notest

clean:
	-rm -rf build/ dist/ crlibm.egg-info/ crlibm.so
	$(MAKE) -C crlibm distclean

crlibm/crlibm_config.h: 
	(cd crlibm; CFLAGS='-fPIC' ./configure --prefix=$(abspath build/crlibm))
<commit_msg>Added targets to Makefile for docs and tests<commit_after>.PHONY: crlibm crlibm-notest msys2 clean

crlibm: crlibm/crlibm_config.h
	$(MAKE) -C crlibm check install

crlibm-notest: crlibm/crlibm_config.h
	$(MAKE) -C crlibm SUBDIRS="scs_lib ." install

# Peculiarities:
# Pretend that msys2 is a BSD-type OS.
# Configure needs a working stdin, which is normally hijacked by appevyor.
# Ensure SSE2 are enabled also on 32bit builds.
msys2:
	(cd crlibm; exec 0</dev/null; CFLAGS='-DCRLIBM_TYPEOS_BSD' ./configure --prefix=$(abspath build/crlibm) --enable-sse2)
	exec 0</dev/null; $(MAKE) crlibm-notest

clean:
	-rm -rf build/ dist/ crlibm.egg-info/ crlibm.so
	$(MAKE) -C crlibm distclean

crlibm/crlibm_config.h: 
	(cd crlibm; CFLAGS='-fPIC' ./configure --prefix=$(abspath build/crlibm))

docs: build/DESCRIPTION.html build/README.html

build/DESCRIPTION.html: README.rst setup.py
	./setup.py --long-description | rst2html.py > $@

build/README.html: README.rst
	rest2html < $< > $@

test:
	./setup.py test -q


{'fraction_non_alphanumeric': 0.13295454545454546, 'fraction_numerical': 0.011363636363636364, 'mean_word_length': 4.134110787172012, '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': '2686644', 'n_tokens_mistral': 760, 'n_tokens_neox': 714, 'n_words': 179}