View Single Post
Old December 20, 2016, 20:19   #3
takkaria's Avatar
Join Date: Apr 2007
Posts: 1,859
Donated: $40
takkaria is on a distinguished road
Originally Posted by spara View Post
I upgraded my system to Debian Testing and Angband won't compile anymore. The error I'm getting after make is this. Any idea what's causing it?

/usr/bin/ld: -r and -pie may not be used together
collect2: error: ld returned 1 exit status
Makefile:34: recipe for target 'angband.o' failed
make[3]: *** [angband.o] Error 1
../mk/ recipe for target 'all' failed
make[2]: *** [all] Error 2
mk/ recipe for target 'subdirs' failed
make[1]: *** [subdirs] Error 2
mk/ recipe for target 'all' failed
make: *** [all] Error 2
Open 'Makefile' in src/. Edit the bit that says:

    $(LD) -nostdlib -Wl,-r -o $@ $(OBJECTS)
    @printf "%10s %-20s\n" LINK $@
Add '-no-pie' to this line:

    $(LD) -nostdlib -no-pie -Wl,-r -o $@ $(OBJECTS)
Hopefully that will work.
"Physician, heal thyself."
takkaria is offline   Reply With Quote