Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 24 Oct 2006 12:06:41 +0200
From:      Jeremie Le Hen <jeremie@le-hen.org>
To:        Julian Elischer <julian@FreeBSD.org>
Cc:        freebsd-small@FreeBSD.org, freebsd-current@FreeBSD.org
Subject:   Handling non-standard directories in tinybsd
Message-ID:  <20061024100641.GB20405@obiwan.tataz.chchile.org>

next in thread | raw e-mail | index | archive | help

--+HP7ph2BbKc20aGI
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

Hi Julian,

(Sorry for cross-posting, but I haven't been able to make my mind.)

I've created a small patch for tinybsd that allows to add files that do not
come from the base system (I needed ${LOCALBASE}/sbin/hping).

Regards,
-- 
Jeremie Le Hen
< jeremie at le-hen dot org >< ttz at chchile dot org >

--+HP7ph2BbKc20aGI
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="tinybsd_nonstddirs.patch"

Index: tinybsd
===================================================================
RCS file: /home/ncvs/src/tools/tools/tinybsd/tinybsd,v
retrieving revision 1.4
diff -u -r1.4 tinybsd
--- tinybsd	11 Oct 2006 21:46:53 -0000	1.4
+++ tinybsd	24 Oct 2006 09:58:21 -0000
@@ -260,6 +260,15 @@
 	mtree -deU -f /etc/mtree/BSD.root.dist -p ${WORKDIR}
 	mtree -deU -f /etc/mtree/BSD.usr.dist -p ${WORKDIR}/usr
 	mtree -deU -f /etc/mtree/BSD.var.dist -p ${WORKDIR}/var
+
+	for file in `cat ${CURRENTDIR}/conf/${CONF}/tinybsd.basefiles | grep -v "#" | \
+		cut -f1 -d":" | sort | uniq` ; do
+		dir=`dirname ${file}`
+		if [ ! -d $WORKDIR/$dir ]; then
+			echo "Non-standard directory created: $dir."
+			mkdir -p $WORKDIR/$dir
+		fi
+	done
 }
 
 

--+HP7ph2BbKc20aGI--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20061024100641.GB20405>