-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tests fail on macOS using SSL - need better paths in the .bundle #69
Comments
Anyone have ideas on this? I do not have a OSX system to test this out on. My internet investigation seems to reveal that disabling System Integrity Protection is not an option, as it requires a reboot, and the only option is to write a shell script that 1) gets run and thus stripped of LD_* and DYLD_* 2) Sets LD_LIBRARY_PATH itself and then 3) runs the actual program. I have no idea how to make all that magic happen via Makefile.PL however. Seems there must be some other solution, as stripping those ENVs seems so draconian it must be affecting lots of programs, not just little old DBD::Pg. |
You don't want to use |
@briandfoy is correct. You need to use |
Oh man, had I checked RT and seen that, I would have saved myself a couple days of frustrating work. Always check the bug queues! |
Update the README but unsure of what else to do. Give Makefile.PL a lot of brains so it detects the error and creates a wrapper shell script with the correct ENV vars that calls install_name_tool? |
I think the solution is to tweak the |
I had the exact problem. Updating the bundle files solved it! Thank you very much! |
This development seems relevant to this issue:
|
I've found the root of the problem, but I don't have a fix.
I installed DBD::Pg with
cpan
on v5.30.2 (perl -V at end) with the Postgres pre-built package for macOS. I had setPOSTGRES_LIB
:The compilation works fine, but the tests fail because it cannot load the libraries:
This is a known problem with macOS's System Integrity Protection, which unsets
DYLD_*
andLD_*
.Looking at the .bundle file produced, I see that the Pg libraries are names only (not paths or rpaths):
I updated the bundle to have absolute paths:
Now the tests work and everyone is happy.
It took me awhile to get to this point, so I haven't even begun to look at the DBD::Pg sources to see where a fix might go in. I'm also hoping someone already knows how to fix this quickly. :)
System details
The text was updated successfully, but these errors were encountered: