Bug#845730: torus-trooper: FTBFS: relocation R_X86_64_PC32 against symbol `_D3std6format18__T10FormatSpecTaZ10FormatSpec6flZeroMFNaNbNdNiNfbZv' can not be used when making a shared object; recompile with -fPIC

Adrian Bunk bunk at stusta.de
Sun Nov 27 08:20:07 UTC 2016


Control: reassign -1 src:gcc-6 6.2.0-7
Control: affects -1 src:torus-trooper

On Sat, Nov 26, 2016 at 10:59:23AM +0100, Chris Lamb wrote:
>...
> torus-trooper fails to build from source in unstable/amd64:
> 
>   […]
> 
>   dh_auto_build -- DFLAGS="-frelease"
>   	make -j1 DFLAGS=-frelease
>   make[2]: Entering directory '«BUILDDIR»'
>   gdc -o torus-trooper import/SDL.d import/SDL_active.d import/SDL_audio.d import/SDL_byteorder.d import/SDL_cdrom.d import/SDL_copying.d import/SDL_endian.d import/SDL_error.d import/SDL_events.d import/SDL_getenv.d import/SDL_joystick.d import/SDL_keyboard.d import/SDL_keysym_.d import/SDL_mixer.d import/SDL_mouse.d import/SDL_mutex.d import/SDL_quit.d import/SDL_rwops.d import/SDL_syswm.d import/SDL_thread.d import/SDL_timer.d import/SDL_types.d import/SDL_version_.d import/SDL_video.d import/bulletml.d import/opengl.d import/openglu.d src/abagames/tt/barrage.d src/abagames/tt/boot.d src/abagames/tt/bulletactor.d src/abagames/tt/bulletactorpool.d src/abagames/tt/bulletimpl.d src/abagames/tt/bullettarget.d src/abagames/tt/camera.d src/abagames/tt/enemy.d src/abagames/tt/floatletter.d src/abagames/tt/gamemanager.d src/abagames/tt/letter.d src/abagames/tt/particle.d src/abagames/tt/prefmanager.d src/abagames/tt/replay.d src/abagames/tt/screen.d src/abagames/tt/shape.d src/abagames/tt/ship.d src/abagames/tt/shot.d src/abagames/tt/soundmanager.d src/abagames/tt/stagemanager.d src/abagames/tt/title.d src/abagames/tt/tunnel.d src/abagames/util/actor.d src/abagames/util/bulletml/bullet.d src/abagames/util/bulletml/bulletsmanager.d src/abagames/util/iterator.d src/abagames/util/logger.d src/abagames/util/prefmanager.d src/abagames/util/rand.d src/abagames/util/sdl/displaylist.d src/abagames/util/sdl/gamemanager.d src/abagames/util/sdl/input.d src/abagames/util/sdl/luminous.d src/abagames/util/sdl/mainloop.d src/abagames/util/sdl/pad.d src/abagames/util/sdl/recordablepad.d src/abagames/util/sdl/screen.d src/abagames/util/sdl/screen3d.d src/abagames/util/sdl/sdlexception.d src/abagames/util/sdl/sound.d src/abagames/util/sdl/texture.d src/abagames/util/tokenizer.d src/abagames/util/vector.d -Iimport -Isrc -Wno-deprecated -frelease -g -O2 -fdebug-prefix-map=«BUILDDIR»=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -Wl,-z,relro -lSDL -lGL -lGLU -lSDL_mixer -lbulletml
>   cc1d: warning: command line option '-Wformat=1' is valid for C/C++/ObjC/ObjC++ but not for D
>   cc1d: warning: command line option '-Wdate-time' is valid for C/C++/Fortran/ObjC/ObjC++ but not for D
>   /usr/bin/ld: /tmp/ccXshIOF.o: relocation R_X86_64_PC32 against symbol `_D3std6format18__T10FormatSpecTaZ10FormatSpec6flZeroMFNaNbNdNiNfbZv' can not be used when making a shared object; recompile with -fPIC
>   /usr/bin/ld: final link failed: Bad value
>   collect2: error: ld returned 1 exit status
>   Makefile:8: recipe for target 'torus-trooper' failed
>   make[2]: *** [torus-trooper] Error 1
>   make[2]: Leaving directory '«BUILDDIR»'
>   dh_auto_build: make -j1 DFLAGS=-frelease returned exit code 2
>   debian/rules:14: recipe for target 'override_dh_auto_build' failed
>   make[1]: *** [override_dh_auto_build] Error 2
>   make[1]: Leaving directory '«BUILDDIR»'
>   debian/rules:11: recipe for target 'build' failed
>   make: *** [build] Error 2
>...

Reproduced, and works when adding -no-pie.

The bug might be in the PIE handling for D:
gdc defaults to PIE, but libgphobos is non-PIE code?

cu
Adrian

-- 

       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed



More information about the Pkg-games-devel mailing list