[MacPorts] #47015: Usage of perl variant for a perl application
#47015: Usage of perl variant for a perl application ------------------------------+---------------------------------- Reporter: Joel.Brogniart@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.3 Keywords: perl | Port: auto-multiple-choice ------------------------------+---------------------------------- Hi, Using informations from <http://trac.macports.org/ticket/46570> I tried to modify port x11/auto-multiple-choice to use perl variants. I added the lines: PortGroup perl5 1.0 ... perl5.require_variant yes perl5.conflict_variants yes perl5.branches 5.16 5.18 5.20 perl5.create_variants ${perl5.branches} and changed all "port:p5.16" to "port:p${perl5.major}" All my tests where done after having "sudo port uninstall installed" before . If I do sudo port install auto-multiple-choice auto-multiple-choice All works fine, the application is built, installed and works. If I do sudo port install perl5 sudo port install auto-multiple-choice auto-multiple-choice All works fine too, the application is built, installed and works. But if I do sudo port install perl5 +perl5_20 sudo port install auto-multiple-choice auto-multiple-choice The application is built, installed but when launched I get the error: Can't locate AMC/Basic.pm in @INC (you may need to install the AMC::Basic module) (@INC contains: /opt/local/lib/perl5/site_perl/5.20/darwin-thread- multi-2level /opt/local/lib/perl5/site_perl/5.20 /opt/local/lib/perl5/vendor_perl/5.20/darwin-thread-multi-2level /opt/local/lib/perl5/vendor_perl/5.20 /opt/local/lib/perl5/5.20/darwin- thread-multi-2level /opt/local/lib/perl5/5.20 .) at /opt/local/lib/AMC/perl/AMC-gui.pl line 45. BEGIN failed--compilation aborted at /opt/local/lib/AMC/perl/AMC-gui.pl line 45. I get the same error when I install perl5_18. All auto-multiple-choice files stays at the same places, whatever perl variant is installed. The unreachable file is in "/opt/local/lib/perl5/vendor_perl/AMC/Basic.pm". With the default perl5 install (perl5_16), it seems that @INC contains the path "/opt/local/lib/perl5/vendor_perl' but not with perl5_18 and perl5_20. Are there other informations I should have added for the application to work with perl5_18 or perl5_20 variants? -- Ticket URL: <https://trac.macports.org/ticket/47015> MacPorts <https://www.macports.org/> Ports system for OS X
#47015: Usage of perl variant for a perl application -----------------------------------+-------------------------------- Reporter: Joel.Brogniart@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.3 Resolution: | Keywords: perl Port: auto-multiple-choice | -----------------------------------+-------------------------------- Comment (by Joel.Brogniart@…): Sorry, I forgot to do some adaptation after my paste. Using informations from ticket:46570 I tried to modify port x11/auto- multiple-choice to user perl variants. I added the lines: {{{ PortGroup perl5 1.0 ... perl5.require_variant yes perl5.conflict_variants yes perl5.branches 5.16 5.18 5.20 perl5.create_variants ${perl5.branches} }}} and changed all "{{(port:p5.16}}}" to "{{{port:p${perl5.major}"}}} All my tests where done after having "{{{sudo port uninstall installed}}}" before . If I do {{{ sudo port install auto-multiple-choice auto-multiple-choice }}} All works fine, the application is built, installed and works. If I do {{{ sudo port install perl5 sudo port install auto-multiple-choice auto-multiple-choice }}} All works fine too, the application is built, installed and works. But if I do {{{ sudo port install perl5 +perl5_20 sudo port install auto-multiple-choice auto-multiple-choice }}} The application is built, installed but when launched I get the error: {{{ Can't locate AMC/Basic.pm in @INC (you may need to install the AMC::Basic module) (@INC contains: /opt/local/lib/perl5/site_perl/5.20/darwin-thread- multi-2level /opt/local/lib/perl5/site_perl/5.20 /opt/local/lib/perl5/vendor_perl/5.20/darwin-thread-multi-2level /opt/local/lib/perl5/vendor_perl/5.20 /opt/local/lib/perl5/5.20/darwin- thread-multi-2level /opt/local/lib/perl5/5.20 .) at /opt/local/lib/AMC/perl/AMC-gui.pl line 45. BEGIN failed--compilation aborted at /opt/local/lib/AMC/perl/AMC-gui.pl line 45. }}} I get the same error when I install perl5_18. All auto-multiple-choice files stays at the same places, whatever perl variant is installed. The unreachable file is in "{{{/opt/local/lib/perl5/vendor_perl/AMC/Basic.pm}}}". With the default perl5 install (perl5_16), it seems that {{{@INC}}} contains the path "{{{/opt/local/lib/perl5/vendor_perl}}}" but not with perl5_18 and perl5_20. Are there other informations I should have added for the application to work with perl5_18 or perl5_20 variants? -- Ticket URL: <https://trac.macports.org/ticket/47015#comment:1> MacPorts <https://www.macports.org/> Ports system for OS X
#47015: Usage of perl variant for a perl application -----------------------------------+-------------------------------- Reporter: Joel.Brogniart@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.3 Resolution: | Keywords: Port: auto-multiple-choice | -----------------------------------+-------------------------------- Changes (by mf2k@…): * keywords: perl => Old description:
Hi,
Using informations from <http://trac.macports.org/ticket/46570> I tried to modify port x11/auto-multiple-choice to use perl variants. I added the lines:
PortGroup perl5 1.0 ... perl5.require_variant yes perl5.conflict_variants yes perl5.branches 5.16 5.18 5.20 perl5.create_variants ${perl5.branches}
and changed all "port:p5.16" to "port:p${perl5.major}"
All my tests where done after having "sudo port uninstall installed" before .
If I do sudo port install auto-multiple-choice auto-multiple-choice
All works fine, the application is built, installed and works.
If I do sudo port install perl5 sudo port install auto-multiple-choice auto-multiple-choice
All works fine too, the application is built, installed and works.
But if I do sudo port install perl5 +perl5_20 sudo port install auto-multiple-choice auto-multiple-choice The application is built, installed but when launched I get the error:
Can't locate AMC/Basic.pm in @INC (you may need to install the AMC::Basic module) (@INC contains: /opt/local/lib/perl5/site_perl/5.20/darwin- thread-multi-2level /opt/local/lib/perl5/site_perl/5.20 /opt/local/lib/perl5/vendor_perl/5.20/darwin-thread-multi-2level /opt/local/lib/perl5/vendor_perl/5.20 /opt/local/lib/perl5/5.20/darwin- thread-multi-2level /opt/local/lib/perl5/5.20 .) at /opt/local/lib/AMC/perl/AMC-gui.pl line 45. BEGIN failed--compilation aborted at /opt/local/lib/AMC/perl/AMC-gui.pl line 45.
I get the same error when I install perl5_18. All auto-multiple-choice files stays at the same places, whatever perl variant is installed. The unreachable file is in "/opt/local/lib/perl5/vendor_perl/AMC/Basic.pm". With the default perl5 install (perl5_16), it seems that @INC contains the path "/opt/local/lib/perl5/vendor_perl' but not with perl5_18 and perl5_20.
Are there other informations I should have added for the application to work with perl5_18 or perl5_20 variants?
New description: Hi, Using informations from ticket:46570 I tried to modify port x11/auto- multiple-choice to use perl variants. I added the lines: {{{ PortGroup perl5 1.0 ... perl5.require_variant yes perl5.conflict_variants yes perl5.branches 5.16 5.18 5.20 perl5.create_variants ${perl5.branches} }}} and changed all "port:p5.16" to "port:p${perl5.major}" All my tests where done after having "sudo port uninstall installed" before . If I do {{{ sudo port install auto-multiple-choice auto-multiple-choice }}} All works fine, the application is built, installed and works. If I do {{{ sudo port install perl5 sudo port install auto-multiple-choice auto-multiple-choice }}} All works fine too, the application is built, installed and works. But if I do {{{ sudo port install perl5 +perl5_20 sudo port install auto-multiple-choice auto-multiple-choice }}} The application is built, installed but when launched I get the error: {{{ Can't locate AMC/Basic.pm in @INC (you may need to install the AMC::Basic module) (@INC contains: /opt/local/lib/perl5/site_perl/5.20/darwin-thread- multi-2level /opt/local/lib/perl5/site_perl/5.20 /opt/local/lib/perl5/vendor_perl/5.20/darwin-thread-multi-2level /opt/local/lib/perl5/vendor_perl/5.20 /opt/local/lib/perl5/5.20/darwin- thread-multi-2level /opt/local/lib/perl5/5.20 .) at /opt/local/lib/AMC/perl/AMC-gui.pl line 45. BEGIN failed--compilation aborted at /opt/local/lib/AMC/perl/AMC-gui.pl line 45. }}} I get the same error when I install perl5_18. All auto-multiple-choice files stays at the same places, whatever perl variant is installed. The unreachable file is in "/opt/local/lib/perl5/vendor_perl/AMC/Basic.pm". With the default perl5 install (perl5_16), it seems that @INC contains the path "/opt/local/lib/perl5/vendor_perl' but not with perl5_18 and perl5_20. Are there other informations I should have added for the application to work with perl5_18 or perl5_20 variants? -- -- Ticket URL: <https://trac.macports.org/ticket/47015#comment:2> MacPorts <https://www.macports.org/> Ports system for OS X
#47015: Usage of perl variant for a perl application -----------------------------------+-------------------------------- Reporter: Joel.Brogniart@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.3 Resolution: | Keywords: Port: auto-multiple-choice | -----------------------------------+-------------------------------- Comment (by Joel.Brogniart@…): When I install PERL with: {{{ sudo port install perl5 +perl5_16 }}} @INC contains: {{{ /opt/local/lib/perl5/site_perl/5.16.3/darwin-thread-multi-2level /opt/local/lib/perl5/site_perl/5.16.3 /opt/local/lib/perl5/vendor_perl/5.16.3/darwin-thread-multi-2level /opt/local/lib/perl5/vendor_perl/5.16.3 /opt/local/lib/perl5/5.16.3/darwin-thread-multi-2level /opt/local/lib/perl5/5.16.3 /opt/local/lib/perl5/site_perl /opt/local/lib/perl5/vendor_perl }}} but when I install PERL with: {{{ sudo port install perl5 +perl5_22 }}} @INC contains: {{{ /opt/local/lib/perl5/site_perl/5.22/darwin-thread-multi-2level /opt/local/lib/perl5/site_perl/5.22 /opt/local/lib/perl5/vendor_perl/5.22/darwin-thread-multi-2level /opt/local/lib/perl5/vendor_perl/5.22 /opt/local/lib/perl5/5.22/darwin-thread-multi-2level /opt/local/lib/perl5/5.22 }}} In the last case, as "/opt/local/lib/perl5/vendor_perl" is not in @INC, auto-multiple-choice can't find his files. -- Ticket URL: <https://trac.macports.org/ticket/47015#comment:3> MacPorts <https://www.macports.org/> Ports system for OS X
#47015: Usage of perl variant for a perl application -----------------------------------+-------------------------------- Reporter: Joel.Brogniart@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.3 Resolution: | Keywords: Port: auto-multiple-choice | -----------------------------------+-------------------------------- Comment (by Joel.Brogniart@…): I found the source of the problem. After 5.16, the PERL_VENDORLIB_STEM changed from "/opt/local/lib/perl5/vendor_perl" to "/opt/local/lib/perl5/vendor_perl/5.xx". I'll make a patch to adapt the port. -- Ticket URL: <https://trac.macports.org/ticket/47015#comment:4> MacPorts <https://www.macports.org/> Ports system for OS X
#47015: Usage of perl variant for a perl application -----------------------------------+-------------------------------- Reporter: Joel.Brogniart@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.3 Resolution: | Keywords: Port: auto-multiple-choice | -----------------------------------+-------------------------------- Changes (by ionic@…): * cc: ionic@… (added) Comment: That's bad. What does the application install? It's obviously also installing a perl module, which should probably be split up as `p5-acm- basic` (or whatever else there is. `ACM::Basic` is probably not the only module.) Afterwards, `auto-multiple-choice` should depend on `p5.xx-acm-basic` based on it selected variant and not install any modules by itself (so as not to conflict with `p5.xx-acm-basic`.) -- Ticket URL: <https://trac.macports.org/ticket/47015#comment:5> MacPorts <https://www.macports.org/> Ports system for OS X
#47015: Usage of perl variant for a perl application -----------------------------------+-------------------------------- Reporter: Joel.Brogniart@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.3 Resolution: | Keywords: Port: auto-multiple-choice | -----------------------------------+-------------------------------- Comment (by Joel.Brogniart@…): The application install it's own modules in a "AMC" folder inside the vendor_perl folder. How could I get the path for this folder from Macports? I think that is it in the Perl global PERL_VENDORLIB_STEM. But I don't know how to access it from a Macport Portfile. -- Ticket URL: <https://trac.macports.org/ticket/47015#comment:6> MacPorts <https://www.macports.org/> Ports system for OS X
#47015: Usage of perl variant for a perl application -----------------------------------+-------------------------------- Reporter: Joel.Brogniart@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.3 Resolution: | Keywords: Port: auto-multiple-choice | -----------------------------------+-------------------------------- Comment (by Joel.Brogniart@…): I found a solution in the perl5-1.0.tcl group file: {{{ perl -V:vendorlib }}} -- Ticket URL: <https://trac.macports.org/ticket/47015#comment:7> MacPorts <https://www.macports.org/> Ports system for OS X
#47015: Usage of perl variant for a perl application -----------------------------------+-------------------------------- Reporter: Joel.Brogniart@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.3 Resolution: | Keywords: Port: auto-multiple-choice | -----------------------------------+-------------------------------- Comment (by Joel.Brogniart@…): This ticket could be close. See ticket #48390. -- Ticket URL: <https://trac.macports.org/ticket/47015#comment:8> MacPorts <https://www.macports.org/> Ports system for OS X
#47015: Usage of perl variant for a perl application -----------------------------------+-------------------------------- Reporter: Joel.Brogniart@… | Owner: macports-tickets@… Type: defect | Status: closed Priority: Normal | Milestone: Component: ports | Version: 2.3.3 Resolution: invalid | Keywords: Port: auto-multiple-choice | -----------------------------------+-------------------------------- Changes (by ionic@…): * status: new => closed * resolution: => invalid -- Ticket URL: <https://trac.macports.org/ticket/47015#comment:9> MacPorts <https://www.macports.org/> Ports system for OS X
participants (1)
-
MacPorts