summaryrefslogtreecommitdiffstats
path: root/src/corelib/io
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@nokia.com>2011-05-02 07:38:40 (GMT)
committerOswald Buddenhagen <oswald.buddenhagen@nokia.com>2011-05-02 07:38:40 (GMT)
commitaae6ef391d2ee2fa5b91c834ea65f14fd61e5af6 (patch)
tree6ddb50540cb3277ecbc6bd694e4bddb62e43d57f /src/corelib/io
parente4de914405880c90298eae1115d39618384758e4 (diff)
downloadQt-aae6ef391d2ee2fa5b91c834ea65f14fd61e5af6.zip
Qt-aae6ef391d2ee2fa5b91c834ea65f14fd61e5af6.tar.gz
Qt-aae6ef391d2ee2fa5b91c834ea65f14fd61e5af6.tar.bz2
fix build on mac
environ needs to be declared properly
Diffstat (limited to 'src/corelib/io')
-rw-r--r--src/corelib/io/qprocess_unix.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/corelib/io/qprocess_unix.cpp b/src/corelib/io/qprocess_unix.cpp
index 47f3e69..a3c589f 100644
--- a/src/corelib/io/qprocess_unix.cpp
+++ b/src/corelib/io/qprocess_unix.cpp
@@ -453,6 +453,18 @@ bool QProcessPrivate::createChannel(Channel &channel)
}
}
+QT_BEGIN_INCLUDE_NAMESPACE
+#if defined(Q_OS_MAC) && !defined(QT_NO_CORESERVICES)
+# include <crt_externs.h>
+# define environ (*_NSGetEnviron())
+#elif defined(Q_OS_SYMBIAN) || (defined(Q_OS_MAC) && defined(QT_NO_CORESERVICES))
+ static char *qt_empty_environ[] = { 0 };
+#define environ qt_empty_environ
+#else
+ extern char **environ;
+#endif
+QT_END_INCLUDE_NAMESPACE
+
QProcessEnvironment QProcessEnvironment::systemEnvironment()
{
QProcessEnvironment env;