<commit_before>#	$Id: Makefile,v 1.7 1998/11/06 22:14:08 des Exp $

LIB=		fetch
CFLAGS+=	-I. -Wall -pedantic
.if !defined(DEBUG)
CFLAGS+=	-DNDEBUG
.endif
SRCS=		fetch.c common.c ftp.c http.c file.c fetch_err.c
DPSRCS=		ftperr.inc httperr.inc fetch_err.c fetch_err.h
MAN3=		fetch.3
CLEANFILES=	${DPSRCS}

SHLIB_MAJOR=    1
SHLIB_MINOR=	0

beforedepend: ${DPSRCS}

beforeinstall: fetch.h fetch_err.h
	${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 ${.CURDIR}/fetch.h \
		${DESTDIR}/usr/include
	${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 fetch_err.h \
		${DESTDIR}/usr/include

ftperr.inc: ftp.errors
	@echo "static struct fetcherr _ftp_errlist[] = {" > ${.TARGET}
	@cat ${.ALLSRC} \
	  | grep -v ^# \
	  | sort \
	  | while read NUM CAT STRING; do \
	    echo "    { $${NUM}, FETCH_$${CAT}, \"$${STRING}\" },"; \
	  done >> ${.TARGET}
	@echo "    { -1, FETCH_UNKNOWN, \"Unknown FTP error\" }" >> ${.TARGET}
	@echo "};" >> ${.TARGET}


httperr.inc: http.errors
	@echo "static struct fetcherr _http_errlist[] = {" > ${.TARGET}
	@cat ${.ALLSRC} \
	  | grep -v ^# \
	  | sort \
	  | while read NUM CAT STRING; do \
	    echo "    { $${NUM}, FETCH_$${CAT}, \"$${STRING}\" },"; \
	  done >> ${.TARGET}
	@echo "    { -1, FETCH_UNKNOWN, \"Unknown FTP error\" }" >> ${.TARGET}
	@echo "};" >> ${.TARGET}

fetch_err.c fetch_err.h: fetch_err.et
	compile_et ${.ALLSRC}

.include <bsd.lib.mk>

.if !exists(${DEPENDFILE})
${OBJS} ${POBJS} ${SOBJS}: ${DPSRCS}
.endif<commit_msg>Fix the "Unknown HTTP error" message. Make compile_et generate prototypes.<commit_after>#	$Id: Makefile,v 1.8 1998/11/07 08:59:38 des Exp $

LIB=		fetch
CFLAGS+=	-I. -Wall -pedantic
.if !defined(DEBUG)
CFLAGS+=	-DNDEBUG
.endif
SRCS=		fetch.c common.c ftp.c http.c file.c fetch_err.c
DPSRCS=		ftperr.inc httperr.inc fetch_err.c fetch_err.h
MAN3=		fetch.3
CLEANFILES=	${DPSRCS}

SHLIB_MAJOR=    1
SHLIB_MINOR=	0

beforedepend: ${DPSRCS}

beforeinstall: fetch.h fetch_err.h
	${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 ${.CURDIR}/fetch.h \
		${DESTDIR}/usr/include
	${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 fetch_err.h \
		${DESTDIR}/usr/include

ftperr.inc: ftp.errors
	@echo "static struct fetcherr _ftp_errlist[] = {" > ${.TARGET}
	@cat ${.ALLSRC} \
	  | grep -v ^# \
	  | sort \
	  | while read NUM CAT STRING; do \
	    echo "    { $${NUM}, FETCH_$${CAT}, \"$${STRING}\" },"; \
	  done >> ${.TARGET}
	@echo "    { -1, FETCH_UNKNOWN, \"Unknown FTP error\" }" >> ${.TARGET}
	@echo "};" >> ${.TARGET}


httperr.inc: http.errors
	@echo "static struct fetcherr _http_errlist[] = {" > ${.TARGET}
	@cat ${.ALLSRC} \
	  | grep -v ^# \
	  | sort \
	  | while read NUM CAT STRING; do \
	    echo "    { $${NUM}, FETCH_$${CAT}, \"$${STRING}\" },"; \
	  done >> ${.TARGET}
	@echo "    { -1, FETCH_UNKNOWN, \"Unknown HTTP error\" }" >> ${.TARGET}
	@echo "};" >> ${.TARGET}

fetch_err.c fetch_err.h: fetch_err.et
	compile_et -lang c ${.ALLSRC}

.include <bsd.lib.mk>

.if !exists(${DEPENDFILE})
${OBJS} ${POBJS} ${SOBJS}: ${DPSRCS}
.endif
{'fraction_non_alphanumeric': 0.21233333333333335, 'fraction_numerical': 0.018666666666666668, 'mean_word_length': 3.1279229711141676, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 33, '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': '730545', 'n_tokens_mistral': 1391, 'n_tokens_neox': 1311, 'n_words': 302}