pcp
[Top] [All Lists]

Re: build issue with AC_PROG_AWK

To: nscott@xxxxxxxxxx
Subject: Re: build issue with AC_PROG_AWK
From: James Peach <jamespeach@xxxxxxx>
Date: Wed, 26 Mar 2008 07:51:19 -0700
Cc: markgw@xxxxxxx, Max Matveev <makc@xxxxxxx>, pcp@xxxxxxxxxxx
In-reply-to: <1206506319.29868.395.camel@xxxxxxxxxxxxxxxxx>
References: <FC71FBC1-38F6-4CA8-A82C-7FFE102A06BF@xxxxxxx> <1206423840.29868.340.camel@xxxxxxxxxxxxxxxxx> <18408.37725.85447.784561@xxxxxxxxxxxxxxxxxxxxxx> <47E894C7.2000903@xxxxxxx> <1206426896.29868.344.camel@xxxxxxxxxxxxxxxxx> <7138BC3A-DEC1-432A-B77C-59BC65E53BE7@xxxxxxx> <1206506319.29868.395.camel@xxxxxxxxxxxxxxxxx>
Sender: pcp-bounce@xxxxxxxxxxx
On 25/03/2008, at 9:38 PM, Nathan Scott wrote:

On Tue, 2008-03-25 at 19:48 -0700, James Peach wrote:

 if test $target_os = irix -a "$AWK" = "gawk"
 then
     dnl always use nawk on IRIX

Mark was saying we should get rid of all this gunk
too, and the mawk stuff.  I second that notion.

OK, see patch below

-       /usr/contrib/bin /opt/local/bin
+       /usr/contrib/bin

You really don't like this bit do you? :) ... I think
since we have /usr/local/bin for Linux, we should also
do this for consistent behaviour on Mac.


Yes, I *really* hate it :)

First, OS X has 2 possible sources of additional software - MacPorts and Fink. MacPorts installs in /opt/local and Fink (IIRC) installs in / fw.

Second, as a matter of policy I don't think that PCP should be using random tools from all over the system. I mean, you might as well just do `locate awk`.

Third I think that the whole concept of searching the $PATH of the person who ran configure is wrong. If PC is going to search the builder's $PATH, then it should update the PATH in pcp.env. Otherwise it should only search the path in pcp.env, since that is what will be searched at the time when these tools are actually needed.

Phew!

diff --git a/configure.in b/configure.in
index d0d26ee..c1e7b24 100644
--- a/configure.in
+++ b/configure.in
@@ -439,15 +439,6 @@ dnl check if user wants their own awk, sed and echo
 if test -z "$AWK" ; then
     AC_PATH_PROG(AWK, awk, /usr/bin/awk)
 fi
-if test $target_os = irix -a "$AWK" = "gawk"
-then
-    dnl always use nawk on IRIX
-    AWK=nawk
-fi
-dnl Use /usr/bin/awk in preference to mawk or
-dnl some other abomination since mawk isn't always
-dnl installed on linux.
-test "$AWK" = "mawk" -a -x /usr/bin/awk && AWK=awk
 awk=$AWK
 AC_SUBST(awk)



<Prev in Thread] Current Thread [Next in Thread>