[omniORB] autoconf build problem on HP-UX - wrong alloca used
Eric McMillan
eric_mcmillan at themcmillans.net
Mon Jul 17 10:56:22 BST 2006
I've been working on porting omniORB to HP-UX/Itanium, and ran into a
problem when using configure to generate the build files. It manifested as
an error preprocessing ir.idl with omnicpp. After much debugging, I found
that it was the build of omnicpp that was the issue. In the traditional
build process, the config.h file includes the config-hpux.h file, which
defines HAVE_ALLOCA and includes HP's <alloca.h>. Configure doesn't set
HAVE_ALLOCA or include <alloca.h>, so the omniORB supplied alloca.c is used.
This doesn't work correctly on HP-UX/Itanium with aCC compiler 6.0 and
beyond. It looks like the routine to determine stack direction changes when
compiled with optimization vs. no optimization. The simple fix is to add
HAVE_ALLOCA and the #include <alloca.h> to the acconfig.h file. More
generically, configure should test for alloca support and use the vendor
supplied version, if available. Minor changes will need to be made to both
cccp.c and cexp.c to include <alloca.h> when configure determines it is
available.
This will probably also effect AIX, VMS and Linux, since they all provide an
alloca().
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.omniorb-support.com/pipermail/omniorb-list/attachments/20060717/ae6318c1/attachment.htm
More information about the omniORB-list
mailing list