[haiku-development] Re: software organization/installation

  • From: Francisco Castro <fcr@xxxxxxxxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Sun, 15 Feb 2009 19:30:43 -0200

On Sunday 15 February 2009 18:14:57 Brecht Machiels wrote:
> Hello,
> With Haiku heading towards a first alpha release, I think it might be
> time to discuss how software for Haiku should be:
> a) installed; an installer application (or not?)
> b) organized; where are files stored
> I would like to start a discussion so that there is a clear concept
> before alpha 1 is released.
> I'll start with point a.
> I think most of us agree that package management systems such as used by
> Linux distributions are not the way to go? The alternative is that the
> user downloads the software (binaries) from a web page.

You can have a package managment system and be able to download binaries from 
a web page. This works fine with apt at least.

You'll need a package management system if you want to list which application 
you've got installed, if you want to upgrade all of them using a standard 
method, if you want to have a single uninstalling procedure.

> Reading some old discussions on software installers, I noticed that
> there are two groups of people when talking about software distribution:
> * Some people prefer to have an installer that is similar to the
> SoftwareValet installer.
> * Others prefer to manually copy files over to their system.

The latter is the worst option, you will easily lose track of the files you've 
copied over the file system, and you won't be sharing the application 
libraries if you do this.

> The second option is hassle-free as long as the software package is
> self-contained. For POSIX-style software, this will not be the case, as
> it typically contains files in several standard directories (lib, man,
> include, ...).
> IIRC, Haiku's replacement for the SoftwareValet packages are to be file
> archives (tar.bz2 for example) that include, next to the actual
> application files, an installation recipe of some kind. This kind of
> package format could also be installed manually by those who prefer to
> do so. For this reason, I would opt for an installation recipe that is
> in plain ASCII (or UTF) and is easy to read and interpret by a human.
> Personally, I do not like to spend time organizing my application menu.
> I would like Haiku to know a standard set of software categories: games,
> graphics, internet, ... . The installer package could specify which
> category the software belongs in.
> Having Haiku check (automatically) for updates of software might be an
> interesting feature. Some software on other platforms already have a
> 'check for new version' feature. I think it would be nice to agree on a
> standard for this so that Haiku can check for updates to all installed
> software. This can be done in cooperation with a BeBits-like site or
> simply using individual software homepages.
> An uninstaller is not necessary for software that is fully contained in
> one directory. Not all software falls into this category, therefor I
> think an uninstaller should be provided. One could make use of BeFS file
> attributes to flag a file as being part of a certain software package in
> order to easily uninstall software. I assume this was already the case
> on BeOS?
> Should we implement support for flagging dependencies between software
> packages? I think this would be a very nice feature to have, but it
> might not be worth the trouble. In theory it should be possible to have
> an installer check dependencies and optionally fill them in
> automatically. I'm not sure if it is feasible in practice, though.
> Next, the organization of software.
> A clean way to organize software is to contain each application in its
> own directory. This is not how POSIX software is typically organized
> however (I don't know whether POSIX specifies the bin/lib/share
> structure though). Its possible to contain such an application in one
> directory however (--prefix). This is not so simple for shared libraries
> though (read on).
> I would like to avoid the "DLL hell" that plagues Linux systems.

There's no "DLL hell" in the linux systems, the problem in the linux distros 
is the "dependency hell" which is a very different problem.

> For 
> this, Haiku should be able to have multiple versions of one library
> installed at the same time. An application should be able to find the
> version it requires. I see two options:
> * all libraries in one folder, version number in the library filename
> (also for the headers)
>    * complicates the building process alot?
> * each library in it's own directory (including bin, lib, include and
> share directories)
>    * change LD_LIBRARY_PATH for each application
>    * for building, we need to set CFLAGS and LDFLAGS depending on which
> version is required
>    * this would keep also libraries contained in one directory (yay)
> Some interesting proposals concerning the installation side of this:
> http://www.freelists.org/post/haiku/on-SoftwareValet-for-OBOS,55
> Adrian Panasiuk pointed me to Nix (http://www.linux.com/feature/155922).
> It might be a good source of ideas.
> Kind regards,
> Brecht

Francisco Castro

Other related posts: