[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: #!/Perl question



-----BEGIN PGP SIGNED MESSAGE-----

On Thu, 2 Sep 1999, Brian Servis wrote:

> *- On  2 Sep, Jonathan Markevich wrote about "Re: #!/Perl question"
> > On Fri, Sep 03, 1999 at 03:04:49AM +0800, Hans van den Boogert wrote:
> >> I'm trying to learn some Perl. I found an on-line book which is Unix
> >> biased, but the scripts all start with #!/usr/local/bin/perl (which makes
> >> sense if you have compiled and installed it yourself). However, on my
> >> Debian system Perl was of course put in /usr/bin/perl. So how can I write a
> >> Perl script that be executed on a variety of systems (Unix/Linux/DOS)?? 
> > 
> > Personally, I would count on /usr/bin/perl.  It seems unusual to take such
> > an important key to lots of system-based scripts and keep it local.  Check
> > out this:
> 
> I think(i.e. just my local experience) many of the commercial Unix's put
> everything under /usr/local that is not part of the core OS.  Unlike
> Linux distributions most commercial Unix's don't come with all the apps
> pre-packaged.

One solution would be to write a makefile that detects the location of the
perl binary and then prepends the proper shebang line to the beginning of
your perl programs.

- -- 
  finger for PGP public key.

-----BEGIN PGP SIGNATURE-----
Version: 2.6.3ia
Charset: noconv

iQCVAwUBN88YXr7M/9WKZLW5AQGmMAP/SjX8U3wyIWTQDZNy1twrlGP20LKq51c7
ayJTppyfV56sps2qdPOh+kclL0FnMqzWCJaISNtwRicYeMLAIb6CGjeQedgV6Vgz
NJh3vHDYWnXU14QX3DX60xANOLOmp+3mCER5SvaNcLNFJyyYEXUzJDe3IoUbr6nN
+mIVd1UFHF0=
=2YGA
-----END PGP SIGNATURE-----


Reply to: