[maemo-developers] Considering /opt and MyDocs in your packages

From: Mohammed Hassan mohammed.2.hassan at nokia.com
Date: Thu Sep 10 15:16:34 EEST 2009
On Thu, 2009-09-10 at 13:35 +0200, Vollmer Marius (Nokia-D/Helsinki)
wrote:
> "Hassan Mohammed.2 (Nokia-D/Helsinki)" <mohammed.2.hassan at nokia.com>
> writes:
> 
> > And that indication is already a packaging difference.
> > I'd rather do ./configure --prefix=/opt/<package> and that's it.
> 
> And then you have to deal with the fallout from that.  If you are ready
> to do that, more power to you, but I really would like to keep a very
> low profile on using /opt/maemo: there are better ways to give more
> space to the rootfs and we should make it easy to stop using /opt/maemo
> again.
> 
> I really hope this is only temporary.
> 
> If you want to use /opt for other reasons, for example because you like
> the cleanliness of storing all your files below /opt/<package>, then I
> don't want to stop you, of course.
> 
> But very few packages do this in practice, and it doesn't look like a
> obviously good thing to me either.  Executable programs and libraries
> _are_ in a flat namespace, and you can not avoid conflicts by storing
> them outside of the usual /bin, /lib etc directories.  For me, it's a
> feature that two installed packages can't both contain libfoo.so.0, and
> I want the package management tools to tell me about this conflict.

Well, ./configure --prefix=/opt/maemo then. I also don't like to
"namespace" packages unless I build them from source and I
use /usr/local/package from there but that's another issue.

I just feel that passing a prefix is a cleaner solution but that's IMHO.

By passing a prefix, you can:
1) add /opt/maemo/{bin,sbin} to $PATH
2) add /opt/maemo/lib to /etc/ld.so.conf (or /etc/ld.so.conf.d)
3) compile and install stuff and that's it.

Some applications still hardcode paths sometimes and will probably fail
but then they should be fixed. The advantage is that you get rid of the
symlinks and stuff.

Only problem is when we start getting libfoo1 and libfoo2. One of them
goes to /usr/lib and the other to /opt/maemo/lib :(


-- 
Maemo Software
Nokia Devices

More information about the maemo-developers mailing list