Alex Rousskov wrote:
Hm... Something does not add up here. ./configure found no mallopt and
should have undefined the HAVE_MALLOPT #define in include/autoconf.h
Do you have the following lines in that file (search for HAVE_MALLOPT)?
/* Define to 1 if you have the `mallopt' function. */
/* #undef HAVE_MALLOPT */
If yes, then Squid cannot be using mallopt in MemPool.cc because the
usage is guarded:
#if HAVE_MALLOPT && M_MMAP_MAX
mallopt(M_MMAP_MAX, MEM_MAX_MMAP_CHUNKS);
#endif
So if HAVE_MALLOPT is undefined, then GCC would not even try to compile
the mallopt() call above!
Please let me know the output of
fgrep -2 MALLOPT include/autoconf.h
core# grep -2 MALLOPT include/autoconf.h
/* Define to 1 if you have the `mallopt' function. */
/* #undef HAVE_MALLOPT */
/* Define to 1 if you have the <math.h> header file. */
and the output of
cd lib/
# this is the compilation command from your original email except I told GCC
# to stop at the preprocessing step and save the results into MemPool.E
g++ -DHAVE_CONFIG_H -I. -I. -I../include -I../include -I../include -Werror -Wall -Wpointer-arith -Wwrite-strings -Wcomments -D_REENTRANT -g -O2 -MT MemPool.o -MD -MP -MF ".deps/MemPool.Tpo" -E -o MemPool.E MemPool.cc
fgrep -3 mallopt MemPool.E
i dont understand what these mean.. sorry
and
g++ --version
core# g++ --version
g++ (GCC) 3.4.4 [FreeBSD] 20050518
Copyright (C) 2004 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.
Thank you,
Alex.
TIA
Zen