0b3afd33639d92732242ee2ca5b2f263970679fb
[dragonfly.git] / usr.bin / cpio / Makefile
1 # $DragonFly: src/usr.bin/cpio/Makefile,v 1.2 2008/07/26 16:25:31 pavalos Exp $
2
3 PROG=   bsdcpio
4 SRCS=   cmdline.c cpio.c err.c matching.c pathmatch.c
5 DPADD=  ${LIBARCHIVE} ${LIBBZ2} ${LIBZ} ${LIBMD}
6 LDADD=  -larchive -lbz2 -lz -lmd
7 .if !defined(NO_OPENSSL)
8 DPADD+= ${LIBCRYPTO}
9 LDADD+= -lcrypto
10 .endif
11
12 CONTRIBDIR=     ${.CURDIR}/../../contrib/libarchive/cpio
13 .PATH: ${CONTRIBDIR}
14 LIBARCHIVE_VERSION!=    cat ${CONTRIBDIR}/../build/version
15 VERSION!=       echo $$((${LIBARCHIVE_VERSION} / 1000000)).$$((${LIBARCHIVE_VERSION} / 1000 % 1000)).$$((${LIBARCHIVE_VERSION} % 1000))
16 CFLAGS+=        -I${.OBJDIR} -I${.CURDIR}/../../lib/libarchive -I${CONTRIBDIR}
17 CFLAGS+=        -DPLATFORM_CONFIG_H=\"config.h\"
18 CFLAGS+=        -DBSDCPIO_VERSION_STRING=\"${VERSION}\"
19
20 SYMLINKS=       ${BINDIR}/bsdcpio ${BINDIR}/cpio
21 MLINKS= bsdcpio.1 cpio.1
22
23 .include <bsd.prog.mk>