freebsd-nq/usr.bin/sort/Makefile
Gabor Kovesdan c66bbc9143 Add a BSD-licensed sort rewrite that was started by me and later completed
with the major functionality and optimizations by Oleg Moskalenko.
It is compatible with the latest version of POSIX and the current GNU sort
version that we have in base.  Beside this, it implements all the
functionality introduced in later versions of GNU sort.  For now, it will
be installed as "bsdsort", keeping GNU sort as the default sort
implementation.
2012-05-11 12:37:16 +00:00

46 lines
776 B
Makefile

# $FreeBSD$
.include <bsd.own.mk>
.if ${MK_BSD_SORT} == "yes"
PROG= sort
.else
PROG= bsdsort
CLEANFILES+= bsdsort.1
bsdsort.1: sort.1
cp ${.ALLSRC} ${.TARGET}
.endif
SRCS= bwstring.c coll.c file.c mem.c radixsort.c sort.c vsort.c
WARNS= 6
sort.1: sort.1.in
/usr/bin/sed ${MAN_SUB} ${.ALLSRC} >${.TARGET}
CLEANFILES+= sort.1
.if !defined(WITHOUT_THREADS)
CFLAGS+= -DSORT_THREADS
LDFLAGS+= -lpthread -lmd
MAN_SUB+= -e 's|%%THREADS%%||g'
.else
LDFLAGS+= -lmd
MAN_SUB+= -e 's|%%THREADS%%|\.\\"|g'
.endif
.if !defined(WITHOUT_NLS)
NLS+= hu_HU.ISO8859-2
NLSSRCFILES= ${NLS:S@$@.msg@}
MAN_SUB+= -e 's|%%NLS%%||g'
.for lang in ${NLS}
NLSSRCDIR_${lang}= ${.CURDIR}/nls
.endfor
.else
CFLAGS+= -DWITHOUT_NLS
MAN_SUB+= -e 's|%%THREADS%%|\.\\"|g'
.endif
.include <bsd.prog.mk>