bug-autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

AC_FUNC_REALLOC causes trouble for compiling C++ on AIX


From: Tom Epperly
Subject: AC_FUNC_REALLOC causes trouble for compiling C++ on AIX
Date: Thu, 13 May 2004 10:21:57 -0700
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040113

address@hidden linux]$ autoconf --version
autoconf (GNU Autoconf) 2.59
Written by David J. MacKenzie and Akim Demaille.

Copyright (C) 2003 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
address@hidden linux]$

We use autoconf, automake, autoheader, and libtool for our project, http://www.llnl.gov/CASC/components/. AC_FUNC_REALLOC causes the following #define in our babel_config.h on AIX:

/* Define to rpl_realloc if the replacement function should be used. */
#ifndef realloc
#define realloc rpl_realloc
#endif

This file get included indirectly when compling a C++ file, and the #define causes this error:

newxlC -DHAVE_CONFIG_H -I. -I/usr/casc_scratch/babel/cronjobs//babel-20040512/regression/sort/runCxx -I../../../runtime/sidl -I. -I/usr/casc_scratch/babel/cronjobs/casc-aix-xlc/make_installcheck/babel/=inst/include -I/usr/casc_scratch/babel/cronjobs/casc-aix-xlc/make_installcheck/babel/=inst/include -g -qstaticinline -c -o sorttest.o /usr/casc_scratch/babel/cronjobs//babel-20040512/regression/sort/runCxx/sorttest.cc "/usr/local/tools/xlc/xlc6006/vacpp/include/cstdlib", line 52.36: 1540-0130 (S) "::rpl_realloc" is not declared.
gmake[4]: *** [sorttest.o] Error 1
gmake[4]: Leaving directory `/usr/casc_scratch/babel/cronjobs/casc-aix-xlc/make_installcheck/babel/regression/sort/runCxx'

In <cstdlib>, it refers to ::realloc, and it gets expanded by the preprocessor to ::rpl_realloc which isn't declared.

Regards,

Tom Epperly






reply via email to

[Prev in Thread] Current Thread [Next in Thread]