* cygport-0.9.2 in release-2 @ 2008-09-17 1:04 Yaakov (Cygwin Ports) 2008-09-17 13:19 ` Andrew Schulman 0 siblings, 1 reply; 4+ messages in thread From: Yaakov (Cygwin Ports) @ 2008-09-17 1:04 UTC (permalink / raw) To: cygwin-apps -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 I've just made cygport-0.9.2 available in release-2 with the following changes: * SRC_URI: now accepts SRPMs. * PATCH_URI: now accepts multiple-patch tarballs. * Installs documentation into /usr/share/doc/PACKAGE. * Removed support for libtool-1.5. * make_desktop_entry(): Updated spec; accepts additional arguments. * autotools.cygclass: Can now be manually re-inherit()ed. * kde3.cygclass: Add KDevelop 3.5.3; remove support for KDE 3.4. * lua.cygclass: Removed support for lua-5.0. * rox.cygclass: NEW for ROX Desktop packages. * ruby.cygclass: Builds and installs RI docs instead of HTML. * ruby-gnome2.cygclass: Removed support for older versions. If there are any changes you want to see in cygport, please let me know ASAP; I would like to have the major changes out of the way this month, so that cygport isn't a moving target once everything is ready for a 1.7 rebuild. Yaakov -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (Cygwin) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iEYEAREIAAYFAkjQV4cACgkQpiWmPGlmQSObtgCfVyGEpb6QH571dl98xNAoBXcn 7XIAnign7/KmYgyODjX5jaJreY0ODnbE =2kxr -----END PGP SIGNATURE----- ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: cygport-0.9.2 in release-2 2008-09-17 1:04 cygport-0.9.2 in release-2 Yaakov (Cygwin Ports) @ 2008-09-17 13:19 ` Andrew Schulman 2008-09-17 16:47 ` Charles Wilson 0 siblings, 1 reply; 4+ messages in thread From: Andrew Schulman @ 2008-09-17 13:19 UTC (permalink / raw) To: cygwin-apps [-- Attachment #1: Type: text/plain, Size: 1488 bytes --] > * Installs documentation into /usr/share/doc/PACKAGE. Thank you, I can now remove my custom dodoc() function that did this for me. > If there are any changes you want to see in cygport, please let me know > ASAP; I would like to have the major changes out of the way this month, > so that cygport isn't a moving target once everything is ready for a 1.7 > rebuild. For a long time now I've patched every release of cygport with the attached patch, that adds the src_prep_fini_hook(), src_install_init_hook(), and src_install_fini_hook() hook functions. Charles Wilson originally posted a patch for this about 2 years ago (http://www.cygwin.com/ml/cygwin/2007-01/msg00110.html). I used to use src_install_fini_hook(), but I don't think I have any packages that need it any more. I don't think I've ever used src_install_init_hook(), so maybe it's less important. src_prep_fini_hook(), OTOH, I use in almost all of my packages. If cygport doesn't supply it, I'll continue to patch cygport to provide it for my own use. I know that cygport now provides src_patch_hook() and src_unpack_hook(), but both of those functions are run before origsrc is mirrored to src, so it's not possible to use them to modify src and not origsrc. For me they don't do the job. This patch is against cygport 0.9.0. If you think that all or part of it is worth incorporating, I'd be glad to update it for 0.9.2 and address any style or other issues. Thanks, Andrew. [-- Attachment #2: cygport-hooks.patch --] [-- Type: application/octet-stream, Size: 1560 bytes --] --- /usr/bin/cygport.orig 2008-08-26 23:07:26.001000000 -0400 +++ /usr/bin/cygport 2008-08-27 14:05:15.604873700 -0400 @@ -728,6 +728,11 @@ fi } +# provides a hook for cygclasses/cygports to take action +# *after* origsrc directory is mirrored to src directory +src_prep_fini_hook() { + : +} __src_prep() { local sigext; local src_patch; @@ -827,10 +832,15 @@ then cygpatch ${top}/${cygwin_patchfile} ${top}/${src_patchfile}; fi + + cd ${top} + src_prep_fini_hook + cd ${S} } # protect functions readonly -f fetch __mirror_fetch __src_fetch unpack __gpg_verify __mkdirs cygpatch __oldpatch __src_prep +export -f src_prep_fini_hook ################################################################################ @@ -1292,6 +1302,7 @@ # Pre-install steps __prepinstalldirs() { + src_install_init_hook; rm -fr ${D}/*; # circumvent pointless libtool relinking during install @@ -1342,8 +1353,21 @@ cyginstall } +# provides a hook for cygclasses/cygports to take action +# *before* built-in preinstall steps. +src_install_init_hook() { + : +} + +# provides a hook for cygclasses/cygports to take action +# *after* built-in postinstall steps. +src_install_fini_hook() { + : +} + # protect functions export -f dodir keepdir docinto exeinto insinto +export -f src_install_init_hook src_install_fini_hook readonly -f dodir keepdir docinto exeinto insinto __prepinstalldirs cyginstall @@ -1680,6 +1704,7 @@ __prep_empty_dirs; __prepstrip; __prep_libtool_modules; + src_install_fini_hook; } # protect functions ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: cygport-0.9.2 in release-2 2008-09-17 13:19 ` Andrew Schulman @ 2008-09-17 16:47 ` Charles Wilson 2008-09-17 16:54 ` Andrew Schulman 0 siblings, 1 reply; 4+ messages in thread From: Charles Wilson @ 2008-09-17 16:47 UTC (permalink / raw) To: CygWin-Apps [-- Attachment #1: Type: text/plain, Size: 624 bytes --] Andrew Schulman wrote: > For a long time now I've patched every release of cygport with the attached > patch, that adds the src_prep_fini_hook(), src_install_init_hook(), and > src_install_fini_hook() hook functions. Charles Wilson originally posted a > patch for this about 2 years ago > (http://www.cygwin.com/ml/cygwin/2007-01/msg00110.html). Current versions of cygport have a modified form of (some) of these hooks. check out 'src_patch_hook', 'src_unpack_hook'. The only remaining hook that I currently use, but which is not in stock cygport, is src_postinst_hook. Patch (against old 3.10) attached. -- Chuck [-- Attachment #2: cygport-postinst-hook.patch --] [-- Type: text/plain, Size: 2691 bytes --] Index: bin/cygport.in =================================================================== RCS file: /cvsroot/cygwin-ports/cygport/bin/cygport.in,v retrieving revision 1.106 diff -u -r1.106 cygport.in --- bin/cygport.in 23 Apr 2008 14:43:48 -0000 1.106 +++ bin/cygport.in 27 Apr 2008 01:22:43 -0000 @@ -1179,6 +1179,7 @@ # mutable: # USE_DESTDIR # src_install +# src_postinst_hook # # public: # cyginstall @@ -1193,6 +1194,7 @@ # _exeinto_dir # _insinto_dir # __prepinstalldirs +# __src_postinst_hook_exec # ################################################################################ @@ -1296,6 +1298,20 @@ esac } +# src_postinst_hook is an optional function that may be +# defined to modify the cygport 'install' sequence. If defined, +# it is called after the automatic "postinst" function. This +# can be useful if, for instance, the default docdir: +# usr/share/doc/${PN}-${PV} +# is not appropriate, and should be "corrected" prior to +# packaging. See the rxvt-unicode-X cygport for an example. +__src_postinst_hook_exec() { + if __check_function src_postinst_hook + then + __check_unstable src_postinst_hook + fi +} + # provides a default src_install # will be overridden by cygclasses or cygports as necessary src_install() { @@ -2209,11 +2225,11 @@ ;; inst*) __stage Installing; - (__prepinstalldirs && src_install && __src_postinst) 2>&1 | tee ${installlog}; + (__prepinstalldirs && src_install && __src_postinst && __src_postinst_hook_exec) 2>&1 | tee ${installlog}; _status=$?; ;; postinst*) - __src_postinst; + __src_postinst && __src_postinst_hook_exec; _status=$?; ;; list) @@ -2244,14 +2260,14 @@ almostall) __stage Preparing && __src_prep && \ __stage Compiling && src_compile 2>&1 | tee ${compilelog} && \ - __stage Installing && (__prepinstalldirs && src_install && __src_postinst) 2>&1 | tee ${installlog} && \ + __stage Installing && (__prepinstalldirs && src_install && __src_postinst && __src_postinst_hook_exec) 2>&1 | tee ${installlog} && \ __stage Packaging && (__pkg_binpkg && __pkg_pkgcheck && __pkg_srcpkg && __pkg_dist) 2>&1 | tee ${pkglog} _status=$?; ;; all) __stage Preparing && __src_prep && \ __stage Compiling && src_compile 2>&1 | tee ${compilelog} && \ - __stage Installing && (__prepinstalldirs && src_install && __src_postinst) 2>&1 | tee ${installlog} && \ + __stage Installing && (__prepinstalldirs && src_install && __src_postinst && __src_postinst_hook_exec) 2>&1 | tee ${installlog} && \ __stage Packaging && (__pkg_binpkg && __pkg_pkgcheck && __pkg_srcpkg && __pkg_dist) 2>&1 | tee ${pkglog} && \ __finish; _status=$?; ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: cygport-0.9.2 in release-2 2008-09-17 16:47 ` Charles Wilson @ 2008-09-17 16:54 ` Andrew Schulman 0 siblings, 0 replies; 4+ messages in thread From: Andrew Schulman @ 2008-09-17 16:54 UTC (permalink / raw) To: cygwin-apps > > For a long time now I've patched every release of cygport with the attached > > patch, that adds the src_prep_fini_hook(), src_install_init_hook(), and > > src_install_fini_hook() hook functions. Charles Wilson originally posted a > > patch for this about 2 years ago > > (http://www.cygwin.com/ml/cygwin/2007-01/msg00110.html). > > Current versions of cygport have a modified form of (some) of these hooks. > > check out 'src_patch_hook', 'src_unpack_hook'. Thanks, but as I explained, src_patch_hook() and src_unpack_hook() are both called before origsrc is copied to src. So, they're unable to modify src separately from origsrc. This matters, because when cygport generates the cygwin.patch file, it compares origsrc to src, so changes made to both are not reflected in the patch. For this reason, I find src_prep_fini_hook() essential for several of my packages. Thanks, Andrew. ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2008-09-17 16:54 UTC | newest] Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2008-09-17 1:04 cygport-0.9.2 in release-2 Yaakov (Cygwin Ports) 2008-09-17 13:19 ` Andrew Schulman 2008-09-17 16:47 ` Charles Wilson 2008-09-17 16:54 ` Andrew Schulman
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).