On 06/16/2014 08:09 PM, Lee Bengston wrote:
On Sun, Jun 15, 2014 at 7:24 PM, Gordon P. Howell, Jr. <[email protected]>
wrote:

I’ve searched for a fix for this problem without luck.  The make process
errors out on usr/bin/ld stating that the process can’t be used for a
shared object and requiring a recompile with option -fPIC.

How can I fix this?

​You must be using the 64 bit version of Ubuntu.  I encountered the same
issue 10 days ago.  I haven't found a solution, either.  For me it has not
been a priority - I was just doing some due ​diligence by testing out a
build script in a 64 bit Ubuntu installation after it had worked fine in a
32 bit installation.  I happen to be using Xastir on a 2009 Intel Atom
based machine, so not being able to build it in the 64 bit version doesn't
impact my actual usage.  I hope it gets figured out soon - 64 bit should be
fairly common now.

Lee - K5DAT
I spun up fresh Ubuntu 14.04 Desktop AMD64 VM and did a maximal install less gdal to verify, here's the error:

gcc -g -O2 -pipe -W -Wall -Wpointer-arith -Wstrict-prototypes -Wno-unused-parameter -pthread -Wl,--no-keep-memory -L/usr/lib -fPIE -pie -Wl,-z,relro -Wl,-z,now -L/usr/lib/X11 -L/usr/local/lib -o xastir alert.o awk.o bulletin_gui.o color.o datum.o db.o db_gis.o dbfawk.o draw_symbols.o fcc_data.o festival.o fetch_remote.o geo-find.o geocoder_gui.o gps.o hashtable.o hashtable_itr.o hostname.o igate.o interface.o interface_gui.o io-common.o io-mmap.o lang.o list_gui.o locate_gui.o location.o location_gui.o main.o maps.o map_cache.o map_dos.o map_gdal.o map_geo.o map_gnis.o map_OSM.o map_pop.o map_pdb.o map_shp.o map_tif.o map_tiger.o map_WMS.o messages.o messages_gui.o objects.o popup_gui.o rac_data.o rotated.o rpl_malloc.o shp_hash.o snprintf.o sound.o tile_mgmnt.o track_gui.o util.o view_message_gui.o wx.o wx_gui.o x_spider.o xa_config.o compiledate.o -Lrtree -lrtree -lXm -lXt -lX11 -lGraphicsMagick -ljbig -llcms2 -ltiff -lfreetype -ljasper -ljpeg -lpng12 -lwmflite -lXext -lSM -lICE -lX11 -llzma -lbz2 -lxml2 -lz -lm -lgomp -lpthread -ldb-5.3 -lXpm -lrt -lXm -lXt -lXp -lXext -lm -lSM -lICE -lX11 -lcurl -lproj -lshp -lpcre -ltiff -lgeotiff -lax25 /usr/bin/ld: alert.o: relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a shared object; recompile with -fPIC
alert.o: error adding symbols: Bad value
collect2: error: ld returned 1 exit status
make[3]: *** [xastir] Error 1
make[3]: Leaving directory `/home/rstark/xastir/src/xastir/build/src'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/rstark/xastir/src/xastir/build/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/rstark/xastir/src/xastir/build'
make: *** [all] Error 2



As a broad work around I did what the compiler suggested and did:
make clean
../configure CPPFLAGS="-fPIC -I/usr/include/geotiff"
make

and as expected the error goes away but then all of the executables are PIC enabled64 AMD64 requires shared libraries to be compiled with -fPIC, ia32 does not thus you don't see the error on your 32bit ATOM box.

It looks like this topic came up on the list last June as well:
http://lists.xastir.org/pipermail/xastir/2013-June/thread.html#21654
"[Xastir] More Kubuntu 13 map problems"

I'll try and narrow it down a bit more tomorrow if I have some time.

-Ryan
_______________________________________________
Xastir mailing list
[email protected]
http://xastir.org/mailman/listinfo/xastir

Reply via email to