From owner-freebsd-current@FreeBSD.ORG Wed Nov 1 13:42:50 2006 Return-Path: X-Original-To: current@freebsd.org Delivered-To: freebsd-current@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8090D16A415 for ; Wed, 1 Nov 2006 13:42:50 +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 4A62C43D45 for ; Wed, 1 Nov 2006 13:42:37 +0000 (GMT) (envelope-from jmelo@freebsdbrasil.com.br) Received: (qmail 21194 invoked by uid 0); 1 Nov 2006 11:42:54 -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.529369 secs); 01 Nov 2006 13:42:54 -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=XtLW9QYIRvCX6i2lL67uW58Q3cN/tuz2n7kJdwXe87hgCcp7YMmL1GwAPQF1flqO9zQ/2z1Yt1taAOEyRzI7eclRRKPuV+mo3Vxjvozr71IsuJDw9QCM2dMPAkpENvSt ; Received: from unknown (HELO ?10.69.69.66?) (jmelo@201.17.149.10) by capeta.freebsdbrasil.com.br with SMTP; 1 Nov 2006 11:42:53 -0200 Message-ID: <45489618.2000106@freebsdbrasil.com.br> Date: Wed, 01 Nov 2006 10:42:00 -0200 From: Jean Milanez Melo User-Agent: Thunderbird 1.5.0.7 (Macintosh/20060909) MIME-Version: 1.0 To: small@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Jeremie Le Hen , current@freebsd.org Subject: [HEADSUP] TinyBSD and ports applications X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 01 Nov 2006 13:42:50 -0000 Hello, I have completly redone the routines for third party applications install, I thought that initial way of doing things as Jeremied had idealized was not very good, and I decided to make it better. Now what I have do works this way: The TinyBSD user will populate the conf//tinybsd.ports file listing the port name (in category/port) he wants to be installed on his tinybsd system, just like: category/application say, for example: www/mini_httpd So based on this information tinybsd will have the path for the port, will cd to that directory, check for the package name with "make -V PKGNAME" and later, run pkg_info to check from its exit code wether the port is installed or not. If not locally installed, tinybsd will "make install" this port in the local system, else (it already locally installed) tinybsd will skip to missing_dir function. On missing_dir function it checks for all directories which are not automatically generated from BSD.local.dist, if the directory does not exist it will "mkdir -p" it under /usr/local PREFIX on TinyBSD workdir, creating on the TinyBSD image the necessary directories hierarchy. Later it goes to copy_ports function where it checks for the applications the port installs, with pkg_info, and updates a listing excluding all things unecessary to a an embedded system, say, all data installed under www,doc,share,include,man (which just makes no sense existing on an embedded system, and would only demand useless storage space). This listing will be called /tmp/ports.files, and will contain all files that need to be added to the tinybsd system the user is building. Later, copy_libraries function will copy all necessary libraries to the image as well, just like the main idea behind the whole TinyBSD. Finally, deinstall_ports will deinstall the port from the local system if and only if it was not installed. It the port was already installed, obviously tinybsd won't remove it from the local system. I believe this is the most efficient way to handle third parties applications on embedded system. At least the easiest way for the users. They can always, of course add or remove binaries or modules themselves, but now we have a subsystem on tinybsd which does the hard work. Julian's just committed the patch and i would like to hear some feedback from you. This latest patchset is fully tested. I built some tinybsd systems from it today. About TinyBSD documentation, we are updating it on tinyBSD website regarding everything that is new, and will soon sgml it. - Jean