Operating System - HP-UX
1748180 Members
3890 Online
108759 Solutions
New Discussion юеВ

Re: Is GCC from Source possible?

 
Curtis Steward
Occasional Contributor

Is GCC from Source possible?

Does anyone have a detailed HowTo or step-by-step on compiling GCC from source (binutils works)? I've tried both DSPP's: http://h21007.www2.hp.com/dspp/tech/tech_TechSoftwareDetailPage_IDX/1,1703,547,00.html

and Merijn's:
http://mirrors.develooper.com/hpux/

without success. I've attempted this with the latest known patches on both 11.00 and 11.11 on more than one machine and usually end up
with a "unknown pseudo-op" error. I'd greatly appreciate a detailed step through on any of the above.

TIA,

cs
3 REPLIES 3
Victor BERRIDGE
Honored Contributor

Re: Is GCC from Source possible?

Hi,
A long time since I last tried...
I seem to remember having to start by compiling bison
then gcc, and after ncurses

I will have a look and see if I can find some old notes...

Good luck

Victor
Curtis Steward
Occasional Contributor

Re: Is GCC from Source possible?

I can't imagine it's this difficult to get GCC to compile on HP-UX/PA-RISC.

Anyone know of a way to get a step-by-step from the above like HP themself, complete with patch detail? Each site provides the source with a GNU linker, just can't get either to compile with the information provided.

cs
H.Merijn Brand (procura
Honored Contributor

Re: Is GCC from Source possible?

that is most likely an assembler errror. Are you sure you were using the right combo?

Did you use the scripts I made available on my site?

My sequence from scratch:

1. build 32bit binutils from scratch with HP C-ANSI-C
2. install
3. build 32bit gcc using those binutils
4. install
5. rebuild binutils with that gcc
6. install
7. rebuild gcc with gcc and binutils
8. install
repeat 5,6,7, and 8

same for 64bit, but that is much harder and manual intervention is needed in step 1 and 3, because 64bit gcc cannot be built with cc built binutils

so most of the time it's easiest to fetch a precompiled binutils/gcc FOR THE RIGHT ARCHITECTURE and OS VERSION and replay 5 .. 8 only once

FWIW if above steps pass, I usually also rebuild gdb with it
FWIW2 I often disable ranlib and ar from binutils on HP-UX and AIX, because they tend to not play nice with HP objects

Enjoy, Have FUN! H.Merijn
Enjoy, Have FUN! H.Merijn