diff options
author | Oswald Buddenhagen <oswald.buddenhagen@nokia.com> | 2011-05-02 07:38:40 (GMT) |
---|---|---|
committer | Oswald Buddenhagen <oswald.buddenhagen@nokia.com> | 2011-05-02 07:38:40 (GMT) |
commit | aae6ef391d2ee2fa5b91c834ea65f14fd61e5af6 (patch) | |
tree | 6ddb50540cb3277ecbc6bd694e4bddb62e43d57f /src/corelib/io | |
parent | e4de914405880c90298eae1115d39618384758e4 (diff) | |
download | Qt-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.cpp | 12 |
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; |