logo       

Substituting variables in installed scripts: msg#00090

sysutils.autoconf.general

Subject: Substituting variables in installed scripts

I have what seems to be a simple question, I want to perform a configuration-dependent substitution in an installed script. What is the autoconf way?

For example, suppose I have a perl script, p.pl, with

use lib "../lib";

This works nicely during development, but on installation I want to change it to

use lib "@libdir@/@PACKAGE@";

for example

use lib "/usr/local/lib/myprog/";

Making a p.pl.in file and having configure process it seems unattractive and doesn't allow me to easily test during development. Patching during 'make install' seems better, but I don't know the autoconf way.

Any tips?

Thanks,
-d


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise