When I go to make this module I get the following relative rpath error on the ‘make test’. Running Perl 5.18, DBD::Pg 3.5.1 (cpan version). libpq.5.dylib is in /Library/PostgreSQL/9.4/lib.
GINITDB="/Library/PostgreSQL/9.4/bin/initdb" PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t t/00_signature.t .... skipped: Set the environment variable TEST_SIGNATURE to enable this test t/00basic.t ......... 1/3 # Failed test 'use DBD::Pg;' # at t/00basic.t line 17. # Tried to use 'DBD::Pg'. # Error: Can't load '/Users/mydir/Perl_Modules/DBD-Pg-3.5.1/blib/arch/auto/DBD/Pg/Pg.bundle' for module DBD::Pg: dlopen(/Users/mydir/Perl_Modules/DBD-Pg-3.5.1/blib/arch/auto/DBD/Pg/Pg.bundle, 2): Library not loaded: libpq.5.dylib # Referenced from: /Users/mydir/Perl_Modules/DBD-Pg-3.5.1/blib/arch/auto/DBD/Pg/Pg.bundle # Reason: unsafe use of relative rpath libpq.5.dylib in /Users/mydir/Perl_Modules/DBD-Pg-3.5.1/blib/arch/auto/DBD/Pg/Pg.bundle with restricted binary at /System/Library/Perl/5.18/darwin-thread-multi-2level/DynaLoader.pm line 194. # at (eval 8) line 2. # Compilation failed in require at (eval 8) line 2. # BEGIN failed--compilation aborted at (eval 8) line 2. # CCFLAGS: q[-arch i386 -arch x86_64 -g -pipe -fno-common -DPERL_DARWIN -fno-strict-aliasing -fstack-protector -DPGLIBVERSION=90400 -DPGDEFPORT=5432] # INC: q[-I/Library/PostgreSQL/9.4/include -I/System/Library/Perl/Extras/5.18/darwin-thread-multi-2level/auto/DBI] # LIBS: [q[-L/Library/PostgreSQL/9.4/lib -lpq -lm]] Bailout called. Further testing stopped: Cannot continue without DBD::Pg FAILED--Further testing stopped: Cannot continue without DBD::Pg make: *** [test_dynamic] Error 255 Thanks, -Adam Wizon
