localshop has asked for the wisdom of the Perl Monks concerning the following question:
Trying to use the system Perl on a new Mac Mojave I had some difficulty getting a XML::LibXML module installed from CPAN module but eventually got it working about a week ago. I remember using brew to install the LIBXML2 libs and fiddling with the paths in a few different ways as well as running a few xcode commands to ensure everything at that end was ok.
Step forward a couple of weeks and I come into the same error when trying to install URL::Encode::XS and figured that I should remember enough to get it build but a few hours later I'm still bumbling about.
I'm guessing that one solution is to use a perlbrew Perl build which should help get around the hard access limits to some of the restricted mac directories ( eg /usr/bin etc ) and I kicked things off down this path but I would still like to understand more about why XS modules are so problematic on MacOSX and have some idea of what is required to work around the system constraints.
Secondly, I'd like to be more confident about the best environment for Perl development on a Mac - do most people step away from the system Perl and use Perlbrew or is there an approach or bunch of knowledge that will allow me to work with system Perl and still be able to build modules with Library dependencies?
NB - Cross post in Stack Overflow Answer
To summarise my findings based on responses here etc the best practice would seem to be:
- Don't use the System Perl on Mac OSX if you require any modules
- do a brew install perl
- then do brew install cpanminus
- then install perlbrew to allow multiple perl setups
If I've missed anything in my findings update let me know so that I can refer ppl here with more confidence.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: MAC Perl EXTERN.H Make Issues
by Corion (Patriarch) on Oct 26, 2018 at 07:28 UTC | |
Re: MAC Perl EXTERN.H Make Issues
by 1nickt (Canon) on Oct 26, 2018 at 12:42 UTC | |
Re: MAC Perl EXTERN.H Make Issues
by tangent (Parson) on Oct 26, 2018 at 14:30 UTC | |
Re: MAC Perl EXTERN.H Make Issues
by Your Mother (Archbishop) on Oct 26, 2018 at 18:32 UTC | |
by localshop (Monk) on Oct 26, 2018 at 19:50 UTC | |
by stevieb (Canon) on Oct 26, 2018 at 20:04 UTC | |
by Your Mother (Archbishop) on Oct 26, 2018 at 20:26 UTC | |
by Anonymous Monk on Oct 26, 2018 at 22:04 UTC | |
by Your Mother (Archbishop) on Oct 26, 2018 at 22:26 UTC |