Reviewers: Sven Panne, Jakob,

Message:
As discussed with Jakob offline yesterday, we can't get GYP to properly set
these defines for everything without duplicating the OS detection in
features.gypi or toolchain.gypi and v8.gyp.
So I'll add a build_config.h similar to Chromium.

Description:
Revert "Add (mostly Chromium-compatible) V8_OS_* defines to v8.gyp."

This reverts commit r16238 for not being able to use the defines
outside of libv8 (i.e. in tests). Will reland the #define's in a
build config header style.

Please review this at https://codereview.chromium.org/22861022/

SVN Base: https://v8.googlecode.com/svn/branches/bleeding_edge

Affected files:
  M tools/gyp/v8.gyp


Index: tools/gyp/v8.gyp
diff --git a/tools/gyp/v8.gyp b/tools/gyp/v8.gyp
index a7e89db682b73570f221b4664c29cfb6eec205a5..eccd7d263b40c58f569bd4c3aaa5e229746a3d60 100644
--- a/tools/gyp/v8.gyp
+++ b/tools/gyp/v8.gyp
@@ -689,10 +689,6 @@
                 }],
               ],
             },
-            'defines': [
-              'V8_OS_LINUX=1',
-              'V8_OS_POSIX=1'
-            ],
             'sources': [  ### gcmole(os:linux) ###
               '../../src/platform-linux.cc',
               '../../src/platform-posix.cc'
@@ -710,29 +706,16 @@
               ['host_os=="mac"', {
                 'target_conditions': [
                   ['_toolset=="host"', {
-                    'defines': [
-                      'V8_OS_BSD=1',
-                      'V8_OS_MACOSX=1',
-                      'V8_OS_POSIX=1'
-                    ],
                     'sources': [
                       '../../src/platform-macos.cc'
                     ]
                   }, {
-                    'defines': [
-                      'V8_OS_LINUX=1',
-                      'V8_OS_POSIX=1'
-                    ],
                     'sources': [
                       '../../src/platform-linux.cc'
                     ]
                   }],
                 ],
               }, {
-                'defines': [
-                  'V8_OS_LINUX=1',
-                  'V8_OS_POSIX=1'
-                ],
                 'sources': [
                   '../../src/platform-linux.cc'
                 ]
@@ -741,11 +724,6 @@
           },
         ],
         ['OS=="freebsd"', {
-            'defines': [
-              'V8_OS_BSD=1',
-              'V8_OS_FREEBSD=1',
-              'V8_OS_POSIX=1'
-            ],
             'link_settings': {
               'libraries': [
                 '-L/usr/local/lib -lexecinfo',
@@ -757,11 +735,6 @@
           }
         ],
         ['OS=="openbsd"', {
-            'defines': [
-              'V8_OS_BSD=1',
-              'V8_OS_OPENBSD=1',
-              'V8_OS_POSIX=1'
-            ],
             'link_settings': {
               'libraries': [
                 '-L/usr/local/lib -lexecinfo',
@@ -773,11 +746,6 @@
           }
         ],
         ['OS=="netbsd"', {
-            'defines': [
-              'V8_OS_BSD=1',
-              'V8_OS_NETBSD=1',
-              'V8_OS_POSIX=1'
-            ],
             'link_settings': {
               'libraries': [
                 '-L/usr/pkg/lib -Wl,-R/usr/pkg/lib -lexecinfo',
@@ -789,10 +757,6 @@
           }
         ],
         ['OS=="solaris"', {
-            'defines': [
-              'V8_OS_POSIX=1',
-              'V8_OS_SOLARIS=1'
-            ],
             'link_settings': {
               'libraries': [
                 '-lsocket -lnsl',
@@ -804,11 +768,6 @@
           }
         ],
         ['OS=="mac"', {
-          'defines': [
-            'V8_OS_BSD=1',
-            'V8_OS_MACOSX=1',
-            'V8_OS_POSIX=1'
-          ],
           'sources': [
             '../../src/platform-macos.cc',
             '../../src/platform-posix.cc'
@@ -825,18 +784,11 @@
               },
               'conditions': [
                 ['build_env=="Cygwin"', {
-                  'defines': [
-                    'V8_OS_CYGWIN=1',
-                    'V8_OS_POSIX=1'
-                  ],
                   'sources': [
                     '../../src/platform-cygwin.cc',
                     '../../src/platform-posix.cc',
                   ],
                 }, {
-                  'defines': [
-                    'V8_OS_WIN=1'
-                  ],
                   'sources': [
                     '../../src/platform-win32.cc',
                     '../../src/win32-math.h',
@@ -848,9 +800,6 @@
                 'libraries': [ '-lwinmm', '-lws2_32' ],
               },
             }, {
-              'defines': [
-                'V8_OS_WIN=1'
-              ],
               'sources': [
                 '../../src/platform-win32.cc',
                 '../../src/win32-math.h',


--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to