From owner-freebsd-small@FreeBSD.ORG Sun Oct 22 09:09:42 2006 Return-Path: X-Original-To: freebsd-small@freebsd.org Delivered-To: freebsd-small@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 72AF116A403 for ; Sun, 22 Oct 2006 09:09:42 +0000 (UTC) (envelope-from eugen@kuzbass.ru) Received: from www.svzserv.kemerovo.su (www.svzserv.kemerovo.su [213.184.65.80]) by mx1.FreeBSD.org (Postfix) with ESMTP id 847F343D49 for ; Sun, 22 Oct 2006 09:09:39 +0000 (GMT) (envelope-from eugen@kuzbass.ru) Received: from kuzbass.ru (kost [213.184.65.82]) by www.svzserv.kemerovo.su (8.13.8/8.13.8) with ESMTP id k9M99SZx005212; Sun, 22 Oct 2006 17:09:28 +0800 (KRAST) (envelope-from eugen@kuzbass.ru) Message-ID: <453B358E.AD803C2A@kuzbass.ru> Date: Sun, 22 Oct 2006 17:10:38 +0800 From: Eugene Grosbein Organization: SVZServ X-Mailer: Mozilla 4.8 [en] (Windows NT 5.0; U) X-Accept-Language: ru,en MIME-Version: 1.0 To: Philippe Lang References: <6C0CF58A187DA5479245E0830AF84F421D1234@poweredge.attiksystem.ch> Content-Type: text/plain; charset=koi8-r Content-Transfer-Encoding: 7bit Cc: freebsd-small@freebsd.org Subject: Re: Nanobsd & CF geometry X-BeenThere: freebsd-small@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 22 Oct 2006 09:09:42 -0000 Philippe Lang wrote: > > Hi, > > I'm trying to flash Nanobsd on a Compact Flash which is not listed in /usr/src/tools/tools/nanobsd/FlashDevice.sub. > > Does anyone know how to calculate NANO_MEDIASIZE, NANO_HEADS and NANO_SECTS for a specific CF, in my case a Transcend 512 MB CF? man diskinfo From owner-freebsd-small@FreeBSD.ORG Tue Oct 24 10:05:59 2006 Return-Path: X-Original-To: freebsd-small@FreeBSD.org Delivered-To: freebsd-small@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4954E16A407; Tue, 24 Oct 2006 10:05:59 +0000 (UTC) (envelope-from tataz@tataz.chchile.org) Received: from smtp5-g19.free.fr (smtp5-g19.free.fr [212.27.42.35]) by mx1.FreeBSD.org (Postfix) with ESMTP id CC60743D5A; Tue, 24 Oct 2006 10:05:58 +0000 (GMT) (envelope-from tataz@tataz.chchile.org) Received: from tatooine.tataz.chchile.org (tataz.chchile.org [82.233.239.98]) by smtp5-g19.free.fr (Postfix) with ESMTP id 023DF27642; Tue, 24 Oct 2006 12:05:58 +0200 (CEST) Received: from obiwan.tataz.chchile.org (unknown [192.168.1.25]) by tatooine.tataz.chchile.org (Postfix) with ESMTP id A16999E6C2; Tue, 24 Oct 2006 10:06:41 +0000 (UTC) Received: by obiwan.tataz.chchile.org (Postfix, from userid 1000) id 841B0405B; Tue, 24 Oct 2006 12:06:41 +0200 (CEST) Date: Tue, 24 Oct 2006 12:06:41 +0200 From: Jeremie Le Hen To: Julian Elischer Message-ID: <20061024100641.GB20405@obiwan.tataz.chchile.org> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="+HP7ph2BbKc20aGI" Content-Disposition: inline User-Agent: Mutt/1.5.13 (2006-08-11) Cc: freebsd-small@FreeBSD.org, freebsd-current@FreeBSD.org Subject: Handling non-standard directories in tinybsd X-BeenThere: freebsd-small@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 24 Oct 2006 10:05:59 -0000 --+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-- From owner-freebsd-small@FreeBSD.ORG Tue Oct 24 11:18:39 2006 Return-Path: X-Original-To: freebsd-small@FreeBSD.org Delivered-To: freebsd-small@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4F0CB16A407 for ; Tue, 24 Oct 2006 11:18:39 +0000 (UTC) (envelope-from jmelo@freebsdbrasil.com.br) Received: from capeta.freebsdbrasil.com.br (vrrp.freebsdbrasil.com.br [200.210.70.30]) by mx1.FreeBSD.org (Postfix) with SMTP id ED7E643D45 for ; Tue, 24 Oct 2006 11:18:37 +0000 (GMT) (envelope-from jmelo@freebsdbrasil.com.br) Received: (qmail 9825 invoked by uid 0); 24 Oct 2006 09:18:53 -0200 Received: from jmelo@freebsdbrasil.com.br by capeta.freebsdbrasil.com.br by uid 82 with qmail-scanner-1.22 (spamassassin: 2.64. Clear:RC:1(201.17.149.10):. Processed in 0.523897 secs); 24 Oct 2006 11:18:53 -0000 Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=capeta; d=freebsdbrasil.com.br; b=dfLYPJUw408H17//GyaLPDECXWa9QgxFHrzB4T19No9axdm3XfLQwVp/elLbggZZQscY7amwnUW/Dg+fJmsnUdLC47Yghh1cZcui5qhIYEepffVq0ZKkJh+x6r1YLVSG ; Received: from unknown (HELO ?10.69.69.66?) (jmelo@201.17.149.10) by capeta.freebsdbrasil.com.br with SMTP; 24 Oct 2006 09:18:52 -0200 Message-ID: <453DE863.7070305@freebsdbrasil.com.br> Date: Tue, 24 Oct 2006 08:18:11 -0200 From: Jean Milanez Melo User-Agent: Thunderbird 1.5.0.7 (Macintosh/20060909) MIME-Version: 1.0 To: Jeremie Le Hen References: <20061024100641.GB20405@obiwan.tataz.chchile.org> In-Reply-To: <20061024100641.GB20405@obiwan.tataz.chchile.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-current@FreeBSD.org, freebsd-small@FreeBSD.org, Julian Elischer Subject: Re: Handling non-standard directories in tinybsd X-BeenThere: freebsd-small@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 24 Oct 2006 11:18:39 -0000 Jeremie Le Hen wrote: > 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, > > > ------------------------------------------------------------------------ > > 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 > } > > > > > ------------------------------------------------------------------------ > > _______________________________________________ > freebsd-current@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-current > To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org" Maybe it's not the better way to do this. I'm thinking a way to add third applications on tinybsd, so when this feature is done the directories will be automatically created. Thanks Jean From owner-freebsd-small@FreeBSD.ORG Tue Oct 24 11:56:42 2006 Return-Path: X-Original-To: freebsd-small@FreeBSD.org Delivered-To: freebsd-small@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1741A16A412; Tue, 24 Oct 2006 11:56:42 +0000 (UTC) (envelope-from tataz@tataz.chchile.org) Received: from smtp3-g19.free.fr (smtp3-g19.free.fr [212.27.42.29]) by mx1.FreeBSD.org (Postfix) with ESMTP id 875AE43D69; Tue, 24 Oct 2006 11:56:41 +0000 (GMT) (envelope-from tataz@tataz.chchile.org) Received: from tatooine.tataz.chchile.org (tataz.chchile.org [82.233.239.98]) by smtp3-g19.free.fr (Postfix) with ESMTP id 5C9608ADA; Tue, 24 Oct 2006 13:56:40 +0200 (CEST) Received: from obiwan.tataz.chchile.org (unknown [192.168.1.25]) by tatooine.tataz.chchile.org (Postfix) with ESMTP id 94A099E6C2; Tue, 24 Oct 2006 11:57:27 +0000 (UTC) Received: by obiwan.tataz.chchile.org (Postfix, from userid 1000) id 81D2F405D; Tue, 24 Oct 2006 13:57:27 +0200 (CEST) Date: Tue, 24 Oct 2006 13:57:27 +0200 From: Jeremie Le Hen To: Jean Milanez Melo Message-ID: <20061024115727.GD20405@obiwan.tataz.chchile.org> References: <20061024100641.GB20405@obiwan.tataz.chchile.org> <453DE863.7070305@freebsdbrasil.com.br> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <453DE863.7070305@freebsdbrasil.com.br> User-Agent: Mutt/1.5.13 (2006-08-11) Cc: freebsd-small@FreeBSD.org, freebsd-current@FreeBSD.org, Julian Elischer Subject: Re: Handling non-standard directories in tinybsd X-BeenThere: freebsd-small@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 24 Oct 2006 11:56:42 -0000 Hi Jean, On Tue, Oct 24, 2006 at 08:18:11AM -0200, Jean Milanez Melo wrote: > Maybe it's not the better way to do this. I'm thinking a way to add > third applications on tinybsd, so when this feature is done the > directories will be automatically created. Actually I tried to make it straightforward, in the manner of the whole script. I daresay it is quite pleasant to have a simple script without too much magic in it, it is far more quicker to apprehend. What are you thinking about for inclusion of third-party apps on tinybsd ? I hope it won't bloat too much the code. Are you already expecting to provide it soon ? Thank you for your work, it is greatly appreciated. Best regards, -- Jeremie Le Hen < jeremie at le-hen dot org >< ttz at chchile dot org > From owner-freebsd-small@FreeBSD.ORG Tue Oct 24 12:38:46 2006 Return-Path: X-Original-To: freebsd-small@FreeBSD.org Delivered-To: freebsd-small@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 13E7816A403; Tue, 24 Oct 2006 12:38:46 +0000 (UTC) (envelope-from tataz@tataz.chchile.org) Received: from smtp3-g19.free.fr (smtp3-g19.free.fr [212.27.42.29]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5E7A243D6D; Tue, 24 Oct 2006 12:38:45 +0000 (GMT) (envelope-from tataz@tataz.chchile.org) Received: from tatooine.tataz.chchile.org (tataz.chchile.org [82.233.239.98]) by smtp3-g19.free.fr (Postfix) with ESMTP id AC72E4859A; Tue, 24 Oct 2006 14:38:44 +0200 (CEST) Received: from obiwan.tataz.chchile.org (unknown [192.168.1.25]) by tatooine.tataz.chchile.org (Postfix) with ESMTP id 9FD169E6C5; Tue, 24 Oct 2006 12:39:31 +0000 (UTC) Received: by obiwan.tataz.chchile.org (Postfix, from userid 1000) id 8CE71405D; Tue, 24 Oct 2006 14:39:31 +0200 (CEST) Date: Tue, 24 Oct 2006 14:39:31 +0200 From: Jeremie Le Hen To: Julian Elischer , Jean Milanez Melo Message-ID: <20061024123931.GF20405@obiwan.tataz.chchile.org> References: <20061024100641.GB20405@obiwan.tataz.chchile.org> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="0ntfKIWw70PvrIHh" Content-Disposition: inline In-Reply-To: <20061024100641.GB20405@obiwan.tataz.chchile.org> User-Agent: Mutt/1.5.13 (2006-08-11) Cc: freebsd-current@FreeBSD.org, freebsd-small@FreeBSD.org Subject: Re: Handling non-standard directories in tinybsd X-BeenThere: freebsd-small@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 24 Oct 2006 12:38:46 -0000 --0ntfKIWw70PvrIHh Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hi, this next patch knows how to handle image file specified with an absolute path. Moreover if the creation of the final image has failed, the temporary "vnode file" is left for the user. Regards, -- Jeremie Le Hen < jeremie at le-hen dot org >< ttz at chchile dot org > --0ntfKIWw70PvrIHh Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="tinybsd_absolutepath.patch" Index: tinybsd =================================================================== RCS file: /home/ncvs/src/tools/tools/tinybsd/tinybsd,v retrieving revision 1.4 diff -u -p -r1.4 tinybsd --- tinybsd 11 Oct 2006 21:46:53 -0000 1.4 +++ tinybsd 24 Oct 2006 12:34:19 -0000 @@ -422,17 +431,29 @@ create_image() { sleep 1 umount ${IMGMNT} - dd if=/dev/${MD} of=${CURRENTDIR}/${IMG} bs=64k + case ${IMG} in + /*) dd if=/dev/${MD} of=${IMG} bs=64k ;; + *) dd if=/dev/${MD} of=${CURRENTDIR}/${IMG} bs=64k ;; + esac + DD_RET=$? - rm -vf ${VNODEFILE} rm -rvf ${IMGMNT} mdconfig -d -u ${MD} - echo "" - echo "${TS} Done!" - echo "${TS} Your configuration options were saved in ${FULLFILENAME}" - echo "${TS} You can see your build log in ${HOME}/tinybsd.log" - echo "${TS} Your final image is in ${CURRENTDIR}/${IMG}" - echo "${TS} Now use dd(1) to write it." + + if [ $DD_RET -eq 0 ]; then + rm -vf ${VNODEFILE} + echo "" + echo "${TS} Done!" + echo "${TS} Your configuration options were saved in ${FULLFILENAME}" + echo "${TS} You can see your build log in ${HOME}/tinybsd.log" + echo "${TS} Your final image is in ${CURRENTDIR}/${IMG}" + echo "${TS} Now use dd(1) to write it." + else + echo "" >&2 + echo "${TS} Failed to create ${CURRENTDIR}/${IMG}!" >&2 + echo "${TS} You can see your build log in ${HOME}/tinybsd.log" >&2 + echo "${TS} The temporary image is still in ${VNODEFILE}" >&2 + fi } --0ntfKIWw70PvrIHh-- From owner-freebsd-small@FreeBSD.ORG Tue Oct 24 15:15:17 2006 Return-Path: X-Original-To: freebsd-small@FreeBSD.org Delivered-To: freebsd-small@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 80E5716A4D0 for ; Tue, 24 Oct 2006 15:15:17 +0000 (UTC) (envelope-from jmelo@freebsdbrasil.com.br) Received: from capeta.freebsdbrasil.com.br (vrrp.freebsdbrasil.com.br [200.210.70.30]) by mx1.FreeBSD.org (Postfix) with SMTP id B3CBE43DF9 for ; Tue, 24 Oct 2006 15:14:51 +0000 (GMT) (envelope-from jmelo@freebsdbrasil.com.br) Received: (qmail 25503 invoked by uid 0); 24 Oct 2006 13:15:01 -0200 Received: from jmelo@freebsdbrasil.com.br by capeta.freebsdbrasil.com.br by uid 82 with qmail-scanner-1.22 (spamassassin: 2.64. Clear:RC:1(201.17.149.10):. Processed in 0.5198 secs); 24 Oct 2006 15:15:01 -0000 Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=capeta; d=freebsdbrasil.com.br; b=cFLmhq916G52Ce42WIw5F7cimWZ+JA5tsQfQwEUvOPmrKs5v54S3PNWHgmbiEFDbrbQlJWpseXTXFfMYJcm352QQ57NFVEc7I9T4m0Aft0XC/rXU7HR3px3eklmKPHo2 ; Received: from unknown (HELO ?10.69.69.66?) (jmelo@201.17.149.10) by capeta.freebsdbrasil.com.br with SMTP; 24 Oct 2006 13:15:01 -0200 Message-ID: <453E1FBC.5060700@freebsdbrasil.com.br> Date: Tue, 24 Oct 2006 12:14:20 -0200 From: Jean Milanez Melo User-Agent: Thunderbird 1.5.0.7 (Macintosh/20060909) MIME-Version: 1.0 To: Jeremie Le Hen References: <20061024100641.GB20405@obiwan.tataz.chchile.org> <453DE863.7070305@freebsdbrasil.com.br> <20061024115727.GD20405@obiwan.tataz.chchile.org> In-Reply-To: <20061024115727.GD20405@obiwan.tataz.chchile.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-current@FreeBSD.org, freebsd-small@FreeBSD.org, Julian Elischer Subject: Re: Handling non-standard directories in tinybsd X-BeenThere: freebsd-small@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 24 Oct 2006 15:15:17 -0000 Jeremie Le Hen wrote: > > What are you thinking about for inclusion of third-party apps on > tinybsd ? I hope it won't bloat too much the code. > Are you already expecting to provide it soon ? > I would like to use pkg_add. Maybe a file called tinybsd.apps and the users should add in this file what port name they want to install, so it'll copy binaries installation to workdir. Suggestions? Jean From owner-freebsd-small@FreeBSD.ORG Wed Oct 25 10:42:27 2006 Return-Path: X-Original-To: freebsd-small@FreeBSD.org Delivered-To: freebsd-small@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5066716A403; Wed, 25 Oct 2006 10:42:27 +0000 (UTC) (envelope-from tataz@tataz.chchile.org) Received: from smtp5-g19.free.fr (smtp5-g19.free.fr [212.27.42.35]) by mx1.FreeBSD.org (Postfix) with ESMTP id 65EBD43D5E; Wed, 25 Oct 2006 10:42:26 +0000 (GMT) (envelope-from tataz@tataz.chchile.org) Received: from tatooine.tataz.chchile.org (tataz.chchile.org [82.233.239.98]) by smtp5-g19.free.fr (Postfix) with ESMTP id 3E9C727A27; Wed, 25 Oct 2006 12:42:25 +0200 (CEST) Received: from obiwan.tataz.chchile.org (unknown [192.168.1.25]) by tatooine.tataz.chchile.org (Postfix) with ESMTP id 7BBEA9E6C2; Wed, 25 Oct 2006 10:43:06 +0000 (UTC) Received: by obiwan.tataz.chchile.org (Postfix, from userid 1000) id 56850405B; Wed, 25 Oct 2006 12:43:06 +0200 (CEST) Date: Wed, 25 Oct 2006 12:43:06 +0200 From: Jeremie Le Hen To: Jean Milanez Melo Message-ID: <20061025104306.GI20405@obiwan.tataz.chchile.org> References: <20061024100641.GB20405@obiwan.tataz.chchile.org> <453DE863.7070305@freebsdbrasil.com.br> <20061024115727.GD20405@obiwan.tataz.chchile.org> <453E1FBC.5060700@freebsdbrasil.com.br> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <453E1FBC.5060700@freebsdbrasil.com.br> User-Agent: Mutt/1.5.13 (2006-08-11) Cc: freebsd-current@FreeBSD.org, freebsd-small@FreeBSD.org, Julian Elischer Subject: Re: Handling non-standard directories in tinybsd X-BeenThere: freebsd-small@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 25 Oct 2006 10:42:27 -0000 Hi Jean, On Tue, Oct 24, 2006 at 12:14:20PM -0200, Jean Milanez Melo wrote: > >What are you thinking about for inclusion of third-party apps on > >tinybsd ? I hope it won't bloat too much the code. > >Are you already expecting to provide it soon ? > > > > I would like to use pkg_add. Maybe a file called tinybsd.apps and the > users should add in this file what port name they want to install, so > it'll copy binaries installation to workdir. Suggestions? Well, this is a neat idea. However I think this is not homogeneous in regard to the current behaviour of TinyBSD: while the base system would still be included on a per-file basis, library dependencies being brought in automatically, using pkg_add(1) for third-party apps would lead to include the whole package, including manpages, documentation, configuration files along with the binaries. Moreover, this may not be a desirable behaviour for an embedded system. My feeling is that TinyBSD has used the KISS principle so far. The code as well as the configuration is somewhat raw (no offence here), but it is thereby easy to use, debug and modify at needs. I am going to code this in my source tree this afternoon and I will be glad to provide you the patch. Best regards, -- Jeremie Le Hen < jeremie at le-hen dot org >< ttz at chchile dot org > From owner-freebsd-small@FreeBSD.ORG Wed Oct 25 13:03:25 2006 Return-Path: X-Original-To: freebsd-small@FreeBSD.org Delivered-To: freebsd-small@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6B6BD16A417 for ; Wed, 25 Oct 2006 13:03:25 +0000 (UTC) (envelope-from jmelo@freebsdbrasil.com.br) Received: from capeta.freebsdbrasil.com.br (vrrp.freebsdbrasil.com.br [200.210.70.30]) by mx1.FreeBSD.org (Postfix) with SMTP id 0845C43D68 for ; Wed, 25 Oct 2006 13:03:19 +0000 (GMT) (envelope-from jmelo@freebsdbrasil.com.br) Received: (qmail 2514 invoked by uid 0); 25 Oct 2006 11:03:40 -0200 Received: from jmelo@freebsdbrasil.com.br by capeta.freebsdbrasil.com.br by uid 82 with qmail-scanner-1.22 (spamassassin: 2.64. Clear:RC:1(201.17.149.10):. Processed in 0.527831 secs); 25 Oct 2006 13:03:40 -0000 Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=capeta; d=freebsdbrasil.com.br; b=UeccwhnePsRLVu30KilgKGQmeM9C6yJmiojqXxPWoJ7qNRAD0Mf9K4GL6JaupuVS1CmQIQJ9O9AFQOpRRj3TF6KtpX4Gju0FdPqzvDFb7BxKpsNSWwJLSicRuK+h99H2 ; Received: from unknown (HELO ?10.69.69.66?) (jmelo@201.17.149.10) by capeta.freebsdbrasil.com.br with SMTP; 25 Oct 2006 11:03:40 -0200 Message-ID: <453F5271.70309@freebsdbrasil.com.br> Date: Wed, 25 Oct 2006 10:02:57 -0200 From: Jean Milanez Melo User-Agent: Thunderbird 1.5.0.7 (Macintosh/20060909) MIME-Version: 1.0 To: Jeremie Le Hen References: <20061024100641.GB20405@obiwan.tataz.chchile.org> <453DE863.7070305@freebsdbrasil.com.br> <20061024115727.GD20405@obiwan.tataz.chchile.org> <453E1FBC.5060700@freebsdbrasil.com.br> <20061025104306.GI20405@obiwan.tataz.chchile.org> In-Reply-To: <20061025104306.GI20405@obiwan.tataz.chchile.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-current@FreeBSD.org, freebsd-small@FreeBSD.org, Julian Elischer Subject: Re: Handling non-standard directories in tinybsd X-BeenThere: freebsd-small@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 25 Oct 2006 13:03:25 -0000 Jeremie Le Hen wrote: to workdir. Suggestions? > > Well, this is a neat idea. However I think this is not homogeneous in > regard to the current behaviour of TinyBSD: while the base system would > still be included on a per-file basis, library dependencies being > brought in automatically, using pkg_add(1) for third-party apps would > lead to include the whole package, including manpages, documentation, > configuration files along with the binaries. Moreover, this may not be > a desirable behaviour for an embedded system. > Yes, but my idea was install it on temporary directory and remove all unnecessary files. > My feeling is that TinyBSD has used the KISS principle so far. The code > as well as the configuration is somewhat raw (no offence here), but it is > thereby easy to use, debug and modify at needs. I am going to code this > in my source tree this afternoon and I will be glad to provide you the > patch. > That's right, make tinybsd simpler is really our idea :) Send to me your patch and i'll take a look. Thanks Jean From owner-freebsd-small@FreeBSD.ORG Thu Oct 26 13:35:54 2006 Return-Path: X-Original-To: freebsd-small@FreeBSD.org Delivered-To: freebsd-small@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8276E16A40F; Thu, 26 Oct 2006 13:35:54 +0000 (UTC) (envelope-from tataz@tataz.chchile.org) Received: from smtp3-g19.free.fr (smtp3-g19.free.fr [212.27.42.29]) by mx1.FreeBSD.org (Postfix) with ESMTP id 01DBE43D5D; Thu, 26 Oct 2006 13:35:53 +0000 (GMT) (envelope-from tataz@tataz.chchile.org) Received: from tatooine.tataz.chchile.org (tataz.chchile.org [82.233.239.98]) by smtp3-g19.free.fr (Postfix) with ESMTP id 74C2C4A0C8; Thu, 26 Oct 2006 15:35:52 +0200 (CEST) Received: from obiwan.tataz.chchile.org (unknown [192.168.1.25]) by tatooine.tataz.chchile.org (Postfix) with ESMTP id 0445E9E6C2; Thu, 26 Oct 2006 13:36:38 +0000 (UTC) Received: by obiwan.tataz.chchile.org (Postfix, from userid 1000) id D3CC0405B; Thu, 26 Oct 2006 15:36:37 +0200 (CEST) Date: Thu, 26 Oct 2006 15:36:37 +0200 From: Jeremie Le Hen To: Jean Milanez Melo Message-ID: <20061026133637.GJ20405@obiwan.tataz.chchile.org> References: <20061024100641.GB20405@obiwan.tataz.chchile.org> <453DE863.7070305@freebsdbrasil.com.br> <20061024115727.GD20405@obiwan.tataz.chchile.org> <453E1FBC.5060700@freebsdbrasil.com.br> <20061025104306.GI20405@obiwan.tataz.chchile.org> <453F5271.70309@freebsdbrasil.com.br> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <453F5271.70309@freebsdbrasil.com.br> User-Agent: Mutt/1.5.13 (2006-08-11) Cc: freebsd-current@FreeBSD.org, freebsd-small@FreeBSD.org, Julian Elischer Subject: Re: [fbsd] Re: Handling non-standard directories in tinybsd X-BeenThere: freebsd-small@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 26 Oct 2006 13:35:54 -0000 Hi Jean, On Wed, Oct 25, 2006 at 10:02:57AM -0200, Jean Milanez Melo wrote: > >My feeling is that TinyBSD has used the KISS principle so far. The code > >as well as the configuration is somewhat raw (no offence here), but it is > >thereby easy to use, debug and modify at needs. I am going to code this > >in my source tree this afternoon and I will be glad to provide you the > >patch. > > That's right, make tinybsd simpler is really our idea :) > > Send to me your patch and i'll take a look. The patch is attached and works pretty well for me. In addition to tinybsd.localfiles, I've made a few improvements: - I've moved the configuration filenames in a variable ; - When computing "sub-dependencies", use a temporary alternate file and then merge it back to the main dependency file ; - "chflags 0" files that are to be turned into symlinks before unlinking them ; - Handle /boot.config correctly in the configuration directory. Thank you. Regards, -- Jeremie Le Hen < jeremie at le-hen dot org >< ttz at chchile dot org > From owner-freebsd-small@FreeBSD.ORG Thu Oct 26 13:37:15 2006 Return-Path: X-Original-To: freebsd-small@FreeBSD.org Delivered-To: freebsd-small@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CBFE216A412; Thu, 26 Oct 2006 13:37:15 +0000 (UTC) (envelope-from tataz@tataz.chchile.org) Received: from smtp5-g19.free.fr (smtp5-g19.free.fr [212.27.42.35]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5A58243D8F; Thu, 26 Oct 2006 13:36:57 +0000 (GMT) (envelope-from tataz@tataz.chchile.org) Received: from tatooine.tataz.chchile.org (tataz.chchile.org [82.233.239.98]) by smtp5-g19.free.fr (Postfix) with ESMTP id 932FF27ABD; Thu, 26 Oct 2006 15:36:56 +0200 (CEST) Received: from obiwan.tataz.chchile.org (unknown [192.168.1.25]) by tatooine.tataz.chchile.org (Postfix) with ESMTP id 22B199E6C5; Thu, 26 Oct 2006 13:37:42 +0000 (UTC) Received: by obiwan.tataz.chchile.org (Postfix, from userid 1000) id 17732405D; Thu, 26 Oct 2006 15:37:42 +0200 (CEST) Date: Thu, 26 Oct 2006 15:37:42 +0200 From: Jeremie Le Hen To: Jean Milanez Melo Message-ID: <20061026133742.GK20405@obiwan.tataz.chchile.org> References: <20061024100641.GB20405@obiwan.tataz.chchile.org> <453DE863.7070305@freebsdbrasil.com.br> <20061024115727.GD20405@obiwan.tataz.chchile.org> <453E1FBC.5060700@freebsdbrasil.com.br> <20061025104306.GI20405@obiwan.tataz.chchile.org> <453F5271.70309@freebsdbrasil.com.br> <20061026133637.GJ20405@obiwan.tataz.chchile.org> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="MnLPg7ZWsaic7Fhd" Content-Disposition: inline In-Reply-To: <20061026133637.GJ20405@obiwan.tataz.chchile.org> User-Agent: Mutt/1.5.13 (2006-08-11) Cc: freebsd-small@FreeBSD.org, freebsd-current@FreeBSD.org, Julian Elischer Subject: Re: Handling non-standard directories in tinybsd X-BeenThere: freebsd-small@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 26 Oct 2006 13:37:15 -0000 --MnLPg7ZWsaic7Fhd Content-Type: text/plain; charset=us-ascii Content-Disposition: inline And the patch... On Thu, Oct 26, 2006 at 03:36:37PM +0200, Jeremie Le Hen wrote: > Hi Jean, > > On Wed, Oct 25, 2006 at 10:02:57AM -0200, Jean Milanez Melo wrote: > > >My feeling is that TinyBSD has used the KISS principle so far. The code > > >as well as the configuration is somewhat raw (no offence here), but it is > > >thereby easy to use, debug and modify at needs. I am going to code this > > >in my source tree this afternoon and I will be glad to provide you the > > >patch. > > > > That's right, make tinybsd simpler is really our idea :) > > > > Send to me your patch and i'll take a look. > > The patch is attached and works pretty well for me. > In addition to tinybsd.localfiles, I've made a few improvements: > - I've moved the configuration filenames in a variable ; > - When computing "sub-dependencies", use a temporary alternate file > and then merge it back to the main dependency file ; > - "chflags 0" files that are to be turned into symlinks before unlinking > them ; > - Handle /boot.config correctly in the configuration directory. > > Thank you. > Regards, -- Jeremie Le Hen < jeremie at le-hen dot org >< ttz at chchile dot org > --MnLPg7ZWsaic7Fhd Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="tinybsd_localfiles.patch" Index: README =================================================================== RCS file: /home/ncvs/src/tools/tools/tinybsd/README,v retrieving revision 1.1 diff -u -p -r1.1 README --- README 20 Sep 2006 22:24:17 -0000 1.1 +++ README 26 Oct 2006 13:32:02 -0000 @@ -69,6 +69,10 @@ usr/sbin/pw usr/sbin/pwd_mkdb usr/sbin/setkey +tinybsd.localfiles: Similar to tinybsd.basefiles but for /usr/local/. The +difference is that directories will have to be created by TinyBSD because +they are not handle by mtree(1). + etc/: This is the directory where you can put your custom /etc configuration. # ls /usr/src/tools/tools/tinybsd/tinybsd Index: tinybsd =================================================================== RCS file: /home/ncvs/src/tools/tools/tinybsd/tinybsd,v retrieving revision 1.4 diff -u -p -r1.4 tinybsd --- tinybsd 11 Oct 2006 21:46:53 -0000 1.4 +++ tinybsd 26 Oct 2006 13:32:02 -0000 @@ -14,6 +14,8 @@ else fi WORKDIR=/usr/obj/tinybsdbuild KERNCONF=TINYBSD +BASEFILE="tinybsd.basefiles" +LOCALFILE="tinybsd.localfiles" DEFINSTARGS="-o 0 -g 0 -m 555" TS="=====>" @@ -262,10 +264,26 @@ create_tree() { mtree -deU -f /etc/mtree/BSD.var.dist -p ${WORKDIR}/var } +create_missingdirs() { + local LISTFILE DIR + LISTFILE=$1 + + for file in `cat $LISTFILE | grep -v "#" | cut -f1 -d":" | sort | uniq`; do + DIR=`dirname ${file}` + if [ ! -d ${WORKDIR}/${DIR} ]; then + echo "Non-standard directory created manually: ${DIR}." + mkdir -p ${WORKDIR}/${DIR} + fi + done +} + copy_binaries() { #set -xv - for file in `cat ${CURRENTDIR}/conf/${CONF}/tinybsd.basefiles | grep -v "#" | \ + cd ${CURRENTDIR}/conf/${CONF} + create_missingdirs ${LOCALFILE} + + for file in `cat ${BASEFILE} ${LOCALFILE} | grep -v "#" | \ cut -f1 -d":" | sort | uniq` ; do echo "${TS} Copying "/${file}" to "${WORKDIR}/${file} cp -fp /${file} ${WORKDIR}/${file} ; @@ -289,24 +307,31 @@ make_kernel() { copy_libraries() { #set -xv - TDEPFILE="`mktemp -t deps`" - TDEPFILES="`mktemp -t depsymlnk`" + TDEPFILE="`mktemp -t deps.XXX`" + TDEPFILE2="`mktemp -t deps.XXX`" + TDEPFILES="`mktemp -t depsymlnk.XXX`" cd ${CURRENTDIR}/conf/${CONF} - for file in `cat tinybsd.basefiles | grep -v "#" | cut -f1 -d":"`; do + for file in `cat ${BASEFILE} ${LOCALFILE} | grep -v "#" | cut -f1 -d":"`; do ldd -f "%p\n" /${file} >> ${TDEPFILE} ; # don't worry on progs been "not dynamic" done for libdeplib in `cat ${TDEPFILE} | sort | uniq`; do - ldd -f "%p\n" /${libdeplib} >> ${TDEPFILE} ; + ldd -f "%p\n" /${libdeplib} >> ${TDEPFILE2} ; done + cat ${TDEPFILE2} >> ${TDEPFILE} for pamdep in `ls -1 /usr/lib/pam*`; do echo $pamdep >> ${TDEPFILE} ; ldd -f "%p\n" /${pamdep} >> ${TDEPFILE} ; done + + cat ${TDEPFILE} | sort | uniq > ${TDEPFILE2} + mv -f ${TDEPFILE2} ${TDEPFILE} + + create_missingdirs ${TDEPFILE} - for lib in `cat ${TDEPFILE} | sort | uniq`; do + for lib in `cat ${TDEPFILE}`; do echo "${TS} Copying "${lib}" to "${WORKDIR}${lib} cp -fp ${lib} ${WORKDIR}${lib} ; done @@ -321,6 +346,7 @@ copy_libraries() { TARGET_FILE=`echo $i | awk -F ":" '{print $2}'` echo "${TS} Unlinking ${WORKDIR}${TARGET_FILE}" + chroot ${WORKDIR} /bin/chflags 0 ${TARGET_FILE} chroot ${WORKDIR} /bin/rm -f ${TARGET_FILE} echo "${TS} Symlinking ${SOURCE_FILE} to ${TARGET_FILE}" @@ -349,16 +375,20 @@ create_ssh_keys() { ssh-keygen -t rsa -f ${WORKDIR}/etc/ssh/ssh_host_rsa_key -N '' } -personal_directories() { +personal_conf() { echo "${TS} Copying your custom configuration on conf/ ..." - for custom in `find ${CURRENTDIR}/conf/${CONF}/ -type d -depth 1`; do + for custom in `find ${CURRENTDIR}/conf/${CONF}/ -type d -depth 1 \! -name CVS`; do cp -Rp ${custom}/* ${WORKDIR}/${custom#${CURRENTDIR}/conf/${CONF}/}/ done + + if [ -f ${CURRENTDIR}/conf/${CONF}/boot.config ]; then + cp ${CURRENTDIR}/conf/${CONF}/boot.config ${WORKDIR}/boot.config + fi } symlinks() { #set -xv - for i in `cat tinybsd.basefiles | grep -v "#" | grep ":"`; do + for i in `cat ${BASEFILE} ${LOCALFILE} | grep -v "#" | grep ":"`; do SOURCE_FILE=`echo $i | awk -F ":" {'print $1'}` TARGET_FILE=`echo $i | awk -F ":" {'print $2'}` chroot ${WORKDIR} /bin/ln -vs /${SOURCE_FILE} ${TARGET_FILE} @@ -460,7 +502,7 @@ saveconfig symlinks create_etc create_ssh_keys - personal_directories + personal_conf create_image #set +xv ) 2>&1 |tee -a ${HOME}/tinybsd.log --MnLPg7ZWsaic7Fhd-- From owner-freebsd-small@FreeBSD.ORG Thu Oct 26 18:34:29 2006 Return-Path: X-Original-To: freebsd-small@freebsd.org Delivered-To: freebsd-small@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 601BF16A403 for ; Thu, 26 Oct 2006 18:34:29 +0000 (UTC) (envelope-from info@martenvijn.nl) Received: from martenvijn.nl (vijn.xs4all.nl [194.109.254.102]) by mx1.FreeBSD.org (Postfix) with ESMTP id EBA1343D45 for ; Thu, 26 Oct 2006 18:34:27 +0000 (GMT) (envelope-from info@martenvijn.nl) Received: from workstation.martenvijn.nl (workstation.martenvijn.nl [192.168.1.6]) by martenvijn.nl (8.13.4/8.13.4) with ESMTP id k9QIag7L018069 for ; Thu, 26 Oct 2006 20:36:47 +0200 (CEST) (envelope-from info@martenvijn.nl) From: Marten To: freebsd-small@freebsd.org In-Reply-To: <20061026133742.GK20405@obiwan.tataz.chchile.org> References: <20061024100641.GB20405@obiwan.tataz.chchile.org> <453DE863.7070305@freebsdbrasil.com.br> <20061024115727.GD20405@obiwan.tataz.chchile.org> <453E1FBC.5060700@freebsdbrasil.com.br> <20061025104306.GI20405@obiwan.tataz.chchile.org> <453F5271.70309@freebsdbrasil.com.br> <20061026133637.GJ20405@obiwan.tataz.chchile.org> <20061026133742.GK20405@obiwan.tataz.chchile.org> Content-Type: text/plain Date: Thu, 26 Oct 2006 20:33:16 +0200 Message-Id: <1161887596.701.24.camel@workstation.martenvijn.nl> Mime-Version: 1.0 X-Mailer: Evolution 2.4.2.1 FreeBSD GNOME Team Port Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-2.0.2 (martenvijn.nl [192.168.1.2]); Thu, 26 Oct 2006 20:36:47 +0200 (CEST) X-Scanned-By: MIMEDefang 2.57 on 192.168.1.2 X-Spam-Status: No, score=0.1 required=3.0 tests=AWL autolearn=ham version=3.1.6 X-Spam-Checker-Version: SpamAssassin 3.1.6 (2006-10-03) on martenvijn.nl X-Virus-Scanned: ClamAV 0.88.5/2107/Thu Oct 26 16:33:29 2006 on martenvijn.nl X-Virus-Status: Clean Subject: image+packages and some patches tinybsd 6.2 and 7 X-BeenThere: freebsd-small@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 26 Oct 2006 18:34:29 -0000 Hi all, Just wanted to share some some work on/with tinybsd Here some other patches for 6.2 and 7.0 https://svn.wifisoft.org/node/trunk/tinybsd/ and a 7.0 image with svn support https://svn.wifisoft.org/node/trunk/base.img and some packages ( not very well tested but feed back is welcome). https://svn.wifisoft.org/node/trunk/pkgs/ and ofcourse some documentation https://svn.wifisoft.org/node/doc/ kind regards, Marten From owner-freebsd-small@FreeBSD.ORG Fri Oct 27 15:58:20 2006 Return-Path: X-Original-To: freebsd-small@freebsd.org Delivered-To: freebsd-small@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D6F1316A5FF for ; Fri, 27 Oct 2006 15:58:20 +0000 (UTC) (envelope-from gnn@neville-neil.com) Received: from mrout2.yahoo.com (mrout2.yahoo.com [216.145.54.172]) by mx1.FreeBSD.org (Postfix) with ESMTP id 634A943D5E for ; Fri, 27 Oct 2006 15:58:20 +0000 (GMT) (envelope-from gnn@neville-neil.com) Received: from minion.local.neville-neil.com (proxy7.corp.yahoo.com [216.145.48.98]) by mrout2.yahoo.com (8.13.6/8.13.6/y.out) with ESMTP id k9RFvu8B075502; Fri, 27 Oct 2006 08:57:58 -0700 (PDT) Date: Fri, 27 Oct 2006 17:57:52 +0200 Message-ID: From: gnn@freebsd.org To: Marten In-Reply-To: <1161887596.701.24.camel@workstation.martenvijn.nl> References: <20061024100641.GB20405@obiwan.tataz.chchile.org> <453DE863.7070305@freebsdbrasil.com.br> <20061024115727.GD20405@obiwan.tataz.chchile.org> <453E1FBC.5060700@freebsdbrasil.com.br> <20061025104306.GI20405@obiwan.tataz.chchile.org> <453F5271.70309@freebsdbrasil.com.br> <20061026133637.GJ20405@obiwan.tataz.chchile.org> <20061026133742.GK20405@obiwan.tataz.chchile.org> <1161887596.701.24.camel@workstation.martenvijn.nl> User-Agent: Wanderlust/2.14.0 (Africa) SEMI/1.14.6 (Maruoka) FLIM/1.14.8 (=?ISO-8859-4?Q?Shij=F2?=) APEL/10.6 Emacs/22.0.50 (i386-apple-darwin8.7.1) MULE/5.0 (SAKAKI) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Cc: freebsd-small@freebsd.org Subject: Re: image+packages and some patches tinybsd 6.2 and 7 X-BeenThere: freebsd-small@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Oct 2006 15:58:20 -0000 Excellent! Thanks. I'll try to update the EmbeddedFreeBSD.org site asap. Thanks, George From owner-freebsd-small@FreeBSD.ORG Fri Oct 27 16:50:42 2006 Return-Path: X-Original-To: freebsd-small@FreeBSD.org Delivered-To: freebsd-small@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BF4FC16A415 for ; Fri, 27 Oct 2006 16:50:42 +0000 (UTC) (envelope-from jmelo@freebsdbrasil.com.br) Received: from capeta.freebsdbrasil.com.br (vrrp.freebsdbrasil.com.br [200.210.70.30]) by mx1.FreeBSD.org (Postfix) with SMTP id 7F12743D4C for ; Fri, 27 Oct 2006 16:50:25 +0000 (GMT) (envelope-from jmelo@freebsdbrasil.com.br) Received: (qmail 97328 invoked by uid 0); 27 Oct 2006 14:50:46 -0200 Received: from jmelo@freebsdbrasil.com.br by capeta.freebsdbrasil.com.br by uid 82 with qmail-scanner-1.22 (spamassassin: 2.64. Clear:RC:1(201.17.149.10):. Processed in 0.525763 secs); 27 Oct 2006 16:50:46 -0000 Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=capeta; d=freebsdbrasil.com.br; b=JNcxNNKKEeg0/gzNqV2aVIfydq9tfCzMpW37+tCi2c+Ckx1pJqCmE3WWC1+SWhohys2b9bzZuLf4pqbKk6VJYvuqtU+P93L0K1201+w8zpr5ARurVebKOpHtxZkehy+w ; Received: from unknown (HELO ?10.69.69.66?) (jmelo@201.17.149.10) by capeta.freebsdbrasil.com.br with SMTP; 27 Oct 2006 14:50:45 -0200 Message-ID: <45422AA6.50309@freebsdbrasil.com.br> Date: Fri, 27 Oct 2006 13:49:58 -0200 From: Jean Milanez Melo User-Agent: Thunderbird 1.5.0.7 (Macintosh/20060909) MIME-Version: 1.0 To: Jeremie Le Hen References: <20061024100641.GB20405@obiwan.tataz.chchile.org> <453DE863.7070305@freebsdbrasil.com.br> <20061024115727.GD20405@obiwan.tataz.chchile.org> <453E1FBC.5060700@freebsdbrasil.com.br> <20061025104306.GI20405@obiwan.tataz.chchile.org> <453F5271.70309@freebsdbrasil.com.br> <20061026133637.GJ20405@obiwan.tataz.chchile.org> <20061026133742.GK20405@obiwan.tataz.chchile.org> In-Reply-To: <20061026133742.GK20405@obiwan.tataz.chchile.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-small@FreeBSD.org, freebsd-current@FreeBSD.org, Julian Elischer Subject: Re: Handling non-standard directories in tinybsd X-BeenThere: freebsd-small@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Oct 2006 16:50:42 -0000 Jeremie Le Hen wrote: > And the patch... > > On Thu, Oct 26, 2006 at 03:36:37PM +0200, Jeremie Le Hen wrote: >> Hi Jean, >> >> On Wed, Oct 25, 2006 at 10:02:57AM -0200, Jean Milanez Melo wrote: >>>> My feeling is that TinyBSD has used the KISS principle so far. The code >>>> as well as the configuration is somewhat raw (no offence here), but it is >>>> thereby easy to use, debug and modify at needs. I am going to code this >>>> in my source tree this afternoon and I will be glad to provide you the >>>> patch. >>> That's right, make tinybsd simpler is really our idea :) >>> >>> Send to me your patch and i'll take a look. >> The patch is attached and works pretty well for me. >> In addition to tinybsd.localfiles, I've made a few improvements: >> - I've moved the configuration filenames in a variable ; >> - When computing "sub-dependencies", use a temporary alternate file >> and then merge it back to the main dependency file ; >> - "chflags 0" files that are to be turned into symlinks before unlinking >> them ; >> - Handle /boot.config correctly in the configuration directory. >> >> Thank you. >> Regards, > Thanks Jeremie, Looks good, i'll test it on saturday. Jean From owner-freebsd-small@FreeBSD.ORG Sat Oct 28 23:32:46 2006 Return-Path: X-Original-To: freebsd-small@FreeBSD.org Delivered-To: freebsd-small@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6CA2616A412 for ; Sat, 28 Oct 2006 23:32:46 +0000 (UTC) (envelope-from jmelo@freebsdbrasil.com.br) Received: from capeta.freebsdbrasil.com.br (vrrp.freebsdbrasil.com.br [200.210.70.30]) by mx1.FreeBSD.org (Postfix) with SMTP id BBBCD43D5A for ; Sat, 28 Oct 2006 23:32:42 +0000 (GMT) (envelope-from jmelo@freebsdbrasil.com.br) Received: (qmail 87973 invoked by uid 0); 28 Oct 2006 21:33:04 -0200 Received: from jmelo@freebsdbrasil.com.br by capeta.freebsdbrasil.com.br by uid 82 with qmail-scanner-1.22 (spamassassin: 2.64. Clear:RC:1(201.17.149.10):. Processed in 1.110136 secs); 28 Oct 2006 23:33:04 -0000 Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=capeta; d=freebsdbrasil.com.br; b=AZ22AR+gHClpWRbkUkxD9RkyXmJPI20vBe78LqPoBri8GSiOXsd5ow3ohXj/0aJy+4Xgm5sRvaFYSfaIVSG9vEl0A+7xU0FeIiCpbYWVac0xklnijdh0DODsRFkoDiiH ; Received: from unknown (HELO ?10.69.69.66?) (jmelo@201.17.149.10) by capeta.freebsdbrasil.com.br with SMTP; 28 Oct 2006 21:33:01 -0200 Message-ID: <4543DA67.4030008@freebsdbrasil.com.br> Date: Sat, 28 Oct 2006 20:32:07 -0200 From: Jean Milanez Melo User-Agent: Thunderbird 1.5.0.7 (Macintosh/20060909) MIME-Version: 1.0 To: Jeremie Le Hen References: <20061024100641.GB20405@obiwan.tataz.chchile.org> <453DE863.7070305@freebsdbrasil.com.br> <20061024115727.GD20405@obiwan.tataz.chchile.org> <453E1FBC.5060700@freebsdbrasil.com.br> <20061025104306.GI20405@obiwan.tataz.chchile.org> <453F5271.70309@freebsdbrasil.com.br> <20061026133637.GJ20405@obiwan.tataz.chchile.org> <20061026133742.GK20405@obiwan.tataz.chchile.org> In-Reply-To: <20061026133742.GK20405@obiwan.tataz.chchile.org> Content-Type: multipart/mixed; boundary="------------060509030608050000020407" Cc: freebsd-small@FreeBSD.org, freebsd-current@FreeBSD.org, Julian Elischer Subject: Re: Handling non-standard directories in tinybsd X-BeenThere: freebsd-small@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 28 Oct 2006 23:32:46 -0000 This is a multi-part message in MIME format. --------------060509030608050000020407 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Jeremie Le Hen wrote: > And the patch... > > On Thu, Oct 26, 2006 at 03:36:37PM +0200, Jeremie Le Hen wrote: >> Hi Jean, >> >> On Wed, Oct 25, 2006 at 10:02:57AM -0200, Jean Milanez Melo wrote: >>>> My feeling is that TinyBSD has used the KISS principle so far. The code >>>> as well as the configuration is somewhat raw (no offence here), but it is >>>> thereby easy to use, debug and modify at needs. I am going to code this >>>> in my source tree this afternoon and I will be glad to provide you the >>>> patch. >>> That's right, make tinybsd simpler is really our idea :) >>> >>> Send to me your patch and i'll take a look. >> The patch is attached and works pretty well for me. >> In addition to tinybsd.localfiles, I've made a few improvements: >> - I've moved the configuration filenames in a variable ; >> - When computing "sub-dependencies", use a temporary alternate file >> and then merge it back to the main dependency file ; >> - "chflags 0" files that are to be turned into symlinks before unlinking >> them ; >> - Handle /boot.config correctly in the configuration directory. >> >> Thank you. >> Regards, > > Hi Jeremie, Your patch was good, but i've made some changes. Here the patch. Take a look and tell me what do you think, if it's ok for you i'll ask Julian to commit. Thanks. Jean --------------060509030608050000020407 Content-Type: text/plain; x-mac-type="0"; x-mac-creator="0"; name="tinybsd.diff" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="tinybsd.diff" Index: README =================================================================== RCS file: /home/ncvs/src/tools/tools/tinybsd/README,v retrieving revision 1.1 diff -u -r1.1 README --- README 20 Sep 2006 22:24:17 -0000 1.1 +++ README 28 Oct 2006 23:22:41 -0000 @@ -69,6 +69,10 @@ usr/sbin/pwd_mkdb usr/sbin/setkey +tinybsd.localfiles: Similar to tinybsd.basefiles but for /usr/local/. The +difference is that directories will have to be created by TinyBSD because +they are not handle by mtree(1). + etc/: This is the directory where you can put your custom /etc configuration. # ls /usr/src/tools/tools/tinybsd/tinybsd 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 28 Oct 2006 23:22:41 -0000 @@ -14,6 +14,8 @@ fi WORKDIR=/usr/obj/tinybsdbuild KERNCONF=TINYBSD +BASEFILE="tinybsd.basefiles" +LOCALFILE="tinybsd.localfiles" DEFINSTARGS="-o 0 -g 0 -m 555" TS="=====>" @@ -239,6 +241,10 @@ fi } +rotate_buidlog() { + mv -f ${HOME}/tinybsd.log ${HOME}/tinybsd.log.old +} + remove_workdir() { chflags -R noschg ${WORKDIR} echo "${TS} Removing "${WORKDIR} @@ -250,7 +256,7 @@ prework() { - remove_workdir + remove_workdir mkdir -p ${WORKDIR} } @@ -259,18 +265,18 @@ echo "${TS} Creating directory hierarchy... " 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.local.dist -p ${WORKDIR}/usr/local mtree -deU -f /etc/mtree/BSD.var.dist -p ${WORKDIR}/var } - copy_binaries() { -#set -xv - for file in `cat ${CURRENTDIR}/conf/${CONF}/tinybsd.basefiles | grep -v "#" | \ + cd ${CURRENTDIR}/conf/${CONF} + + for file in `cat ${BASEFILE} ${LOCALFILE} | grep -v "#" | \ cut -f1 -d":" | sort | uniq` ; do echo "${TS} Copying "/${file}" to "${WORKDIR}/${file} cp -fp /${file} ${WORKDIR}/${file} ; done -#set +xv } make_kernel() { @@ -293,7 +299,7 @@ TDEPFILES="`mktemp -t depsymlnk`" cd ${CURRENTDIR}/conf/${CONF} - for file in `cat tinybsd.basefiles | grep -v "#" | cut -f1 -d":"`; do + for file in `cat ${BASEFILE} ${LOCALFILE} | grep -v "#" | cut -f1 -d":"`; do ldd -f "%p\n" /${file} >> ${TDEPFILE} ; # don't worry on progs been "not dynamic" done @@ -305,7 +311,7 @@ echo $pamdep >> ${TDEPFILE} ; ldd -f "%p\n" /${pamdep} >> ${TDEPFILE} ; done - + for lib in `cat ${TDEPFILE} | sort | uniq`; do echo "${TS} Copying "${lib}" to "${WORKDIR}${lib} cp -fp ${lib} ${WORKDIR}${lib} ; @@ -321,6 +327,7 @@ TARGET_FILE=`echo $i | awk -F ":" '{print $2}'` echo "${TS} Unlinking ${WORKDIR}${TARGET_FILE}" + chroot ${WORKDIR} /bin/chflags 0 ${TARGET_FILE} chroot ${WORKDIR} /bin/rm -f ${TARGET_FILE} echo "${TS} Symlinking ${SOURCE_FILE} to ${TARGET_FILE}" @@ -349,27 +356,29 @@ ssh-keygen -t rsa -f ${WORKDIR}/etc/ssh/ssh_host_rsa_key -N '' } -personal_directories() { +personal_conf() { echo "${TS} Copying your custom configuration on conf/ ..." - for custom in `find ${CURRENTDIR}/conf/${CONF}/ -type d -depth 1`; do + for custom in `find ${CURRENTDIR}/conf/${CONF}/ -type d -depth 1 \! -name CVS`; do cp -Rp ${custom}/* ${WORKDIR}/${custom#${CURRENTDIR}/conf/${CONF}/}/ done + + if [ -f ${CURRENTDIR}/conf/${CONF}/boot.config ]; then + cp ${CURRENTDIR}/conf/${CONF}/boot.config ${WORKDIR}/boot.config + fi } symlinks() { -#set -xv - for i in `cat tinybsd.basefiles | grep -v "#" | grep ":"`; do +set -xv + for i in `cat ${BASEFILE} ${LOCALFILE} | grep -v "#" | grep ":"`; do SOURCE_FILE=`echo $i | awk -F ":" {'print $1'}` TARGET_FILE=`echo $i | awk -F ":" {'print $2'}` chroot ${WORKDIR} /bin/ln -vs /${SOURCE_FILE} ${TARGET_FILE} done -#set +xv +set +xv } create_image() { - #set -ex - VNODEFILE=`mktemp -t tinybsd` IMGMNT=`mktemp -d -t tinybsd` @@ -448,6 +457,9 @@ loadconfig saveconfig +# Rotate build log +rotate_buidlog + # Now start logging. ( # Do the build @@ -460,7 +472,7 @@ symlinks create_etc create_ssh_keys - personal_directories + personal_conf create_image #set +xv ) 2>&1 |tee -a ${HOME}/tinybsd.log Index: conf/bridge/tinybsd.localfiles =================================================================== RCS file: conf/bridge/tinybsd.localfiles diff -N conf/bridge/tinybsd.localfiles --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ conf/bridge/tinybsd.localfiles 28 Oct 2006 23:22:41 -0000 @@ -0,0 +1,6 @@ +# $FreeBSD$ +# Add here your third-party applications that are already installed on /usr/local +# Make sure you have enough space to add it. +# Example: +# usr/local/sbin/httpd + Index: conf/default/tinybsd.localfiles =================================================================== RCS file: conf/default/tinybsd.localfiles diff -N conf/default/tinybsd.localfiles --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ conf/default/tinybsd.localfiles 28 Oct 2006 23:22:41 -0000 @@ -0,0 +1,6 @@ +# $FreeBSD$ +# Add here your third-party applications that are already installed on /usr/local +# Make sure you have enough space to add it. +# Example: +# usr/local/sbin/httpd + Index: conf/firewall/tinybsd.localfiles =================================================================== RCS file: conf/firewall/tinybsd.localfiles diff -N conf/firewall/tinybsd.localfiles --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ conf/firewall/tinybsd.localfiles 28 Oct 2006 23:22:41 -0000 @@ -0,0 +1,6 @@ +# $FreeBSD$ +# Add here your third-party applications that are already installed on /usr/local +# Make sure you have enough space to add it. +# Example: +# usr/local/sbin/httpd + Index: conf/minimal/tinybsd.localfiles =================================================================== RCS file: conf/minimal/tinybsd.localfiles diff -N conf/minimal/tinybsd.localfiles --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ conf/minimal/tinybsd.localfiles 28 Oct 2006 23:22:41 -0000 @@ -0,0 +1,6 @@ +# $FreeBSD$ +# Add here your third-party applications that are already installed on /usr/local +# Make sure you have enough space to add it. +# Example: +# usr/local/sbin/httpd + Index: conf/vpn/tinybsd.localfiles =================================================================== RCS file: conf/vpn/tinybsd.localfiles diff -N conf/vpn/tinybsd.localfiles --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ conf/vpn/tinybsd.localfiles 28 Oct 2006 23:22:41 -0000 @@ -0,0 +1,6 @@ +# $FreeBSD$ +# Add here your third-party applications that are already installed on /usr/local +# Make sure you have enough space to add it. +# Example: +# usr/local/sbin/httpd + Index: conf/wireless/tinybsd.localfiles =================================================================== RCS file: conf/wireless/tinybsd.localfiles diff -N conf/wireless/tinybsd.localfiles --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ conf/wireless/tinybsd.localfiles 28 Oct 2006 23:22:41 -0000 @@ -0,0 +1,6 @@ +# $FreeBSD$ +# Add here your third-party applications that are already installed on /usr/local +# Make sure you have enough space to add it. +# Example: +# usr/local/sbin/httpd + Index: conf/wrap/tinybsd.localfiles =================================================================== RCS file: conf/wrap/tinybsd.localfiles diff -N conf/wrap/tinybsd.localfiles --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ conf/wrap/tinybsd.localfiles 28 Oct 2006 23:22:41 -0000 @@ -0,0 +1,6 @@ +# $FreeBSD$ +# Add here your third-party applications that are already installed on /usr/local +# Make sure you have enough space to add it. +# Example: +# usr/local/sbin/httpd + --------------060509030608050000020407--