Make ramdisk location configurable

Also, the ramdisk is now built when the memory driver is compiled.
This commit is contained in:
Dirk Vogt
2012-05-01 16:43:09 +02:00
committed by Thomas Veerman
parent 3baaafe113
commit a8f6f3ebc9
2 changed files with 18 additions and 8 deletions

View File

@@ -3,6 +3,8 @@ PROG= memory
SRCS= memory.c imgrd.mfs
OBJS= ${SRCS:N*.h:R:S/$/.o/g}
RAMDISK_PATH?= ${NETBSDSRCDIR}/drivers/ramdisk
DPADD+= ${LIBBLOCKDRIVER} ${LIBCHARDRIVER} ${LIBSYS}
LDADD+= -lblockdriver -lchardriver -lsys
@@ -25,8 +27,11 @@ touch-genfiles:
${_MKTARGET_CREATE}
${OBJCOPY} -Ibinary -B${ARCH} -Oelf32-${ARCH}-minix $< $@
imgrd.mfs:
ln -s ../ramdisk/image $@
${RAMDISK_PATH}/image: .PHONY
${MAKE} -C ${RAMDISK_PATH} image
imgrd.mfs: ${RAMDISK_PATH}/image
ln -fs ${RAMDISK_PATH}/image $@
CLEANFILES+= imgrd.mfs
.include <minix.bootprog.mk>