service
PROG_SERVERS=mfs procfs
PROG_USRSBIN=pwd_mkdb
-PROGRAMS=${PROG_DRIVERS} ${PROG_COMMANDS} ${PROG_SERVERS} ${PROG_USRSBIN}
+
+.if ${LDSTATIC} == "-dynamic"
+RAMDISK_DYNAMIC=1
+PROG_LIBEXEC+=ld.elf_so
+PROG_LIBS+=libc libminlib libcompat_minix libterminfo
+.endif
+
+PROGRAMS=${PROG_DRIVERS} ${PROG_COMMANDS} ${PROG_SERVERS} ${PROG_USRSBIN} ${PROG_LIBEXEC}
+
EXTRA=system.conf master.passwd rs.single
PROTO_FILES=proto.common.etc proto.common.dynamic proto.dev
CPPFLAGS+= -I${NETBSDSRCDIR}/servers
CLEANFILES += ${PROGRAMS} ${SCRIPTS} ${EXTRA} image image.c t proto.gen
CLEANFILES += ${LIBRARIES}
+CLEANFILES += ${PROG_LIBEXEC}
CLEANFILES += ${.OBJDIR}/etc/*
image: proto.gen ${EXTRA} mtab rc pwd.db spwd.db passwd
${INSTALL} $> $@
${PROGROOT}/drivers/${driver}/${driver}:
- ${MAKE} -C ${NETBSDSRCDIR}/drivers/${driver} ${driver}
+ ${MAKE} -C ${NETBSDSRCDIR}/drivers/${driver} all
.endfor
+.for lib in ${PROG_LIBS}
+PROGRAMS+=${lib}.so.0
+CLEANFILES += ${lib}.so.0
+${lib}.so.0:${PROGROOT}/lib/${lib}/${lib}.so.0
+ ${INSTALL} $> $@
+
+${PROGROOT}/lib/${lib}/${lib}.so.0:
+ ${MAKE} -C ${NETBSDSRCDIR}/lib/${lib} all
+.endfor
+
+.for libexec in ${PROG_LIBEXEC}
+${libexec}:${PROGROOT}/libexec/${libexec}/${libexec}
+ ${INSTALL} $> $@
+
+${PROGROOT}/libexec/${libexec}/${libexec}:
+ ${MAKE} -C ${NETBSDSRCDIR}/libexec/${libexec} all
+.endfor
+
+
.for cmd in ${PROG_COMMANDS}
.if ${cmd} == sh
dir.${cmd}=ash
${INSTALL} $> $@
${PROGROOT}/commands/$(dir.${cmd})/${cmd}:
- ${MAKE} -C ${NETBSDSRCDIR}/commands/${dir.${cmd}} ${cmd}
+ ${MAKE} -C ${NETBSDSRCDIR}/commands/${dir.${cmd}} all
.endfor
.for etc in ${EXTRA}
${INSTALL} $> $@
${PROGROOT}/usr.sbin/${cmd}/${cmd}:
- ${MAKE} -C ${NETBSDSRCDIR}/usr.sbin/${cmd} ${cmd}
+ ${MAKE} -C ${NETBSDSRCDIR}/usr.sbin/${cmd} all
.endfor
.for server in ${PROG_SERVERS}
${INSTALL} $> $@
${PROGROOT}/servers/${server}/${server}:
- ${MAKE} -C ${NETBSDSRCDIR}/servers/${server} ${server}
+ ${MAKE} -C ${NETBSDSRCDIR}/servers/${server} all
.endfor
etc/master.passwd: ${NETBSDSRCDIR}/etc/master.passwd
libexec d--755 0 0
- ld.elf_so ---755 0 0 /usr/libexec/ld.elf_so
+ ld.elf_so ---755 0 0 ld.elf_so
$
usr d--755 0 0
lib d--755 0 0
- libc.so.0 ---755 0 0 /usr/lib/libc.so.0
- libminlib.so.0 ---755 0 0 /usr/lib/libminlib.so.0
- libcompat_minix.so.0 ---755 0 0 /usr/lib/libcompat_minix.so.0
- libterminfo.so.0 ---755 0 0 /usr/lib/libterminfo.so.0
+ libc.so.0 ---755 0 0 libc.so.0
+ libminlib.so.0 ---755 0 0 libminlib.so.0
+ libcompat_minix.so.0 ---755 0 0 libcompat_minix.so.0
+ libterminfo.so.0 ---755 0 0 libterminfo.so.0
$
$