diff options
author | Geoff Lang <geofflang@chromium.org> | 2014-01-10 13:04:48 -0500 |
---|---|---|
committer | Geoff Lang <geofflang@chromium.org> | 2014-01-10 21:36:20 +0000 |
commit | 3cd50f7e244aedcdec43b3fd1425fef48cb84de8 (patch) | |
tree | 2a79aa2134440007c8452ae202ae0063021c9f92 /build | |
parent | 91382e555f35727043b6011e7f01fb2c74950fdb (diff) | |
download | angle-3cd50f7e244aedcdec43b3fd1425fef48cb84de8.tar.gz |
Fix remaining discrepencies between master and es3proto project files.
Change-Id: I335c9346ac268beab25184e2b18ccfdd0b15c7b1
Reviewed-on: https://chromium-review.googlesource.com/182150
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Tested-by: Geoff Lang <geofflang@chromium.org>
Diffstat (limited to 'build')
-rw-r--r-- | build/all.gyp | 46 | ||||
-rw-r--r-- | build/common.gypi | 538 | ||||
-rw-r--r-- | build/gyp_angle | 31 |
3 files changed, 332 insertions, 283 deletions
diff --git a/build/all.gyp b/build/all.gyp index 724ab4f0..735fbeac 100644 --- a/build/all.gyp +++ b/build/all.gyp @@ -3,31 +3,23 @@ # found in the LICENSE file. { - 'targets': [ - { - 'target_name': 'All', - 'type': 'none', - 'dependencies': [ - '../src/angle.gyp:*', - ], - 'conditions': [ - ['angle_build_samples==1', { - 'dependencies': [ - '../samples/samples.gyp:*', - ], - }], - ['angle_build_tests==1', { - 'dependencies': [ - '../tests/tests.gyp:*', - ], - }], - ], - }, - ], + 'targets': + [ + { + 'target_name': 'All', + 'type': 'none', + 'dependencies': [ '../src/angle.gyp:*', ], + 'conditions': + [ + ['angle_build_samples==1', + { + 'dependencies': [ '../samples/samples.gyp:*', ], + }], + ['angle_build_tests==1', + { + 'dependencies': [ '../tests/tests.gyp:*', ], + }], + ], + }, + ], } - -# Local Variables: -# tab-width:2 -# indent-tabs-mode:nil -# End: -# vim: set expandtab tabstop=2 shiftwidth=2: diff --git a/build/common.gypi b/build/common.gypi index 07eb4a1e..4047f066 100644 --- a/build/common.gypi +++ b/build/common.gypi @@ -3,255 +3,313 @@ # found in the LICENSE file. { - 'variables': { - 'component%': 'static_library', - 'angle_build_tests%': '1', - 'angle_build_samples%': '1', - # angle_code is set to 1 for the core ANGLE targets defined in src/build_angle.gyp. - # angle_code is set to 0 for test code, sample code, and third party code. - # When angle_code is 1, we build with additional warning flags on Mac and Linux. - 'angle_code%': 0, - 'windows_sdk_path%': 'C:/Program Files (x86)/Windows Kits/8.0', - 'gcc_or_clang_warnings': [ - '-Wall', - '-Wchar-subscripts', - '-Werror', - '-Wextra', - '-Wformat=2', - '-Winit-self', - '-Wno-sign-compare', - '-Wno-unused-function', - '-Wno-unused-parameter', - '-Wno-unknown-pragmas', - '-Wpacked', - '-Wpointer-arith', - '-Wundef', - '-Wwrite-strings', - ], - }, - 'target_defaults': { - 'default_configuration': 'Debug', - 'variables': { - 'warn_as_error%': 1, + 'variables': + { + 'component%': 'static_library', + 'angle_build_tests%': '1', + 'angle_build_samples%': '1', + # angle_code is set to 1 for the core ANGLE targets defined in src/build_angle.gyp. + # angle_code is set to 0 for test code, sample code, and third party code. + # When angle_code is 1, we build with additional warning flags on Mac and Linux. + 'angle_code%': 0, + 'windows_sdk_path%': 'C:/Program Files (x86)/Windows Kits/8.0', + 'gcc_or_clang_warnings': + [ + '-Wall', + '-Wchar-subscripts', + '-Werror', + '-Wextra', + '-Wformat=2', + '-Winit-self', + '-Wno-sign-compare', + '-Wno-unused-function', + '-Wno-unused-parameter', + '-Wno-unknown-pragmas', + '-Wpacked', + '-Wpointer-arith', + '-Wundef', + '-Wwrite-strings', + ], }, - 'target_conditions': [ - ['warn_as_error == 1', { - 'msvs_settings': { - 'VCCLCompilerTool': { - 'WarnAsError': 'true', - }, - }, - }], - ], - 'configurations': { - 'Common_Base': { - 'abstract': 1, - 'msvs_configuration_attributes': { - 'OutputDirectory': '$(SolutionDir)$(ConfigurationName)_$(Platform)', - 'IntermediateDirectory': '$(OutDir)\\obj\\$(ProjectName)', - 'CharacterSet': '1', # UNICODE + 'target_defaults': + { + 'default_configuration': 'Debug', + 'variables': + { + 'warn_as_error%': 1, }, - 'msvs_settings': { - 'VCCLCompilerTool': { - 'AdditionalOptions': ['/MP'], - 'BufferSecurityCheck': 'true', - 'DebugInformationFormat': '3', - # TODO(alokp): Disable exceptions before integrating with chromium. - #'ExceptionHandling': '0', - 'EnableFunctionLevelLinking': 'true', - 'MinimalRebuild': 'false', - 'PreprocessorDefinitions': [ - '_CRT_SECURE_NO_DEPRECATE', - '_SCL_SECURE_NO_WARNINGS', - '_HAS_EXCEPTIONS=0', - '_WIN32_WINNT=0x0600', - '_WINDOWS', - 'NOMINMAX', - 'WIN32', - 'WIN32_LEAN_AND_MEAN', - 'WINVER=0x0600', - ], - 'RuntimeTypeInfo': 'false', - 'WarningLevel': '4', - }, - 'VCLinkerTool': { - 'FixedBaseAddress': '1', - 'GenerateDebugInformation': 'true', - 'ImportLibrary': '$(OutDir)\\lib\\$(TargetName).lib', - 'MapFileName': '$(OutDir)\\$(TargetName).map', - # Most of the executables we'll ever create are tests - # and utilities with console output. - 'SubSystem': '1', # /SUBSYSTEM:CONSOLE - 'AdditionalDependencies': [ - 'kernel32.lib', - 'gdi32.lib', - 'winspool.lib', - 'comdlg32.lib', - 'advapi32.lib', - 'shell32.lib', - 'ole32.lib', - 'oleaut32.lib', - 'user32.lib', - 'uuid.lib', - 'odbc32.lib', - 'odbccp32.lib', - 'delayimp.lib', - ], - }, - 'VCResourceCompilerTool': { - 'Culture': '1033', - }, - }, - 'msvs_disabled_warnings': [4100, 4127, 4189, 4239, 4244, 4245, 4512, 4702, 4530, 4718], - 'msvs_system_include_dirs': [ - '<(windows_sdk_path)/Include/shared', - '<(windows_sdk_path)/Include/um', + 'target_conditions': + [ + ['warn_as_error == 1', + { + 'msvs_settings': + { + 'VCCLCompilerTool': + { + 'WarnAsError': 'true', + }, + }, + }], ], - }, # Common_Base + 'configurations': + { + 'Common_Base': + { + 'abstract': 1, + 'msvs_configuration_attributes': + { + 'OutputDirectory': '$(SolutionDir)$(ConfigurationName)_$(Platform)', + 'IntermediateDirectory': '$(OutDir)\\obj\\$(ProjectName)', + 'CharacterSet': '1', # UNICODE + }, + 'msvs_settings': + { + 'VCCLCompilerTool': + { + 'AdditionalOptions': ['/MP'], + 'BufferSecurityCheck': 'true', + 'DebugInformationFormat': '3', + # TODO(alokp): Disable exceptions before integrating with chromium. + #'ExceptionHandling': '0', + 'EnableFunctionLevelLinking': 'true', + 'MinimalRebuild': 'false', + 'PreprocessorDefinitions': + [ + '_CRT_SECURE_NO_DEPRECATE', + '_SCL_SECURE_NO_WARNINGS', + '_HAS_EXCEPTIONS=0', + '_WIN32_WINNT=0x0600', + '_WINDOWS', + 'NOMINMAX', + 'WIN32', + 'WIN32_LEAN_AND_MEAN', + 'WINVER=0x0600', + ], + 'RuntimeTypeInfo': 'false', + 'WarningLevel': '4', + }, + 'VCLinkerTool': + { + 'FixedBaseAddress': '1', + 'GenerateDebugInformation': 'true', + 'ImportLibrary': '$(OutDir)\\lib\\$(TargetName).lib', + 'MapFileName': '$(OutDir)\\$(TargetName).map', + # Most of the executables we'll ever create are tests + # and utilities with console output. + 'SubSystem': '1', # /SUBSYSTEM:CONSOLE + 'AdditionalDependencies': + [ + 'kernel32.lib', + 'gdi32.lib', + 'winspool.lib', + 'comdlg32.lib', + 'advapi32.lib', + 'shell32.lib', + 'ole32.lib', + 'oleaut32.lib', + 'user32.lib', + 'uuid.lib', + 'odbc32.lib', + 'odbccp32.lib', + 'delayimp.lib', + ], + }, + 'VCResourceCompilerTool': + { + 'Culture': '1033', + }, + }, + 'msvs_disabled_warnings': [ 4100, 4127, 4189, 4239, 4244, 4245, 4512, 4702, 4530, 4718 ], + 'msvs_system_include_dirs': + [ + '<(windows_sdk_path)/Include/shared', + '<(windows_sdk_path)/Include/um', + ], + }, # Common_Base - 'Debug_Base': { - 'abstract': 1, - 'msvs_settings': { - 'VCCLCompilerTool': { - 'Optimization': '0', # /Od - 'PreprocessorDefinitions': ['_DEBUG'], - 'BasicRuntimeChecks': '3', - 'RuntimeLibrary': '1', # /MTd (debug static) - }, - 'VCLinkerTool': { - 'LinkIncremental': '2', - }, - }, - 'xcode_settings': { - 'COPY_PHASE_STRIP': 'NO', - 'GCC_OPTIMIZATION_LEVEL': '0', - }, - }, # Debug_Base + 'Debug_Base': + { + 'abstract': 1, + 'msvs_settings': + { + 'VCCLCompilerTool': + { + 'Optimization': '0', # /Od + 'PreprocessorDefinitions': [ '_DEBUG' ], + 'BasicRuntimeChecks': '3', + 'RuntimeLibrary': '1', # /MTd (debug static) + }, + 'VCLinkerTool': + { + 'LinkIncremental': '2', + }, + }, + 'xcode_settings': + { + 'COPY_PHASE_STRIP': 'NO', + 'GCC_OPTIMIZATION_LEVEL': '0', + }, + }, # Debug_Base - 'Release_Base': { - 'abstract': 1, - 'msvs_settings': { - 'VCCLCompilerTool': { - 'Optimization': '2', # /Os - 'PreprocessorDefinitions': ['NDEBUG'], - 'RuntimeLibrary': '0', # /MT (static) - }, - 'VCLinkerTool': { - 'LinkIncremental': '1', - }, - }, - }, # Release_Base + 'Release_Base': + { + 'abstract': 1, + 'msvs_settings': + { + 'VCCLCompilerTool': + { + 'Optimization': '2', # /Os + 'PreprocessorDefinitions': ['NDEBUG'], + 'RuntimeLibrary': '0', # /MT (static) + }, + 'VCLinkerTool': + { + 'LinkIncremental': '1', + }, + }, + }, # Release_Base - 'x86_Base': { - 'abstract': 1, - 'msvs_configuration_platform': 'Win32', - 'msvs_settings': { - 'VCLinkerTool': { - 'TargetMachine': '1', - 'AdditionalLibraryDirectories': [ - '<(windows_sdk_path)/Lib/win8/um/x86', - ], - }, - 'VCLibrarianTool': { - 'AdditionalLibraryDirectories': [ - '<(windows_sdk_path)/Lib/win8/um/x86', - ], - }, - }, - }, # x86_Base + 'x86_Base': + { + 'abstract': 1, + 'msvs_configuration_platform': 'Win32', + 'msvs_settings': + { + 'VCLinkerTool': + { + 'TargetMachine': '1', + 'AdditionalLibraryDirectories': + [ + '<(windows_sdk_path)/Lib/win8/um/x86', + ], + }, + 'VCLibrarianTool': + { + 'AdditionalLibraryDirectories': + [ + '<(windows_sdk_path)/Lib/win8/um/x86', + ], + }, + }, + }, # x86_Base - 'x64_Base': { - 'abstract': 1, - 'msvs_configuration_platform': 'x64', - 'msvs_settings': { - 'VCLinkerTool': { - 'TargetMachine': '17', # x86 - 64 - 'AdditionalLibraryDirectories': [ - '<(windows_sdk_path)/Lib/win8/um/x64', - ], - }, - 'VCLibrarianTool': { - 'AdditionalLibraryDirectories': [ - '<(windows_sdk_path)/Lib/win8/um/x64', - ], - }, - }, - }, # x64_Base + 'x64_Base': + { + 'abstract': 1, + 'msvs_configuration_platform': 'x64', + 'msvs_settings': + { + 'VCLinkerTool': + { + 'TargetMachine': '17', # x86 - 64 + 'AdditionalLibraryDirectories': + [ + '<(windows_sdk_path)/Lib/win8/um/x64', + ], + }, + 'VCLibrarianTool': { + 'AdditionalLibraryDirectories': + [ + '<(windows_sdk_path)/Lib/win8/um/x64', + ], + }, + }, + }, # x64_Base - # Concrete configurations - 'Debug': { - 'inherit_from': ['Common_Base', 'x86_Base', 'Debug_Base'], - }, - 'Release': { - 'inherit_from': ['Common_Base', 'x86_Base', 'Release_Base'], - }, - 'conditions': [ - [ 'OS=="win" and MSVS_VERSION != "2010e" and MSVS_VERSION != "2012e"', { - 'Debug_x64': { - 'inherit_from': ['Common_Base', 'x64_Base', 'Debug_Base'], - }, - 'Release_x64': { - 'inherit_from': ['Common_Base', 'x64_Base', 'Release_Base'], - }, - }], - ], - }, # configurations - 'conditions': [ - ['component=="shared_library"', { - 'defines': ['COMPONENT_BUILD'], - }], - ], - }, # target_defaults - 'conditions': [ - ['OS=="win"', { - 'target_defaults': { - 'msvs_cygwin_dirs': ['../third_party/cygwin'], - }, - }], - ['OS!="win" and OS!="mac"', { - 'target_defaults': { - 'cflags': [ - '-pthread', - '-fno-exceptions', - ], - 'ldflags': [ - '-pthread', - ], - 'configurations': { - 'Debug': { - 'variables': { - 'debug_optimize%': '0', + # Concrete configurations + 'Debug': + { + 'inherit_from': ['Common_Base', 'x86_Base', 'Debug_Base'], }, - 'defines': [ - '_DEBUG', - ], - 'cflags': [ - '-O>(debug_optimize)', - '-g', + 'Release': + { + 'inherit_from': ['Common_Base', 'x86_Base', 'Release_Base'], + }, + 'conditions': + [ + [ 'OS == "win" and MSVS_VERSION != "2010e" and MSVS_VERSION != "2012e"', + { + 'Debug_x64': + { + 'inherit_from': ['Common_Base', 'x64_Base', 'Debug_Base'], + }, + 'Release_x64': + { + 'inherit_from': ['Common_Base', 'x64_Base', 'Release_Base'], + }, + }], ], - } - }, - }, - }], - ['angle_code==1', { - 'target_defaults': { - 'conditions': [ - ['OS=="mac"', { - 'xcode_settings': { - 'WARNING_CFLAGS': ['<@(gcc_or_clang_warnings)'] + }, # configurations + 'conditions': + [ + ['component=="shared_library"', + { + 'defines': [ 'COMPONENT_BUILD' ], + }], + ], + }, # target_defaults + 'conditions': + [ + ['OS == "win"', + { + 'target_defaults': + { + 'msvs_cygwin_dirs': ['../third_party/cygwin'], + }, + }], + ['OS != "win" and OS != "mac"', + { + 'target_defaults': + { + 'cflags': + [ + '-pthread', + '-fno-exceptions', + ], + 'ldflags': + [ + '-pthread', + ], + 'configurations': + { + 'Debug': + { + 'variables': + { + 'debug_optimize%': '0', + }, + 'defines': + [ + '_DEBUG', + ], + 'cflags': + [ + '-O>(debug_optimize)', + '-g', + ], + } + }, }, - }], - ['OS!="win" and OS!="mac"', { - 'cflags': ['<@(gcc_or_clang_warnings)'] - }], - ] - } - }], - ], + }], + ['angle_code==1', + { + 'target_defaults': + { + 'conditions': + [ + ['OS == "mac"', + { + 'xcode_settings': + { + 'WARNING_CFLAGS': ['<@(gcc_or_clang_warnings)'] + }, + }], + ['OS != "win" and OS != "mac"', + { + 'cflags': ['<@(gcc_or_clang_warnings)'] + }], + ] + } + }], + ], } - -# Local Variables: -# tab-width:2 -# indent-tabs-mode:nil -# End: -# vim: set expandtab tabstop=2 shiftwidth=2: diff --git a/build/gyp_angle b/build/gyp_angle index ca533224..262b6162 100644 --- a/build/gyp_angle +++ b/build/gyp_angle @@ -14,22 +14,21 @@ script_dir = os.path.dirname(__file__) angle_dir = os.path.normpath(os.path.join(script_dir, os.pardir)) sys.path.append(os.path.join(angle_dir, 'third_party', 'gyp', 'pylib')) -print os.path.join(angle_dir, 'third_party', 'gyp', 'pylib') import gyp if __name__ == '__main__': - args = sys.argv[1:] - - print 'Updating projects from gyp files...' - sys.stdout.flush() - - # Set the depth to get the top-level Makefile generated into the - # correct directory. This only has an effect on Linux. - args.append('--depth'); - args.append('.'); - # Add common.gypi to the include path. - args.append('-I' + os.path.join(script_dir, 'common.gypi')) - args.append('--no-parallel') - # Add all.gyp as the main gyp file to be generated. - args.append(os.path.join(script_dir, 'all.gyp')) - sys.exit(gyp.main(args)) + args = sys.argv[1:] + + print 'Updating projects from gyp files...' + sys.stdout.flush() + + # Set the depth to get the top-level Makefile generated into the + # correct directory. This only has an effect on Linux. + args.append('--depth'); + args.append('.'); + # Add common.gypi to the include path. + args.append('-I' + os.path.join(script_dir, 'common.gypi')) + args.append('--no-parallel') + # Add all.gyp as the main gyp file to be generated. + args.append(os.path.join(script_dir, 'all.gyp')) + sys.exit(gyp.main(args)) |