Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/rump Allow multiple "rumpcomp_user" source modules to be...
details: https://anonhg.NetBSD.org/src/rev/0822c13b6141
branches: trunk
changeset: 327616:0822c13b6141
user: pooka <pooka%NetBSD.org@localhost>
date: Thu Mar 13 01:34:06 2014 +0000
description:
Allow multiple "rumpcomp_user" source modules to be specified by
introducing RUMPCOMP_USER_SRCS. Make RUMPCOMP_USER issue a deprecation
warning, but for compat make it set RUMPCOMP_USER_SRCS=rumpcomp_user.c
for now.
diffstat:
sys/rump/Makefile.rump | 40 ++++++++++++++++------------
sys/rump/librump/rumpkern/Makefile.rumpkern | 4 +-
2 files changed, 25 insertions(+), 19 deletions(-)
diffs (95 lines):
diff -r e95016268955 -r 0822c13b6141 sys/rump/Makefile.rump
--- a/sys/rump/Makefile.rump Thu Mar 13 00:56:41 2014 +0000
+++ b/sys/rump/Makefile.rump Thu Mar 13 01:34:06 2014 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.rump,v 1.90 2014/03/10 22:38:53 pooka Exp $
+# $NetBSD: Makefile.rump,v 1.91 2014/03/13 01:34:06 pooka Exp $
#
WARNS?= 3 # XXX: src/sys won't compile with -Wsign-compare yet
@@ -96,30 +96,36 @@
# XXX: Warning flags are not in CWARNFLAGS. Manually add a few important ones.
-.ifdef RUMPCOMP_USER && !defined(RUMPKERN_ONLY)
+.ifdef RUMPCOMP_USER
+.warning RUMPCOMP_USER is deprecated. Use RUMPCOMP_USER_SRCS
+RUMPCOMP_USER_SRCS= rumpcomp_user.c
+.endif
+.ifdef RUMPCOMP_USER_SRCS && !defined(RUMPKERN_ONLY)
.if empty(DESTDIR)
DESTDIR=/
.endif
BUILDRUMP_CPPFLAGS ?= -isysroot ${DESTDIR}
RUMPCOMP_USER_WERROR = ${${_NOWERROR} == "no" :?-Werror:}
-rumpcomp_user.d: rumpcomp_user.c
+.for rcusrc in ${RUMPCOMP_USER_SRCS:R}
+${rcusrc}.d: ${rcusrc}.c
${_MKTARGET_CREATE}
- ${MKDEP} -f ${.TARGET} -- ${MKDEPFLAGS} ${BUILDRUMP_CPPFLAGS} ${RUMPCOMP_USER_CPPFLAGS} ${.ALLSRC:O:u:M*rumpcomp_user.c}
+ ${MKDEP} -f ${.TARGET} -- ${MKDEPFLAGS} ${BUILDRUMP_CPPFLAGS} ${RUMPCOMP_USER_CPPFLAGS} ${.ALLSRC:O:u:M*${rcusrc}.c}
-rumpcomp_user.o: rumpcomp_user.c
+${rcusrc}.o: ${rcusrc}.c
${_MKTARGET_COMPILE}
- ${CC} -o ${.TARGET} ${DBG} ${CWARNFLAGS} ${RUMPCOMP_USER_WERROR} -Wall -Wmissing-prototypes ${BUILDRUMP_CPPFLAGS} ${BUILDRUMP_CFLAGS} ${RUMPCOMP_USER_CPPFLAGS} ${RUMPCOMP_USER_CFLAGS} -c
${.ALLSRC:O:u:M*rumpcomp_user.c}
+ ${CC} -o ${.TARGET} ${DBG} ${CWARNFLAGS} ${RUMPCOMP_USER_WERROR} -Wall -Wmissing-prototypes ${BUILDRUMP_CPPFLAGS} ${BUILDRUMP_CFLAGS} ${RUMPCOMP_USER_CPPFLAGS} ${RUMPCOMP_USER_CFLAGS} -c
${.ALLSRC:O:u:M*${rcusrc}.c}
-rumpcomp_user.pico: rumpcomp_user.c
+${rcusrc}.pico: ${rcusrc}.c
${_MKTARGET_COMPILE}
- ${CC} -o ${.TARGET} -fPIC -DPIC ${DBG} ${CWARNFLAGS} ${RUMPCOMP_USER_WERROR} -Wall -Wmissing-prototypes ${BUILDRUMP_CPPFLAGS} ${BUILDRUMP_CFLAGS} ${RUMPCOMP_USER_CPPFLAGS}
${RUMPCOMP_USER_CFLAGS} -c ${.ALLSRC:O:u:M*rumpcomp_user.c}
+ ${CC} -o ${.TARGET} -fPIC -DPIC ${DBG} ${CWARNFLAGS} ${RUMPCOMP_USER_WERROR} -Wall -Wmissing-prototypes ${BUILDRUMP_CPPFLAGS} ${BUILDRUMP_CFLAGS} ${RUMPCOMP_USER_CPPFLAGS}
${RUMPCOMP_USER_CFLAGS} -c ${.ALLSRC:O:u:M*${rcusrc}.c}
-rumpcomp_user.po: rumpcomp_user.c
+${rcusrc}.po: ${rcusrc}.c
${_MKTARGET_COMPILE}
- ${CC} -o ${.TARGET} ${PROFFLAGS} -pg ${DBG} ${CWARNFLAGS} ${RUMPCOMP_USER_WERROR} -Wall -Wmissing-prototypes ${BUILDRUMP_CPPFLAGS} ${BUILDRUMP_CFLAGS} ${RUMPCOMP_USER_CPPFLAGS}
${RUMPCOMP_USER_CFLAGS} -c ${.ALLSRC:O:u:M*rumpcomp_user.c}
+ ${CC} -o ${.TARGET} ${PROFFLAGS} -pg ${DBG} ${CWARNFLAGS} ${RUMPCOMP_USER_WERROR} -Wall -Wmissing-prototypes ${BUILDRUMP_CPPFLAGS} ${BUILDRUMP_CFLAGS} ${RUMPCOMP_USER_CPPFLAGS}
${RUMPCOMP_USER_CFLAGS} -c ${.ALLSRC:O:u:M*${rcusrc}.c}
-RUMPOBJ_NORENAME+=rumpcomp_user.*o
-SRCS+=rumpcomp_user.c
+RUMPOBJ_NORENAME+=${rcusrc}.o ${rcusrc}.pico ${rcusrc}.po
+SRCS+=${rcusrc}.c
+.endfor
.endif
#
@@ -182,14 +188,14 @@
${_MKTARGET_BUILD}
rm -f ${.TARGET}
.endif
- for obj in ${RUMP_SYMREN:U${.ALLSRC:N${RUMPOBJ_NORENAME}}}; do \
- ${NM} -go $${obj} | ${TOOL_AWK} ' \
+ for renameobj in ${RUMP_SYMREN:U${.ALLSRC:C/(${RUMPOBJ_NORENAME:ts|})//g}}; do \
+ ${NM} -go $${renameobj} | ${TOOL_AWK} ' \
$$NF!~/^'${_PQ}'(rump|RUMP|__|_GLOBAL_OFFSET_TABLE'${_SYMQUIRK}')/ \
{s=$$NF;sub(/^'${_PQ}'/, "&rumpns_", s); print $$NF, s}'\
- | sort | uniq > renametab.$${obj}; \
+ | sort | uniq > renametab.$${renameobj}; \
${OBJCOPY} --preserve-dates --redefine-syms \
- renametab.$${obj} $${obj}; \
- rm -f renametab.$${obj}; \
+ renametab.$${renameobj} $${renameobj}; \
+ rm -f renametab.$${renameobj}; \
done
.if !defined(RUMP_SYMREN)
${AR} ${_ARFL} ${.TARGET} \
diff -r e95016268955 -r 0822c13b6141 sys/rump/librump/rumpkern/Makefile.rumpkern
--- a/sys/rump/librump/rumpkern/Makefile.rumpkern Thu Mar 13 00:56:41 2014 +0000
+++ b/sys/rump/librump/rumpkern/Makefile.rumpkern Thu Mar 13 01:34:06 2014 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.rumpkern,v 1.139 2014/03/10 22:38:53 pooka Exp $
+# $NetBSD: Makefile.rumpkern,v 1.140 2014/03/13 01:34:06 pooka Exp $
#
.include "${RUMPTOP}/Makefile.rump"
@@ -27,7 +27,7 @@
signals.c sleepq.c threads.c vm.c hyperentropy.c
# autogenerated into the correct namespace
-RUMPOBJ_NORENAME= rump_syscalls.*o
+RUMPOBJ_NORENAME= rump_syscalls.o rump_syscalls.pico rump_syscalls.po
.ifdef RUMP_KERNEL_IS_LIBC
CPPFLAGS+= -DRUMP_KERNEL_IS_LIBC
Home |
Main Index |
Thread Index |
Old Index