Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined (1255 Views)
Acclaimed Contributor
Posts: 25,907
Registered: ‎03-06-2006
Message 26 of 62 (1,250 Views)

Re: Using aC++ A.06.15 compiler version => Identifier "__fpreg" is undefined

[ Edited ]

>So I just want to know, to get rid of error #3449 explicit specialization of member. Is it unavoidable with aCC6, there is no backward-compatibility?

Yes, it is unavoidable. This is a bug in the old compiler that's been fixed. That it doesn't check for source layout errors.

>1. Can I use some flag which will take care of the above discussed issue.

There are no flags for this. (I don't remember seeing any customer complaints about it either.)

>2. Do I need to start changing all source code files, just because we have change the compiler version?

Yes, your code is broken and you have to fix it.

>3. What best available options are there to solve the above discussed issue, since you the complete issue?

Your only option is to add those explicit specialization declarations.

Regular Advisor
Posts: 101
Registered: ‎03-24-2008
Message 27 of 62 (1,250 Views)

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

Hi Dennis,

Thanks for reply. Today I found that one of my file extn is .c, and the compile log shows that it invoke the cc driver to compile .c file(below).I have set my driver as aCC, and want to compile .c file with aCC only. I do not want to automatically take care by driver, then which flag should I pass from command line to forcefully compile .c file with aCC.

cc -c -D_REENTRANT -mt -g +DD32 +Z -DDEBUG -I.. templates.c -o templates.o

Best regards,
Neel

Acclaimed Contributor
Posts: 25,907
Registered: ‎03-06-2006
Message 28 of 62 (1,250 Views)

Re: Using aC++ A.06.15 compiler version => Identifier "__fpreg" is undefined

[ Edited ]

>which flag should I pass from command line to forcefully compile .c file with aCC.

The -Ae, -AC89 or -AC99 options:
aCC -Ae -c -mt -g +DD32 +Z -DDEBUG -I.. templates.c

Regular Advisor
Posts: 101
Registered: ‎03-24-2008
Message 29 of 62 (1,250 Views)

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

Thanks Dennis.

I have one more question regarding the template. I found that +ESnolit needed for compiler/linker workaround for templates at least through ACC 03.33/03.30. And -DOS_ENABLE_MEMBER_TEMPLATE_FEATURES in one of our makefiles, Is it still available with aCC6?

Also, +inst_compiletime flag can be useful for the above discussed issue of template?

Best regards,
Neel
Regular Advisor
Posts: 101
Registered: ‎03-24-2008
Message 30 of 62 (1,250 Views)

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

aCC -c -Ae +DD32 +Z -g0 -v template.c

/opt/aCC.06.15/opt/aCC/lbin/ecom -architecture 32 -ia64abi all -ext on -lang c -exception off -sysdir /usr/include -inline_power 1 -link_type dynamic -fpeval float -tls_dyn on -target_os 11.23 --sys_include /usr/include -D__hpux -D__unix -D__ia64=1 -D_BIG_ENDIAN=1 -D__STDCPP__ -D_ILP32 -D__HP_cc=61500 -D__STDC_EXT__ -D_HPUX_SOURCE -D_INCLUDE_LONGLONG -D_INLINE_ASM -D_BIND_LIBCALLS -D_Math_errhandling=MATH_ERREXCEPT -D_FLT_EVAL_METHOD=0 -debug debugG -ucode hdriver=optlevel%1% -plusolistoption -Ol06all! -plusolistoption -Ol13moderate! -plusooption -Oq01,al,ag,cn,sz,ic,vo,Mf,Po,es,rs,Rf,Pr,sp,in,cl,om,vc,pi,fa,pe,rr,pa,pv,nf,cp,lx,Pg,ug,lu,lb,uj,dn,sg,pt,kt,em,np,ar,rp,dl,fs,bp,wp,pc,mp,lr,cx,cr,pi,so,Rc,fa,ft,fe,ap,st,lc,Bl,sr,ib,pl,sd,ll,rl,dl,Lt,ol,fl,lm,ts,rd,dp,If! t.c

Hi Dennis,

When I used command line flag "-Ae", and looking at verbose it shows that "-D__HP_cc=61500", what does it mean, i found that broke my compilation since we had some check for __HP_aCC which got failed now.

I am looking for a flag which will treat .c file as .cpp and will be compile with aCC.

Best regards,
Neel
Acclaimed Contributor
Posts: 25,907
Registered: ‎03-06-2006
Message 31 of 62 (1,255 Views)

Re: Using aC++ A.06.15 compiler version => Identifier "__fpreg" is undefined

[ Edited ]

>I found that +ESnolit needed for compiler/linker workaround for templates at least through ACC 03.33/03.30.

This is not needed for aCC6.

>And -DOS_ENABLE_MEMBER_TEMPLATE_FEATURES in one of our makefiles, Is it still available with aCC6?

Member templates are implemented for aCC6. But that define is not for HP's supplied STL.

>+inst_compiletime flag can be useful for the above discussed issue of template?

No, it is the default.

>I am looking for a flag which will treat .c file as .cpp and will be compile with aCC.

This is the default, all files are C++. If it is invoking cc, you need to fix your makefile suffix rules.

Regular Advisor
Posts: 101
Registered: ‎03-24-2008
Message 32 of 62 (1,255 Views)

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

Thanks a lot for your reply.

Regular Advisor
Posts: 101
Registered: ‎03-24-2008
Message 33 of 62 (1,255 Views)

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

Hi,

In order to build with aCC6.15 on IPF 11.23 machine, do we need to change our linking order/re-order of object files, since earlier with aCC 3.57 on PA-RICS the same source code & makefiles( the order of linking object files ) works fine without changing any object files linking order in makefiles.

While porting the same on IPF, aCC 6.15 we are continusely getting unsatisfied error while linking.

Can someone point out or suggest what need to be change in our makefiles OR provide any command line flag which will take care of the above discussed issue.

(Remark: I already tried with +n cmd line
option)

Best regards,
Neel


Highlighted
Regular Advisor
Posts: 101
Registered: ‎03-24-2008
Message 34 of 62 (1,255 Views)

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

Hi,

I am getting usatisfied linking error for
ospace 5.0.6 using aCC6.15 on IPF.
//--------------------------------------
ld: Unsatisfied symbol "os_init_network_toolkit()" in file veddriver.o
ld: Unsatisfied symbol "os_exit_network_toolkit()" in file veddriver.o
//---------------------------------------

The following is my findings so far:

//
// DLL settings.
//

#if !(defined _MSC_VER || defined __BORLANDC__)
# define OS_STATIC_LIB
#endif

#if defined OS_STATIC_LIB
# define OS_PUBLIC
# define OS_VCC_PUBLIC
# define OS_BCC_PUBLIC
............
.................

A function definition from sockinit.cpp.

// Initialize Network.

OS_VCC_PUBLIC void OS_BCC_PUBLIC
os_init_network_toolkit()
{
os_init_io_toolkit();

if ( !os_network_toolkit_startup_count_++ )
{
# ifdef OS_WIN32
os_init_winsock();
# endif

os_host::my_host();
os_ip_address::my_address();
}
}


Any clues?

Best regards,
Neel
Acclaimed Contributor
Posts: 25,907
Registered: ‎03-06-2006
Message 35 of 62 (1,255 Views)

Re: Using aC++ A.06.15 compiler version => Identifier "__fpreg" is undefined

[ Edited ]

>do we need to change our linking order/re-order of object files, since earlier with aCC 3.57 on PA-RISC the same source code & makefiles (the order of linking object files) works fine without changing any object files linking order in makefiles.

It depends. There are several issues:
1) Template definitions and unsats may be in different places in archive libs.
2) Order of static construction is reversed. You have wrong runtime results.
3) Your template layout is illegal.

>While porting the same on IPF, aCC 6.15 we are continuously getting unsatisfied error while linking.

Which kind? If it was 1) above, just use -Wl,+n and you never have to worry about it again.

>Can someone point out or suggest what need to be change in our makefiles OR provide any command line flag which will take care of the above discussed issue.
>(Remark: I already tried with +n cmd line option)

I can only suggest for issue 1). If you still have problems, then they have to be addressed individually.

Acclaimed Contributor
Posts: 25,907
Registered: ‎03-06-2006
Message 36 of 62 (1,255 Views)

Re: Using aC++ A.06.15 compiler version => Identifier "__fpreg" is undefined

[ Edited ]

>I am getting unsatisfied linking error for ospace 5.0.6 using A.06.15 on IPF.
ld: Unsatisfied symbol "os_init_network_toolkit()" veddriver.o
ld: Unsatisfied symbol "os_exit_network_toolkit()" veddriver.o

These aren't templates. You just need to do macro spelunking.

>The following is my findings so far:
#if !(defined _MSC_VER || defined __BORLANDC__)
# define OS_STATIC_LIB
#endif

#if defined OS_STATIC_LIB
# define OS_PUBLIC
# define OS_VCC_PUBLIC
# define OS_BCC_PUBLIC

>A function definition from sockinit.cpp.
OS_VCC_PUBLIC void OS_BCC_PUBLIC
os_init_network_toolkit(){
...
}

>Any clues?

Compile sockinit.cpp and veddriver.cpp with -E -.i and look at the macro expansion.

Regular Advisor
Posts: 101
Registered: ‎03-24-2008
Message 37 of 62 (1,255 Views)

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

CPP_AR=ar cr
C_AR=ar rv
PIC_FLAG=+Z
STATIC_LIB_FLAG=-Wl,-a,archive
SHARED_LIB_FLAG=-Wl,-a,default

the above is correct for aCC6.15 on IPF machine?

Regards,
Neel
Acclaimed Contributor
Posts: 25,907
Registered: ‎03-06-2006
Message 38 of 62 (1,256 Views)

Re: Using aC++ A.06.15 compiler version => Identifier "__fpreg" is undefined

[ Edited ]

>PIC_FLAG=+Z
>the above is correct for aCC6.15 on IPF machine?

+Z/+Z does nothing on IPF since PIC is the default. You could keep it for documentation purposes.

Regular Advisor
Posts: 101
Registered: ‎03-24-2008
Message 39 of 62 (1,256 Views)

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

Hi,

1) /opt/aCC/lib/shlrt0.o

Earlier, my makefiles used the above mentioned .o file, does this .o file have any relation with aCC6.15 now? If yes, what should be the new path?

2) I have installed the patch PHSS_37947. How should i confirmed it, whether the patch is installed or not?

I have my compiler installed at following location:
/opt/aCC.06.15/opt/aCC

3) When I looked at:/opt/aCC.06.15/opt/aCC/lib/hpux32/libmielf
I could see only .o files, I have installed compiler for evolution purpose. So the above folder contains only .o files?

4) To get rid of "ld: Unsatisfied symbol" I used +compat flag, still I am getting the same linking errors, Do I missing something to add while linking?

Best regards,
Neel
Acclaimed Contributor
Posts: 25,907
Registered: ‎03-06-2006
Message 40 of 62 (1,256 Views)

Re: Using aC++ A.06.15 compiler version => Identifier "__fpreg" is undefined

[ Edited ]

>1) /opt/aCC/lib/shlrt0.o
>my makefiles used the above mentioned .o file, does this .o file have any relation with aCC6.15 now?

You should have NO knowledge of this file. You must create aC++ shlibs with aCC -b.
(It is only for PA32.)

>2) I have installed the patch PHSS_37947. How should i confirm it

$ swlist PHSS_37947

>3) When I looked at /opt/aCC/lib/hpux32/libmielf. So the above directory contains only .o files?

Yes.

>4) To get rid of "ld: Unsatisfied symbol" I used +compat flag, still I am getting the same linking errors

I'm not aware of +compat fixing any linking errors, only +n. Basically you have to do what I said above.

Regular Advisor
Posts: 101
Registered: ‎03-24-2008
Message 41 of 62 (1,256 Views)

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

Hi,

Could you please let me know the meaning of the following error.

1)
ld: Unsatisfied symbol "VCursor::VCursor(char const*,char const*,unsigned long,PPredicate const&)(complete)" in file db2tty.o

In above error (complete) what does it mean?
Also I have seen ld:(warning) ... ?

2)
ld: Unsatisfied symbol "ch_l_classname" in file /disk/nkhemkar/BUILD/aCC_6.15_build/cxx/7.0.1.4/HP-UX_32bit/dbg//lib/libcxxcls.a[checkapi.o]

And when I use:
$/usr/ccs/bin/nm -oA /disk/nkhemkar/VOD_BUILD/aCC_6.15_build/cxx/7.0.1.4/HP-UX_32bit/dbg//lib/libcxxcls.a | grep ch_l_classname
[148] |0000000000000|0000001020|FUNC |GLOB |0| .text|/disk/nkhemkar/VOD_BUILD/aCC_6.15_build/cxx/7.0.1.4/HP-UX_32bit/dbg//lib/libcxxcls.a[check.o]:ch_l_classname
[91] |0000000000000|0000000000|FUNC |GLOB |0| UNDEF|/disk/nkhemkar/VOD_BUILD/aCC_6.15_build/cxx/7.0.1.4/HP-UX_32bit/dbg//lib/libcxxcls.a[checkapi.o]:ch_l_classname


So, As per my understanding the function definition (.text) is present inside the archive. Then why it giving unsatisfied error?

Also, I am looking for what has been change in linker settings for the aCC6.15 compiler version from earlier version of aCC3.57? Could you please provide me the details of changes or some link of documents which contains the details.

Best regards,
Neel
Acclaimed Contributor
Posts: 25,907
Registered: ‎03-06-2006
Message 42 of 62 (1,256 Views)

Re: Using aC++ A.06.15 compiler version => Identifier "__fpreg" is undefined

[ Edited ]

>Could you please let me know the meaning of the following error.
>1) ld: Unsatisfied symbol "VCursor::VCursor(char const*,char const*,unsigned long,PPredicate const&)(complete)"

It says the "complete" entry point to the constructor is missing. The one that constructs virtual base classes.

>I have seen ld:(warning)?
>2) ld: Unsatisfied symbol "ch_l_classname" in libcxxcls.a[checkapi.o]

Where should it be defined?

>And when I use:
$nm -oA libcxxcls.a | grep ch_l_classname
FUNC |GLOB |0| .text| libcxxcls.a[check.o]:ch_l_classname
FUNC |GLOB |0| UNDEF| libcxxcls.a[checkapi.o]:ch_l_classname

(You should be using -x for hex and not -o.)

>As per my understanding the function definition (.text) is present inside the archive. Then why it giving unsatisfied error?

Perhaps you used a foreign devil ar(1) to create the archive? Use "/usr/ccs/bin/ar -rs libcxxcls.a" to fix it. Then remove/rename all gnu object file tools in /usr/local/bin/.

You can check by:
elfdump -g libcxxcls.a | fgrep ch_l_classname

>I am looking for what has been changed in linker settings for the A.06.15 compiler version from earlier version of A.03.57?

These are completely different. There is no earlier. One is SOM the other is ELF.

>Could you please provide me the details of changes or some link of documents which contains the details.

You need to look at the man pages and the Online Help for the compiler and ld:
ld +help
aCC +help

Regular Advisor
Posts: 101
Registered: ‎03-24-2008
Message 43 of 62 (1,256 Views)

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

Hi,

When I use file command on, it shows:

$file /usr/ccs/bin/ar
ar: ELF-64 executable object file - IA64

And when I use file command on, it shows:

$file /usr/local/bin/ar
ar: ELF-32 executable object file - IA64


And my build type is 32bit. then which ar should I use ?


Best regards,
Neel
Acclaimed Contributor
Posts: 25,907
Registered: ‎03-06-2006
Message 44 of 62 (1,256 Views)

Re: Using aC++ A.06.15 compiler version => Identifier "__fpreg" is undefined

[ Edited ]

>When I use file command on, it shows:
>$file /usr/ccs/bin/ar
ar: ELF-64 executable object file - IA64

This check is meaningless. The whole HP-UX compiler tool chain is now 64 bit. But it can handle either 32 or 64 bit binaries.

>And my build type is 32bit, then which ar should I use?

Remove the foreign devil gnu ar(1). You can't use this on HP-UX. (Or you can use it to look but not touch. :-)

Regular Advisor
Posts: 101
Registered: ‎03-24-2008
Message 45 of 62 (1,256 Views)

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

Hi,

Ok now I have renamed the devils.
After compilation and linking ( explicitly provided the .o files) when I run my executable i got the following errors:

I also noticed that after linking the following exe. does not have execute permission, so I menually give it(chmod +x)

$db2tty
/usr/lib/hpux32/dld.so: Unsatisfied data symbol '_ZN4PDOM9defaultDbE' in load module 'db2tty'.
/usr/lib/hpux32/dld.so: Unsatisfied data symbol 'dom' in load module 'db2tty.save'.
/usr/lib/hpux32/dld.so: Unsatisfied data symbol 'vpp_mt_safe' in load module 'db2tty'.
/usr/lib/hpux32/dld.so: Unsatisfied data symbol '_vpp_o_during_scap' in load module 'db2tty'.
/usr/lib/hpux32/dld.so: Unsatisfied data symbol '_vpp_PDOM_defaultLock' in load module 'db2tty'.
/usr/lib/hpux32/dld.so: Unsatisfied code symbol '_ZN6PErrorD1Ev' in load module 'db2tty'.
Killed

Could you please, let me know the reason of above failure.

Best regards,
Neel
Acclaimed Contributor
Posts: 25,907
Registered: ‎03-06-2006
Message 46 of 62 (1,256 Views)

Re: Using aC++ A.06.15 compiler version => Identifier "__fpreg" is undefined

[ Edited ]

>linking (explicitly provided the .o files) when I run my executable i got the following errors:

You should instead recreate those archives.

>I also noticed that after linking the following exe. does not have execute permission, so I manually give it (chmod +x)

Well, what link errors did you get? You have just moved the errors to runtime with a more confusing messages.

Unsatisfied data symbol '_ZN4PDOM9defaultDbE'
Unsatisfied data symbol 'dom'
Unsatisfied data symbol 'vpp_mt_safe'
Unsatisfied data symbol '_vpp_o_during_scap'
Unsatisfied data symbol '_vpp_PDOM_defaultLock'
Unsatisfied code symbol '_ZN6PErrorD1Ev'

>let me know the reason of above failure.

The same as before. Where are these symbols defined and where are they used?
Most are data symbols.

The two mangled names can be demangled with:
$ c++filt _ZN4PDOM9defaultDbE _ZN6PErrorD1Ev
PDOM::defaultDb
PError::~PError()

Regular Advisor
Posts: 101
Registered: ‎03-24-2008
Message 47 of 62 (1,256 Views)

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

Hi,

Where can i find the below documents:

Transitioning from PA-RISC to HP-UX 11i on Integrity servers

http://devresource.hp.com/drc/STK/PA_Integrity.jsp

Above link is not accessible. Could you please let me know where can i find the document.

Best regards,
Neel
Acclaimed Contributor
Posts: 25,907
Registered: ‎03-06-2006
Message 48 of 62 (1,256 Views)

Re: Using aC++ A.06.15 compiler version => Identifier "__fpreg" is undefined

[ Edited ]

>Transitioning from PA-RISC to HP-UX 11i on Integrity servers
>Above link is not accessible.

If you can't find it with google, it's probably gone.

Using your words above in the "search all of HP" finds a bunch for STK.
Unfortunately it finds a bunch on h21007.www2.hp.com, which seems to be having problems now??

What kind of help are you looking for?

Regular Advisor
Posts: 101
Registered: ‎03-24-2008
Message 49 of 62 (1,256 Views)

Re: Using aCC 06.15 compiler veersion => Identifier "__fpreg" is undefined

Hi,

I am getting the following error:

//================================
aCC -D_REENTRANT -AA -mt -g0 -Wl,+n +DD32 -Wl,+compat +z -I/.. Wl,+s /HP-UX_32bit/dbg//lib/libcxxcls.a /disk/nkhemkar/BUILD/aCC_6.15_build/lib/liboscfe.a -Wl,-a,default -lpthread -lm -o /disk/nkhemkar/BUILD/aCC_6.15_build/cxx/7.0.1.4/HP-UX_32bit/dbg//bin/db2tty
ld: Unsatisfied symbol "_V_Context::_V_Context(_V_flag,char*,char*,PClass*,PClass*,int,int,_V_Context*)(complete)" in file /disk/nkhemkar/BUILD/aCC_6.15_build/cxx/7.0.1.4/HP-UX_32bit/dbg//lib/libcxxcls.a[fund.o]
1 errors.
//=======================================

So, I searched for the above function, and found:
$ nm++ -xA pclass.o | grep _V_Context::_V_Context
[460] |0x00000000|0x000000f0|FUNC |GLOB |0| .text|pclass.o:_V_Context::_V_Context(_V_flag,char*,char*,PClass*,PClass*,long,long,_V_Context*)(complete)
[461] |0x00000000|0x00000100|FUNC |GLOB |0| .text|pclass.o:_V_Context::_V_Context(_V_flag,char*,char*,PClass*,PClass*,long,long,_V_Context*)(base)

Its defined inside pclass.o, when i again relink against pclass.o added in linking command, it does not resolve the above error, it still shows as unsatisfied symbols.

Could you point out what goes wrong here?
And i was looking for the documents so i could figure out the linker changes between PA-RISC Vs. IPF other than http://docs.hp.com/en/B2355-90968/linkerdifferencesiapa.htm

Best regards,
Neel
Acclaimed Contributor
Posts: 25,907
Registered: ‎03-06-2006
Message 50 of 62 (1,256 Views)

Re: Using aC++ A.06.15 compiler version => Identifier "__fpreg" is undefined

[ Edited ]

>I am getting the following error:
ld: Unsatisfied symbol _V_Context::_V_Context(_V_flag,char*,char*,PClass*,PClass*,int,int,_V_Context*) (complete) libcxxcls.a[fund.o]

>I searched for the above function, and found:
$ nm++ -xA pclass.o | grep _V_Context::_V_Context
FUNC |GLOB|pclass.o: _V_Context::_V_Context(_V_flag,char*,char*,PClass*,PClass*,long,long,_V_Context*)(complete)

>It's defined inside pclass.o
>Could you point out what goes wrong here?

You aren't looking close enough. You should be using the raw mangled name and then you can't fail.
Link with -Wf,-o. That will give you both the mangled and demangled names. Use the mangled name and NOT nm++ and you'll see that those symbols are NOT in pclass.o.

You have illegally used two different typedefs for the parms 6 & 7, int vs long.

>And i was looking for the documents so i could figure out the linker changes between PA-RISC vs. IPF

This unsat has nothing to do with PA vs IPF. This is just C++ and would fail on any OS.

The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation.