Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: Problems building perl on AIX

by bliako (Monsignor)
on Mar 08, 2019 at 15:15 UTC ( [id://1231055]=note: print w/replies, xml ) Need Help??


in reply to Problems building perl on AIX

Two things ring alarm in the log you posted:

first, the output of sh -x Configure ...

+ + echo AIX + /usr/bin/sed -e s/[ ][ ]*/_/g + ./tr [A-Z] [a-z]

I am not acquainted much with the output of sh -x But I assume that what follows a plus sign is a command executed in current shell and whatever commands are preceded by two-or-more plus signs were executed in sub-shells therein. For example:

sh -x -e "echo abc | sed s'/a/b/'" + echo abc + sed s/a/b/ bbc

whereas,

sh -x -c 'z=`echo abc | sed "s/a/b/"`' ++ echo abc ++ sed s/a/b/ + z=bbc

So, the output you posted has echo AIX in a sub-shell and following sed and tr commands are executed on current shell. But *if* that output is at corresponds to this Configure part:

rp="Operating system name?" . ./myread case "$ans" in none) osname='' ;; *) osname=`echo "$ans" | $sed -e 's/[ ][ ]*/_/g' | ./tr '[A-Z]' + '[a-z]'`;; esac

Then echo, sed, tr should have all been preceded by 2 plus signs as they are all part of one single `...`.

The second alarm is that $sed is a variable which refers to some sed executable I guess. But it is worth investigating what it actually contains. Also, ./tr is not the same as tr. It probably is another script created on the fly and it is used instead of /usr/bin/tr. So, it is also worth finding out what that ./tr file contains...

So, I suggest to add some debugging lines in Configure (sorry if that contradicts the other advice you got about not modifying that file, which is correct but this is special and once you sort things out you will go back to original Configure and discard any perl executable may have been produced). Something like this perhaps (untested):

rp="Operating system name?" . ./myread case "$ans" in none) osname='' ;; *) echo "AAAA: ans='${ans}', sed='${sed}', Here is tr:" cat ./tr echo "BBBB: done cat tr" osname=`echo "$ans" | $sed -e 's/[ ][ ]*/_/g' | ./tr '[A-Z]' '[ +a-z]'` echo "CCCC: osname='${osname}'" ;; esac echo " " echo "XXXXXX out of case with this osname='${osname}'"

bw, bliako

p.s. Although the log was posted in another node of this post, I chose to create a new comment/answer to avoid clutter.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1231055]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others wandering the Monastery: (4)
As of 2024-04-18 05:58 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found