Mark Dootson wrote: Hi,
For info, in building PPMs for MacOSX on Snow Leopard, here are steps I had to take. A lot is ActivePerl specific but it ties in with other issues folks seem to be having. Firstly, for ActivePerl, I need to target OSX 10.4. Taken from the wxWidgets site, I exported the following values into ENV export CC=gcc-4.0 export CXX=g++-4.0 export LD=g++-4.0 This was not enough to get wxWidgets to build using Alien-wxWidgets, so to pass some extra arguments to configure I crudely patched Alien-wxWidgets with attached macosap.patch. (not intended for permanent use). Some of this is probably not required considering the args to Build.PL but the 10.4 SDK and min version settings, and CC, CXX and LD flags are. There isn't a way (yet) off passing extra configure flags to Alien-wxWidgets - which would be the way to incorporate this properly I would think. Then build patched Alien-wxWidgets with perl Build.PL --wxWidgets-build='yes' --wxWidgets-source='tar.gz' --wxWidgets-unicode=1 --wxWidgets-build-opengl=1 --wxWidgets-version=2.8.10 --wxWidgets-universal Next, building Wx fails because $Config{ccflags} and $Config{cppflags} both include '-nostdinc' which will cause the output from latest ExtUtils::XSpp to fail because the 'exception' header file cannot be found. ( as tracked down by Michael and Mattia in general 'wxPerl on Snow Leopard' thread). My solution to this was to install ExtUtils::FakeConfig, and then create my own config - attached Config_ap.pm Then I can build Wx with perl -MConfig_ap Makefile.PL I wonder if anyone has any thoughts on 1. Would it be desirable to have Alien-wxWidgets figure out matching SDK and min_version according to $Config{} values, further modified for OSX version vs wxWidgets version and 32bit vs 64bit
I'm not sure I understand. Apart from the special case for wxWidgets 2.9.0, is there any reason to _automatically_ set SDK/min version? or you mean that Build.PL should automatically set SDK/min version to the lowest possible value?
OR are the number of possibilities too great,so it would be better to have just the necessary cases for installed Perl on Mac and an an option for Build.PL of wxWidgets-extraflags that overrides wxwidgets_configure_extra_flags ( this would be useful beyond MacOSX )
Looks useful: could you add it?
OR something else I haven't thought of? 2. Using ExtUtils::FakeConfig was the simplest way I could think of of overcoming -nostdinc problem. Is there a better way? If not, I'll put together a patch for ExtUtils::FakeConfig to include a Config_mac? (suggestions for name appreciated) and include some way of figuring out if the cpp / cname etc settings are needed aswell as the ccflags / cppflags ones.
I do not see a better way. It's a pity that -nostding is both used by ActivePerl and suggested in the OS X Perl README.
Regards, Mattia