Make Macports compile Boost for iOS as well as OS X
I have used Macports to install Boost on my Mac. So far I've been using the header-only parts of Boost for my iOS project and everything was fine.
Now I need to u开发者_Go百科se one of the compiled libraries. I would like to keep using Macports to keep Boost up to date.
Is there a way to tell the port
command to compile the libraries for multiple platforms when installing/upgrading?
For the record, I have used sudo port install boost
to install Boost and I'm at 1.47 now. Using OS X Lion and the SVN version of Macports.
As far as I'm aware MacPorts does not currently have a "platform armv6" or "platform armv7" command so you're out of luck on that front. The +universal flag might help with the simulator but obviously won't compile for the handsets.
aleph7 suggests creating an XCode project (read his source) as the Boost build system does not fully support the iOS framework.
MacPorts stores source packages in /opt/local/var/macports/distfiles
so you can get-a-symlinking rather than downloading the source as per his instructions.
If you'd prefer a Boost framework for iOS rather than an XCode project, check out Peter Goodliffe's instructions.
精彩评论