On Tue, 28 Jul 2009 22:10:39 +0100, "Markus Moeller"
<huaraz_at_moeller.plus.com> wrote:
> Any idea what I need to do to avoid this error ?
>
> ld: fatal: symbol `void*operator new(unsigned)' is multiply-defined:
> (file debug.o type=FUNC; file SquidNew.o type=FUNC);
> ld: fatal: symbol `void operator delete(void*)' is multiply-defined:
> (file debug.o type=FUNC; file SquidNew.o type=FUNC);
> ld: fatal: symbol `void*operator new[](unsigned)' is multiply-defined:
> (file store.o type=FUNC; file SquidNew.o type=FUNC);
> ld: fatal: symbol `void operator delete[](void*)' is multiply-defined:
> (file store.o type=FUNC; file SquidNew.o type=FUNC);
> ld: fatal: file processing errors. No output written to ufsdump
No clear ideas. Perhapse something is going wrong with inline.
Amos
> "Markus Moeller" <huaraz_at_moeller.plus.com> wrote in message
> news:h4hlvp$1tl$1_at_ger.gmane.org...
>> OK removing "private:" from the definition seems to work. Not sure how
>> important the warnings are.
>>
>> CC -DHAVE_CONFIG_H
>> -DDEFAULT_CONFIG_FILE=\"/usr/local/squid/etc/squid.conf\"
>> -I. -I../include -I. -I. -I../include -I../include
>> -I../lib/libTrie/include
>> -I/usr/include/libxml2 -fhuge-objects -g -c comm.cc -o comm.o
>> CC: Warning: Option -fhuge-objects passed to ld, if ld is invoked,
>> ignored
>> otherwise
>> "comm.h", line 24: Warning: Identifier expected instead of "}".
>> "comm.cc", line 329: Warning: Identifier expected instead of "}".
>> "comm.cc", line 2112: Warning: fd hides fdc_t::fd.
>> 3 Warning(s) detected.
>>
>>
>> until I get here which seems a linker error because of -fhuge-objects.
>> I
>> guess this should be check in configure.
>>
>>
>> (cd .libs && rm -f libauth.la && ln -s ../libauth.la libauth.la)
>> /bin/bash ../libtool --tag=CXX --mode=link CC -fhuge-objects -g -g
>> -o
>> cf_gen cf_gen.o debug.o time.o globals.o libsquid.la
>> libauth.la -L../lib -lmiscutil -lm -lresolv -lmalloc -lsocket -lnsl
>> CC -fhuge-objects -g -g -o cf_gen cf_gen.o debug.o time.o globals.o
>> ./.libs/libsquid.a
>> ./.libs/libauth.a -L/home/markus/sources/squid-3.0.STABLE16/lib
>> -lmiscutil
>> -lm -lresolv -lmalloc -lsocket -lnsl
>> CC: Warning: Option -fhuge-objects passed to ld, if ld is invoked,
>> ignored
>> otherwise
>> ld: fatal: auxiliary filter option (-f, --auxiliary) is incompatible
with
>>
>> building a dynamic executable
>> ld: fatal: flags processing errors
>> *** Error code 1
>> make: Fatal error: Command failed for target `cf_gen'
>> Current working directory /src/src/squid-3.0.STABLE16/src
>> *** Error code 1
>> The following command caused the error:
>> failcom='exit 1'; \
>> for f in x $MAKEFLAGS; do \
>> case $f in \
>> *=* | --[!k]*);; \
>> *k*) failcom='fail=yes';; \
>> esac; \
>> done; \
>> dot_seen=no; \
>> target=`echo all-recursive | sed s/-recursive//`; \
>> list='lib snmplib scripts src icons errors doc helpers test-suite
tools';
>>
>> for subdir in $list; do \
>> echo "Making $target in $subdir"; \
>> if test "$subdir" = "."; then \
>> dot_seen=yes; \
>> local_target="$target-am"; \
>> else \
>> local_target="$target"; \
>> fi; \
>> (cd $subdir && make $local_target) \
>> || eval $failcom; \
>> done; \
>> if test "$dot_seen" = "no"; then \
>> make "$target-am" || exit 1; \
>> fi; test -z "$fail"
>> make: Fatal error: Command failed for target `all-recursive'
>>
>>
>> After removing -fhuge-objetcs I get till:
>>
>>
>> /bin/bash ../libtool --tag=CXX --mode=link CC -g -g -o ufsdump
>> debug.o int.o mem.o store_key_md5.o StoreMeta.o StoreMetaMD5.o
>> StoreMetaSTD.o StoreMetaSTDLFS.o StoreMetaUnpacker.o StoreMetaURL.o
>> StoreMetaVary.o String.o time.o ufsdump.o url.o AsyncCall.o BodyPipe.o
>> ConfigParser.o store.o StoreFileSystem.o StoreSwapLogData.o
>> access_log.o
>> acl.o acl_noncore.o ACLChecklist.o ACLProxyAuth.o ACLUserData.o
>> ACLRegexData.o ACLStringData.o authenticate.o cache_cf.o
cache_manager.o
>>
>> CacheDigest.o carp.o cbdata.o ChunkedCodingParser.o client_db.o
>> client_side.o client_side_reply.o client_side_request.o clientStream.o
>> comm_select.o comm_select_win32.o comm_poll.o comm_epoll.o
comm_kqueue.o
>>
>> ConfigOption.o disk.o dns_internal.o errorpage.o ETag.o event.o
>> external_acl.o ExternalACLEntry.o fd.o fde.o filemap.o forward.o
>> fqdncache.o ftp.o gopher.o helper.o htcp.o http.o HttpStatusLine.o
>> HttpHdrCc.o HttpHdrRange.o HttpHdrSc.o HttpHdrScTarget.o
>> HttpHdrContRange.o HttpHeader.o HttpHeaderTools.o HttpBody.o HttpMsg.o
>> HttpReply.o HttpRequest.o HttpRequestMethod.o icmp.o icp_v2.o icp_v3.o
>> ACLIdent.o ident.o internal.o ipc.o ipcache.o list.o logfile.o
>> mem_node.o MemBuf.o MemObject.o mime.o multicast.o neighbors.o net_db.o
>> Packer.o Parsing.o pconn.o peer_digest.o peer_select.o
>> peer_sourcehash.o peer_userhash.o redirect.o referer.o refresh.o
>> RemovalPolicy.o send-announce.o snmp_core.o snmp_agent.o tunnel.o
>> Server.o SquidNew.o stat.o StatHist.o stmem.o store_io.o
StoreIOState.o
>>
>> store_client.o store_digest.o store_dir.o store_log.o store_rebuild.o
>> store_swapin.o store_swapmeta.o store_swapout.o SwapDir.o
>> TextException.o tools.o unlinkd.o URLScheme.o urn.o useragent.o wccp.o
>> wccp2.o whois.o wordlist.o repl_modules.o globals.o string_arrays.o
>> libsquid.la libauth.la repl/liblru.a fs/libufs.a auth/libntlm.a
>> auth/libbasic.a auth/libdigest.a auth/libnegotiate.a -lcrypt -lmd5
>> ../snmplib/libsnmp.a -L../lib -lmiscutil -lm -lresolv -lmalloc
>> -lsocket
>> -lnsl
>> CC -g -g -o ufsdump debug.o int.o mem.o store_key_md5.o StoreMeta.o
>> StoreMetaMD5.o StoreMetaSTD.o StoreMetaSTDLFS.o StoreMetaUnpacker.o
>> StoreMetaURL.o StoreMetaVary.o String.o time.o ufsdump.o url.o
>> AsyncCall.o
>> BodyPipe.o ConfigParser.o store.o StoreFileSystem.o StoreSwapLogData.o
>> access_log.o acl.o acl_noncore.o ACLChecklist.o ACLProxyAuth.o
>> ACLUserData.o ACLRegexData.o ACLStringData.o authenticate.o cache_cf.o
>> cache_manager.o CacheDigest.o carp.o cbdata.o ChunkedCodingParser.o
>> client_db.o client_side.o client_side_reply.o client_side_request.o
>> clientStream.o comm_select.o comm_select_win32.o comm_poll.o
comm_epoll.o
>>
>> comm_kqueue.o ConfigOption.o disk.o dns_internal.o errorpage.o ETag.o
>> event.o external_acl.o ExternalACLEntry.o fd.o fde.o filemap.o forward.o
>> fqdncache.o ftp.o gopher.o helper.o htcp.o http.o HttpStatusLine.o
>> HttpHdrCc.o HttpHdrRange.o HttpHdrSc.o HttpHdrScTarget.o
>> HttpHdrContRange.o HttpHeader.o HttpHeaderTools.o HttpBody.o HttpMsg.o
>> HttpReply.o HttpRequest.o HttpRequestMethod.o icmp.o icp_v2.o icp_v3.o
>> ACLIdent.o ident.o internal.o ipc.o ipcache.o list.o logfile.o
mem_node.o
>>
>> MemBuf.o MemObject.o mime.o multicast.o neighbors.o net_db.o Packer.o
>> Parsing.o pconn.o peer_digest.o peer_select.o peer_sourcehash.o
>> peer_userhash.o redirect.o referer.o refresh.o RemovalPolicy.o
>> send-announce.o snmp_core.o snmp_agent.o tunnel.o Server.o SquidNew.o
>> stat.o StatHist.o stmem.o store_io.o StoreIOState.o store_client.o
>> store_digest.o store_dir.o store_log.o store_rebuild.o store_swapin.o
>> store_swapmeta.o store_swapout.o SwapDir.o TextException.o tools.o
>> unlinkd.o URLScheme.o urn.o useragent.o wccp.o wccp2.o whois.o
wordlist.o
>>
>> repl_modules.o globals.o string_arrays.o ./.libs/libsquid.a
>> ./.libs/libauth.a repl/liblru.a fs/libufs.a auth/libntlm.a
>> auth/libbasic.a
>> auth/libdigest.a auth/libnegotiate.a -lcrypt -lmd5
>> ../snmplib/libsnmp.a -L/home/markus/sources/squid-3.0.STABLE16/lib
>> -lmiscutil
>> -lm -lresolv -lmalloc -lsocket -lnsl
>> ld: fatal: symbol `void*operator new(unsigned)' is multiply-defined:
>> (file debug.o type=FUNC; file SquidNew.o type=FUNC);
>> ld: fatal: symbol `void operator delete(void*)' is multiply-defined:
>> (file debug.o type=FUNC; file SquidNew.o type=FUNC);
>> ld: fatal: symbol `void*operator new[](unsigned)' is multiply-defined:
>> (file store.o type=FUNC; file SquidNew.o type=FUNC);
>> ld: fatal: symbol `void operator delete[](void*)' is multiply-defined:
>> (file store.o type=FUNC; file SquidNew.o type=FUNC);
>> ld: fatal: file processing errors. No output written to ufsdump
>> *** Error code 1
>> make: Fatal error: Command failed for target `ufsdump'
>> Current working directory /src/src/squid-3.0.STABLE16/src
>> *** Error code 1
>> The following command caused the error:
>> failcom='exit 1'; \
>> for f in x $MAKEFLAGS; do \
>> case $f in \
>> *=* | --[!k]*);; \
>> *k*) failcom='fail=yes';; \
>> esac; \
>> done; \
>> dot_seen=no; \
>> target=`echo all-recursive | sed s/-recursive//`; \
>> list='fs repl auth'; for subdir in $list; do \
>> echo "Making $target in $subdir"; \
>> if test "$subdir" = "."; then \
>> dot_seen=yes; \
>> local_target="$target-am"; \
>> else \
>> local_target="$target"; \
>> fi; \
>> (cd $subdir && make $local_target) \
>> || eval $failcom; \
>> done; \
>> if test "$dot_seen" = "no"; then \
>> make "$target-am" || exit 1; \
>> fi; test -z "$fail"
>> make: Fatal error: Command failed for target `all-recursive'
>> Current working directory /src/src/squid-3.0.STABLE16/src
>> *** Error code 1
>> make: Fatal error: Command failed for target `all'
>> Current working directory /src/src/squid-3.0.STABLE16/src
>> *** Error code 1
>> The following command caused the error:
>> failcom='exit 1'; \
>> for f in x $MAKEFLAGS; do \
>> case $f in \
>> *=* | --[!k]*);; \
>> *k*) failcom='fail=yes';; \
>> esac; \
>> done; \
>> dot_seen=no; \
>> target=`echo all-recursive | sed s/-recursive//`; \
>> list='lib snmplib scripts src icons errors doc helpers test-suite
tools';
>>
>> for subdir in $list; do \
>> echo "Making $target in $subdir"; \
>> if test "$subdir" = "."; then \
>> dot_seen=yes; \
>> local_target="$target-am"; \
>> else \
>> local_target="$target"; \
>> fi; \
>> (cd $subdir && make $local_target) \
>> || eval $failcom; \
>> done; \
>> if test "$dot_seen" = "no"; then \
>> make "$target-am" || exit 1; \
>> fi; test -z "$fail"
>> make: Fatal error: Command failed for target `all-recursive'
>>
>>
>> Regards
>> Markus
>>
>> "Amos Jeffries" <squid3_at_treenet.co.nz> wrote in message
>> news:4A6C5285.5040007_at_treenet.co.nz...
>>> Markus Moeller wrote:
>>>> I get the following compile error on Opensolaris. How can I fix this
?
>>>>
>>>> Thank you
>>>> Markus
>>>>
>>>>
>>>> # uname -a
>>>> SunOS opensolaris 5.11 snv_109 i86pc i386 i86pc
>>>>
>>>> # cc -V
>>>> cc: Sun C 5.9 SunOS_i386 Patch 124868-07 2008/10/07
>>>> usage: cc [ options] files. Use 'cc -flags' for details
>>>>
>>>>
>>>> source='comm.cc' object='comm.lo' libtool=yes \
>>>> DEPDIR=.deps depmode=none /bin/bash ../cfgaux/depcomp \
>>>> /bin/bash ../libtool --tag=CXX --mode=compile
>>>> CC -DHAVE_CONFIG_H
>>>> -DDEFAULT_CONFIG_FILE=\"/usr/local/squid/etc/squid.conf\"
>>>> -I. -I../include -I. -I. -I../include -I../include
>>>> -I../lib/libTrie/include
>>>> -I/usr/include/libxml2 -fhuge-objects -g -c -o comm.lo comm.cc
>>>> CC -DHAVE_CONFIG_H
>>>> -DDEFAULT_CONFIG_FILE=\"/usr/local/squid/etc/squid.conf\"
>>>> -I. -I../include -I. -I. -I../include -I../include
>>>> -I../lib/libTrie/include
>>>> -I/usr/include/libxml2 -fhuge-objects -g -c comm.cc -o comm.o
>>>> CC: Warning: Option -fhuge-objects passed to ld, if ld is invoked,
>>>> ignored otherwise
>>>> "cbdata.h", line 134: Error: "}" expected instead of ";".
>>>> "cbdata.h", line 135: Error: A declaration was expected instead of
"}".
>>>> "MemBuf.h", line 126: Error: "}" expected instead of ";".
>>>> "MemBuf.h", line 53: Error: buf is not defined.
>>>
>>> Looks like macros are not working. The one in question expands to a
set
>>>
>>> of definitions, terminating in "private:". I would think that is the
>>> problem.
>>>
>>> But there is some code checking and cleanup before that can be removed.
>>> Every class that uses CBDATA_CLASS2() macro needs to be checked of need
>>> of the "private:".
>>>
>>> Amos
>>> --
>>> Please be using
>>> Current Stable Squid 2.7.STABLE6 or 3.0.STABLE16
>>> Current Beta Squid 3.1.0.10 or 3.1.0.11
>>>
>>
>>
>>
Received on Wed Jul 29 2009 - 02:29:43 MDT
This archive was generated by hypermail 2.2.0 : Wed Jul 29 2009 - 12:00:05 MDT