Skip Menu |
 

This queue is for tickets about the PAR-Packer CPAN distribution.

Report information
The Basics
Id: 101000
Status: rejected
Priority: 0/
Queue: PAR-Packer

People
Owner: Nobody in particular
Requestors: angan.das [...] intel.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



CC: "Jayapal, Pradeep Kumar" <pradeep.kumar.jayapal [...] intel.com>
Subject: Perl pp error: Nested packages
Date: Thu, 18 Dec 2014 21:15:30 +0000
To: "bug-PAR-Packer [...] rt.cpan.org" <bug-PAR-Packer [...] rt.cpan.org>
From: "Das, Angan" <angan.das [...] intel.com>
Download (untitled) / with headers
text/plain 925b
Hi Roderich, Pradeep (from our team) has a recent issue with 'pp' -- nested Perl packages (used within 'included/called' Perl scripts from parent Perl script) complain being not found. Environment does not seem to be an issue over here, and including all packages within the parent script does not help. Probably the main code spawns off a separate process from 'pp'-transformed code, and it does not have much clue where to pick up the package from. Could you kindly help? - Angan Show quoted text
-----Original Message----- From: Roderich Schupp via RT [mailto:bug-PAR-Packer@rt.cpan.org] Sent: Sunday, November 02, 2014 5:54 AM To: Das, Angan Subject: [rt.cpan.org #95417] Resolved: Perl pp error: Seeking some info <URL: https://rt.cpan.org/Ticket/Display.html?id=95417 > According to our records, your request has been resolved. If you have any further questions or concerns, please respond to this message.
Download (untitled) / with headers
text/plain 709b
On 2014-12-18 16:15:48, angan.das@intel.com wrote: Show quoted text
> Pradeep (from our team) has a recent issue with 'pp' -- nested Perl > packages (used within 'included/called' Perl scripts from parent Perl > script) complain being not found. Environment does not seem to be an > issue over here, and including all packages within the parent script > does not help. > > Could you kindly help?
Sorry, rt.cpan.org is a *bug* tracker: clearly state what you were trying to do, what you expected and what you got instead. Your report does not contain anything base a diagnosis on. Stuff like "need some help" do not belong on the bug tracker, please take them to the PAR mailing list, par@perl.org, instead. Cheers, Roderich
CC: "Jayapal, Pradeep Kumar" <pradeep.kumar.jayapal [...] intel.com>
Subject: RE: [rt.cpan.org #101000] Perl pp error: Nested packages
Date: Fri, 19 Dec 2014 18:56:05 +0000
To: "bug-PAR-Packer [...] rt.cpan.org" <bug-PAR-Packer [...] rt.cpan.org>
From: "Das, Angan" <angan.das [...] intel.com>
Download (untitled) / with headers
text/plain 1.5k
Roderich, Thanks. I am not sure why Pradeep got stripped off from the mail thread. Anyways, looks like a 'bug' to us (from the what we could decipher from the user guide). Now, whether it is a real bug to be fixed or is there is some work around -- I will let you decide. Pradeep, could you kindly give some snippets of the error messages you got (hiding relevant Intel IP information) that might help Roderich to give some pointers. Also, please send the same email to "par@perl.org" so that we might get some help from there as well. - Angan Show quoted text
-----Original Message----- From: Roderich Schupp via RT [mailto:bug-PAR-Packer@rt.cpan.org] Sent: Friday, December 19, 2014 4:09 AM To: Das, Angan Subject: [rt.cpan.org #101000] Perl pp error: Nested packages <URL: https://rt.cpan.org/Ticket/Display.html?id=101000 > On 2014-12-18 16:15:48, angan.das@intel.com wrote:
> Pradeep (from our team) has a recent issue with 'pp' -- nested Perl > packages (used within 'included/called' Perl scripts from parent Perl > script) complain being not found. Environment does not seem to be an > issue over here, and including all packages within the parent script > does not help. > > Could you kindly help?
Sorry, rt.cpan.org is a *bug* tracker: clearly state what you were trying to do, what you expected and what you got instead. Your report does not contain anything base a diagnosis on. Stuff like "need some help" do not belong on the bug tracker, please take them to the PAR mailing list, par@perl.org, instead. Cheers, Roderich
CC: "Das, Angan" <angan.das [...] intel.com>
Subject: RE: [rt.cpan.org #101000] Perl pp error: Nested packages
Date: Fri, 19 Dec 2014 23:52:26 +0000
To: "bug-PAR-Packer [...] rt.cpan.org" <bug-PAR-Packer [...] rt.cpan.org>, "'par [...] perl.org'" <par [...] perl.org>
From: "Jayapal, Pradeep Kumar" <pradeep.kumar.jayapal [...] intel.com>
Download (untitled) / with headers
text/plain 2.8k
Hi Roderich, Let me try to give a clear picture of my scenario, I have a perl script which I am compiling using pp. In the executable returned as output by pp we see few Intel specific paths being mentioned (eg: /<prefix>/intel/<suffix>). To keep it generic and to ensure that Intel specific paths are not used we replace all the occurrence of "intel" with "dummy" in the PP output executable file. But we see that when we run the executable and another Perl script is called from inside this executable (system call in the original Perl script) we get an error in the lines of, Can't locate warnings.pm in @INC (@INC contains: /<prefix>/dummy/<suffix>) at <perl_script_called_using_systemcall> at line <line_no>. BEGIN failed--compilation aborted at <perl_script_called_using_systemcall> at line <line_no>. The <line_no> and warnings.pm points to "use warnings;" line in the Perl script called from the executable using system calls. Is there way to prevent the PP output executable from controlling @INC for the system calls of Perl scripts inside the executable? Regards, Pradeep Show quoted text
-----Original Message----- From: Das, Angan Sent: Friday, December 19, 2014 10:56 AM To: bug-PAR-Packer@rt.cpan.org Cc: Jayapal, Pradeep Kumar Subject: RE: [rt.cpan.org #101000] Perl pp error: Nested packages Roderich, Thanks. I am not sure why Pradeep got stripped off from the mail thread. Anyways, looks like a 'bug' to us (from the what we could decipher from the user guide). Now, whether it is a real bug to be fixed or is there is some work around -- I will let you decide. Pradeep, could you kindly give some snippets of the error messages you got (hiding relevant Intel IP information) that might help Roderich to give some pointers. Also, please send the same email to "par@perl.org" so that we might get some help from there as well. - Angan
-----Original Message----- From: Roderich Schupp via RT [mailto:bug-PAR-Packer@rt.cpan.org] Sent: Friday, December 19, 2014 4:09 AM To: Das, Angan Subject: [rt.cpan.org #101000] Perl pp error: Nested packages <URL: https://rt.cpan.org/Ticket/Display.html?id=101000 > On 2014-12-18 16:15:48, angan.das@intel.com wrote:
> Pradeep (from our team) has a recent issue with 'pp' -- nested Perl > packages (used within 'included/called' Perl scripts from parent Perl > script) complain being not found. Environment does not seem to be an > issue over here, and including all packages within the parent script > does not help. > > Could you kindly help?
Sorry, rt.cpan.org is a *bug* tracker: clearly state what you were trying to do, what you expected and what you got instead. Your report does not contain anything base a diagnosis on. Stuff like "need some help" do not belong on the bug tracker, please take them to the PAR mailing list, par@perl.org, instead. Cheers, Roderich
CC: "par [...] perl.org" <par [...] perl.org>
Subject: Re: [rt.cpan.org #101000] Perl pp error: Nested packages
Date: Sun, 21 Dec 2014 17:36:04 +0100
To: bug-PAR-Packer [...] rt.cpan.org
From: Bagdevi <bagdevi.mishra [...] gmail.com>
Download (untitled) / with headers
text/plain 4.2k
Hello Pradeep and Angan, I had a similar situation, where I was calling a perl script (B) from the compiled executable (A) and, as it is happening with you, it did not work for me as well because of the system path issues. Well, the direct solution is, one should keep the (B) as a sub routine of perl code (A), which would solve the issue. But for some reason (constrains), I could not put both these perl scripts together. I had a work around which solved my problem. 1// first I compiled the perl code (B) individually and make the executable. 2// from perl script (A) I called the executable for (B) (not the perl code (B)). 3// I packed the executable (B) along with (A) while compiling (A). This, at the end, takes up much space as it bundles up most of the needed packages twice, but at least it works that's way. Hope that helps. Regards, Bagdevi Mishra. On Sat, Dec 20, 2014 at 12:52 AM, Jayapal, Pradeep Kumar via RT < bug-PAR-Packer@rt.cpan.org> wrote: Show quoted text
> Fri Dec 19 18:52:40 2014: Request 101000 was acted upon. > Transaction: Correspondence added by pradeep.kumar.jayapal@intel.com > Queue: PAR-Packer > Subject: RE: [rt.cpan.org #101000] Perl pp error: Nested packages > Broken in: (no value) > Severity: (no value) > Owner: Nobody > Requestors: angan.das@intel.com > Status: rejected > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=101000 > > > > Hi Roderich, > > Let me try to give a clear picture of my scenario, > > I have a perl script which I am compiling using pp. In the executable > returned as output by pp we see few Intel specific paths being mentioned > (eg: /<prefix>/intel/<suffix>). To keep it generic and to ensure that Intel > specific paths are not used we replace all the occurrence of "intel" with > "dummy" in the PP output executable file. > But we see that when we run the executable and another Perl script is > called from inside this executable (system call in the original Perl > script) we get an error in the lines of, > > Can't locate warnings.pm in @INC (@INC contains: > /<prefix>/dummy/<suffix>) at <perl_script_called_using_systemcall> at line > <line_no>. > BEGIN failed--compilation aborted at <perl_script_called_using_systemcall> > at line <line_no>. > > The <line_no> and warnings.pm points to "use warnings;" line in the Perl > script called from the executable using system calls. Is there way to > prevent the PP output executable from controlling @INC for the system calls > of Perl scripts inside the executable? > > Regards, > Pradeep > > > -----Original Message----- > From: Das, Angan > Sent: Friday, December 19, 2014 10:56 AM > To: bug-PAR-Packer@rt.cpan.org > Cc: Jayapal, Pradeep Kumar > Subject: RE: [rt.cpan.org #101000] Perl pp error: Nested packages > > Roderich, > > Thanks. I am not sure why Pradeep got stripped off from the mail thread. > Anyways, looks like a 'bug' to us (from the what we could decipher from the > user guide). Now, whether it is a real bug to be fixed or is there is some > work around -- I will let you decide. > > Pradeep, could you kindly give some snippets of the error messages you got > (hiding relevant Intel IP information) that might help Roderich to give > some pointers. Also, please send the same email to "par@perl.org" so that > we might get some help from there as well. > > - Angan > > -----Original Message----- > From: Roderich Schupp via RT [mailto:bug-PAR-Packer@rt.cpan.org] > Sent: Friday, December 19, 2014 4:09 AM > To: Das, Angan > Subject: [rt.cpan.org #101000] Perl pp error: Nested packages > > <URL: https://rt.cpan.org/Ticket/Display.html?id=101000 > > > On 2014-12-18 16:15:48, angan.das@intel.com wrote:
> > Pradeep (from our team) has a recent issue with 'pp' -- nested Perl > > packages (used within 'included/called' Perl scripts from parent Perl > > script) complain being not found. Environment does not seem to be an > > issue over here, and including all packages within the parent script > > does not help. > > > > Could you kindly help?
> > Sorry, rt.cpan.org is a *bug* tracker: clearly state what you were trying > to do, what you expected and what you got instead. Your report does not > contain anything base a diagnosis on. > Stuff like "need some help" do not belong on the bug tracker, please take > them to the PAR mailing list, par@perl.org, instead. > > Cheers, Roderich > >
CC: bug-PAR-Packer [...] rt.cpan.org, "par [...] perl.org" <par [...] perl.org>
Subject: Re: [rt.cpan.org #101000] Perl pp error: Nested packages
Date: Mon, 5 Jan 2015 11:47:41 -0500
To: Bagdevi <bagdevi.mishra [...] gmail.com>
From: Ron W <ronw.mrmx [...] gmail.com>
Download (untitled) / with headers
text/plain 1.3k
On Sun, Dec 21, 2014 at 11:36 AM, Bagdevi <bagdevi.mishra@gmail.com> wrote: Show quoted text
> Hello Pradeep and Angan, > I had a similar situation, where I was calling a perl script (B) from the > compiled executable (A) and, as it is happening with you, it did ... > 1// first I compiled the perl code (B) individually and make the > executable. > 2// from perl script (A) I called the executable for (B) (not the perl > code (B)). > 3// I packed the executable (B) along with (A) while compiling (A). > This, at the end, takes up much space as it bundles up most of the needed > packages twice, but at least it works that's way. >
You can bundle multiple Perl scripts inside the generated executable. Make the base name of the executable the same as the primary script. (If a.pl is the primary, then name the executable a (or a.exe for MS Windows).) You can invoke b.pl from a.pl with: my $progb = $0; $0 =~ s/a\.pl/b\.pl/; do $progb; Also, FYI, in a Linux/Unix/POSIX environment, you can create links to the executable, each one named for the bundled script to be executed. Example: ln -s a b # run a a # run b b In a MS Windows environment, you have to make additional copies of the executable, however, the same behavior applies: Whichever name the executable is invoked by, that is the script that will run.


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.