Commit 392492c0 authored by Matthias Clasen's avatar Matthias Clasen Committed by Matthias Clasen

Check for crt_extern.h and _NSGetEnviron. Fix compilation on Darwin where

2006-12-10  Matthias Clasen  <mclasen@redhat.com>

        * configure.in: Check for crt_extern.h and _NSGetEnviron.
        * gdk/x11/gdkspawn-x11.c: Fix compilation on Darwin where
        environ is not available.  (#384168, Min Sik Kim)
parent b8756357
2006-12-10 Matthias Clasen <mclasen@redhat.com>
* configure.in: Check for crt_extern.h and _NSGetEnviron.
* gdk/x11/gdkspawn-x11.c: Fix compilation on Darwin where
environ is not available. (#384168, Min Sik Kim)
2006-12-07 Paolo Maggi <paolo@gnome.org>
Fixes bug #383407
......
......@@ -728,6 +728,10 @@ else
pixbuf_libtool_config="${CONFIG_SHELL-/bin/sh} ./libtool --config"
pixbuf_deplibs_check=`$pixbuf_libtool_config | \
grep '^[[a-z_]]*check[[a-z_]]*_method=[['\''"]]' | \
# Checks for gdkspawn
AC_CHECK_HEADERS(crt_externs.h)
AC_CHECK_FUNCS(_NSGetEnviron)
sed 's/.*[['\''"]]\(.*\)[['\''"]]$/\1/'`
if test "x$pixbuf_deplibs_check" = "xnone" || \
test "x$pixbuf_deplibs_check" = "xunknown" || \
......
......@@ -22,13 +22,25 @@
#include <config.h>
#include <string.h>
#ifdef HAVE_CRT_EXTERNS_H
#include <crt_externs.h> /* for _NSGetEnviron */
#endif
#include "gdkspawn.h"
#include <glib.h>
#include <gdk/gdk.h>
#include "gdkalias.h"
#ifdef HAVE__NSGETENVIRON
#define environ (*_NSGetEnviron())
#else
/* According to the Single Unix Specification, environ is not in
* any system header, although unistd.h often declares it.
*/
extern char **environ;
#endif
/**
* gdk_make_spawn_environment_for_screen:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment