Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/kern If RUMP_KERNEL_IS_LIBC is defined, alias the rump k...
details: https://anonhg.NetBSD.org/src/rev/361ca9c9c786
branches: trunk
changeset: 789701:361ca9c9c786
user: pooka <pooka%NetBSD.org@localhost>
date: Tue Sep 03 21:28:24 2013 +0000
description:
If RUMP_KERNEL_IS_LIBC is defined, alias the rump kernel syscalls to libc
syscall stub symbol names. This allows running standalone programs in
OS-less environments such as directly on a Xen DomU backed only by a
libc and a rump kernel.
diffstat:
sys/kern/makesyscalls.sh | 11 ++++++++++-
1 files changed, 10 insertions(+), 1 deletions(-)
diffs (39 lines):
diff -r 651bb05ca397 -r 361ca9c9c786 sys/kern/makesyscalls.sh
--- a/sys/kern/makesyscalls.sh Tue Sep 03 20:54:03 2013 +0000
+++ b/sys/kern/makesyscalls.sh Tue Sep 03 21:28:24 2013 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: makesyscalls.sh,v 1.131 2013/09/03 20:54:03 pooka Exp $
+# $NetBSD: makesyscalls.sh,v 1.132 2013/09/03 21:28:24 pooka Exp $
#
# Copyright (c) 1994, 1996, 2000 Christopher G. Demetriou
# All rights reserved.
@@ -256,6 +256,12 @@
printf "\t__weak_alias(nam,rump_enosys);\n" > rumpcalls
printf "#endif\n\n" > rumpcalls
+ printf "#ifdef RUMP_KERNEL_IS_LIBC\n" > rumpcalls
+ printf "#define rsys_aliases(what,where) \\\n" > rumpcalls
+ printf "\t__strong_alias(what,where); \\\n" > rumpcalls
+ printf "\t__strong_alias(_##what,where);\n" > rumpcalls
+ printf "#else\n#define rsys_aliases(a,b)\n#endif\n\n" > rumpcalls
+
printf "#if\tBYTE_ORDER == BIG_ENDIAN\n" > rumpcalls
printf "#define SPARG(p,k)\t((p)->k.be.datum)\n" > rumpcalls
printf "#else /* LITTLE_ENDIAN, I hope dearly */\n" > rumpcalls
@@ -869,6 +875,8 @@
printf("}\n") > rumpcalls
printf("rsys_define(rumpns_%s%s);\n", \
compatwrap_, funcname) > rumpcalls
+ printf("rsys_aliases(%s%s,rump___sysimpl_%s);\n", \
+ compatwrap_, funcalias, rumpfname) > rumpcalls
}
$2 == "STD" || $2 == "NODEF" || $2 == "NOARGS" || $2 == "INDIR" \
@@ -940,6 +948,7 @@
printf("\t\tfd[1] = retval[1];\n\t}\n") > rumpcalls
printf("\treturn error ? -1 : 0;\n}\n") > rumpcalls
printf("rsys_define(rumpns_sys_pipe);\n") > rumpcalls
+ printf "rsys_aliases(pipe,rump_sys_pipe);\n" > rumpcalls
}
# print default rump syscall interfaces
Home |
Main Index |
Thread Index |
Old Index