Operating System - HP-UX
1753976 Members
7404 Online
108811 Solutions
New Discussion юеВ

gcc complains about ASM directives -> HP as is being called?

 
Fernando C. Jeronymo
Occasional Contributor

gcc complains about ASM directives -> HP as is being called?

as: warning 2: Unknown option "--traditional-format" ignored.
as: "/var/tmp/ccZCpQ0a.s", line 10: error 1052: Directive name not recognized - FILE
as: "/var/tmp/ccZCpQ0a.s", line 11: error 1052: Directive name not recognized - STABS
as: "/var/tmp/ccZCpQ0a.s", line 47: error 1052: Directive name not recognized - NSUBSPA


I think I am getting the HP assembler. But the problem is, I changed my path to /data/tools/binutils/bin, and when I do a which as I get:

/data/tools/binutils/bin/as

But it seems that even so, gcc still is going after HP asm. How can I make gcc find the binutils as?

Or is this really the problem? Maybe something else is wrong? I am trying to use my 3.0.1 binary, or even the 3.0.4 I got from http://hpux.cs.utah.edu/hppd/hpux/Gnu/gcc-3.0.4/.

The 3.0.4 gives the same errors the 3.0.1 is giving (the asm errors)

Any ideas?
What we do in life echoes in eternity
3 REPLIES 3
H.Merijn Brand (procura
Honored Contributor

Re: gcc complains about ASM directives -> HP as is being called?

Strange. IIRC --traditional-format should be an option to gcc that would force gcc to emit HPas code instead of gas code.

have you tried -mpa-risc-2-0 or -mpa-risc-1-1 as option to gcc?
Enjoy, Have FUN! H.Merijn
Fernando C. Jeronymo
Occasional Contributor

Re: gcc complains about ASM directives -> HP as is being called?

I found a way to make gcc to "see" the correct assembler.

I am setting the environment variable "COMPILER_PATH=/binutils/bin" and that solved it.
What we do in life echoes in eternity
Luoguoxiong
Occasional Contributor

Re: gcc complains about ASM directives -> HP as is being called?

I installed gcc/g++(version 3.4.2) on HPUX 11i with the depot downloaded from HP website. But when I tried to compile C code file errors occured as the following:

as: "/var/tmp//cc6YlAQL.s", line 14: error 1052: Directive name not recognized -
NSUBSPA
as: "/var/tmp//cc6YlAQL.s", line 41: error 1052: Directive name not recognized -
NSUBSPA
......

What is wrong with my compiling?
Your advices are appreciated.