martin-pe / maitreya7

This is a legacy repository. Please visit the website for updates.
Other
10 stars 9 forks source link

relocation R_X86_64_32 against `.rodata.str1.1' can not be used when... #8

Open gour opened 7 years ago

gour commented 7 years ago

Hello,

as suggested in #7, I've tried to build against wx-2.8.x, but have the following problem:

...
/usr/include/wx-2.8/wx/debug.h:194:43: warning: typedef ‘wxDummyCheckInt’ locally defined but not used [-Wunused-local-typedefs]
     #define wxFORCE_SEMICOLON typedef int wxDummyCheckInt
                                           ^
/usr/include/wx-2.8/wx/debug.h:224:9: note: in expansion of macro ‘wxFORCE_SEMICOLON’
         wxFORCE_SEMICOLON /* just to force a semicolon */
         ^~~~~~~~~~~~~~~~~
/usr/include/wx-2.8/wx/dynarray.h:353:7: note: in expansion of macro ‘wxCHECK2_MSG’
       wxCHECK2_MSG( iIndex != wxNOT_FOUND, return,                    \
       ^~~~~~~~~~~~
/usr/include/wx-2.8/wx/dynarray.h:486:5: note: in expansion of macro ‘_WX_DEFINE_TYPEARRAY_HELPER’
     _WX_DEFINE_TYPEARRAY_HELPER(T, name, base, classexp, _WX_PTROP_NONE)
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/wx-2.8/wx/dynarray.h:669:5: note: in expansion of macro ‘_WX_DEFINE_TYPEARRAY_PTR’
     _WX_DEFINE_TYPEARRAY_PTR(_wxArray##name, name, base, classdecl)
     ^~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/wx-2.8/wx/dynarray.h:856:5: note: in expansion of macro ‘WX_DEFINE_TYPEARRAY_WITH_DECL_PTR’
     WX_DEFINE_TYPEARRAY_WITH_DECL_PTR(T, name, wxBaseArrayInt, wxARRAY_EMPTY expmode)
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/wx-2.8/wx/textbuf.h:43:1: note: in expansion of macro ‘WX_DEFINE_USER_EXPORTED_ARRAY_INT’
 WX_DEFINE_USER_EXPORTED_ARRAY_INT(wxTextFileType,
 ^
<stdout>: In function ‘int yy_get_next_buffer()’:
<stdout>:3010:18: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
<stdout>:4167:3: note: in expansion of macro ‘YY_INPUT’
<stdout>: At global scope:
<stdout>:4269:17: warning: ‘void yyunput(int, char*)’ defined but not used [-Wunused-function]
mv -f .deps/MdlLexer.Tpo .deps/MdlLexer.Po
rm -f libjyotish.a
ar cru libjyotish.a ArabicParts.o Ashtakavarga.o AshtottariDasa.o Aspect.o astrobase.o Dasa.o Eclipse.o Ephemeris.o Expert.o Expression.o GenericDasa.o Hora.o Horoscope.o HtmlWriter.o Jaimini.o KalachakraDasa.o MdlInterpreter.o Nakshatra.o Partner.o Planet.o PrintoutHelper.o SimpleHoroscope.o SingletonLifeline.o textclient.o TextHelper.o TextWriter.o Transit.o UranianBase.o Uranian.o UranianHelper.o Varga.o VargaHoroscope.o VimsottariDasa.o Writer.o WriterFactory.o YogaConfig.o Yoga.o MdlParser.o MdlParser.o MdlLexer.o MdlLexer.o 
ranlib libjyotish.a
g++  -g -O2   -o maitreya_textclient textclient.o libjyotish.a ../base/libmaitreya_base.a ../swe/libswe.a  -pthread -Wl,-z,relro -specs=/usr/lib/rpm/redhat/redhat-hardened-ld  -lwx_gtk2u_richtext-2.8 -lwx_gtk2u_aui-2.8 -lwx_gtk2u_xrc-2.8 -lwx_gtk2u_qa-2.8 -lwx_gtk2u_html-2.8 -lwx_gtk2u_adv-2.8 -lwx_gtk2u_core-2.8 -lwx_baseu_xml-2.8 -lwx_baseu_net-2.8 -lwx_baseu-2.8  
/usr/bin/ld: textclient.o: relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a shared object; recompile with -fPIC
textclient.o: error adding symbols: Bad value
collect2: error: ld returned 1 exit status
Makefile:465: recipe for target 'maitreya_textclient' failed
make[4]: *** [maitreya_textclient] Error 1
make[4]: Leaving directory '/home/gour/repos/external/maitreya7/src/jyotish'
Makefile:380: recipe for target 'all' failed
make[3]: *** [all] Error 2
make[3]: Leaving directory '/home/gour/repos/external/maitreya7/src/jyotish'
Makefile:362: recipe for target 'all-recursive' failed
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory '/home/gour/repos/external/maitreya7/src'
Makefile:486: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/home/gour/repos/external/maitreya7'
Makefile:385: recipe for target 'all' failed
make: *** [all] Error 2

Any hint?

martin-pe commented 7 years ago

Try wxWidgets 3.0.2 with configure --with-gtk=2

gour commented 7 years ago

Tried and it does build, but have the same problem with missing menu & toolbars. :-(