Makefile - perl script syntax error

Discussion in 'Perl Misc' started by NewBie, Aug 24, 2005.

  1. NewBie

    NewBie Guest

    Hi,

    Appreciate any pointer why there is a compliant:

    The perl script (partial):
    :
    orca_logo.gif.hex: orca_logo.gif
    perl -e 'while (sysread(STDIN, $$b, 35)){print unpack("h*",
    $$b),"\n"}' < $< > $@
    :

    The complaint:
    :
    make CFLAGS=-g -O2 || exit 1
    perl -e 'while (sysread(STDIN, $b, 35)){print unpack("h*",
    $b),"\n"}' < > orca_logo.gif.hex
    sh: Syntax error at line 1 : `>' is not expected.
    :

    Thanks in advance.
    NewBie, Aug 24, 2005
    #1
    1. Advertising

  2. NewBie wrote:
    > Hi,
    >
    > Appreciate any pointer why there is a compliant:
    >
    > The perl script (partial):


    This is not a part of a perl script, it is part of your makefile:

    > :
    > orca_logo.gif.hex: orca_logo.gif
    > perl -e 'while (sysread(STDIN, $$b, 35)){print unpack("h*",
    > $$b),"\n"}' < $< > $@
    > :
    >
    > The complaint:
    > :
    > make CFLAGS=-g -O2 || exit 1
    > perl -e 'while (sysread(STDIN, $b, 35)){print unpack("h*",
    > $b),"\n"}' < > orca_logo.gif.hex
    > sh: Syntax error at line 1 : `>' is not expected.
    > :


    And your Perl question is?

    You seem to have problems with your makefile, not with your perl
    one-liner. (Strange thing is that it works for me.) Apparently your make
    doesn't recognize the "$<", but again, you don't have a Perl problem (yet).

    --
    Josef Möllers (Pinguinpfleger bei FSC)
    If failure had no penalty success would not be a prize
    -- T. Pratchett
    Josef Moellers, Aug 24, 2005
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. dpackwood
    Replies:
    3
    Views:
    1,792
  2. Replies:
    3
    Views:
    921
    Nick Vargish
    Apr 20, 2005
  3. Replies:
    1
    Views:
    709
  4. Replies:
    0
    Views:
    271
  5. Mark Richards
    Replies:
    3
    Views:
    310
    Tad McClellan
    Nov 18, 2007
Loading...

Share This Page