gbarr/perl-Convert-ASN1

Convert::ASN1 can't be fatpacked

Closed this issue · 6 comments

Fatpacking an app that depends on this module causes these errors:

Bareword "cVAR" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 56, <DATA> line 755.
Bareword "cTAG" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 58, <DATA> line 755.
Bareword "cEXT" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 63, <DATA> line 755.
Bareword "cTAG" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 67, <DATA> line 755.
Bareword "cTYPE" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 69, <DATA> line 755.
Bareword "cTAG" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 86, <DATA> line 755.
Bareword "ASN_CONSTRUCTOR" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 86, <DATA> line 755.
Bareword "cTYPE" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 86, <DATA> line 755.
Bareword "cEXT" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 109, <DATA> line 755.
Bareword "cTAG" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 113, <DATA> line 755.
Bareword "cTYPE" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 113, <DATA> line 755.
Bareword "cVAR" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 113, <DATA> line 755.
Bareword "cTYPE" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 118, <DATA> line 755.
Bareword "opANY" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 118, <DATA> line 755.
Bareword "cEXT" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 124, <DATA> line 755.
Bareword "cDEFINE" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 131, <DATA> line 755.
Bareword "cDEFINE" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 132, <DATA> line 755.
Bareword "cVAR" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 133, <DATA> line 755.
Bareword "cDEFINE" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 133, <DATA> line 755.
Bareword "cTYPE" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 141, <DATA> line 755.
Bareword "opCHOICE" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 141, <DATA> line 755.
Bareword "cEXT" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 149, <DATA> line 755.
Bareword "cCHILD" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 153, <DATA> line 755.
Bareword "cTAG" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 155, <DATA> line 755.
Bareword "cVAR" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 164, <DATA> line 755.
Bareword "cVAR" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 164, <DATA> line 755.
Bareword "cTYPE" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 164, <DATA> line 755.
Bareword "cTYPE" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 178, <DATA> line 755.
Bareword "opEXTENSIONS" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 178, <DATA> line 755.
Bareword "cTAG" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 183, <DATA> line 755.
Bareword "cTAG" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 213, <DATA> line 755.
Bareword "ASN_CONSTRUCTOR" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 213, <DATA> line 755.
Bareword "cTYPE" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 213, <DATA> line 755.
Bareword "cVAR" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 234, <DATA> line 755.
Bareword "cEXT" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 249, <DATA> line 755.
Bareword "cTYPE" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 249, <DATA> line 755.
Bareword "opEXTENSIONS" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 249, <DATA> line 755.
Bareword "CHECK_UTF8" not allowed while "strict subs" in use at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 610, <DATA> line 755.
BEGIN not safe after errors--compilation aborted at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/Convert/ASN1/_decode.pm line 610, <DATA> line 755.
Compilation failed in require at /home/marcusr/.plenv/versions/5.20.1/lib/perl5/site_perl/5.20.1/App/FatPacker.pm line 149, <DATA> line 755.
BEGIN failed--compilation aborted at /home/marcusr/.plenv/versions/5.20.1/bin/fatpack line 3, <DATA> line 755.

@marcusramberg did this start working or did you decide to close it based in inactivity?

@timlegge it's been 7 years so I figured it wasn't relevant anymore, closed it as part of a cleanup of my old issues.

@marcusramberg I looked this morning and if I was doing the fatpacking correctly only ASN_CONSTRUCTOR caused similar issues. The module is "somewhat" supported in that I can release new versions if there is a fix I can certainly look at it.

for example after I fixed the ASN_CONSTRUCTOR issue:

perl -I blib/lib -I blib/arch /usr/local/bin/fatpack pack examples/x509decode > x509decode.packed

it worked fine (complained that a pod file could not be packed)

Well, honestly I can't even remember what I was fatpacking back in 2015 that caused me to open this issue, but I'm happy that it works better now. :)

@marcusramberg I will take a look at whether the fix I have is fine and whether anything else is required. If it fine I will issue a trial release.

@marcusramberg I know you have moved on but is appears running the pack multiple times show similar errors. I can get rid of most of the errors - however the resulting packed version seems to work regardless. I will ask some questions on IRC...