So I am writing a Perl/Tk program, and packaging it up with just pp. This is the line I used:

pp -c -o script.exe script.pl

It packages up fine, but when I try to run it, I get this error message:

couldn't read bitmap file "": No such file or directoryerror reading b +itmap file "" at Tk/Widget.pm line 205. at Tk/Widget.pm line 203.

Sources online (including the CPAN PAR::FAQ page) say it's not picking up the image files for certain widgets (such as the Browse Entry) and I need to include certain .xbm files. I put all the .xbm files in an xbm folder (inside the directory where I ran the pp command). First I tried to include just the files indicated (arrowdownwin.xbm and cbxarrow.xbm), then I tried adding all of the .xbm files:

pp -c -a xbm/arrowdownwin.xbm -a xbm/cbxarrow.xbm -o script.exe script +.pl pp -c -a xbm -o script.exe script.pl

But in all cases, even after I manually add the .xbm files, I still get the same error. Heck, just for kicks and giggles, I added all the .xpm file to the xbm folder so they would be added too. I even added the .gif files too! Still no dice. I really am at a loss as to why this keeps happening.

PAR and PAR::Packer are up to date (1.007 and 1.014 respectively). So is Tk (804.031). Perl is v5.16.0, non-threaded. Dev OS is Linux, Red Hat Enterprise 5.6 and the target OS will be the same.

I also read that having unicode characters in the path would bork it up, but my paths are ascii-only characters. So I can't change that to fix the problem.

Update! Unfortunately I cannot include the actual program because of proprietary information, but I worked on a few simple examples that I could share. Unfortunately, they are too small, too simple, and most unfortunately, they work. I will continue to grow the sample's complexity until they reproduce the problem.

To give you an idea of what is going on, my beastly program includes several CPAN modules, many homemade modules, and a megawidget; it also makes system calls and calls other perl scripts. The Tk gui is in its own module, as is the logic that runs the gui.


In reply to error reading bitmap file "" at Tk/Widget.pm line 205 by ric00015

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.