No empty .Rs/.Re
[netbsd-mini2440.git] / tools / compat / Makefile
blob1ded7c950334c6124d8f38bc06a12b1c12b1b111
1 # $NetBSD: Makefile,v 1.52 2008/10/18 16:25:04 tsutsui Exp $
3 HOSTLIB= nbcompat
5 SRCS= atoll.c basename.c dirname.c fgetln.c flock.c fparseln.c \
6 fpurge.c getmode.c getopt_long.c gettemp.c heapsort.c \
7 issetugid.c lchflags.c lchmod.c lchown.c libyywrap.c \
8 md2.c md2hl.c md4c.c md4hl.c md5c.c md5hl.c mkdtemp.c \
9 mkstemp.c pread.c putc_unlocked.c pwcache.c pwrite.c \
10 pw_scan.c \
11 raise_default_signal.c rmd160.c rmd160hl.c \
12 setenv.c setgroupent.c \
13 setpassent.c setprogname.c sha1.c sha1hl.c sha2.c \
14 sha256hl.c sha384hl.c sha512hl.c snprintf.c stat_flags.c \
15 strlcat.c strlcpy.c strmode.c strndup.c strsep.c strsuftoll.c \
16 strtoll.c unvis.c vis.c err.c errx.c verr.c verrx.c \
17 vwarn.c vwarnx.c warn.c warnx.c fts.c glob.c efun.c
19 BUILD_OSTYPE!= uname -s
21 # Disable use of pre-compiled headers on Darwin.
22 .if ${BUILD_OSTYPE} == "Darwin"
23 CPPFLAGS+= -no-cpp-precomp
24 .endif
26 # -D_FILE_OFFSET_BITS=64 produces a much more amenable `struct stat', and
27 # other file ops, on many systems, without changing function names.
29 CPPFLAGS+= -I. -I./include -I${.CURDIR} -I${.CURDIR}/sys \
30 -DHAVE_NBTOOL_CONFIG_H=1 -D_FILE_OFFSET_BITS=64
32 .PATH: ${.CURDIR}/../../lib/libc/gen \
33 ${.CURDIR}/../../lib/libc/hash \
34 ${.CURDIR}/../../lib/libc/hash/md2 \
35 ${.CURDIR}/../../lib/libc/hash/md5 \
36 ${.CURDIR}/../../lib/libc/hash/rmd160 \
37 ${.CURDIR}/../../lib/libc/hash/sha1 \
38 ${.CURDIR}/../../lib/libc/hash/sha2 \
39 ${.CURDIR}/../../lib/libc/md \
40 ${.CURDIR}/../../lib/libc/stdio \
41 ${.CURDIR}/../../lib/libc/stdlib \
42 ${.CURDIR}/../../lib/libc/string \
43 ${.CURDIR}/../../lib/libutil \
44 ${.CURDIR}/../../common/lib/libc/string \
45 ${.CURDIR}/../../common/lib/libc/hash/rmd160 \
46 ${.CURDIR}/../../common/lib/libc/hash/sha1 \
47 ${.CURDIR}/../../common/lib/libc/hash/sha2 \
48 ${.CURDIR}/../../common/lib/libc/md \
49 ${.CURDIR}/../../common/lib/libc/stdlib \
50 ${.CURDIR}/../../usr.bin/lex
52 DPSRCS+= defs.mk
53 CLEANFILES+= config.log config.status configure.lineno *.stamp
55 # Get components of Berkeley DB.
56 _CURDIR:= ${.CURDIR}
57 .CURDIR:= ${_CURDIR}/../../lib/libc
58 .include "${.CURDIR}/db/Makefile.inc"
59 .CURDIR:= ${_CURDIR}
61 SRCS:= ${SRCS:Nndbm*.c}
63 config.cache: include/.stamp configure nbtool_config.h.in defs.mk.in
64 rm -f ${.TARGET}
65 CC=${HOST_CC:Q} CFLAGS=${HOST_CFLAGS:Q} LDFLAGS=${HOST_LDFLAGS:Q} \
66 ${HOST_SH} ${.CURDIR}/configure --cache-file=config.cache
68 defs.mk: config.cache
69 @touch ${.TARGET}
71 # Run "${TOOLDIR}/bin/nbmake-${MACHINE} regen" by hand after editing
72 # configure.ac. See more detailed instructions in configure.ac.
73 regen:
74 cd ${.CURDIR} && ${TOOLDIR}/bin/${_TOOL_PREFIX}autoconf
75 cd ${.CURDIR} && ${TOOLDIR}/bin/${_TOOL_PREFIX}autoheader
77 include/.stamp:
78 mkdir -p include/sys include/machine include/rpc include/arpa
79 @touch ${.TARGET}
81 cleandir:
82 -rm -f nbtool_config.h confdefs.h defs.mk
83 -rm -r -f include
84 -rm -f config.cache
86 HOST_CPPFLAGS:= ${CPPFLAGS}
87 CPPFLAGS:= # empty
89 .include <bsd.hostlib.mk>