List Info

Thread: Relocatable install, 1/n




Relocatable install, 1/n
country flaguser name
Switzerland
2008-03-17 09:13:24
This patch provides the meat for relocatable installs.  This
means that 
you can move an installation arbitrarily, for example with:

   # First way, copy to staging directory and move from
there.
   ./configure
   make
   make install DESTDIR=`pwd`
   (cd usr/local && tar cvf - .) | (cd $HOME
&& tar xvf -)

This patch is mostly boring configury.  Some of it will have
to be 
refactored into something pleasant to see, but that can wait
until 
problems are fixed; in the meanwhile you can already run
"./gst" from a 
relocated installation, and that's a good part of the work. 
The only 
part that does not work yet is loading packages, because the
kernel path 
stored in the image is fixed and absolute (and does not move
when you 
restart gst), so the PackageLoader cannot find .star files. 
This will 
be fixed of course, but I don't want to rush in a bad design
so I'll 
give some more thought to it.


To get a relocatable install, several conditions should be
fulfilled. 
On glibc-based systems (e.g. most GNU/Linux distros) a
simple 
"./configure && make" does fulfill them.

1) the exec-prefix and prefix should be identical;

2) the installation should reside entirely within the
prefix; e.g. no 
--localstatedir=/var (I will see if this can be fixed);

3) on Windows, the bindir and libdir should be the same or
shared 
libraries should be disabled;

4) if neither on Windows nor under a glibc-based system,
shared 
libraries should be disabled (period).

If the above conditions are satisfied, and you want a
relocatable 
install, it is suggested that you configure with a
non-existent prefix 
such as "--prefix=/nonexistent".  You can then
apply the above recipe 
like this:

   ./configure --prefix=/nonexistent
   make
   make install DESTDIR=`pwd`
   (cd nonexistent && tar cvf - .) | (cd $HOME
&& tar xvf -)

There's some hope to add relocatability support for Solaris
and Darwin. 
  I'll look into the latter when I have time, the former
should be the 
same as Linux actually.

Paolo

_______________________________________________
help-smalltalk mailing list
help-smalltalkgnu.org

http://lists.gnu.org/mailman/listinfo/help-smalltalk

  
[1]

about | contact  Other archives ( Real Estate discussion Medical topics )