While trying your suggestion, I may have stumbled on the cause of my problem. I modified the .pm file as you suggested, and ran my test file. The library paths were printed as you'd expect, but the library still did not load. I wanted to be sure the library was actually where I specified, so I cd'd to that folder and did a directory listing. Then I ran the test file again, and the library loaded!!
WBBirkett-M:perl5 wbirkett$ cd ~/ WBBirkett-M:~ wbirkett$ perl -I/Users/wbirkett/Library/Application\ Su +pport/TextMate/Pristine\ Copy/Bundles/PressCal.tmbundle/Support/lib/p +erl5 /Users/wbirkett/Desktop/Rmath_test.pl XXX=/usr/lib XXX=/usr/local/lib XXX=/Users/wbirkett/Library/Application Support/TextMate/Pristine Copy +/Bundles/PressCal.tmbundle/Support/lib/perl5 Can't load '/Users/wbirkett/Library/Application Support/TextMate/Prist +ine Copy/Bundles/PressCal.tmbundle/Support/lib/perl5/darwin-thread-mu +lti-2level/auto/ICC/Support/Rmath/Rmath.bundle' for module ICC::Suppo +rt::Rmath: dlopen(/Users/wbirkett/Library/Application Support/TextMat +e/Pristine Copy/Bundles/PressCal.tmbundle/Support/lib/perl5/darwin-th +read-multi-2level/auto/ICC/Support/Rmath/Rmath.bundle, 1): Library no +t loaded: libRmath.dylib Referenced from: /Users/wbirkett/Library/Application Support/TextMat +e/Pristine Copy/Bundles/PressCal.tmbundle/Support/lib/perl5/darwin-th +read-multi-2level/auto/ICC/Support/Rmath/Rmath.bundle Reason: image not found at /System/Library/Perl/5.18/darwin-thread-m +ulti-2level/DynaLoader.pm line 194. at /Users/wbirkett/Desktop/Rmath_test.pl line 1. Compilation failed in require at /Users/wbirkett/Desktop/Rmath_test.pl + line 1. BEGIN failed--compilation aborted at /Users/wbirkett/Desktop/Rmath_tes +t.pl line 1. WBBirkett-M:~ wbirkett$ cd /Users/wbirkett/Library/Application\ Suppor +t/TextMate/Pristine\ Copy/Bundles/PressCal.tmbundle/Support/lib/perl5 WBBirkett-M:perl5 wbirkett$ perl -I/Users/wbirkett/Library/Application +\ Support/TextMate/Pristine\ Copy/Bundles/PressCal.tmbundle/Support/l +ib/perl5 /Users/wbirkett/Desktop/Rmath_test.pl XXX=/usr/lib XXX=/usr/local/lib XXX=/Users/wbirkett/Library/Application Support/TextMate/Pristine Copy +/Bundles/PressCal.tmbundle/Support/lib/perl5 OK
So, the failure to load the library is somehow connected to the current directory in the Terminal app. I don't know why that would matter, but it looks this is a macOS problem, not a Perl problem.
Thank you again for your help.
In reply to Re^4: XSLoader/DynaLoader Can't Locate Library
by wbirkett
in thread XSLoader/DynaLoader Can't Locate Library
by wbirkett
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |