Opened 6 years ago

Last modified 6 years ago

#6746 new Bugs

Boost fails to build 64-bit on Solaris sparc with toolset=gcc

Reported by: tripivceta@… Owned by: Vladimir Prus
Milestone: To Be Determined Component: build
Version: Boost 1.38.0 Severity: Showstopper
Keywords: Cc:

Description

Boost 1.38.0 is needed in order to build PowerDNS, as PowerDNS specifically looks for libboost_program_options_*gcc*.so.

I have tried each and every permutation to convince the Boost build system that it is really OK to use GCC on the sparc platform with Solaris's linker and assembler, but to no avail.

The following is used:

tools/jam/src/bin.solaris/bjam -d4 -j2 --without-mpi --toolset=gcc --prefix=/opt/boost --libdir=/opt/boost/lib/64 address-model=64 cxxflags=-m64 linkflags=-m64

...and here is one of many identical failures during the build process:

"g++" -ftemplate-depth-128 -O3 -finline-functions -Wno-inline -Wall -pthreads -fPIC -m64 -DBOOST_ALL_NO_LIB=1 -DBOOST_MATH_TR1_DYN_LINK=1 -DNDEBUG -I"." -c -o "bin.v2/libs/math/build/gcc-3.4.3/release/address-model-64/threading-multi/expm1.o" "libs/math/build/../src/tr1/expm1.cpp"

/usr/ccs/bin/as: error: unknown option '-' /usr/ccs/bin/as: error: unknown option 't' /usr/ccs/bin/as: error: unknown option 'aditional-format' /usr/ccs/bin/as: error: unknown option '6' /usr/ccs/bin/as: error: unknown option '4' /usr/ccs/bin/as: error: unknown option 'A' /usr/ccs/bin/as: error: unknown option '9' usage: /usr/ccs/bin/as [-V] [-Q{y,n}] [-q] [-s]

[-S] [-K {pic,PIC}] [-o objfile] [-L] [-T] [-P -Yc,path] [-Ipath] [-Dname] [-Dname=def] [-Uname?...] [-m [-Ym,path]] [-n] [-ul] [-xF] [-m32] [-m64] [-xarch={v7,v8,v8a,v8plus,v8plusa,v8plusb,v9,v9a,v9b,sparc,sparcvis,sparcvis2,sparcvis3,sparcfmaf,sparcima}] [-xcode={pic13,pic32}] file.s...

0.000129 sec system; 0.003178 sec user ...failed gcc.compile.c++ bin.v2/libs/math/build/gcc-3.4.3/release/address-model-64/threading-multi/expm1.o...

Upgrading to newer version of Boost has been unsuccessful, as PowerDNS's ./configure specifically looks for library version in the .so file name, and this has changed sometime after the 1.38.0 revision.

Where is the linker getting the "-t aditional-format 64A9' from, and why does this happen only on sparc?

Change History (4)

comment:1 in reply to:  description Changed 6 years ago by Steven Watanabe

Replying to tripivceta@…:

Where is the linker getting the "-t aditional-format 64A9' from, and why does this happen only on sparc?

I have no idea. Forget about Boost.Build for now. Can you find a g++ command line that works? I don't see anything odd about it.

comment:2 Changed 6 years ago by anonymous

No, unfortunately there are no results written to either stage/ or the target install directory.

Should I crank up the logging with -d9?

comment:3 Changed 6 years ago by anonymous

I tracked down the as(1) error to SUNWgcc: for some reason, Sun compiled GCC --with-as=/usr/sfw/bin/gas --with-gnu-as, but "SUNWgcc" does not declare "SUNWbinutils", which brings on /usr/sfw/bin/gas as a dependency. Installing "SUNWbinutils" resolves the "/usr/ccs/bin/as: error: unknown option '-' /usr/ccs/bin/as: error: unknown option 't' /usr/ccs/bin/as: error: unknown option" since GNU as(1) is now avabilable, but "bjam" still ignores any combination of options to build 64-bit.

The following combinations have all been tried by passing them to "bjam":

-sBUILD='<cxxflags>-m64 <linkflags>-m64 <address-model>64'

as well as

"cxxflags=-m64 linkflags=-m64 adress-model=-m64"

all to no avail. All of those invocations are simply ignored, and bjam builds a 32-bit version of the libraries.

comment:4 Changed 6 years ago by viboes

Component: Building Boostbuild
Owner: set to Vladimir Prus
Note: See TracTickets for help on using tickets.