<commit_before>all: installed

BUILD_DIR = build
SOURCE_DIR = $(BUILD_DIR)/csm-git

########
## Install from git
#GIT_URL = http://github.com/AndreaCensi/csm.git
#GIT_REVISION = 23703a998fff57250322
#include $(shell rospack find mk)/git_checkout.mk
## Install from tarball
TARBALL     = build/csm-git-23703a998fff57250322.tar.gz
TARBALL_URL = https://code.ros.org/svn/release/download/thirdparty/csm-git-23703a998fff57250322.tar.gz
UNPACK_CMD  = tar zxf
MD5SUM_FILE = csm-git-23703a998fff57250322.tar.gz.md5sum
include $(shell rospack find mk)/download_unpack_build.mk
########

patch:
ifneq (,$(wildcard $(BUILD_DIR)/.patched))
	@echo Patching CSM
	cd $(SOURCE_DIR) && patch -p0 < ../../patch_a
	cd $(SOURCE_DIR) && patch -p0 < ../../patch_b
	cd $(SOURCE_DIR) && patch -p0 < ../../patch_c
	touch $(BUILD_DIR)/.patched
else
	@echo CSM previously patched, use 'make wipe' to completely remove build directory.
endif

installed: $(SOURCE_DIR)/unpacked patch
	cd $(SOURCE_DIR) && mkdir -p deploy
	cd $(SOURCE_DIR) && cmake -DCMAKE_INSTALL_PREFIX:PATH=$(CURDIR) -DCMAKE_C_FLAGS:STRING="-fPIC"
	cd $(SOURCE_DIR) && make
	cd $(SOURCE_DIR) && make install
	touch installed

clean:
	-cd $(SOURCE_DIR) && make clean
	rm -rf $(CURDIR)/lib $(CURDIR)/include $(CURDIR)/bin installed 

wipe: clean
	rm -rf $(BUILD_DIR)
<commit_msg>Install csm from git (no longer on google code)<commit_after>all: installed

BUILD_DIR = build
SOURCE_DIR = $(BUILD_DIR)/csm-git

########
## Install from git
GIT_DIR = $(SOURCE_DIR)
GIT_URL = http://github.com/AndreaCensi/csm.git
GIT_REVISION = 23703a998fff57250322
#GIT_PATCH = (patch_a patch_b patch_c)
include $(shell rospack find mk)/git_checkout.mk
## Install from tarball
#TARBALL     = build/csm-git-23703a998fff57250322.tar.gz
#TARBALL_URL = https://code.ros.org/svn/release/download/thirdparty/csm-git-23703a998fff57250322.tar.gz
#UNPACK_CMD  = tar zxf
#MD5SUM_FILE = csm-git-23703a998fff57250322.tar.gz.md5sum
#include $(shell rospack find mk)/download_unpack_build.mk
#########

patch:
ifneq (,$(wildcard $(BUILD_DIR)/.patched))
	@echo Patching CSM
	cd $(SOURCE_DIR) && patch -p0 < ../../patch_a
	cd $(SOURCE_DIR) && patch -p0 < ../../patch_b
	cd $(SOURCE_DIR) && patch -p0 < ../../patch_c
	touch $(BUILD_DIR)/.patched
else
	@echo CSM previously patched, use 'make wipe' to completely remove build directory.
endif

installed: download patch
	cd $(SOURCE_DIR) && mkdir -p deploy
	cd $(SOURCE_DIR) && cmake -DCMAKE_INSTALL_PREFIX:PATH=$(CURDIR) -DCMAKE_C_FLAGS:STRING="-fPIC"
	cd $(SOURCE_DIR) && make
	cd $(SOURCE_DIR) && make install
	touch installed

clean:
	-cd $(SOURCE_DIR) && make clean
	rm -rf $(CURDIR)/lib $(CURDIR)/include $(CURDIR)/bin installed 

wipe: clean
	rm -rf $(BUILD_DIR)

{'fraction_non_alphanumeric': 0.15466568699485672, 'fraction_numerical': 0.050698016164584865, 'mean_word_length': 4.672916666666667, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 3, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 5, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2068407', 'n_tokens_mistral': 1125, 'n_tokens_neox': 1019, 'n_words': 236}