xref: /freebsd/usr.bin/sort/Makefile (revision e3d5f18e56120e60390dda5c559338ef2660c41c)
1# $FreeBSD$
2
3.include <src.opts.mk>
4
5PACKAGE= runtime
6PROG=	sort
7SRCS=	bwstring.c coll.c file.c mem.c radixsort.c sort.c vsort.c
8CSTD=	c11
9
10sort.1: sort.1.in
11	sed ${MAN_SUB} ${.ALLSRC} >${.TARGET}
12
13CLEANFILES+= sort.1
14
15.if ${MK_SORT_THREADS} != "no"
16CFLAGS+= -DSORT_THREADS
17LIBADD=	pthread md
18MAN_SUB+= -e 's|%%THREADS%%||g'
19.else
20LIBADD=	md
21MAN_SUB+= -e 's|%%THREADS%%|\.\\"|g'
22.endif
23
24.if ${MK_NLS} != "no"
25NLS+=	hu_HU.ISO8859-2
26NLSSRCFILES= ${NLS:S@$@.msg@}
27MAN_SUB+= -e 's|%%NLS%%||g'
28.for lang in ${NLS}
29NLSSRCDIR_${lang}= ${.CURDIR}/nls
30.endfor
31.else
32CFLAGS+= -DWITHOUT_NLS
33MAN_SUB+= -e 's|%%NLS%%|\.\\"|g'
34.endif
35
36HAS_TESTS=
37SUBDIR.${MK_TESTS}+= tests
38
39.include <bsd.prog.mk>
40