• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Using SystemConfiguration API inside KEXT
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Using SystemConfiguration API inside KEXT


  • Subject: Re: Using SystemConfiguration API inside KEXT
  • From: Jamison Hope <email@hidden>
  • Date: Tue, 11 May 2010 17:20:25 -0400

On May 11, 2010, at 4:36 PM, John B Brown wrote:

	As you say, a decidedly non-portable framework

	(SystemConfiguration)

even an Apple proprietary form, but the call as listed in the original note, <SystemConfiguration/SystemConfiguration.h>, looks like classic C language. Ie. look under the include tree.

I suggested there was no way that call could produce the header because the file did not exist as the include call described.

It got out of hand because the classic C language #include, according to my reading of the replies, apparently does not work in the Apple compile system. Or maybe it does. I looked at the referenced manual pages and still could not find anything to meet the original call.


Well actually, according to the C language spec:

"A preprocessing directive of the form
#include <h-char-sequence> new-line
searches a sequence of implementation-defined places for a header identified uniquely by
the specified sequence between the<and>delimiters, and causes the replacement of that
directive bythe entire contents of the header."
-- http://www.open-std.org/JTC1/SC22/WG14/www/docs/n1256.pdf


So, <SystemConfiguration/SystemConfiguration.h> just needs to uniquely identify a file. The spec doesn't say anything about slashes necessarily being interpreted as path directory delimiters.

GCC (and Clang) on Mac OS X does treat it as a relative path, and will find <sys/cdefs.h> at /usr/include/sys/cdefs.h, but it also knows how to find headers inside of frameworks, in which case <Foo/Bar.h> translates to Foo.framework/Headers/Bar.h. I'm not sure which takes precedence (i.e. what if there's also a /usr/include/Foo/Bar.h).

Anyway, the key phrase in the C specification is "implementation- defined". "#include <SystemConfiguration/SystemConfiguration.h>" *is* Standard C.

--
Jamison Hope
The PTR Group
www.theptrgroup.com



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Using SystemConfiguration API inside KEXT
      • From: John B Brown <email@hidden>
References: 
 >Using SystemConfiguration API inside KEXT (From: Andy Huang <email@hidden>)
 >Re: Using SystemConfiguration API inside KEXT (From: John B Brown <email@hidden>)
 >Re: Using SystemConfiguration API inside KEXT (From: Jean-Daniel Dupas <email@hidden>)
 >Re: Using SystemConfiguration API inside KEXT (From: John B Brown <email@hidden>)
 >Re: Using SystemConfiguration API inside KEXT (From: Jean-Daniel Dupas <email@hidden>)
 >Re: Using SystemConfiguration API inside KEXT (From: Uli Kusterer <email@hidden>)
 >Re: Using SystemConfiguration API inside KEXT (From: Jean-Daniel Dupas <email@hidden>)
 >Re: Using SystemConfiguration API inside KEXT (From: John B Brown <email@hidden>)
 >Re: Using SystemConfiguration API inside KEXT (From: Mo McRoberts <email@hidden>)
 >Re: Using SystemConfiguration API inside KEXT (From: David Leimbach <email@hidden>)
 >Re: Using SystemConfiguration API inside KEXT (From: John B Brown <email@hidden>)
 >Re: Using SystemConfiguration API inside KEXT (From: Jean-Daniel Dupas <email@hidden>)
 >Re: Using SystemConfiguration API inside KEXT (From: John B Brown <email@hidden>)
 >Re: Using SystemConfiguration API inside KEXT (From: Kevin Van Vechten <email@hidden>)
 >Re: Using SystemConfiguration API inside KEXT (From: John B Brown <email@hidden>)

  • Prev by Date: Re: Using SystemConfiguration API inside KEXT
  • Next by Date: Re: Using SystemConfiguration API inside KEXT
  • Previous by thread: Re: Using SystemConfiguration API inside KEXT
  • Next by thread: Re: Using SystemConfiguration API inside KEXT
  • Index(es):
    • Date
    • Thread