Re: [OT] Perl to C Converter?

From: CBFalconer (cbfalconer_at_yahoo.com)
Date: 08/23/04


Date: Mon, 23 Aug 2004 00:30:35 GMT

Alan Connor wrote:
> Joe Smith <Joe.Smith@inwap.com> wrote:
>> Alan Connor wrote:
>>
>>> There's this utility called html2ps that's written in perl, but
>>> the box I want to run it on doesn't have room for perl. It does
>>> have room for a C compiler.
>>
>> A general purpose perl-to-C converter will be the same size as
>> perl itself. If the program you're coverting uses eval($string),
>> then you'd have to include the *entire* perl language.
>
> Sure, but the perl-to-C converter would not have to be on the box
> that I want to run html2ps on. I can do the conversion and
> compilation elsewhere and then have a nice little C binary to
> install on that box, which will be a small fraction of the size
> of perl and the perl html2ps.

So sit down with a listing of html2ps.prl as a guide, and write
your own C version. That limits your understanding of perl to the
portions used. The critical thing is how to massage the data.

-- 
fix (vb.): 1. to paper over, obscure, hide from public view; 2.
to work around, in a way that produces unintended consequences
that are worse than the original problem.  Usage: "Windows ME
fixes many of the shortcomings of Windows 98 SE". - Hutchison


Relevant Pages

  • Re: [OT] Perl to C Converter?
    ... >> the box I want to run it on doesn't have room for perl. ... >> have room for a C compiler. ... but the perl-to-C converter would not have to be on the box that ... I want to run html2ps on. ...
    (comp.lang.c)
  • Re: [OT] Perl to C Converter?
    ... > that I want to run html2ps on. ... I can do the conversion and ... > of perl and the perl html2ps. ... fixes many of the shortcomings of Windows 98 SE". ...
    (comp.lang.c)
  • Re: [OT] Perl to C Converter?
    ... >> the box I want to run it on doesn't have room for perl. ... >> have room for a C compiler. ... but the perl-to-C converter would not have to be on the box that ... I want to run html2ps on. ...
    (comp.lang.perl)
  • Re: [OT] Perl to C Converter?
    ... Alan Connor wrote: ... > There's this utility called html2ps that's written in perl, ... > the box I want to run it on doesn't have room for perl. ... Erik de Castro Lopo nospam@mega-nerd.com ...
    (comp.lang.c)
  • Re: GUI and Rapid Application Development?
    ... Most simple applications that I dealt with did not need the use of API ... I imagine Perl is faster, ... my Perl scripts are more compact ... Chirag> in Windows that could run on Windows 98 through 2003. ...
    (comp.os.linux.misc)