[mira_talk] how do you get MIRA to compile on OpenSolaris?

  • From: Steven Cozza <scozza3@xxxxxxxxxxx>
  • To: mira_talk@xxxxxxxxxxxxx
  • Date: Mon, 6 Jul 2009 21:24:56 -0600

Hi all,

I'm trying to install MIRA on an OpenSolaris system. I used the command:

./configure --enable-64=yes --disable-static

to configure the install but it still ends up failing to compile. The error message is:

g++ -pthread -DPUBLICQUIET -m64 -pthreads -I/data/mccombie/cozzas/ include -I/data/mccombie/cozzas/include/boost-1_39 -L/usr/lib/amd64 -O3 -L../io/ -L../util/ -L../errorhandling/ -L../mira -L../examine/ - L../EdIt/ -L../caf/ -L../knn_abi373 -L../knn_alf -o mira_101 mira_101.o -lmira -lEdIt -lExamine -lmsupport -lestass - lerrorhandling -lutil -ldptools -lfio -lcaf -lKNN_abi373 -lm -lexpat ld: warning: file ../knn_abi373/libKNN_abi373.a(wrong.o): wrong ELF class: ELFCLASS32 ld: warning: relocation warning: R_AMD64_64: file ../mira/ libmira.a(newpathfinder.o): section .rela.eh_frame: symbol .gnu .linkonce .t ._ZNSt6vectorIiSaIiEE13_M_insert_auxEN9__gnu_cxx17__normal_iteratorIPiS1_EERKi (section): relocation against discarded COMDAT section .gnu .linkonce .t ._ZNSt6vectorIiSaIiEE13_M_insert_auxEN9__gnu_cxx17__normal_iteratorIPiS1_EERKi : symbol not found, relocation ignored

a lot of this ending in:

Undefined                       first referenced
 symbol                             in file
add                                 ../examine//libExamine.a(calc.o)
over                                ../examine//libExamine.a(calc.o)
typeinfo for boost::thread_resource_error ../mira/libmira.a(skim.o)
ncall                               ../examine//libExamine.a(calc.o)
nplus                               ../examine//libExamine.a(calc.o)
under                               ../examine//libExamine.a(calc.o)
wrong                               ../examine//libExamine.a(calc.o)
boost::lock_error::~lock_error()    ../mira/libmira.a(skim.o)
boost::lock_error::lock_error()     ../mira/libmira.a(skim.o)
vtable for boost::detail::thread_data_base ../mira/libmira.a(skim.o)
typeinfo for boost::detail::thread_data_base ../mira/libmira.a(skim.o)
boost::detail::get_current_thread_data()    ../mira/libmira.a(skim.o)
missing                             ../examine//libExamine.a(calc.o)
boost::thread_resource_error::thread_resource_error() ../mira/ libmira.a(skim.o) boost::thread_resource_error::~thread_resource_error() ../mira/ libmira.a(skim.o)
boost::thread::join()               ../mira/libmira.a(skim.o)
boost::thread::start_thread()       ../mira/libmira.a(skim.o)
typeinfo for boost::lock_error      ../mira/libmira.a(skim.o)
boost::thread::~thread()            ../mira/libmira.a(skim.o)
boost::detail::thread_data_base::~thread_data_base() ../mira/ libmira.a(skim.o)
ld: fatal: Symbol referencing errors. No output written to mira_101
collect2: ld returned 1 exit status


I've tried various things to get it to create a shared library (which I thought --disable-static would have done anyway) but nothing has work. It looks like it is using ar directly and not going through libtool, for example:

mv -f .deps/ncall.Tpo .deps/ncall.Po
rm -f libKNN_abi373.a
ar cru libKNN_abi373.a wrong.o under.o add.o over.o nplus.o missing.o ncall.o
ranlib libKNN_abi373.a

Does anyone have any suggestions on how to get this to compile? Thanks for any help.

-steve

Steven Cozza

The output from the configure looks like:

checking for a BSD-compatible install... /usr/local/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/local/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking build system type... i386-pc-solaris2.11
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
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 g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking for ranlib... ranlib
checking whether make sets $(MAKE)... (cached) yes
checking whether ln -s works... yes
checking for a sed that does not truncate output... /usr/bin/gsed
checking for flex... flex
checking lex output file root... lex.yy
checking lex library... -lfl
checking whether yytext is a pointer... yes
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /usr/sfw/bin/ggrep
checking for egrep... /usr/sfw/bin/ggrep -E
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 stdbool.h that conforms to C99... yes
checking for _Bool... yes
checking for an ANSI C-conforming const... yes
checking for inline... inline
checking for C/C++ restrict keyword... __restrict
checking whether struct tm is in sys/time.h or time.h... time.h
checking for stdlib.h... (cached) yes
checking for GNU libc compatible malloc... yes
checking for stdlib.h... (cached) yes
checking for GNU libc compatible realloc... yes
checking whether lstat dereferences a symlink specified with a trailing slash... yes
checking whether stat accepts an empty string... no
checking for strftime... yes
checking for floor... no
checking for memset... yes
checking for pow... no
checking for sqrt... no
checking for boostlib >= 1.35.0... yes
checking whether the Boost::Thread library is available... yes
checking for int64_t... yes
checking whether long long has 64bit... no
checking whether enabling 64bit compilation support... yes
checking for flex version compatible with MIRA... yes
checking for compiler optimisation settings... -O3
checking for purify... no
checking whether mira should compile in public quiet mode... yes
checking whether mira should compile a development version... yes
checking whether mira should compile with bound tracking... yes
checking whether mira should compile with bug tracking... yes
checking whether mira should compile with extended bug tracking... no
checking whether mira should compile with function trace... no
checking expat.h usability... yes
checking expat.h presence... yes
checking for expat.h... yes
configure: creating ./config.status
config.status: creating Makefile
config.status: creating src/Makefile
config.status: creating src/stdinc/Makefile
config.status: creating src/lec/Makefile
config.status: creating src/errorhandling/Makefile
config.status: creating src/util/Makefile
config.status: creating src/io/Makefile
config.status: creating src/mira/Makefile
config.status: creating src/EdIt/Makefile
config.status: creating src/caf/Makefile
config.status: creating src/examine/Makefile
config.status: creating src/knn_abi373/Makefile
config.status: creating src/knn_alf/Makefile
config.status: creating src/support/Makefile
config.status: creating src/scripts/Makefile
config.status: creating src/test/Makefile
config.status: creating src/test/io/Makefile
config.status: creating src/test/io/scf/Makefile
config.status: creating src/test/io/fasta/Makefile
config.status: creating src/test/io/generalio/Makefile
config.status: creating src/test/mira/Makefile
config.status: creating src/test/mira/align/Makefile
config.status: creating src/test/mira/read/Makefile
config.status: creating src/test/mira/readpool/Makefile
config.status: creating src/examples_programming/Makefile
config.status: creating src/progs/Makefile
config.status: creating doc/Makefile
config.status: creating distribution/Makefile
config.status: executing depfiles commands

--------------------------------------------------------------------------------
                       Summary of MIRA configuration
--------------------------------------------------------------------------------

Building version ................................. 2.9.46_dev_solaris2.11_i386
-n Production or development version?................
development

We are building on ............................... SunOS
CPU supports 64 bit? ......... ................... no
Compiler ......................................... gcc
-n Compiler optimisation flags used .................
-O3
Building completely static? ...................... no
-n BOOST expected to compile and link?...............
maybe

Can MIRA be built on this system? ................ unknown

No information regarding builds in this environment available. Please report
success or failure.


System: SunOS jupiter 5.11 snv_101b i86pc i386 i86pc Solaris
Compiler: 'gcc -v' output:
Using built-in specs.
Target: i386-pc-solaris2.11
Configured with: ./configure --prefix=/opt/gcc4.3.1 --with-gnu-as -- with-as=/usr/bin/gas --without-gnu-ld --with-ld=/usr/ccs/bin/ld -- enable-languages=c,c++,fortran,objc --with-mpfr=/usr/local --with- gmp=/usr/local
Thread model: posix
gcc version 4.3.1 (GCC)


There was a problem in configuring Boost completely automatically.
The configure script tried to guess some directories, but in case
 there is a problem in compiling or linking with BOOST, you
 might want to test a few other ./configure options for Boost.
--------------------------------------------------------------------------------
Ooops, we might encounter some problems in compilation/linking. Please give
it a try and report success or failure.

Type 'make' to make the binaries and if no error occured,
then 'make install' to install them.

In case of failure, please help to fix if you can.

Other related posts: