|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r67768 - trunk/libs/program_options/src
From: ghost_at_[hidden]
Date: 2011-01-08 04:57:35
Author: vladimir_prus
Date: 2011-01-08 04:57:31 EST (Sat, 08 Jan 2011)
New Revision: 67768
URL: http://svn.boost.org/trac/boost/changeset/67768
Log:
Make program_options compile on iOS.
Patch from Alejandro Isaza.
Fixes #5053.
Text files modified:
trunk/libs/program_options/src/parsers.cpp | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
Modified: trunk/libs/program_options/src/parsers.cpp
==============================================================================
--- trunk/libs/program_options/src/parsers.cpp (original)
+++ trunk/libs/program_options/src/parsers.cpp 2011-01-08 04:57:31 EST (Sat, 08 Jan 2011)
@@ -45,7 +45,10 @@
// See: http://article.gmane.org/gmane.comp.lib.boost.devel/103843
// See: http://lists.gnu.org/archive/html/bug-guile/2004-01/msg00013.html
#if defined(__APPLE__) && defined(__DYNAMIC__)
-#include <crt_externs.h>
+// The proper include for this is crt_externs.h, however it's not
+// available on iOS. The right replacement is not known. See
+// https://svn.boost.org/trac/boost/ticket/5053
+extern "C" { extern char ***_NSGetEnviron(void); }
#define environ (*_NSGetEnviron())
#else
#if defined(__MWERKS__)
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk