[MacPorts] #30937: intltool @0.40.6_1 Enhancement to support perl5 variants
#30937: intltool @0.40.6_1 Enhancement to support perl5 variants ----------------------------------+----------------------------------------- Reporter: ccarey@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.0.1 Keywords: haspatch | Port: intltool ----------------------------------+----------------------------------------- The attached patch to {{{intltool}}}’s Portfile allows either Perl 5.8, 5.10, 5.12, or 5.14 to be a supported library dependency through the addition of variants with identical names to those for {{{perl5}}}. If no variant be specified when compiling {{{intltool}}}, then the default will be a Perl 5.12 library dependency, which leaves the unpatched behavior unchanged and mirrors the default variant of {{{perl5}}} compilation. -- Ticket URL: <https://trac.macports.org/ticket/30937> MacPorts <http://www.macports.org/> Ports system for Mac OS
#30937: intltool @0.40.6_1 Enhancement to support perl5 variants ----------------------------------+----------------------------------------- Reporter: ccarey@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.0.1 Keywords: haspatch | Port: intltool ----------------------------------+----------------------------------------- Comment(by ccarey@…): A similar patch for {{{help2man}}}, #30938, should be applied and compiled first, since {{{help2man}}} is an ancestral dependency of {{{intltool}}}. -- Ticket URL: <https://trac.macports.org/ticket/30937#comment:1> MacPorts <http://www.macports.org/> Ports system for Mac OS
#30937: intltool @0.40.6_1 Enhancement to support perl5 variants ----------------------------------+----------------------------------------- Reporter: ccarey@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.0.1 Keywords: haspatch | Port: intltool ----------------------------------+----------------------------------------- Changes (by dports@…): * cc: dports@… (added) Comment: Hmm. At the moment, it's important that we keep intltool using perl5.12 only. Because autoconf for intltool-using programs looks at build-time for a version of perl to use for intltool, we have to set `INTLTOOL_PERL` to the perl binary that we installed intltool for, in all the ports that use it. (See, for example, #32425). If we added support for building intltool with a different perl version, we'd have to change those ports to figure out which one was used to build the installed intltool, and set INTLTOOL_PERL accordingly. That might be the way to go, but it'll require some effort... -- Ticket URL: <https://trac.macports.org/ticket/30937#comment:2> MacPorts <http://www.macports.org/> Ports system for Mac OS
#30937: intltool @0.40.6_1 Enhancement to support perl5 variants ----------------------------------+----------------------------------------- Reporter: ccarey@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.0.1 Keywords: haspatch | Port: intltool ----------------------------------+----------------------------------------- Comment(by nonstop.server@…): Replying to [comment:2 dports@…]: Using this code in a pre-configure block to figure out what version of perl was used for intltool at build-time works very well.[[BR]] I was able to install port VLC and all its dependencies this way using perl5.16 only. {{{ pre-configure { # the perl executable should be the one explicitly required by intltool if { [file exists "${prefix}/bin/intltool-prepare"] == 1 } { set channel [open "${prefix}/bin/intltool-prepare"] set line [gets ${channel}] close ${channel} configure.env-append INTLTOOL_PERL=[string trim [string trimright \ [string trimleft ${line} #!] -w]] } else { configure.env-append INTLTOOL_PERL=${prefix}/bin/perl${perl5.major} } } }}} I added PortGroup perl5 to some ports (including non-perl) to get access to variable perl5.major averting the need to set the variable by hand, but I'm not sure if this is acceptable for non-perl ports.[[BR]][[BR]] The following 16 ports have the INTLTOOL_PERL variable set in their Portfile: {{{ ./databases/libgda3/Portfile:configure.env-append INTLTOOL_PERL=${configure.perl} ./databases/libgda4/Portfile:configure.env-append INTLTOOL_PERL=${configure.perl} ./databases/libgda5/Portfile:configure.env-append INTLTOOL_PERL=${configure.perl} ./devel/shared-mime-info/Portfile:configure.env-append INTLTOOL_PERL=${prefix}/bin/perl5.12 ./gnome/gnome-doc-utils/Portfile:configure.env-append INTLTOOL_PERL=${prefix}/bin/perl5.12 ./gnome/gnome-mime-data/Portfile:configure.env-append INTLTOOL_PERL=${prefix}/bin/perl ./gnome/libbonobo/Portfile:configure.env-append INTLTOOL_PERL=${prefix}/bin/perl5.12 ./gnome/libgnomecanvas/Portfile:configure.env-append INTLTOOL_PERL=${prefix}/bin/perl ./gnome/oaf/Portfile: ac_cv_path_INTLTOOL_PERL=${prefix}/bin/perl5 \ ./xfce/xfce-utils/Portfile: INTLTOOL_PERL=${prefix}/bin/perl5.12 ./xfce/xfce4-appfinder/Portfile:configure.env INTLTOOL_PERL=${prefix}/bin/perl5.12 ./xfce/xfce4-session/Portfile:configure.env INTLTOOL_PERL=${prefix}/bin/perl5.12 ./xfce/xfce4-settings/Portfile:configure.env INTLTOOL_PERL=${prefix}/bin/perl5.12 ./xfce/xfdesktop/Portfile:configure.env INTLTOOL_PERL=${prefix}/bin/perl5.12 ./xfce/xfprint/Portfile:configure.env INTLTOOL_PERL=${prefix}/bin/perl5.12 ./xfce/xfwm4/Portfile:configure.env INTLTOOL_PERL=${prefix}/bin/perl5.12 }}} Hopefully this will help to get intltool and intltool-using programs separated from a specific perl version. -- Ticket URL: <https://trac.macports.org/ticket/30937#comment:4> MacPorts <http://www.macports.org/> Ports system for Mac OS
#30937: intltool @0.40.6_1 Enhancement to support perl5 variants --------------------------+-------------------------------- Reporter: ccarey@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.0.1 Resolution: | Keywords: haspatch Port: intltool | --------------------------+-------------------------------- Comment (by raimue@…): I added the `INTLTOOL_PERL` variable to port libsoup in r99246. -- Ticket URL: <https://trac.macports.org/ticket/30937#comment:5> MacPorts <http://www.macports.org/> Ports system for Mac OS
#30937: intltool @0.40.6_1 Enhancement to support perl5 variants --------------------------+-------------------------------- Reporter: ccarey@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.0.1 Resolution: | Keywords: haspatch Port: intltool | --------------------------+-------------------------------- Comment (by raimue@…): I added the `INTLTOOL_PERL` variable to port gegl in r99259. -- Ticket URL: <https://trac.macports.org/ticket/30937#comment:6> MacPorts <http://www.macports.org/> Ports system for Mac OS
#30937: intltool @0.40.6_1 Enhancement to support perl5 variants --------------------------+-------------------------------- Reporter: ccarey@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.0.1 Resolution: | Keywords: haspatch Port: intltool | --------------------------+-------------------------------- Comment (by raimue@…): Fixed gtkspell2 in r99771, inkscape in r99772. Maybe it's time for a PortGroup to avoid changing each dependent port once again when the version of perl used for intltool changes? -- Ticket URL: <https://trac.macports.org/ticket/30937#comment:7> MacPorts <http://www.macports.org/> Ports system for Mac OS
#30937: intltool @0.40.6_1 Enhancement to support perl5 variants --------------------------+-------------------------------- Reporter: ccarey@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.0.1 Resolution: | Keywords: haspatch Port: intltool | --------------------------+-------------------------------- Comment (by ryandesign@…): intltool-1.0.tcl: {{{ depends_build-append port:intltool configure.env-append INTLTOOL_PERL=${prefix}/bin/perl5.12 }}} ? -- Ticket URL: <https://trac.macports.org/ticket/30937#comment:8> MacPorts <http://www.macports.org/> Ports system for Mac OS
#30937: intltool @0.40.6_1 Enhancement to support perl5 variants --------------------------+-------------------------------- Reporter: ccarey@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.0.1 Resolution: | Keywords: haspatch Port: intltool | --------------------------+-------------------------------- Changes (by raimue@…): * cc: raimue@… (added) Comment: Fixed gimp2 in r100415. An alternative and maybe the better way to fix the issue would be to change `${prefix}/share/aclocal/intltool.m4` not to detect any `perl` binary, but use the path `${prefix}/bin/perl5.XY` that was used when building intltool. This would be a patch to the port intltool itself and would allow to use the variant approach originally suggested in this ticket. -- Ticket URL: <https://trac.macports.org/ticket/30937#comment:10> MacPorts <http://www.macports.org/> Ports system for Mac OS
#30937: intltool @0.40.6_1 Enhancement to support perl5 variants --------------------------+-------------------------------- Reporter: ccarey@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.0.1 Resolution: | Keywords: haspatch Port: intltool | --------------------------+-------------------------------- Comment (by raimue@…): Replying to [comment:10 raimue@…]:
An alternative and maybe the better way to fix the issue would be to change `${prefix}/share/aclocal/intltool.m4` not to detect any `perl` binary, but use the path `${prefix}/bin/perl5.XY` that was used when building intltool. This would be a patch to the port intltool itself and would allow to use the variant approach originally suggested in this ticket.
I looked into this approach, but unfortunately this would not remove all changes from the port using intltool. The distributed software might already ship a copy of the macros from intltool.m4 as a local version in aclocal.m4. In this case, it is still required to specify the `INTLTOOL_PERL` variable in the Portfile or, as an alternative, regenerate the aclocal.m4 using something like `autogen.sh` or `autoreconf`. Forcing a regenerate of the autotools related files is more intrusive than simply specifying the required environment variable, so I have to acknowledge that my proposal would not be the better fix. -- Ticket URL: <https://trac.macports.org/ticket/30937#comment:11> MacPorts <http://www.macports.org/> Ports system for Mac OS
#30937: intltool @0.40.6_1 Enhancement to support perl5 variants --------------------------+-------------------------------- Reporter: ccarey@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.0.1 Resolution: | Keywords: haspatch Port: intltool | --------------------------+-------------------------------- Comment (by raimue@…): Fixed zenity in r100455. -- Ticket URL: <https://trac.macports.org/ticket/30937#comment:12> MacPorts <http://www.macports.org/> Ports system for Mac OS
#30937: intltool @0.40.6_1 Enhancement to support perl5 variants --------------------------+-------------------------------- Reporter: ccarey@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.0.1 Resolution: | Keywords: haspatch Port: intltool | --------------------------+-------------------------------- Comment (by jmr@…): You're right that the macro is fundamentally broken, but it's already baked into countless configure scripts. Maybe we could at least have intltool install a file indicating which perl it uses, so the dependents can do something like: {{{ configure.env-append INTLTOOL_PERL=[exec cat ${prefix}/share/intltool/perl_path] }}} which then allows the version used to be updated without breaking everything. -- Ticket URL: <https://trac.macports.org/ticket/30937#comment:13> MacPorts <http://www.macports.org/> Ports system for Mac OS
#30937: intltool @0.40.6_1 Enhancement to support perl5 variants --------------------------+-------------------------------- Reporter: ccarey@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.0.1 Resolution: | Keywords: haspatch Port: intltool | --------------------------+-------------------------------- Comment (by ryandesign@…): Any comment on the [comment:8 two-line portgroup] proposed earlier? -- Ticket URL: <https://trac.macports.org/ticket/30937#comment:14> MacPorts <http://www.macports.org/> Ports system for Mac OS
#30937: intltool @0.40.6_1 Enhancement to support perl5 variants --------------------------+-------------------------------- Reporter: ccarey@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.0.1 Resolution: | Keywords: haspatch Port: intltool | --------------------------+-------------------------------- Comment (by jmr@…): Not a lot of point since using the PortGroup takes one line anyway and reduces clarity. -- Ticket URL: <https://trac.macports.org/ticket/30937#comment:15> MacPorts <http://www.macports.org/> Ports system for Mac OS
#30937: intltool @0.40.6_1 Enhancement to support perl5 variants --------------------------+-------------------------------- Reporter: ccarey@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.0.1 Resolution: | Keywords: haspatch Port: intltool | --------------------------+-------------------------------- Comment (by ryandesign@…): It would embody the "don't repeat yourself" principle and give us a single place where the perl version number can be changed when the time comes. -- Ticket URL: <https://trac.macports.org/ticket/30937#comment:16> MacPorts <http://www.macports.org/> Ports system for Mac OS
#30937: intltool @0.40.6_1 Enhancement to support perl5 variants --------------------------+-------------------------------- Reporter: ccarey@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.0.1 Resolution: | Keywords: haspatch Port: intltool | --------------------------+-------------------------------- Comment (by jeremyhu@…): There's no need to use INTLTOOL_PERL at all, anywhere. All setting it does is allow you to pass that configure check. It has absolutely no baring on the built product because intltool has the correct path in its #! r107542 removes it from intltool.m4 Just remove the envvar from Ports and have them autoreconf to pickup the fixed macro. -- Ticket URL: <https://trac.macports.org/ticket/30937#comment:18> MacPorts <http://www.macports.org/> Ports system for OS X
participants (1)
-
MacPorts