<commit_before>libdir=/usr/lib
sbindir=/usr/sbin
includedir=/usr/include

PACKAGE_DEPS=libsystemd
SONAME=libmapper.so
VERSION=1
LIBMAPPER=$(SONAME).$(VERSION)
BIN=mapper
INCLUDES=mapper.h

LDLIBS+=$(shell pkg-config --libs $(PACKAGE_DEPS))
ALL_CFLAGS+=$(shell pkg-config --cflags $(PACKAGE_DEPS)) -fPIC -Werror $(CFLAGS)

all: $(SONAME) $(BIN)

%.o: %.c
	$(CC) -c $(ALL_CFLAGS) -o $@ $<

$(SONAME): $(LIBMAPPER)
	ln -sf $^ $@

$(LIBMAPPER): lib%.so.$(VERSION): %.o
	$(CC) -shared $(CFLAGS) $(LDFLAGS) -Wl,-soname,$(SONAME) \
		-o $@ $^ $(LDLIBS)

$(BIN): app.o $(LIBMAPPER)
	$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^ $(LDLIBS)

install: $(SONAME) $(LIBMAPPER) $(BIN)
	@mkdir -p $(DESTDIR)$(includedir)
	install $(INCLUDES) $(DESTDIR)$(includedir)
	@mkdir -p $(DESTDIR)$(libdir)
	install $(LIBMAPPER) $(DESTDIR)$(libdir)
	ln -sf $(LIBMAPPER) $(DESTDIR)$(libdir)/$(SONAME)
	@mkdir -p $(DESTDIR)$(sbindir)
	install $(BIN) $(DESTDIR)$(sbindir)

clean:
	rm -f *.o $(LIBMAPPER) $(SONAME) $(BIN)<commit_msg>Ensure all tools are building with -Wall and -Werror<commit_after>libdir=/usr/lib
sbindir=/usr/sbin
includedir=/usr/include

PACKAGE_DEPS=libsystemd
SONAME=libmapper.so
VERSION=1
LIBMAPPER=$(SONAME).$(VERSION)
BIN=mapper
INCLUDES=mapper.h

LDLIBS+=$(shell pkg-config --libs $(PACKAGE_DEPS))
ALL_CFLAGS+=$(shell pkg-config --cflags $(PACKAGE_DEPS)) \
	-fPIC -Wall -Werror $(CFLAGS)

all: $(SONAME) $(BIN)

%.o: %.c
	$(CC) -c $(ALL_CFLAGS) -o $@ $<

$(SONAME): $(LIBMAPPER)
	ln -sf $^ $@

$(LIBMAPPER): lib%.so.$(VERSION): %.o
	$(CC) -shared $(CFLAGS) $(LDFLAGS) -Wl,-soname,$(SONAME) \
		-o $@ $^ $(LDLIBS)

$(BIN): app.o $(LIBMAPPER)
	$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^ $(LDLIBS)

install: $(SONAME) $(LIBMAPPER) $(BIN)
	@mkdir -p $(DESTDIR)$(includedir)
	install $(INCLUDES) $(DESTDIR)$(includedir)
	@mkdir -p $(DESTDIR)$(libdir)
	install $(LIBMAPPER) $(DESTDIR)$(libdir)
	ln -sf $(LIBMAPPER) $(DESTDIR)$(libdir)/$(SONAME)
	@mkdir -p $(DESTDIR)$(sbindir)
	install $(BIN) $(DESTDIR)$(sbindir)

clean:
	rm -f *.o $(LIBMAPPER) $(SONAME) $(BIN)
{'fraction_non_alphanumeric': 0.23968565815324164, 'fraction_numerical': 0.0009823182711198428, 'mean_word_length': 5.287037037037037, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, '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': '5151864', 'n_tokens_mistral': 928, 'n_tokens_neox': 879, 'n_words': 176}