darwin-c.c (handle_c_option): Handle -fapple-kext here so we can...
authorMike Stump <mrs@apple.com>
Fri, 13 Apr 2007 17:29:27 +0000 (17:29 +0000)
committerMike Stump <mrs@gcc.gnu.org>
Fri, 13 Apr 2007 17:29:27 +0000 (17:29 +0000)
* config/darwin-c.c (handle_c_option): Handle -fapple-kext here so
we can...
* config/darwin.opt (fapple-kext): Make C++ only.
* config/darwin.c (darwin_override_options): Remove code to ensure
-fapple-kext is given for C++ only.

From-SVN: r123792

gcc/ChangeLog
gcc/config/darwin-c.c
gcc/config/darwin.c
gcc/config/darwin.opt

index 60be46405c317c346d92701650585cbb280b02dc..1c32a95fbb361e980783a23db5239c74b3049689 100644 (file)
@@ -1,3 +1,11 @@
+2007-04-13  Mike Stump  <mrs@apple.com>
+
+       * config/darwin-c.c (handle_c_option): Handle -fapple-kext here so
+       we can...
+       * config/darwin.opt (fapple-kext): Make C++ only.
+       * config/darwin.c (darwin_override_options): Remove code to ensure
+       -fapple-kext is given for C++ only.
+
 2007-04-13  Richard Sandiford  <richard@codesourcery.com>
 
        * config/mips/vxworks.h (SUBTARGET_OVERRIDE_OPTIONS): Define.
index dc03a9d96be4d7a36665868e4bf6215da24990ab..0b3e8200f72c851d06a2a8513a1b99d7c352983f 100644 (file)
@@ -635,6 +635,9 @@ handle_c_option (size_t code,
     case OPT_iframework:
       add_system_framework_path (xstrdup (arg));
       break;
+
+    case OPT_fapple_kext:
+      ;
     }
 
   /* We recognized the option.  */
index 507b1b47a3f149b674aad4d5ab390f6f8ac7f22e..73836ae08b06e4e3ffb530d9c6d5a6ab293119b4 100644 (file)
@@ -1708,11 +1708,6 @@ darwin_kextabi_p (void) {
 void
 darwin_override_options (void)
 {
-  if (flag_apple_kext && strcmp (lang_hooks.name, "GNU C++") != 0)
-    {
-      warning (0, "command line option %<-fapple-kext%> is only valid for C++");
-      flag_apple_kext = 0;
-    }
   if (flag_mkernel || flag_apple_kext)
     {
       /* -mkernel implies -fapple-kext for C++ */
index b27b3db75caac5cee03358719122ff82475c5573..0ffc72e754a50716359791af6eb45704296c7d71 100644 (file)
@@ -36,7 +36,7 @@ Target RejectNegative Report Var(darwin_one_byte_bool)
 Set sizeof(bool) to 1
 
 fapple-kext
-Target Report Var(flag_apple_kext)
+Target Report C++ Var(flag_apple_kext)
 Generate code for darwin loadable kernel extensions
 
 mkernel