[beports] Re: making binary zips

> I'm trying something different to capture all of the installed files
> for things built using the GNU system.  Here's what I did, first I
> got
> it to the point where I knew everything that is required to build the
> package, built it and tested it, then ran make clean.  For my porting
> efforts I've been using the new Haiku /boot/common as my --prefix
> target.  I make a new folder called say /boot/target, then use
> ./configure --prefix=/boot/target, then make, make install.  Now I
> rename target to common and zip up /boot/common into a file called
> port-haiku-x.x.x.zip

This can't work in some cases, and is incorrect.

While I use --target=/boot/test-foo sometimes to see what files get
installed where, it's the wrong method as many programs actually
hardcode paths based on the configure argument, so if you use that and
then move it it will break.

> Then I delete this new common folder and rename the common-1 back to
> common.
> I'm guessing there's other ways to do this and only capture the files
> that should be included in a binary zip file.  Anyone have other
> ideas
> on this?

The correct method is to use DESTDIR on autotools-based things.
However not all software support it.
Some non autotools based things use a different variable name also.
On projects supporting it one sets the target to the correct install
path, and install with DESTDIR set to some place that is to hold a
mirror of the intended target filesystem.
I use something like:
mkdir /boot/test-foo
./configure --target=/boot/common (or $HOME/config or /boot/beos when I
used to package for Zeta)
make
make install DESTDIR=/boot/test-foo
cd /boot/test-foo/boot
zip -ry9 foo.bin.zip *

See the released sources of OSS projects used in Zeta for the
GNUmakefile and the autotools based engine I wrote.

> Note that indent then created several new folders in the common
> folder, mostly for documentation type stuff.

Also, we might want to have guidelines for documentation and other
shared files in Haiku, though we can't really stop ppl to install
things to $prefix/{shared|common|lib|whatever} really...

François.

--
BePorts homepage - http://tools.assembla.com/BePorts
List archives: http://www.freelists.org/archives/beports
Administrative contact: brecht@xxxxxxxxxxx

Other related posts: