After my recent failure to build Sage with the gcc on my system (4.5.0), I tried to use Sage's built in gcc (4.9.2), which worked until it tried to build the package zeromq-4.0.5, which I think is a standard package added since I last built Sage on Solaris. I believe this is an upstream bug, and have reported it to Martin Sustrik sust...@250bpm.com
I created a trac ticket http://trac.sagemath.org/ticket/18576 This is the build log. drkirkby@buzzard:~/sage-6.7/logs/pkgs$ cat zeromq-4.0.5.log Found local metadata for zeromq-4.0.5 Found local sources at /export/home/drkirkby/sage-6.7/upstream/zeromq-4.0.5.tar.gz /export/home/drkirkby/sage-6.7/src/bin/sage-spkg: line 101: command: shasum: not found /export/home/drkirkby/sage-6.7/src/bin/sage-spkg: line 104: command: md5sum: not found /export/home/drkirkby/sage-6.7/src/bin/sage-spkg: line 107: command: md5: not found Checksum: 667919094 vs 667919094 zeromq-4.0.5 ==================================================== Setting up build directory for zeromq-4.0.5 Finished set up **************************************************** Host system: SunOS buzzard 5.10 Generic sun4u sparc SUNW,Sun-Blade-1000 **************************************************** C compiler: gcc C compiler version: Using built-in specs. COLLECT_GCC=gcc COLLECT_LTO_WRAPPER=/export/home/drkirkby/sage-6.7/local/libexec/gcc/sparc-sun-solaris2.10/4.9.2/lto-wrapper Target: sparc-sun-solaris2.10 Configured with: ../src/configure --prefix=/export/home/drkirkby/sage-6.7/local --with-local-prefix=/export/home/drkirkby/sage-6.7/local --with-gmp=/export/home/drkirkby/sage-6.7/local --with-mpfr=/export/home/drkirkby/sage-6.7/local --with-mpc=/export/home/drkirkby/sage-6.7/local --with-system-zlib --disable-multilib --disable-nls --enable-languages=c,c++,fortran --disable-libitm --with-as=/usr/ccs/bin/as --with-ld=/usr/ccs/bin/ld Thread model: posix gcc version 4.9.2 (GCC) **************************************************** patching file tools/curve_keygen.c patching file tools/curve_keygen.cpp patching file tools/Makefile.am patching file tools/Makefile.in patching file configure.ac patching file src/Makefile.am patching file configure Hunk #1 succeeded at 623 (offset -20 lines). Hunk #2 succeeded at 17631 (offset -12 lines). Hunk #3 succeeded at 19842 (offset -14 lines). Hunk #4 succeeded at 20324 (offset -22 lines). patching file src/Makefile.in Hunk #1 succeeded at 472 (offset -32 lines). checking for a BSD-compatible install... config/install-sh -c checking whether build environment is sane... yes checking for a thread-safe mkdir -p... config/install-sh -c -d checking for gawk... no checking for mawk... no checking for nawk... nawk checking whether make sets $(MAKE)... yes checking how to create a ustar tar archive... gnutar checking whether make supports nested variables... yes checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes checking for gcc option to accept ISO C89... none needed checking for style of include used by make... GNU checking dependency style of gcc... gcc3 checking for gcc option to accept ISO C99... -std=gnu99 checking whether we are using the GNU C++ compiler... yes checking whether g++ accepts -g... yes checking dependency style of g++... gcc3 checking whether gcc -std=gnu99 and cc understand -c and -o together... yes checking for a sed that does not truncate output... /usr/bin/sed checking for gawk... (cached) nawk checking for xmlto... no checking for asciidoc... no checking build system type... sparc-sun-solaris2.10 checking host system type... sparc-sun-solaris2.10 checking how to print strings... printf checking for a sed that does not truncate output... (cached) /usr/bin/sed checking for grep that handles long lines and -e... /usr/sfw/bin/ggrep checking for egrep... /usr/sfw/bin/ggrep -E checking for fgrep... /usr/sfw/bin/ggrep -F checking for ld used by gcc -std=gnu99... /usr/ccs/bin/ld checking if the linker (/usr/ccs/bin/ld) is GNU ld... no checking for BSD- or MS-compatible name lister (nm)... /usr/ccs/bin/nm -p checking the name lister (/usr/ccs/bin/nm -p) interface... BSD nm checking whether ln -s works... yes checking the maximum length of command line arguments... 786240 checking whether the shell understands some XSI constructs... yes checking whether the shell understands "+="... no checking how to convert sparc-sun-solaris2.10 file names to sparc-sun-solaris2.10 format... func_convert_file_noop checking how to convert sparc-sun-solaris2.10 file names to toolchain format... func_convert_file_noop checking for /usr/ccs/bin/ld option to reload object files... -r checking for objdump... objdump checking how to recognize dependent libraries... pass_all checking for dlltool... dlltool checking how to associate runtime and link libraries... printf %s\n checking for archiver @FILE support... no checking for strip... strip checking for ranlib... ranlib checking command to parse /usr/ccs/bin/nm -p output from gcc -std=gnu99 object... ok checking for sysroot... no checking for mt... mt checking if mt is a manifest tool... no checking how to run the C preprocessor... cpp checking for ANSI C header files... yes checking for sys/types.h... yes checking for sys/stat.h... yes checking for stdlib.h... yes checking for string.h... yes checking for memory.h... yes checking for strings.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for unistd.h... yes checking for dlfcn.h... yes checking for objdir... .libs checking if gcc -std=gnu99 supports -fno-rtti -fno-exceptions... no checking for gcc -std=gnu99 option to produce PIC... -fPIC -DPIC checking if gcc -std=gnu99 PIC flag -fPIC -DPIC works... yes checking if gcc -std=gnu99 static flag -static works... no checking if gcc -std=gnu99 supports -c -o file.o... yes checking if gcc -std=gnu99 supports -c -o file.o... (cached) yes checking whether the gcc -std=gnu99 linker (/usr/ccs/bin/ld) supports shared libraries... yes checking whether -lc should be explicitly linked in... no checking dynamic linker characteristics... solaris2.10 ld.so checking how to hardcode library paths into programs... immediate checking whether stripping libraries is possible... no checking if libtool supports shared libraries... yes checking whether to build shared libraries... yes checking whether to build static libraries... yes checking how to run the C++ preprocessor... g++ -E checking for ld used by g++... /usr/ccs/bin/ld checking if the linker (/usr/ccs/bin/ld) is GNU ld... no checking whether the g++ linker (/usr/ccs/bin/ld) supports shared libraries... yes checking for g++ option to produce PIC... -fPIC -DPIC checking if g++ PIC flag -fPIC -DPIC works... yes checking if g++ static flag -static works... no checking if g++ supports -c -o file.o... yes checking if g++ supports -c -o file.o... (cached) yes checking whether the g++ linker (/usr/ccs/bin/ld) supports shared libraries... yes checking dynamic linker characteristics... solaris2.10 ld.so checking how to hardcode library paths into programs... immediate checking whether the C compiler works... yes checking whether we are using Intel C compiler... no checking whether we are using Sun Studio C compiler... no checking whether we are using clang C compiler... no checking whether we are using gcc >= 4 C compiler... yes checking whether the C++ compiler works... yes checking whether we are using Intel C++ compiler... no checking whether we are using Sun Studio C++ compiler... no checking whether we are using clang C++ compiler... no checking whether we are using gcc >= 4 C++ compiler... yes checking whether to enable debugging information... no checking whether to enable code coverage... no checking for socket in -lsocket... yes checking for gethostbyname in -lnsl... yes checking whether atomic operations can be used... yes checking for pthread_create in -lpthread... yes checking for clock_gettime in -lrt... yes checking for sodium_init in -lsodium... no configure: WARNING: libsodium is needed for CURVE security checking whether C++ compiler supports -fvisibility=hidden... yes checking whether C++ compiler supports dso visibility... yes checking whether C++ compiler supports -mcpu=v9... yes checking for asciidoc... no checking for xmlto... no checking whether to build documentation... no checking whether to install manpages... yes checking for suitable polling system... using poll checking for ANSI C header files... (cached) yes checking errno.h usability... yes checking errno.h presence... yes checking for errno.h... yes checking arpa/inet.h usability... yes checking arpa/inet.h presence... yes checking for arpa/inet.h... yes checking netinet/tcp.h usability... yes checking netinet/tcp.h presence... yes checking for netinet/tcp.h... yes checking netinet/in.h usability... yes checking netinet/in.h presence... yes checking for netinet/in.h... yes checking stddef.h usability... yes checking stddef.h presence... yes checking for stddef.h... yes checking for stdlib.h... (cached) yes checking for string.h... (cached) yes checking sys/socket.h usability... yes checking sys/socket.h presence... yes checking for sys/socket.h... yes checking sys/time.h usability... yes checking sys/time.h presence... yes checking for sys/time.h... yes checking time.h usability... yes checking time.h presence... yes checking for time.h... yes checking for unistd.h... (cached) yes checking limits.h usability... yes checking limits.h presence... yes checking for limits.h... yes checking ifaddrs.h usability... no checking ifaddrs.h presence... no checking for ifaddrs.h... no checking sys/uio.h usability... yes checking sys/uio.h presence... yes checking for sys/uio.h... yes checking sys/eventfd.h usability... no checking sys/eventfd.h presence... no checking for sys/eventfd.h... no checking for stdbool.h that conforms to C99... yes checking for _Bool... no checking for an ANSI C-conforming const... yes checking for inline... inline checking for size_t... yes checking for ssize_t... yes checking whether time.h and sys/time.h may both be included... yes checking for uint32_t... yes checking for working volatile... yes checking how to enable additional warnings for C++ compiler... -Wall checking how to turn warnings to errors in C++ compiler... -Werror checking how to enable strict standards compliance in C++ compiler... -pedantic checking return type of signal handlers... void checking for perror... yes checking for gettimeofday... yes checking for clock_gettime... yes checking for memset... yes checking for socket... yes checking for getifaddrs... no checking for freeifaddrs... no checking for fork... yes checking alloca.h usability... yes checking alloca.h presence... yes checking for alloca.h... yes checking whether SOCK_CLOEXEC is supported... no checking whether SO_KEEPALIVE is supported... yes checking whether TCP_KEEPCNT is supported... no checking whether TCP_KEEPIDLE is supported... no checking whether TCP_KEEPINTVL is supported... no checking whether TCP_KEEPALIVE is supported... no configure: creating ./config.status config.status: creating Makefile config.status: creating src/Makefile config.status: creating src/libzmq.pc config.status: creating doc/Makefile config.status: creating perf/Makefile config.status: creating tests/Makefile config.status: creating tools/Makefile config.status: creating builds/msvc/Makefile config.status: creating foreign/openpgm/Makefile config.status: creating builds/redhat/zeromq.spec config.status: creating src/platform.hpp config.status: executing depfiles commands config.status: executing libtool commands make[3]: Entering directory `/export/home/drkirkby/sage-6.7/local/var/tmp/sage/build/zeromq-4.0.5/src' Making all in src make[4]: Entering directory `/export/home/drkirkby/sage-6.7/local/var/tmp/sage/build/zeromq-4.0.5/src/src' make[5]: Entering directory `/export/home/drkirkby/sage-6.7/local/var/tmp/sage/build/zeromq-4.0.5/src' make[5]: Leaving directory `/export/home/drkirkby/sage-6.7/local/var/tmp/sage/build/zeromq-4.0.5/src' make all-am make[5]: Entering directory `/export/home/drkirkby/sage-6.7/local/var/tmp/sage/build/zeromq-4.0.5/src/src' make[6]: Entering directory `/export/home/drkirkby/sage-6.7/local/var/tmp/sage/build/zeromq-4.0.5/src' make[6]: Leaving directory `/export/home/drkirkby/sage-6.7/local/var/tmp/sage/build/zeromq-4.0.5/src' CXX libzmq_la-address.lo CXX libzmq_la-clock.lo CXX libzmq_la-ctx.lo In file included from ctx.hpp:34:0, from ctx.cpp:30: atomic_counter.hpp: In member function 'zmq::atomic_counter_t::integer_t zmq::atomic_counter_t::add(zmq::atomic_counter_t::integer_t)': atomic_counter.hpp:87:71: error: invalid conversion from 'volatile integer_t* {aka volatile unsigned int*}' to 'uint32_t* {aka unsigned int*}' [-fpermissive] integer_t new_value = atomic_add_32_nv (&value, increment_); ^ atomic_counter.hpp: In member function 'bool zmq::atomic_counter_t::sub(zmq::atomic_counter_t::integer_t)': atomic_counter.hpp:130:59: error: invalid conversion from 'volatile integer_t* {aka volatile unsigned int*}' to 'uint32_t* {aka unsigned int*}' [-fpermissive] integer_t nv = atomic_add_32_nv (&value, delta); ^ make[5]: *** [libzmq_la-ctx.lo] Error 1 make[5]: Leaving directory `/export/home/drkirkby/sage-6.7/local/var/tmp/sage/build/zeromq-4.0.5/src/src' make[4]: *** [all] Error 2 make[4]: Leaving directory `/export/home/drkirkby/sage-6.7/local/var/tmp/sage/build/zeromq-4.0.5/src/src' make[3]: *** [all-recursive] Error 1 make[3]: Leaving directory `/export/home/drkirkby/sage-6.7/local/var/tmp/sage/build/zeromq-4.0.5/src' Failed to build zeromq real 4m43.892s user 0m20.656s sys 0m17.228s ************************************************************************ Error installing package zeromq-4.0.5 ************************************************************************ I suspect that the actual line of code that is presenting the problem is not executed on either x86 or ARM processors, which probably explains why it has not been seen before. It appears there is assembly code for x86 and ARM processors, and what I assume is standard C++ on the SPARC processor. #if defined ZMQ_ATOMIC_COUNTER_WINDOWS old_value = InterlockedExchangeAdd ((LONG*) &value, increment_); #elif defined ZMQ_ATOMIC_COUNTER_ATOMIC_H integer_t new_value = atomic_add_32_nv (&value, increment_); // ERROR OCCURS HERE ON SOLARIS old_value = new_value - increment_; #elif defined ZMQ_ATOMIC_COUNTER_TILE old_value = arch_atomic_add (&value, increment_); #elif defined ZMQ_ATOMIC_COUNTER_X86 __asm__ volatile ( "lock; xadd %0, %1 \n\t" : "=r" (old_value), "=m" (value) : "0" (increment_), "m" (value) : "cc", "memory"); #elif defined ZMQ_ATOMIC_COUNTER_ARM integer_t flag, tmp; Dr. David Kirkby Ph.D CEng MIET Kirkby Microwave Ltd Registered office: Stokes Hall Lodge, Burnham Rd, Althorne, Essex, CM3 6DT, UK. Registered in England and Wales, company number 08914892. http://www.kirkbymicrowave.co.uk/ Tel: 07910 441670 / +44 7910 441670 (0900 to 2100 GMT only please) -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.