svadev AT lists.siebelschool.illinois.edu
Subject: Svadev mailing list
List archive
- From: Paul Bombach <pmb AT novodynamics.com>
- To: svadev AT cs.uiuc.edu
- Subject: [svadev] Link error with fmemsafety and boost
- Date: Thu, 8 Sep 2011 11:24:29 -0400
- List-archive: <http://lists.cs.uiuc.edu/pipermail/svadev>
- List-id: <svadev.cs.uiuc.edu>
Hello:
I'm having problems linking multiple modules that include any boost algorithm
headers. In particular, when I have two modules that include
<boost/algorithm/string.hpp> in more than one module, I get the following
link error.
clang version 3.0 (:
http://llvm.org/svn/llvm-project/safecode/trunk/tools/clang)
Target: x86_64-apple-darwin11.0.0
Thread model: posix
clang: warning: argument unused during compilation: '-fmemsafety'
"/usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld" -demangle
-dynamic -arch x86_64 -macosx_version_min 10.7.0 -o fmem.exe -lcrt1.10.6.o
-L/Users/pmb/Projects/safecode/lib fmem.o subroutine.o -lsc_dbg_rt
-lpoolalloc_bitmap -lstdc++ -lstdc++ -lSystem
ld: duplicate symbol ___unnamed_1 in subroutine.o and fmem.o for
architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see
invocation)
The compilation and linking commands that I use are:
#!/bin/bash
PATH=$SAFECODEDIR/bin
/usr/local/llvm/bin/clang++ -g
-I/Volumes/Workspaces/2.5alpha2-memsafe/crs/3rd-party/include -fmemsafety -c
fmem.cpp -o fmem.o
/usr/local/llvm/bin/clang++ -g
-I/Volumes/Workspaces/2.5alpha2-memsafe/crs/3rd-party/include -fmemsafety -c
subroutine.cpp -o subroutine.o
/usr/local/llvm/bin/clang++ -v -o fmem.exe -fmemsafety fmem.o
subroutine.o -L$SAFECODEDIR/lib -lsc_dbg_rt -lpoolalloc_bitmap -lstdc++
I've attached the modules fmem.cpp and subroutine.cpp that are causing the
problems. Thanks in advance for any help.
pmb
Attachment:
fmem.cpp
Description: Binary data
Attachment:
subroutine.cpp
Description: Binary data
- [svadev] Link error with fmemsafety and boost, Paul Bombach, 09/08/2011
- Re: [svadev] Link error with fmemsafety and boost, John Criswell, 09/08/2011
- Re: [svadev] Link error with fmemsafety and boost, Matthew Wala, 09/08/2011
- Re: [svadev] Link error with fmemsafety and boost, John Criswell, 09/08/2011
- Message not available
- Re: [svadev] Link error with fmemsafety and boost, John Criswell, 09/09/2011
- Message not available
- Re: [svadev] Link error with fmemsafety and boost, John Criswell, 09/08/2011
- Re: [svadev] Link error with fmemsafety and boost, Matthew Wala, 09/08/2011
- Re: [svadev] Link error with fmemsafety and boost, John Criswell, 09/08/2011
Archive powered by MHonArc 2.6.16.