Re: [squid-users] Error making squid-3.1.0.7-20090412 on Mac OS X 10.4

From: <vollkommen_at_gmx.net>
Date: Sun, 10 May 2009 23:09:15 +0200

Apparently, I spoke too soon. It's been crashing with Bus error, even when started manually (not through launchd).

Date/Time: 2009-05-10 16:48:56.722 -0400
OS Version: 10.4.11 (Build 8S2167)
Report Version: 4

Command: squid
Path: /usr/local/squid/sbin/squid
Parent: launchd [1]

Version: ??? (???)

PID: 24312
Thread: 0

Exception: EXC_BAD_ACCESS (0x0001)
Codes: KERN_PROTECTION_FAILURE (0x0002) at 0x00000008

Thread 0 Crashed:
0 squid 0x001aed30 _static_initialization_and_destruction_0(int, int) + 96 (AuthReg.cc:21)
1 dyld 0x8fe0fe90 ImageLoaderMachO::doInitialization(ImageLoader::LinkContext const&) + 170
2 dyld 0x8fe0a236 ImageLoader::recursiveInitialization(ImageLoader::LinkContext const&) + 160
3 dyld 0x8fe0c6de ImageLoader::runInitializers(ImageLoader::LinkContext const&) + 90
4 dyld 0x8fe03070 dyld::initializeMainExecutable() + 112
5 squid 0x0000282e _start + 148
6 squid 0x00002799 start + 41

Thread 0 crashed with X86 Thread State (32-bit):
  eax: 0x00229cf0 ebx: 0x001aecdc ecx: 0x00113d28 edx: 0x00000000
  edi: 0x8fe54860 esi: 0x00000001 ebp: 0xbffffdd8 esp: 0xbffffdc0
   ss: 0x0000001f efl: 0x00010282 eip: 0x001aed30 cs: 0x00000017
   ds: 0x0000001f es: 0x0000001f fs: 0x00000000 gs: 0x00000037

Binary Images Description:
    0x1000 - 0x1edfff squid /usr/local/squid/sbin/squid
0x8fe00000 - 0x8fe4afff dyld 46.16 /usr/lib/dyld
0x90000000 - 0x90171fff libSystem.B.dylib /usr/lib/libSystem.B.dylib
0x901c1000 - 0x901c3fff libmathCommon.A.dylib /usr/lib/system/libmathCommon.A.dylib
0x90aff000 - 0x90b63fff libstdc++.6.dylib /usr/lib/libstdc++.6.dylib
0x90bd2000 - 0x90bd9fff libgcc_s.1.dylib /usr/lib/libgcc_s.1.dylib
0x93510000 - 0x9352dfff libresolv.9.dylib /usr/lib/libresolv.9.dylib
0x952bd000 - 0x9536ffff libcrypto.0.9.7.dylib /usr/lib/libcrypto.0.9.7.dylib
0x953cc000 - 0x953f1fff libssl.0.9.7.dylib /usr/lib/libssl.0.9.7.dylib

-------- Original-Nachricht --------
I see in the changelog that ClientInfo.h issue has been fixed. So I gave squid-3.HEAD-20090510 a whirl. It erred out:

rm -f .libs/squidS.c .libs/squid.nm .libs/squid.nmS .libs/squid.nmT
g++ -Werror -Wall -Wpointer-arith -Wwrite-strings -Wcomments -g -O2 .libs/squidS.o -g -o squid AclRegs.o AuthReg.o access_log.o asn.o AsyncEngine.o cache_cf.o ProtoPort.o CacheDigest.o cache_manager.o carp.o cbdata.o ChunkedCodingParser.o client_db.o client_side.o client_side_reply.o client_side_request.o BodyPipe.o clientStream.o CompletionDispatcher.o comm_select.o comm_select_win32.o comm_poll.o comm_epoll.o comm_kqueue.o ConfigOption.o ConfigParser.o debug.o delay_pools.o DelayId.o DelayBucket.o DelayConfig.o DelayPool.o DelaySpec.o DelayTagged.o DelayUser.o DelayVector.o NullDelayId.o disk.o DiskIO/DiskIOModule.o DiskIO/ReadRequest.o DiskIO/WriteRequest.o dlink.o dns_internal.o errorpage.o ETag.o event.o EventLoop.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 HttpRe
questMethod.o icp_v2.o icp_v3.o int.o internal.o ipc.o ipcache.o list.o logfile.o main.o mem.o mem_node.o MemBuf.o MemObject.o mime.o multicast.o neighbors.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 SquidNew.o ssl_support.o stat.o StatHist.o String.o stmem.o store.o StoreFileSystem.o store_io.o StoreIOState.o store_client.o store_digest.o store_dir.o store_key_md5.o store_log.o store_rebuild.o store_swapin.o store_swapmeta.o store_swapout.o StoreMeta.o StoreMetaMD5.o StoreMetaSTD.o StoreMetaSTDLFS.o StoreMetaUnpacker.o StoreMetaURL.o StoreMetaVary.o StoreSwapLogData.o Server.o SwapDir.o time.o tools.o tunnel.o unlinkd.o url.o URLScheme.o urn.o useragent.o wccp.o wccp2.o whois.o wordlist.o LoadableModule.o LoadableModules.o DiskIO/DiskIOModules_gen.o repl_modules.o globals.o string_arrays.o DiskIO/Blocking/BlockingDiskIOModule.o -Wl,-bind_at_load ./.libs/libsquid.a auth/.lib
s/libacls.a acl/.libs/libacls.a acl/.libs/libstate.a auth/.libs/libauth.a acl/.libs/libapi.a base/.libs/libbase.a ip/.libs/libip.a fs/.libs/libfs.a icmp/.libs/libicmp.a icmp/.libs/libicmp-core.a -L/Users/raymont/squid-3.HEAD-20090510/lib repl/libheap.a repl/liblru.a libBlocking.a ../snmplib/libsnmp.a adaptation/.libs/libadaptation.a -lssl -lcrypto -lmiscutil -lm -lresolv ../lib/libLtdl/.libs/libltdlc.a -ldl
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::prepareForUse()
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::prepareForUse() in section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::prepareForUse() in section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol __ZN14ACLStrategisedIiE13prepareForUseEv.eh
acl/.libs/libacls.a(MyPort.o) definition of absolute __ZN14ACLStrategisedIiE13prepareForUseEv.eh (value 0x0)
acl/.libs/libacls.a(SslError.o) definition of absolute __ZN14ACLStrategisedIiE13prepareForUseEv.eh (value 0x0)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::Pool
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::Pool in section (__DATA,__data)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::Pool in section (__DATA,__data)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::match(ACLChecklist*)
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::match(ACLChecklist*) in section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::match(ACLChecklist*) in section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::match(int const&)
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::match(int const&)in section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::match(int const&)in section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::parse()
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::parse() in section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::parse() in section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol __ZN14ACLStrategisedIiE5parseEv.eh
acl/.libs/libacls.a(MyPort.o) definition of absolute __ZN14ACLStrategisedIiE5parseEv.eh (value 0x0)
acl/.libs/libacls.a(SslError.o) definition of absolute __ZN14ACLStrategisedIiE5parseEv.eh (value 0x0)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::ACLStrategised(ACLData<int>*, ACLStrategy<int>*, char const*)
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::ACLStrategised(ACLData<int>*, ACLStrategy<int>*, char const*)in section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::ACLStrategised(ACLData<int>*, ACLStrategy<int>*, char const*)in section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol __ZN14ACLStrategisedIiEC1EP7ACLDataIiEP11ACLStrategyIiEPKc.eh
acl/.libs/libacls.a(MyPort.o) definition of absolute __ZN14ACLStrategisedIiEC1EP7ACLDataIiEP11ACLStrategyIiEPKc.eh (value 0x0)
acl/.libs/libacls.a(SslError.o) definition of absolute __ZN14ACLStrategisedIiEC1EP7ACLDataIiEP11ACLStrategyIiEPKc.eh (value 0x0)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::ACLStrategised(ACLStrategised<int> const&)
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::ACLStrategised(ACLStrategised<int> const&)in section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::ACLStrategised(ACLStrategised<int> const&)in section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol __ZN14ACLStrategisedIiEC1ERKS0_.eh
acl/.libs/libacls.a(MyPort.o) definition of absolute __ZN14ACLStrategisedIiEC1ERKS0_.eh (value 0x0)
acl/.libs/libacls.a(SslError.o) definition of absolute __ZN14ACLStrategisedIiEC1ERKS0_.eh (value 0x0)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::ACLStrategised(ACLData<int>*, ACLStrategy<int>*, char const*)
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::ACLStrategised(ACLData<int>*, ACLStrategy<int>*, char const*)in section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::ACLStrategised(ACLData<int>*, ACLStrategy<int>*, char const*)in section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::ACLStrategised(ACLStrategised<int> const&)
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::ACLStrategised(ACLStrategised<int> const&)in section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::ACLStrategised(ACLStrategised<int> const&)in section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::~ACLStrategised()
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::~ACLStrategised()in section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::~ACLStrategised()in section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::~ACLStrategised()
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::~ACLStrategised()in section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::~ACLStrategised()in section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol __ZN14ACLStrategisedIiED1Ev.eh
acl/.libs/libacls.a(MyPort.o) definition of absolute __ZN14ACLStrategisedIiED1Ev.eh (value 0x0)
acl/.libs/libacls.a(SslError.o) definition of absolute __ZN14ACLStrategisedIiED1Ev.eh (value 0x0)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::~ACLStrategised()
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::~ACLStrategised()in section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::~ACLStrategised()in section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::operator=(ACLStrategised<int> const&)
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::operator=(ACLStrategised<int> const&)in section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::operator=(ACLStrategised<int> const&)in section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::operator delete(void*)
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::operator delete(void*)in section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::operator delete(void*)in section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::operator new(unsigned long)
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::operator new(unsigned long)in section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::operator new(unsigned long)in section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::typeString() const
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::typeString() constin section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::typeString() constin section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol __ZNK14ACLStrategisedIiE10typeStringEv.eh
acl/.libs/libacls.a(MyPort.o) definition of absolute __ZNK14ACLStrategisedIiE10typeStringEv.eh (value 0x0)
acl/.libs/libacls.a(SslError.o) definition of absolute __ZNK14ACLStrategisedIiE10typeStringEv.eh (value 0x0)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::requiresReply() const
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::requiresReply() constin section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::requiresReply() constin section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::requiresRequest() const
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::requiresRequest() constin section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::requiresRequest() constin section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::dump() const
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::dump() constin section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::dump() constin section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol __ZNK14ACLStrategisedIiE4dumpEv.eh
acl/.libs/libacls.a(MyPort.o) definition of absolute __ZNK14ACLStrategisedIiE4dumpEv.eh (value 0x0)
acl/.libs/libacls.a(SslError.o) definition of absolute __ZNK14ACLStrategisedIiE4dumpEv.eh (value 0x0)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::clone() const
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::clone() constin section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::clone() constin section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::empty() const
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::empty() constin section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::empty() constin section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol ACLStrategised<int>::valid() const
acl/.libs/libacls.a(MyPort.o) definition of ACLStrategised<int>::valid() constin section (__TEXT,__text)
acl/.libs/libacls.a(SslError.o) definition of ACLStrategised<int>::valid() constin section (__TEXT,__text)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol typeinfo for ACLStrategised<int>
acl/.libs/libacls.a(MyPort.o) definition of typeinfo for ACLStrategised<int>in section (__DATA,__const)
acl/.libs/libacls.a(SslError.o) definition of typeinfo for ACLStrategised<int>in section (__DATA,__const)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol typeinfo name for ACLStrategised<int>
acl/.libs/libacls.a(MyPort.o) definition of typeinfo name for ACLStrategised<int>in section (__TEXT,__cstring)
acl/.libs/libacls.a(SslError.o) definition of typeinfo name for ACLStrategised<int>in section (__TEXT,__cstring)
/usr/libexec/gcc/i686-apple-darwin8/4.2.1/ld: multiple definitions of symbol CbDataList<int>::CBDATA_CbDataList
asn.o definition of CbDataList<int>::CBDATA_CbDataList in section (__DATA,__data)
acl/.libs/libacls.a(SslErrorData.o) definition of CbDataList<int>::CBDATA_CbDataList in section (__DATA,__data)
collect2: ld returned 1 exit status
rm -f .libs/squidS.o
make[3]: *** [squid] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all] Error 2
make: *** [all-recursive] Error 1

These appear to be due to "duplicate template instantiation", and a combination of strict enforcement by Apple and GCC 4.x. After trying a variety of techniques such as extern, inline, or pragma interface/implemenation in the header files, I finally found the following workaround that got it built successfully:

1. In src/acl/MyPort.cc, comment out:
template class ACLStrategised<int>;

2. In src/asn.cc, comment out:
template cbdata_type CbDataList<int>::CBDATA_CbDataList;

Now I'm able to browse IPv6 sites without cache-peering with Polipo 6to4 relay. However, Squid 3 Head standalone seems to have problem with a particular site, as seen in cache.log: ipcacheParse: No Address records in response to 'ipv6.google.com'.

-- 
Neu: GMX FreeDSL Komplettanschluss mit DSL 6.000 Flatrate + Telefonanschluss für nur 17,95 Euro/mtl.!* http://dslspecial.gmx.de/freedsl-surfflat/?ac=OM.AD.PD003K11308T4569a
Received on Sun May 10 2009 - 21:09:23 MDT

This archive was generated by hypermail 2.2.0 : Mon May 11 2009 - 12:00:02 MDT