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

  • From: Steven Cozza <scozza3@xxxxxxxxxxx>
  • To: mira_talk@xxxxxxxxxxxxx
  • Date: Tue, 7 Jul 2009 20:11:42 -0600

Bastien,

I tried the build you gave me and ran into a few more problems. If I just untar and try the configure command I can see that it has trouble find my Expat installation even with the --with-expat-lib line:

checking for Expat XML Parser libraries... not found
checking for Expat XML Parser... no

I went ahead and did a make anyway and it fails at:

g++ -DPACKAGE_NAME=\"mira\" -DPACKAGE_TARNAME=\"mira\" -DPACKAGE_VERSION=\"2.9.46x3ctest1\" -DPACKAGE_STRING=\"mira\ 2.9.46x3ctest1\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE=\"mira\" -DVERSION=\"2.9.46x3ctest1\" -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DLT_OBJDIR=\".libs/\" -DYYTEXT_POINTER=1 -DSTDC_HEADERS=1 -DHAVE__BOOL=1 -DHAVE_STDBOOL_H=1 -Drestrict=__restrict -DHAVE_STDLIB_H=1 -DHAVE_MALLOC=1 -DHAVE_STDLIB_H=1 -DHAVE_REALLOC=1 -DLSTAT_FOLLOWS_SLASHED_SYMLINK=1 -DHAVE_STRFTIME=1 -DHAVE_MEMSET=1 -DHAVE_ISBLANK=1 -DHAVE_LIBZ=1 -DHAVE_NAMESPACES=/\*\*/ -DHAVE_STD=/\*\*/ -DHAVE_STL=/\*\*/ -DHAVE_BOOST=/\*\*/ -DHAVE_BOOST_THREAD=/\*\*/ -DDEVELOPMENTVERSION=1 -DBOUNDTRACKFLAG=1 -DBUGTRACKFLAG=1 -DENABLE64=1 -I. -I../  -I/usr/local/include  -DPUBLICQUIET -I/data/mccombie/cozzas/include/boost-1_39  -m64 -O2 -MT exp_flexer.flex.o -MD -MP -MF .deps/exp_flexer.flex.Tpo -c -o exp_flexer.flex.o exp_flexer.flex.C
exp_flexer.flex.C:324: error: no ‘int EXPFlexLexer::yywrap()’ member function declared in class ‘EXPFlexLexer’
exp_flexer.flex.C: In member function ‘virtual int EXPFlexLexer::yylex()’:
exp_flexer.flex.C:1312: error: ‘yywrap’ was not declared in this scope
exp_flexer.flex.C: In member function ‘int EXPFlexLexer::yyinput()’:
exp_flexer.flex.C:1731: error: ‘yywrap’ was not declared in this scope
make[2]: *** [exp_flexer.flex.o] Error 1

The problem seems that it doesn't notice the 64-bit version on the expat libraries. To solve this I had to add "-m64" to my CXXFLAGS and "-I/data/mccombie/cozzas/include" to my CPPFLAGS environment variables.

Those changes allowed the make to continue to a point where it once again complained about needing to use "-pthreads" in the compilation:

make[2]: Entering directory `/datafc/zfsdata/mccombie/cozzas/mira-2.9.46x3ctest1/src/mira'
g++ -DPACKAGE_NAME=\"mira\" -DPACKAGE_TARNAME=\"mira\" -DPACKAGE_VERSION=\"2.9.46x3ctest1\" -DPACKAGE_STRING=\"mira\ 2.9.46x3ctest1\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE=\"mira\" -DVERSION=\"2.9.46x3ctest1\" -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DLT_OBJDIR=\".libs/\" -DYYTEXT_POINTER=1 -DSTDC_HEADERS=1 -DHAVE__BOOL=1 -DHAVE_STDBOOL_H=1 -Drestrict=__restrict -DHAVE_STDLIB_H=1 -DHAVE_MALLOC=1 -DHAVE_STDLIB_H=1 -DHAVE_REALLOC=1 -DLSTAT_FOLLOWS_SLASHED_SYMLINK=1 -DHAVE_STRFTIME=1 -DHAVE_MEMSET=1 -DHAVE_ISBLANK=1 -DHAVE_LIBZ=1 -DHAVE_NAMESPACES=/\*\*/ -DHAVE_STD=/\*\*/ -DHAVE_STL=/\*\*/ -DHAVE_BOOST=/\*\*/ -DHAVE_BOOST_THREAD=/\*\*/ -DDEVELOPMENTVERSION=1 -DBOUNDTRACKFLAG=1 -DBUGTRACKFLAG=1 -DENABLE64=1 -I. -I../  -I/data/mccombie/cozzas/include -I/usr/local/include  -DPUBLICQUIET -m64 -I/data/mccombie/cozzas/include/boost-1_39  -m64 -O2 -MT estassembly.o -MD -MP -MF .deps/estassembly.Tpo -c -o estassembly.o estassembly.C
In file included from /opt/gcc4.3.1/lib/gcc/i386-pc-solaris2.11/4.3.1/../../../../include/c++/4.3.1/ext/hash_map:64,
                 from ../stdinc/stlincludes.H:72,
                 from assembly.H:54,
                 from estassembly.C:31:
/opt/gcc4.3.1/lib/gcc/i386-pc-solaris2.11/4.3.1/../../../../include/c++/4.3.1/backward/backward_warning.h:32:2: warning: #warning This file includes at least one deprecated or antiquated header which may be removed without further notice at a future date. Please use a non-deprecated interface with equivalent functionality instead. For a listing of replacement headers and interfaces, consult the file backward_warning.h. To disable this warning use -Wno-deprecated.
In file included from /data/mccombie/cozzas/include/boost-1_39/boost/thread/detail/platform.hpp:17,
                 from /data/mccombie/cozzas/include/boost-1_39/boost/thread/thread.hpp:12,
                 from ../mira/skim.H:26,
                 from assembly.H:64,
                 from estassembly.C:31:
/data/mccombie/cozzas/include/boost-1_39/boost/config/requires_threads.hpp:47:5: error: #error "Compiler threading support is not turned on. Please set the correct command line options for threading: -pthread (Linux), -pthreads (Solaris) or -mthreads (Mingw32)"

To fix that I added "-pthreads" to CXXFLAGS. At this point things moved along fairly well until once again we came to "example-programming" where we hit:

libtool: link: g++ -pthread -I/data/mccombie/cozzas/include/boost-1_39/include -DPUBLICQUIET -m64 -pthreads -I/data/mccombie/cozzas/include/boost-1_39 -m64 -O2 -m64 -o mira_101 mira_101.o  -L/data/mccombie/cozzas/mira-2.9.46x3ctest1/src/io -L/data/mccombie/cozzas/mira-2.9.46x3ctest1/src/util -L/data/mccombie/cozzas/mira-2.9.46x3ctest1/src/errorhandling -L/data/mccombie/cozzas/mira-2.9.46x3ctest1/src/mira -L/data/mccombie/cozzas/mira-2.9.46x3ctest1/src/examine -L/data/mccombie/cozzas/mira-2.9.46x3ctest1/src/EdIt -L/data/mccombie/cozzas/mira-2.9.46x3ctest1/src/caf -L/data/mccombie/cozzas/mira-2.9.46x3ctest1/src/knn_abi373 -L/data/mccombie/cozzas/mira-2.9.46x3ctest1/src/knn_alf -L/data/mccombie/cozzas/include/boost-1_39/lib -L/usr/local/lib -lmira -lEdIt -lExamine -lmsupport -lestass -lerrorhandling -lutil -ldptools -lfio -lcaf -lKNN_abi373 -lm /usr/local/lib/libexpat.so -lboost_thread-sw-mt -lz -pthreads -pthread -Wl,-R -Wl,/usr/local/lib -Wl,-R -Wl,/usr/local/lib
ld: fatal: file /usr/local/lib/libexpat.so: wrong ELF class: ELFCLASS32

Attached are the config.log and the make.log:

 

If I'm being too verbose please let me know!

-steve

Steven Cozza

Other related posts: