all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Mario Lassnig <mario.lassnig@cern.ch>
To: <emacs-devel@gnu.org>
Subject: Re: OSX breakage
Date: Mon, 28 Nov 2011 19:35:09 +0100	[thread overview]
Message-ID: <4ED3D45D.20206@cern.ch> (raw)

[-- Attachment #1: Type: text/plain, Size: 1056 bytes --]

>>/  Date: Mon, 28 Nov 2011 16:36:25 +0100/
>>/  From: Mario Lassnig<address@hidden>/
>>/  /
>>/  The remedy (to include at the appropriate time and place):/
>>/  /
>>/  #include<crt_externs.h>/
>>/  #define environ (*_NSGetEnviron())/

>Is there really no system header on OS X that declares `environ'?  I'm
>surprised.

That's correct. And even system headers do it like this, probably
there's some magic in the background to work with ns-dragndrop and the likes.

Mario@shodan:/usr/include$ grep -r " environ " *
X11/Xw32defs.h:#  define environ     _environ
apache2/modperl_perl_includes.h:#   define environ (*_NSGetEnviron())
architecture/i386/fpu.h: *     #define environ (*_NSGetEnviron())

>If there really isn't, and we need to use #ifdef, I'm inclined to use
>"extern char **environ;".  What would be a MAC OS X specific symbol to
>use with such an ifdef?

That would be

#ifdef __APPLE__


Thanks,
Mario

-- 
Mario Lassnig
CERN PH-ADP-DDM 1-R-022
CH-1211 Geneve 23
mario.lassnig@cern.ch
+41 22 76 71268



[-- Attachment #2: S/MIME Cryptographic Signature --]
[-- Type: application/pkcs7-signature, Size: 4394 bytes --]

             reply	other threads:[~2011-11-28 18:35 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-28 18:35 Mario Lassnig [this message]
  -- strict thread matches above, loose matches on Subject: below --
2011-11-28 15:36 OSX breakage Mario Lassnig
2011-11-28 16:48 ` Paul Eggert
2011-11-28 17:47 ` Eli Zaretskii
2011-11-28 19:00   ` Paul Eggert
2011-11-29  5:00     ` Chong Yidong
2011-11-29  9:27       ` Paul Eggert
2011-11-28 19:29   ` Randal L. Schwartz
2011-11-29 11:45 ` Ashish SHUKLA
2011-11-30 12:08   ` Carsten Mattner
2011-11-30 15:00   ` Ashish SHUKLA

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4ED3D45D.20206@cern.ch \
    --to=mario.lassnig@cern.ch \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.