From: Lionel Sambuc Date: Thu, 28 Feb 2013 10:06:24 +0000 (+0100) Subject: Cleanup: Remove minix.bootprog.mk X-Git-Tag: v3.3.0~1109 X-Git-Url: http://zhaoyanbai.com/repos/%22http:/www.isc.org/icons/mdoc.3.txt?a=commitdiff_plain;h=refs%2Fchanges%2F75%2F375%2F2;p=minix.git Cleanup: Remove minix.bootprog.mk The build system distinction between "bootprog" and "service" is meaningless as boot programs are standard services. As minix.service.mk simply imports minix.bootprog.mk, reduce confusion by removing minix.bootprog.mk and placing the rules in minix.service.mk. Change-Id: I4056b1e574bed59a8c890239b41b1a7c7cad63e8 --- diff --git a/distrib/sets/lists/minix/mi b/distrib/sets/lists/minix/mi index 63cbc4711..b6f4c5edb 100644 --- a/distrib/sets/lists/minix/mi +++ b/distrib/sets/lists/minix/mi @@ -3893,7 +3893,7 @@ ./usr/share/mk/bsd.sys.mk minix-sys ./usr/share/mk/bsd.test.mk minix-sys ./usr/share/mk/bsd.x11.mk minix-sys -./usr/share/mk/minix.bootprog.mk minix-sys +./usr/share/mk/minix.bootprog.mk minix-sys obsolete ./usr/share/mk/minix.gcc.mk minix-sys obsolete ./usr/share/mk/minix.gcov.mk minix-sys ./usr/share/mk/minix.service.mk minix-sys diff --git a/drivers/log/Makefile b/drivers/log/Makefile index 87e9d256d..7c197e7df 100644 --- a/drivers/log/Makefile +++ b/drivers/log/Makefile @@ -9,4 +9,4 @@ MAN= BINDIR?= /usr/sbin -.include +.include diff --git a/drivers/memory/Makefile b/drivers/memory/Makefile index ce0debae4..e8a6f5a27 100644 --- a/drivers/memory/Makefile +++ b/drivers/memory/Makefile @@ -36,4 +36,4 @@ CLEANFILES+= imgrd.mfs imgrd.mfs: ../ramdisk/image ${HOST_LN} -fs ../ramdisk/image $@ -.include +.include diff --git a/drivers/tty/Makefile b/drivers/tty/Makefile index d609aad75..6f0336eac 100644 --- a/drivers/tty/Makefile +++ b/drivers/tty/Makefile @@ -18,5 +18,5 @@ SUBDIR= keymaps # Needs kernel/const.h, etc CPPFLAGS+= -I${.CURDIR} -I${NETBSDSRCDIR} -.include +.include .include diff --git a/kernel/Makefile b/kernel/Makefile index a55dbdf28..0a1d6f7f7 100644 --- a/kernel/Makefile +++ b/kernel/Makefile @@ -24,7 +24,7 @@ CPPFLAGS+= -D__kernel__ # kernel headers are always called through kernel/*.h CPPFLAGS+= -I${NETBSDSRCDIR} -# kernel headers are always called through kernel/*.hi, this +# kernel headers are always called through kernel/*.h, this # time for generated headers, during cross compilation CPPFLAGS+= -I${.OBJDIR}/.. @@ -86,4 +86,4 @@ extracted-mtype.h: extract-mtype.sh ../include/minix/com.h ${_MKTARGET_CREATE} cd ${.CURDIR} ; ${HOST_SH} extract-mtype.sh > ${.OBJDIR}/extracted-mtype.h -.include +.include diff --git a/servers/ds/Makefile b/servers/ds/Makefile index a7449af03..c7cad6605 100644 --- a/servers/ds/Makefile +++ b/servers/ds/Makefile @@ -9,4 +9,4 @@ MAN= BINDIR?= /usr/sbin -.include +.include diff --git a/servers/mfs/Makefile b/servers/mfs/Makefile index c9fec9dc8..1371c697d 100644 --- a/servers/mfs/Makefile +++ b/servers/mfs/Makefile @@ -15,4 +15,4 @@ BINDIR?= /sbin DEFAULT_NR_BUFS= 1024 CPPFLAGS+= -DDEFAULT_NR_BUFS=${DEFAULT_NR_BUFS} -.include +.include diff --git a/servers/pfs/Makefile b/servers/pfs/Makefile index 98ec55b3f..f4b0cb699 100644 --- a/servers/pfs/Makefile +++ b/servers/pfs/Makefile @@ -13,4 +13,4 @@ MAN= BINDIR?= /usr/sbin -.include +.include diff --git a/servers/pm/Makefile b/servers/pm/Makefile index 906543213..5a64169c0 100644 --- a/servers/pm/Makefile +++ b/servers/pm/Makefile @@ -28,4 +28,4 @@ CPPFLAGS.misc.c+= -I${NETBSDSRCDIR} CPPFLAGS.schedule.c+= -I${NETBSDSRCDIR} CPPFLAGS.utility.c+= -I${NETBSDSRCDIR} -.include +.include diff --git a/servers/rs/Makefile b/servers/rs/Makefile index 7c41b2ee3..fc6804dbf 100644 --- a/servers/rs/Makefile +++ b/servers/rs/Makefile @@ -17,4 +17,4 @@ BINDIR?= /usr/sbin CPPFLAGS+= -I${NETBSDSRCDIR} -.include +.include diff --git a/servers/sched/Makefile b/servers/sched/Makefile index ebfc56cd5..72f1b2003 100644 --- a/servers/sched/Makefile +++ b/servers/sched/Makefile @@ -13,4 +13,4 @@ CPPFLAGS.main.c+= -I${NETBSDSRCDIR} CPPFLAGS.schedule.c+= -I${NETBSDSRCDIR} CPPFLAGS.utility.c+= -I${NETBSDSRCDIR} -.include +.include diff --git a/servers/vfs/Makefile b/servers/vfs/Makefile index b3a203115..083a5675c 100644 --- a/servers/vfs/Makefile +++ b/servers/vfs/Makefile @@ -22,4 +22,4 @@ MAN= BINDIR?= /usr/sbin -.include +.include diff --git a/servers/vm/Makefile b/servers/vm/Makefile index a0f416cef..db7d8c26e 100644 --- a/servers/vm/Makefile +++ b/servers/vm/Makefile @@ -22,4 +22,4 @@ CPPFLAGS+= -I${.CURDIR} -I${.CURDIR}/arch/${MACHINE_ARCH} CPPFLAGS+= -I${NETBSDSRCDIR} .include "arch/${MACHINE_ARCH}/Makefile.inc" -.include +.include diff --git a/share/mk/Makefile b/share/mk/Makefile index 2ced9842a..fc0fa6e2e 100644 --- a/share/mk/Makefile +++ b/share/mk/Makefile @@ -16,7 +16,7 @@ FILES= bsd.README bsd.clang-analyze.mk bsd.clean.mk bsd.dep.mk bsd.doc.mk \ bsd.subdir.mk bsd.sys.mk bsd.test.mk bsd.x11.mk sys.mk # MINIX-specific files -FILES+= minix.bootprog.mk minix.service.mk minix.gcov.mk +FILES+= minix.service.mk minix.gcov.mk FILESDIR=/usr/share/mk .endif diff --git a/share/mk/minix.bootprog.mk b/share/mk/minix.bootprog.mk deleted file mode 100644 index bb5bcb08c..000000000 --- a/share/mk/minix.bootprog.mk +++ /dev/null @@ -1,25 +0,0 @@ -# MINIX-specific boot program options -.include - -# LSC Static linking, order matters! -# We can't use --start-group/--end-group as they are not supported by our -# version of clang. - -# 1. No default libs -LDADD+= -nodefaultlibs - -# 2. Compiler-specific libs -.if !empty(CC:M*gcc) -.if (${MACHINE_ARCH} == "earm") -LDADD+= -lsys -.else -LDADD+= -lgcc -lsys -lgcc -.endif -.elif !empty(CC:M*clang) -LDADD+= -L/usr/pkg/compiler-rt/lib -lCompilerRT-Generic -lsys -lCompilerRT-Generic -.endif - -# 3. Minimal C library -LDADD+= -lminc - -.include diff --git a/share/mk/minix.service.mk b/share/mk/minix.service.mk index cfdf9cbc7..037fbe901 100644 --- a/share/mk/minix.service.mk +++ b/share/mk/minix.service.mk @@ -1,4 +1,21 @@ # MINIX-specific servers/drivers options .include -.include +# LSC Static linking, order matters! +# We can't use --start-group/--end-group as they are not supported by our +# version of clang. + +# 1. No default libs +LDADD+= -nodefaultlibs + +# 2. Compiler-specific libs +.if !empty(CC:M*gcc) +LDADD+= -lsys +.elif !empty(CC:M*clang) +LDADD+= -L/usr/pkg/compiler-rt/lib -lCompilerRT-Generic -lsys -lCompilerRT-Generic +.endif + +# 3. Minimal C library +LDADD+= -lminc + +.include