Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 105 lines (93 sloc) 2.837 kb
1f8d743 make default TARGET to "bogus" to raise errors on all platforms.
itojun authored
1 TARGET?= bogus
81d9443 make autobuild
itojun authored
2 ARCH?= i386
514b31f bsdi4 uses GENERIC.KAME
itojun authored
3 .if ${TARGET} == "freebsd4" || ${TARGET} == "openbsd" || ${TARGET} == "netbsd" || ${TARGET} == "bsdi4"
81d9443 make autobuild
itojun authored
4 KERNCONF?= GENERIC.KAME
5 .else
6 KERNCONF?= GENERIC.v6
7 .endif
8714844 support .prepare file.
itojun authored
8
6804810 ?= for DEVELOPER
itojun authored
9 DEVELOPER?= NO
c0a2c52 non-developer should use anoncvs.kame.net (need more work for migrati…
itojun authored
10 .if ${DEVELOPER} == "YES"
11 CVSHOST= cvs.kame.net
12 .else
13 CVSHOST= anoncvs.kame.net
14 .endif
15
5bd5efb warn if the user simply typed in "make".
itojun authored
16 all:
17 @(echo '**** WARNING: Read through INSTALL and platform/INSTALL, '; \
18 echo ' and follow the steps documented'.; \
19 exit 1)
20
8714844 support .prepare file.
itojun authored
21 prepare::
d536b60 add "cd .CURDIR" to all cvs operations-what a mess!
itojun authored
22 (cd ${.CURDIR}; perl prepare.pl kame ${TARGET})
c8c621c add targets: bsdi3 and bsdi4
itojun authored
23
8806318 add clean target, which nukes symlinks.
itojun authored
24 clean::
d536b60 add "cd .CURDIR" to all cvs operations-what a mess!
itojun authored
25 (cd ${.CURDIR}; find ${TARGET} -type l -print | perl -nle unlink)
8806318 add clean target, which nukes symlinks.
itojun authored
26
c8c621c add targets: bsdi3 and bsdi4
itojun authored
27 # only for developers
28 bsdi3:
7f18c74 fix typo (in bsdi3/bsdi4 rule)
itojun authored
29 (cd ${.CURDIR}; set CVSROOT=cvs.kame.net:/cvsroot/kame-local; export CVSROOT; cvs -d cvs.kame.net:/cvsroot/kame-local co -d bsdi3 -P kame/bsdi3)
c8c621c add targets: bsdi3 and bsdi4
itojun authored
30
31 bsdi4:
7f18c74 fix typo (in bsdi3/bsdi4 rule)
itojun authored
32 (cd ${.CURDIR}; set CVSROOT=cvs.kame.net:/cvsroot/kame-local; export CVSROOT; cvs -d cvs.kame.net:/cvsroot/kame-local co -d bsdi4 -P kame/bsdi4)
273f315 "update", "update-doc" and "update-plat" targets.
itojun authored
33
7138d85 add freeebsd4 on PLAT.
sumikawa authored
34 PLAT= freebsd2 freebsd3 freebsd4 kame netbsd openbsd bsdi3 bsdi4
b418f57 share definition of DOCS between top-level Makefile and platform/Make…
itojun authored
35 # DOCS is defined in Makefile.inc
36 TOOLS= Makefile Makefile.inc prepare.pl
273f315 "update", "update-doc" and "update-plat" targets.
itojun authored
37
38 update: update-doc update-plat
39 update-doc:
b418f57 share definition of DOCS between top-level Makefile and platform/Make…
itojun authored
40 (cd ${.CURDIR}; cvs update -d -P ${DOCS} ${TOOLS})
273f315 "update", "update-doc" and "update-plat" targets.
itojun authored
41 update-plat:
d536b60 add "cd .CURDIR" to all cvs operations-what a mess!
itojun authored
42 (cd ${.CURDIR}; \
8806318 add clean target, which nukes symlinks.
itojun authored
43 for i in kame ${TARGET}; do \
659f88f "make update-plat" will update kame/kame and kame/TARGET.
itojun authored
44 if test -d $$i; then \
45 (cd $$i; cvs update -d -P); \
46 fi \
d536b60 add "cd .CURDIR" to all cvs operations-what a mess!
itojun authored
47 done)
659f88f "make update-plat" will update kame/kame and kame/TARGET.
itojun authored
48 update-all: update-doc
d536b60 add "cd .CURDIR" to all cvs operations-what a mess!
itojun authored
49 (cd ${.CURDIR}; \
8806318 add clean target, which nukes symlinks.
itojun authored
50 for i in ${PLAT}; do \
273f315 "update", "update-doc" and "update-plat" targets.
itojun authored
51 if test -d $$i; then \
52 (cd $$i; cvs update -d -P); \
53 fi \
d536b60 add "cd .CURDIR" to all cvs operations-what a mess!
itojun authored
54 done)
a5f1873 "make tree" which ease the checkout process (as well as tar.gz genera…
itojun authored
55
aee47dc top-level "Makefile.inc" is required to be checked out.
itojun authored
56 # % cvs co kame/Makefile kame/Makefile.inc
a5f1873 "make tree" which ease the checkout process (as well as tar.gz genera…
itojun authored
57 # % cd kame
58 # % make TARGET=foo tree
59 tree:
d536b60 add "cd .CURDIR" to all cvs operations-what a mess!
itojun authored
60 (cd ${.CURDIR}; \
61 $(MAKE) update-doc; \
a5f1873 "make tree" which ease the checkout process (as well as tar.gz genera…
itojun authored
62 if test $(TARGET) = bsdi3 -o $(TARGET) = bsdi4; then \
63 $(MAKE) $(TARGET); \
64 else \
65 cvs update -d -P $(TARGET); \
d536b60 add "cd .CURDIR" to all cvs operations-what a mess!
itojun authored
66 fi; \
67 cvs update -d -P kame)
b418f57 share definition of DOCS between top-level Makefile and platform/Make…
itojun authored
68
81d9443 make autobuild
itojun authored
69 # use it with caution - must be root for "make includes"
70 autobuild:
dde60d7 have uname -a at the beginning of autobuild
itojun authored
71 @uname -a
72 @echo -n '${.TARGET} started at '
73 @date
81d9443 make autobuild
itojun authored
74 (cd ${.CURDIR}; ${MAKE} clean update prepare)
75 (cd ${.CURDIR}/${TARGET}; ${MAKE} clean)
76 case ${TARGET} in \
77 bsdi*|freebsd*) \
78 (cd ${.CURDIR}/${TARGET}; ${MAKE} includes); \
79 (cd ${.CURDIR}/${TARGET}; ${MAKE} install-includes); \
80 ;; \
81 netbsd*|openbsd*) \
82 (cd ${.CURDIR}/${TARGET}; ${MAKE} includes); \
83 ;; \
84 esac
85 (cd ${.CURDIR}/${TARGET}; ${MAKE})
86 case ${TARGET} in \
87 bsdi*|freebsd*) \
1e594e6 on autobuild, nuke kernel build tree before doing anything
itojun authored
88 (cd ${.CURDIR}/${TARGET}/sys/compile; /bin/rm -fr ${KERNCONF}); \
81d9443 make autobuild
itojun authored
89 (cd ${.CURDIR}/${TARGET}/sys/${ARCH}/conf; config ${KERNCONF}); \
1e594e6 on autobuild, nuke kernel build tree before doing anything
itojun authored
90 (cd ${.CURDIR}/${TARGET}/sys/compile/${KERNCONF}; ${MAKE} depend; ${MAKE}); \
81d9443 make autobuild
itojun authored
91 ;; \
92 netbsd*|openbsd*) \
1e594e6 on autobuild, nuke kernel build tree before doing anything
itojun authored
93 (cd ${.CURDIR}/${TARGET}/sys/arch/${ARCH}/compile; /bin/rm -fr ${KERNCONF}); \
81d9443 make autobuild
itojun authored
94 (cd ${.CURDIR}/${TARGET}/sys/arch/${ARCH}/conf; config ${KERNCONF}); \
1e594e6 on autobuild, nuke kernel build tree before doing anything
itojun authored
95 (cd ${.CURDIR}/${TARGET}/sys/arch/${ARCH}/compile/${KERNCONF}; ${MAKE} depend; ${MAKE}); \
81d9443 make autobuild
itojun authored
96 ;; \
97 esac
b0cb3bc print done
itojun authored
98 @echo -n '${.TARGET} done at '
99 @date
ada26aa touch cookie file if autobuild goes okay.
itojun authored
100 .if defined(AUTOBUILD_COOKIE)
101 touch ${AUTOBUILD_COOKIE}
102 .endif
81d9443 make autobuild
itojun authored
103
b418f57 share definition of DOCS between top-level Makefile and platform/Make…
itojun authored
104 .include "Makefile.inc"
Something went wrong with that request. Please try again.