Operating System - HP-UX
1821832 Members
3573 Online
109638 Solutions
New Discussion юеВ

Re: Gcc HP-UX compiler error. EXPERTS help!!!!

 
Ishafizan Ishak
New Member

Gcc HP-UX compiler error. EXPERTS help!!!!

I downloaded the gcc hp-ux compiler at hpux.cae.wisc.edu. Uncompress and swinstall it and set the $path. (system is HP-UX 9000 10.20)
I created a simple C program that outputs a line 'hello'. When compiling, gcc returned an error which is as follows:

"/var/tmp/ccXX62Cc.s", line 23:error 1052: Directive name not recognised - NSUBSPA

Need help urgently. Pls.
Cheers
I kick ass
4 REPLIES 4
Anthony Goonetilleke
Esteemed Contributor

Re: Gcc HP-UX compiler error. EXPERTS help!!!!

Try compiling this program by doing this

%gcc test.c

----------

#include

int main (void)
{
printf ("HELLO ITRCn");
}




Does it give the same error?
Minimum effort maximum output!
Ishafizan Ishak
New Member

Re: Gcc HP-UX compiler error. EXPERTS help!!!!

Morning. Yup, same error....The file:
#include
#include
int main(void)
{
printf("hello");
}

1) %gcc hello.c
/gcc/opt/gcc/bin (root) >#%gcc hello.c
sh: %gcc: not found.
2) gcc hello.c
/gcc/opt/gcc/bin (root) >#gcc hello.c
as: "/var/tmp/ccriEaQc.s", line 23: error 1052: Directive name not recognized -
NSUBSPA
(copied DIRECTLY from screen)
it's the same error. By the way, here's the PATH:
/ (root) >#echo $PATH
/usr/sbin:/usr/bin:/usr/ccs/bin:/usr/contrib/bin:usr/bin/X11:/usr/contrib/bin/X11:/opt/upgrade/bin:/opt/perf/bin:/opt/cobol/bin:/opt/ignite/bin:/op:/opt/CC/bin:/gcc/opt/gcc/bin:/sbin:/home/root

Pls help....
I kick ass
Andrew Fieldsend
Occasional Advisor

Re: Gcc HP-UX compiler error. EXPERTS help!!!!

What version of GCC and assembler are you using?

That error looks like the compiler is producing incorrect assembler code - which is probably either a bug or a mismatch between the compiler and assembler.
Ralf Hildebrandt
Valued Contributor

Re: Gcc HP-UX compiler error. EXPERTS help!!!!

You need GNU binutils, espec. GAS. Why can't you just read the dependencies -- they clearly state that GNU binutils are needed!
Postfix/BIND/Security/IDS/Scanner, you name it...