This is the mail archive of the
cygwin-apps
mailing list for the Cygwin project.
[BUG] cygport-0.2.7 fails to build multiple binary packages
- From: Stefan Björnelund <stefanb+cygwin-bug at update dot uu dot se>
- To: cygwin-apps at cygwin dot com
- Date: Tue, 9 Jan 2007 22:47:36 +0100
- Subject: [BUG] cygport-0.2.7 fails to build multiple binary packages
While tying to rebuild the gettext-0.15-1 package, (with the intent
with the po-mode emacs mode), I noticed that it did not build
correctly any more.
The problem is that the postinstall/preremove scripts for all but the
primary binary packages are ignored, and thus the packaging step
fails.
I have tried to correct this fault in the attached patch, but as it
was done in a bit of a rush I probably broke as much as I corrected.
Could someone familiar with cygport have a look at it, please?
Some notes on the changes:
* The __prepetc() postinstall function is staring to become too large,
so some part were split out into separate functions:
- The __prepetc_pre_post_old() now contains the old
postinstall/preremove scripts handling.
- The __prepetc_profile() now contains the old
profile scripts handling.
- The __prep_check_pre_post() now postinstall/preremove scripts chmod.
* The __prepetc_pre_post() was added to handle postinstall/preremove
scripts for multiple binary packages.
* The prep_gnu_info.sh script added commands to the wrong
postinstall/preremove script, if more than one was used.
That is it assumed that all info files were located in the primary
package, which is not true for the gettext package.
This was replaced with the new prep_gnu_info() function, (not sure
if this was an imrovement or not). This function now checks which
package the info file belongs to and adds the command to the
corresponding postinstall/preremove scripts.
Unfortunately this change will probably break the
postinstall/preremove scripts in the existing multiple binary
packages. Coincidentally this also removes the need for the
handcrafted postinstall/preremove scripts in the gettext package,
so this change seems to be in line with the intent of the cygport
goals.
Test Package etc:
=================
http://www.update.uu.se/~stefanb/cygwin/bug/cygport-1/cygport-test
http://www.update.uu.se/~stefanb/cygwin/bug/cygport-1/cygport-test.patch
http://www.update.uu.se/~stefanb/cygwin/bug/cygport-1/gettext-0.15-2.tar.bz2
http://www.update.uu.se/~stefanb/cygwin/bug/cygport-1gettext-0.15-2-src.tar.bz2
/Stefan B.