1 # Target directory to install the rescue tools
4 # Temporary directory to stage the initrd files (e.g., /etc)
5 # NOTE: Ignore ${DESTDIR} when staging files into this directory
6 INITRD_STAGEDIR!= mktemp -d -t initrd-stage
9 rm -rf ${INITRD_STAGEDIR}
12 @${ECHO} ">>> Building and installing rescue tools ..."
13 .for _dir in bin oinit sbin sbin.libcrypto sbin.lvm
14 (cd ${.CURDIR}/${_dir}; \
15 @${ECHO} "=> ${_dir}"; \
16 make BINDIR=${RESCUE_DIR} depend all install clean cleandepend)
20 @${ECHO} ">>> Preparing initrd contents ..."
22 mkdir ${INITRD_STAGEDIR}/etc; \
23 make DESTDIR="" BINDIR=${INITRD_STAGEDIR}/etc \
25 @${ECHO} ">>> Creating initrd.img.gz ..."
26 sh ${.CURDIR}/mkinitrd.sh \
28 -r ${DESTDIR}${RESCUE_DIR} \
30 (cd ${.CURDIR}/etc; make clean cleandepend)