Skip to content
This repository has been archived by the owner on Mar 7, 2019. It is now read-only.
This repository has been archived by the owner on Mar 7, 2019. It is now read-only.

Fails on FreeBSD 9.x #9

Closed
plicease opened this issue Jan 18, 2015 · 4 comments
Closed

Fails on FreeBSD 9.x #9

plicease opened this issue Jan 18, 2015 · 4 comments
Labels

Comments

@plicease
Copy link
Contributor

No description provided.

@plicease
Copy link
Contributor Author

t/00-use.t ....... ok
t/eud.t .......... ok
Use of uninitialized value $lib in concatenation (.) or string at t/static_link.t line 57.

#   Failed test 'linked '
#   at t/static_link.t line 57.
# cc -shared -L/usr/local/lib -fstack-protector -o t/static_link/main.so t/static_link/main.o -L_alien/dontpanic-1.0/src -L_alien/dontpanic-1.0/src/.libs -L-L/usr/home/eserte/.cpan/build/Acme-Alien-DontPanic-0.019-7QSasV/_alien/dontpanic-1.0/lib -ldontpanic
# /usr/bin/ld: _alien/dontpanic-1.0/src/libdontpanic.a(libdontpanic.o): relocation R_X86_64_32 against `a local symbol' can not be used when making a shared object; recompile with -fPIC
# _alien/dontpanic-1.0/src/libdontpanic.a: could not read symbols: Bad value
# Looks like you failed 1 test of 3.
t/static_link.t .. 
Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/3 subtests 

Test Summary Report
-------------------
t/static_link.t (Wstat: 256 Tests: 3 Failed: 1)
  Failed test:  3
  Non-zero exit status: 1
Files=3, Tests=6,  0 wallclock secs ( 0.04 usr  0.02 sys +  0.58 cusr  0.11 csys =  0.74 CPU)
Result: FAIL
Failed 1/3 test programs. 1/6 subtests failed.

@plicease plicease added the bug label Feb 27, 2015
@plicease
Copy link
Contributor Author

  • I am able to reproduce this on my FreeBSD 9.x VM --with-pic is being passed into configure and the configure script IS detecting the correct flags, but not apparently using them.
  • FreeBSD 10.x is not affected (big difference betwwen 9.x and 10.x is the latter uses clang instead of gcc as the default compiler)
  • I am able to install Alien::FFI and FFI::platypus on FreeBSD 9.x. So I suspect the problem lies in the dontpanic C package.

@plicease
Copy link
Contributor Author

Little more digging, and it looks like it is building two libdontpanic.a files. One which uses the correct -fPIC flag and the other that does not. Unfortunately the one that appears firs with -L is the one that doesn't have -fPIC. This is also the one that gets installed so even if I do install Acme::Alien::DontPanic, installing Acme::Ford::Prefect will fail with this same problem.

The relevant documentation for autoconf appears to be :

http://www.gnu.org/software/libtool/manual/html_node/LT_005fINIT.html

but is not helping me figure it out.

plicease added a commit that referenced this issue Feb 28, 2015
@plicease
Copy link
Contributor Author

Problem was due to the Makefile.am file in the src directory.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

1 participant