Personally, I think the best approach would be to have a desktop application you run on a Perl script to turn it into an easily-parsable form, and then reimplement the parser in your Palm code to read that form and create the optrees from it. Yeesh.

There are a lot of differences between Palm OS and traditional desktop OSes, for example the existence of a heirarchical file system. Some commands might need different syntax to do this, ie, open.

One of the big plans in Perl 6 is that you'll be able to rip out the parser and replace it with something else, so a Palm port would be (relatively) easy to implement--just load up the interpreter (codenamed Parrot) with a bytecode loader, stick the bytecode into a database, and run Parrot on the bytecode database. You lose certain functionality, such as eval $string, but you also end up with a Perl that doesn't crash your Visor or fill up its memory.

I wouldn't recommend the zlib technique--in order for Perl to be a glue language, it has to interact with other program's databases.

Simon Cozens said a long time ago on perl5-porters that he was almost finished with a Palm port. Maybe you can contact him and ask about it.

I'd be happy to help. I have a Visor Prism (mmm, color...) and an itsy bitsy teeny weeny bit of experience with both Palm OS programming and Perl internals. Lemmie know...

=cut
--Brent Dax
There is no sig.


In reply to Re: palm perl porting, problems? by BrentDax
in thread palm perl porting, problems? by dr_lambado

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.