release.sh: simplify by removing usb option
[minix3.git] / bin / pax / Makefile
blob70415cdb9bdd50b03b1687d523574a84e6404d4d
1 # $NetBSD: Makefile,v 1.39 2010/04/23 19:41:02 joerg Exp $
2 # @(#)Makefile 8.1 (Berkeley) 5/31/93
4 .include <bsd.own.mk>
6 .if defined(__MINIX)
7 WARNS=2
8 .endif
10 PROG= pax
11 SRCS= ar_io.c ar_subs.c buf_subs.c file_subs.c ftree.c\
12 gen_subs.c getoldopt.c options.c pat_rep.c pax.c sel_subs.c tables.c\
13 tar.c tty_subs.c
15 .if defined(SMALLPROG)
16 CPPFLAGS+= -DSMALL -DNO_CPIO
17 .else
18 SRCS+= getid.c spec.c misc.c pack_dev.c cpio.c
19 CPPFLAGS+= -I${NETBSDSRCDIR}/usr.sbin/mtree \
20 -I${NETBSDSRCDIR}/sbin/mknod
21 .PATH: ${NETBSDSRCDIR}/usr.sbin/mtree \
22 ${NETBSDSRCDIR}/sbin/mknod
24 .if (${HOSTPROG:U} == "")
25 DPADD+= ${LIBUTIL}
26 LDADD+= -lutil
27 .endif
28 .endif
30 MAN= pax.1 tar.1 cpio.1
32 .if defined(HOSTPROG)
33 CPPFLAGS+= -DHOSTPROG
34 .else # { ! HOSTPROG
36 # XXX: Interix does not have it; we need a conditional for it.
37 CPPFLAGS+= -DHAVE_SYS_MTIO_H
39 .if ${MKBSDTAR} == "no"
40 LINKS+= ${BINDIR}/pax ${BINDIR}/tar
41 SYMLINKS+=${BINDIR}/tar /usr/bin/tar
42 .if defined(__MINIX)
43 SYMLINKS+=${BINDIR}/tar /usr/bin/bsdtar
44 .endif
46 LINKS+= ${BINDIR}/pax ${BINDIR}/cpio
47 SYMLINKS+=${BINDIR}/cpio /usr/bin/cpio
48 .endif
49 .endif # } ! HOSTPROG
51 .if !defined(HOSTPROG) && !defined(SMALLPROG)
52 CPPFLAGS+= -DSUPPORT_RMT
54 LDADD+= -lrmt
55 DPADD+= ${LIBRMT}
56 .endif
58 .if defined(__MINIX)
59 CPPFLAGS+= -DHOSTPROG
60 CPPFLAGS+= -Dlchown=chown -Dlchmod=chmod
62 MLINKS+= pax.1 bsdtar.1
63 .endif # defined(__MINIX)
65 .include <bsd.prog.mk>