pankaj_it09 has asked for the wisdom of the Perl Monks concerning the following question:

I ran pp -o file.out file.pl in Windows. When I ran the "file.out" in Linux the error message came bash: ./file.out: cannot execute binary file .
Its Mandriva Linux.

Replies are listed 'Best First'.
Re: Creating executable for Linux using pp command
by moritz (Cardinal) on Nov 23, 2009 at 10:23 UTC
    Try running the pp command on linux instead.
Re: Creating executable for Linux using pp command
by marto (Cardinal) on Nov 23, 2009 at 10:28 UTC

    It's not possible to create a single stand alone exe for multiple platforms. This is covered in the FAQ. You may have luck creating a PAR package if your script is pure perl, though I've no experience of doing this.

    Martin

      I just want the executable for all the Linux machines.

        Then the obvious thing to do would be to package your application on Linux using pp.

        This is impossible. With luck, you can get an executable that works for some Linux machines. But you won't get a single executable that runs on all Linux machines. See also Re^3: perl pp packging problem. Distribute the perl source.

        Alexander

        --
        Today I will gladly share my knowledge and experience, for there are no sweeter words than "I told you so". ;-)