From owner-freebsd-hackers Wed Sep 20 9:49:42 2000 Delivered-To: freebsd-hackers@freebsd.org Received: from hermes.research.kpn.com (hermes.research.kpn.com [139.63.192.8]) by hub.freebsd.org (Postfix) with ESMTP id 5805337B422 for ; Wed, 20 Sep 2000 09:49:39 -0700 (PDT) Received: from l04.research.kpn.com (l04.research.kpn.com [139.63.192.204]) by research.kpn.com (PMDF V5.2-31 #42699) with ESMTP id <01JUEMZEWJ68000IBJ@research.kpn.com> for freebsd-hackers@freebsd.org; Wed, 20 Sep 2000 18:49:37 +0200 Received: by l04.research.kpn.com with Internet Mail Service (5.5.2650.21) id ; Wed, 20 Sep 2000 18:49:36 +0100 Content-return: allowed Date: Wed, 20 Sep 2000 18:49:36 +0100 From: "Koster, K.J." Subject: Executable packages (long, sorry) To: 'FreeBSD Hackers mailing list' Message-id: <59063B5B4D98D311BC0D0001FA7E4522026D78DA@l04.research.kpn.com> MIME-version: 1.0 X-Mailer: Internet Mail Service (5.5.2650.21) Content-type: text/plain; charset="iso-8859-1" Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Dear All, While we're on the subject of packaging formats, I would like to present an idea that has been running around in the back of my head. Years ago I had the pleasure of playing with a new RiscPC by Acorn. If you create a directory on RiscOS and stick a little BASIC script in with exactly the right name, RiscOS will treat that directory as an executable. You can use the directory to stick in whatever the application needs, and the user never needs to bother. Uninstalling it is as easy as the RiscOS equivalent of "rm -rf". Riding on the wave of the unified BSD packages effort, this might be a good time to rekindle that idea. Say that we agree on some form of uniform package layout. You'd say that man pages go into $PKG_BASE/$PKG_NAME/man, and that libraries go into $PKG_BASE/$PKG_NAME/lib, and that there is probably a script named $PKG_BASE/$PKG_NAME/etc/rc that takes the arguments "start" and "stop" for system startup. A script named $PKG_BASE/$PKG_NAME/bin/run is invoked when a user types $PKG_NAME at the command prompt (triggered by a script in /usr/local/bin, which is symlinked to $PKG_NAME. We are already doing this now, but instead we scatter packages across the filesystem, keeping file lists of where we left the various body parts of the port. So is this a bad idea? I don't think so. Some programs already install themselves in a similar fashion. If you'll allow me to use Tomcat as an example. After you have installed it, only /usr/local/tomcat new on your system. It has its own bin/, conf/ and lib/ directory. Deinstalling is as simple as it is on a RiscPC. There are other places too, where you see this self-containment crop up. The executable JAR files from Java, for example. And someone over at KDE or Gnome (or some desktop kit like that, I can't tell them apart) mentioned that they were going to do a ZIP archive abstraction, much like they did with the file system. You could easily make a zip archive behave like an executable. I do not think that this is the perfect solution to system clobbering. In fact, there are some good examples of stuff that should really not be installed in an executable directory. The GNU tools spring to mind. They were written according to a UNIX utility philosophy, and should be treated as such. Other things, such as a web server, or a word processor are much more self contained. I hope that you will remember this idea when you find yourself staring at traces of an old port, unsure if you should delete it or not. :-) Kees Jan ================================================ You are only young once, but you can stay immature all your life. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message