Operating System - HP-UX
1833451 Members
2905 Online
110052 Solutions
New Discussion

@Procura alias Merijn (or others); still gcc-3.1 problems

 
Ralph Grothe
Honored Contributor

@Procura alias Merijn (or others); still gcc-3.1 problems

Hello again,

I would like to continue my last thread in this matter because the gcc 64Bit HP-UX problem still lingers on:

http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0xb990107d277ad611abdb0090277a778c,00.html

I downloaded the suggested Release Candidate 1 of Perl 5.8.0 sources.
When running the Configure script it now dies with this message:

Use which C compiler? [cc] gcc
:1:2: missing '(' after predicate
Uh-oh, the C compiler 'gcc' doesn't seem to be working.
:1:2: missing '(' after predicate
Uh-oh, the C compiler 'gcc' doesn't seem to be working.
You need to find a working C compiler.
Either (purchase and) install the C compiler supplied by your OS vendor,
or for a free C compiler try http://gcc.gnu.org/
I cannot continue any further, aborting.

I need a self compiled Perl to be able to get DBD::Oracle compiled later.
Madness, thy name is system administration
32 REPLIES 32
H.Merijn Brand (procura
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

The 5.8.0 RC2 is now available at

http://mirrors.kernel.org/cpan/src/perl-5.8.0-RC2.tgz
http://cpan.valueclick.com/src/perl-5.8.0-RC2.tgz
ftp://ftp.leo.org/pub/CPAN/src/perl-5.8.0-RC2.tgz
ftp://ftp.funet.fi/pub/CPAN/src/perl-5.8.0-RC2.tgz

Not that this would change anything (I didn't change anything to hpux related stuff in between the two RC's)

Did you clean up anything in the folder before unpacking? I hope you did.

At this moment of abort, it is very likely there is a subdirectory called 'UU' go there and see if there is a file called 'try.c', which should be (almost) the last when you do 'ls -lrt'

What happens when you do

.../perl-current/UU > gcc -o try try.c

If that succeeds, run ./try
If that also succeeds, it might have added some flags I don't see in your post. Edit Configure, go to line 3783, where it should do

echo "Checking for GNU cc in disguise and/or its version number..." >&4

insert "set -x" before that line and try Configure again, and show me the output (also show me the *complete* Configure line you call
Enjoy, Have FUN! H.Merijn
Ralph Grothe
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

Hello Merijn,

thank you once again for your endurance helping an idiot like me.

The whole gcc stuff and HP-UX seems really rotten to me.

But I was somewhat relieved to find out that I'm not the only idiot who is defeated by gcc & Co.

Please, have a look at the README attached to this post, which I found on yet another porting URI (viz.: ftp://sunsite.informatik.rwth-aachen.de/pub/packages/gcc_hpux/)

I will be downloading RC 2, although I'm sure it will make no difference.
I did an rm -rf of the extracted archive before running Configure.

I will follow your guidelines and try again.

Unfortunately, I have to postpone it until tomorrow, as urgent interference is demanded right now on a another site...
Madness, thy name is system administration
H.Merijn Brand (procura
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

It's tomorrow, and you're on-line. How did it go?
Enjoy, Have FUN! H.Merijn
Ralph Grothe
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

Hello Merijn,

I have a bad conscience for not posting anything to this thread yesterday :-(
But I was too busy with other stuff (well, or not in the mood for humilatingly fruitless Perl build attempts) yesterday.

OK, I downloaded your new RC2 source (so no cleanup necessary), started script to dump the output (please, see the attachment), and invoked Configure with the flags that I again had read about in your README.hpux.
Additionally I made sure to have GNU's archiver invoked rather than HP's.

As you can see from script's dump Configure claims that the supplied -A flag is not understood by gcc. :-o
This seems to contradict to what I read in README.hpux, or I have mixed up something here again.

Would you mind to give a little help again?

Regards
Ralph
Madness, thy name is system administration
H.Merijn Brand (procura
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

I thought you were going to use gcc?

# env CC=gcc sh Configure -A prepend:libswanted='cl pthread ' -de

perl wil *NOT* build with the (non-ANSI) bundled C compiler

Alternatively you can use a Policy.sh
Here's a modified version of my own you could use for gcc with Oracle

# make distclean
# cp /tmp/Policy.sh .
# sh Configure -de
Enjoy, Have FUN! H.Merijn
H.Merijn Brand (procura
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

Sorry, script needs two additional remarks:

0. I presume in this script you want to install in /opt/perl. Change throughout the script for a different location
1. Type in last line 'man3dir=opt/perl/man/man1' missing a slash before opt
2. This script is written for portability. Change -mparisc-1-1 to -mpa-risc-2-0 if you are planning to use this perl on pa-risc-2.0 systems only for better performance
3. The -mpa-risc flags are only valid for gcc-3.0.4 and up

HTH
Enjoy, Have FUN! H.Merijn
Ralph Grothe
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

Sorry, makes no difference.
I invoked Configure exactly as wrote in (viz. setting the CC env var for the subshell through the prepended env command).
Btw. I already had tried all quirks before.
this included setting an environment variable through export to the shell from where I invoke the subshell with Configure.
If my memory serves me correctly, a forked child process (like the Configure process) inherits all the environment and file handles from its parent, isn't that so?

This was where Configure aborted:

Use which C compiler? [cc] gcc
:1:2: missing '(' after predicate
Uh-oh, the C compiler 'gcc' doesn't seem to be working.
:1:2: missing '(' after predicate
Uh-oh, the C compiler 'gcc' doesn't seem to be working.
You need to find a working C compiler.
Either (purchase and) install the C compiler supplied by your OS vendor,
or for a free C compiler try http://gcc.gnu.org/
I cannot continue any further, aborting.


The silly Configure seems to take the Mickey, because it says that I should use my installed gcc instead when I just press enter here (and leave cc as default):

Nor is it Venix...
Use which C compiler? [cc]
(Bundled) cc: warning 480: The -A option is available only with the C/ANSI C pro
duct; ignored.
(Bundled) cc: "try.c", line 1: error 1705: Function prototypes are an ANSI featu
re.
Uh-oh, the C compiler 'cc' doesn't seem to be working.

You seem to have a working gcc, though.



So no matter which way I try, the gcc from the ports collection seems to be crap.

Now I will try your Police.sh patch...
Madness, thy name is system administration
Ralph Grothe
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

I got a few steps further in the Configure script,
maybe now I supplied (from the defaults) the wrong CC_FLAGS?
Shall I continue here?


Checking your choice of C compiler and flags for coherency...
I've tried to compile and run the following simple program:

#include
int main() { printf("Ok\n"); exit(0); }

I used the command:

gcc -o try +O2 +Onolimit -fno-strict-aliasing -L/usr/local/lib try.c -lc
l -lpthread -lnsl -lnm -lndbm -lmalloc -ldld -lm -lc -lndir -lcrypt -lsec
./try

and I got the following output:

gcc: +O2: No such file or directory
gcc: +Onolimit: No such file or directory
I can't compile the test program.
(The supplied flags or libraries might be incorrect.)

You have a BIG problem. Shall I abort Configure [y]

Madness, thy name is system administration
H.Merijn Brand (procura
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

- forked processes inherit exported env. yes.
- Use which C compiler? [cc] gcc
:1:2: missing '(' after predicate

please add the 'set -x' before the 'Use wich C compiler'
- bundled c is not supported, so don't even try :) [ that's why it does not accept -A ]

- gcc does not accept HP C-ANSI-C specific flags such as +O2 or +Onolimit. just use -O2 for gcc

HTH. next step.
Enjoy, Have FUN! H.Merijn
H.Merijn Brand (procura
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

What was the exact version of perl you need?

5.8.0/RC2+ gcc-3.1.1/64 prepared for Oracle?

I could try build one today. Otherwise, you will have to wait two weeks.
Enjoy, Have FUN! H.Merijn
Ralph Grothe
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

Good Morning Merijn,

actually I only need a Perl that comprehends references (i.e. anything from Perl 5.00X upwards), and above all - especially on these platforms - will cooperate with the DBI and DBD::Oracle.
Apart from this libnet and libwww would be nice, and the Storable, and MLDBM modules.
As you see i don't have to be on the bleeding edge of Perl development.
The only new features from Perl >= 5.6 that I have adopted so far are the "warnings" pragma, and the "our" function for globals' declarations to replace the "vars" pragma.
I don't use threading, make no use of additional pattern match special variables, don't use Unicode, and all the other new goodies.
If it doesn't take you too much effort it would be nice if you could built a Perl 5.6.1 binary for HP-UX 11.00 with gcc that includes the DBI, and DBD::Oracle for Oracle Release 8.0.5.
Maybe you could temporarily put it on the ftp server where you publish your other ported stuff?

Regards
Ralph
Madness, thy name is system administration
H.Merijn Brand (procura
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

32bit?
Enjoy, Have FUN! H.Merijn
Ralph Grothe
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

$ getconf KERNEL_BITS
64
Madness, thy name is system administration
Ralph Grothe
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

regarding your last mail,
no my browser is timed out (I think wget will be no difference), but this will mean not much since for the last couple of days we've been having very poor internet connections (maybe too many bandwidth waste by streaming WC videos?)
Madness, thy name is system administration
H.Merijn Brand (procura
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

I've mailed you the specifics of what I've put on-line. I hope to speak to the web-owner (you know who, it's still a secret to the rest of the forum :) Shhhh) to make it accessable for you

Kernel bit don't matter here, Oracle conf does.
Enjoy, Have FUN! H.Merijn
Ralph Grothe
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

Many, many thanks for your efforts.

Of course I'm an idiot to post the output of getconf.
We've learned the hard way that gcc isn't HP-UX 64bit ready yet, didn't we? ;-)

Hm, our DBAs are out (some meeting or so), and I know about Oracle only as much as is necessary to write wee Perl backup or archive scripts (which only scratches the surface).
Can you gather from the intro screen of the server manager if it's 32 or 64bit?
Is there a view in the data directory that I could query to find out?
(the hardcopy docs are in our DBAs' office, and this is locked :-(

Here is how svrmgrl greets me:


Oracle Server Manager Release 3.0.5.0.0 - Production

(c) Copyright 1997, Oracle Corporation. All Rights Reserved.

Oracle8 Enterprise Edition Release 8.0.5.0.0 - Production
PL/SQL Release 8.0.5.0.0 - Production

Madness, thy name is system administration
H.Merijn Brand (procura
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

l1:/pro/oracle/v817/bin 103 > file sqlplus
sqlplus: PA-RISC1.1 shared executable dynamically linked -not stripped
l1:/pro/oracle/v817/bin 104 >

if it shows ELF64, you have the 64bit port installed, and I should start building the other version, for which I think there is no time left today :(
Enjoy, Have FUN! H.Merijn
Ralph Grothe
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

Phew, looks like vanilla 32Bit, doesn't it?

# file /app/oracle/product/8.0.5/bin/sqlplus
/app/oracle/product/8.0.5/bin/sqlplus: PA-RISC1.1 shared executable dynamically
linked -not stripped
Madness, thy name is system administration
H.Merijn Brand (procura
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

Yeah! Now just find a way to fetch those two links I posted and get on with the show.

I cannot build DBD-Oracle for you because I only have 8.1.7.0, but using the gcc from that link, it should not give more than usual trouble
Enjoy, Have FUN! H.Merijn
Ralph Grothe
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

Ah, "usual" trouble,
this is nicely put :-)
Madness, thy name is system administration
H.Merijn Brand (procura
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

I'm back, how are you going? Did you manage to fetch from https://www.beepz.com/personal/merijn ? Was Steven able to help?
Enjoy, Have FUN! H.Merijn
Ralph Grothe
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

Hi Merijn,

thanks for resuming this thread.

Have you been on holiday?
Seen no postings from you recently.

Since there is no disaster is lurking at the moment here I have some time to give it yet another try.

I saw in CPAN they already placed the RC3, for those who need to be at the bleeding edge:

http://www.cpan.org/src/5.0/devel/

I'm just about to download this one...
Madness, thy name is system administration
Ralph Grothe
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

Ah, forgot to tell you,
yes I was able to get a HTTPS connection to your site, unfortunately only with Internet Exploder :-(
And I could have a look at your photo (where was it taken?)
Madness, thy name is system administration
Steven Sim Kok Leong
Honored Contributor

Re: @Procura alias Merijn (or others); still gcc-3.1 problems

Hi Ralph,

Yes, IE supports HTTP-SSL.

Do feedback if you should encounter any issues with the webserver.

Thanks in advance. Regards.

Steven Sim Kok Leong