Bug#872881: simgrid: FTBFS: `__atomic_fetch_add_8' undefined
Hi, On 24/08/17 08:59, Martin Quinson wrote: > Hello, > > thanks for the patch. I came to something very similar, only > protecting it to be used only by GCC. I was waiting to find the time > to test it before upload, but if you tested, I'll upload it right away. I have tested the patch I attached on a mips machine. If you want I could test your alternative patch as well. Thanks, James > On Wed, Aug 23, 2017 at 02:41:15PM +0100, James Cowgill wrote: >> Hi, >> >> The attached patch seems to work (ie replace atomic-library with it). >> Using target_link_libraries should put any linker arguments at the end >> instead of the beginning. >> >> Thanks, >> James > >> --- a/tools/cmake/MakeLib.cmake >> +++ b/tools/cmake/MakeLib.cmake >> @@ -114,6 +114,7 @@ if(enable_smpi AND APPLE) >>set(SIMGRID_DEP "${SIMGRID_DEP} -Wl,-U -Wl,_smpi_simulated_main") >> endif() >> >> +set(SIMGRID_DEP "${SIMGRID_DEP} -Wl,--as-needed -latomic >> -Wl,--no-as-needed") >> target_link_libraries(simgrid ${SIMGRID_DEP}) >> >> # Dependencies from maintainer mode signature.asc Description: OpenPGP digital signature
Bug#872881: simgrid: FTBFS: `__atomic_fetch_add_8' undefined
Hello, thanks for the patch. I came to something very similar, only protecting it to be used only by GCC. I was waiting to find the time to test it before upload, but if you tested, I'll upload it right away. Many thanks, Mt On Wed, Aug 23, 2017 at 02:41:15PM +0100, James Cowgill wrote: > Hi, > > The attached patch seems to work (ie replace atomic-library with it). > Using target_link_libraries should put any linker arguments at the end > instead of the beginning. > > Thanks, > James > --- a/tools/cmake/MakeLib.cmake > +++ b/tools/cmake/MakeLib.cmake > @@ -114,6 +114,7 @@ if(enable_smpi AND APPLE) >set(SIMGRID_DEP "${SIMGRID_DEP} -Wl,-U -Wl,_smpi_simulated_main") > endif() > > +set(SIMGRID_DEP "${SIMGRID_DEP} -Wl,--as-needed -latomic -Wl,--no-as-needed") > target_link_libraries(simgrid${SIMGRID_DEP}) > > # Dependencies from maintainer mode -- If the facts don't fit the theory, change the facts. -- Albert Einstein (?) signature.asc Description: PGP signature
Bug#872881: simgrid: FTBFS: `__atomic_fetch_add_8' undefined
Hi, The attached patch seems to work (ie replace atomic-library with it). Using target_link_libraries should put any linker arguments at the end instead of the beginning. Thanks, James --- a/tools/cmake/MakeLib.cmake +++ b/tools/cmake/MakeLib.cmake @@ -114,6 +114,7 @@ if(enable_smpi AND APPLE) set(SIMGRID_DEP "${SIMGRID_DEP} -Wl,-U -Wl,_smpi_simulated_main") endif() +set(SIMGRID_DEP "${SIMGRID_DEP} -Wl,--as-needed -latomic -Wl,--no-as-needed") target_link_libraries(simgrid ${SIMGRID_DEP}) # Dependencies from maintainer mode signature.asc Description: OpenPGP digital signature
Processed: Re: Bug#872881: simgrid: FTBFS: `__atomic_fetch_add_8' undefined
Processing commands for cont...@bugs.debian.org: > notfixed 872881 3.16+dfsg-2 Bug #872881 [src:simgrid] simgrid: FTBFS: `__atomic_fetch_add_8' undefined Ignoring request to alter fixed versions of bug #872881 to the same values previously set > found 872881 3.16+dfsg-2 Bug #872881 [src:simgrid] simgrid: FTBFS: `__atomic_fetch_add_8' undefined Marked as found in versions simgrid/3.16+dfsg-2. > thanks Stopping processing here. Please contact me if you need assistance. -- 872881: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=872881 Debian Bug Tracking System Contact ow...@bugs.debian.org with problems
Bug#872881: simgrid: FTBFS: `__atomic_fetch_add_8' undefined
notfixed 872881 3.16+dfsg-2 found 872881 3.16+dfsg-2 thanks "Aaron M. Ucko"writes: > -Wl,--as-needed -latomic --Wl,--no-as-needed Thanks for the quick upload. However, I forgot to note that this construct needs to appear *after* the object files (or whatever else needs -latomic) to be effective. Could you please take another look? -- Aaron M. Ucko, KB1CJC (amu at alum.mit.edu, ucko at debian.org) http://www.mit.edu/~amu/ | http://stuff.mit.edu/cgi/finger/?a...@monk.mit.edu
Bug#872881: simgrid: FTBFS: `__atomic_fetch_add_8' undefined
Source: simgrid Version: 3.16+dfsg-1 Severity: serious Tags: upstream Justification: fails to build from source (but built successfully in the past) Builds of simgrid failed on armel, mips, mipsel, and the non-release architectures m68k and powerpc: lib/libsimgrid.so.3.16: undefined reference to `__atomic_fetch_add_8' collect2: error: ld returned 1 exit status CMakeFiles/testall.dir/build.make:314: recipe for target 'testall' failed Please link libsimgrid against -latomic on these architectures. You can in general do so without hardcoding an architecture list by arranging to link with -Wl,--as-needed -latomic --Wl,--no-as-needed but I don't know how easy that is to do under CMake. Thanks! -- Aaron M. Ucko, KB1CJC (amu at alum.mit.edu, ucko at debian.org) http://www.mit.edu/~amu/ | http://stuff.mit.edu/cgi/finger/?a...@monk.mit.edu