kroy@softech.com has asked for the
wisdom of the Perl Monks concerning the following question:

We are using perlxs with C++ code and we are trying to support the Itanium platform. This code works on Solaris, Windows, and non-Itanium HP-UX. In the past we have had problems with HP-UX and the "Exec Format Error", to resolve this we used the '+A' link option to embed the funcions from the standard libraries in our shared library. With Itanium the aCC compiler is no longer supporting the '+A' link option.

My understanding of the "Exec Format Error" is that either our shared library isn't resolving something or it is conflicting something in our perl installation. Unfortunately I cannot determine what it is or how to resolve it. I tried building our shared library as closely as we can to the our perl installation. As well as setting the LD_LIBRARY_PATH to where our shared libraries exist.

It looks like there is (or was) a USENet group for HPUX questions -- comp.sys.hp.hpux.

There were a couple of posts approximating your problem in late 2008/early 2009. The consensus answer seemed to be "Make sure you have the most current patch level installed and cross your fingers". I realize that this is not much help, sigh.

Probably your best bet is to throw this at your HP Sales Engineer and let them talk to the HP Developers who have a real opinion on compilers and such.

I used to get that type of error when linking object files/libraries that were built from a mixture of compilers, usually gcc vs cc/aCC. I haven't have that sort of problem for a few years now (since HP/UX 11.11). I've stopped using gcc to avoid that situation altogether.

If I remember correctly, I was using "ldd" to get the list of shared libraies and "file" to identify their types. It's not much, but it should provide a lead or two.

This was useful for me. To help people like me, whom are not as familiar with Unix as we should be.

lld -r <library> - was very useful to determine what is unresolved.
file <lib|exe> - helped me find that there was a mismatch with my shar+ed lib and the perl executible.
chatr <library> - can help find library dependancies and library searc+h paths.