Commit 2b8f6fb4 by Geoff Lang

Public project generation script is now a python script and generates projects…

Public project generation script is now a python script and generates projects into the projects directory. TRAC #24020 Signed-off-by: Jamie Madill Signed-off-by: Shannon Woods
parent dd7234c5
......@@ -18,3 +18,5 @@ debug.txt
third_party
tests/third_party
out
build/Debug*
build/Release*
#!/usr/bin/python
# Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
# This script regenerates the canonical visual studio project files that
# are distributed with the ANGLE repository. It requires that depot_tools
# is installed and gclient sync has been run to download gyp. The project
# files are generated and then git added so they can be committed.
import os
import sys
script_dir = os.path.join(os.path.dirname(__file__), 'build')
angle_dir = os.path.normpath(os.path.join(script_dir, os.pardir))
gyp_dir = os.path.join(angle_dir, 'third_party', 'gyp')
generation_dir = "projects"
gyp_generators = "msvs"
msvs_version = "2010e"
build_samples = True
build_tests = False
express_patch_script = os.path.join(generation_dir, 'convert_solutions_to_express.patch')
if __name__ == '__main__':
gyp_cmd = os.path.join(gyp_dir, 'gyp')
gyp_cmd += ' --ignore-environment'
gyp_cmd += ' --depth=.'
gyp_cmd += ' --include=' + os.path.join(script_dir, 'common.gypi')
gyp_cmd += ' --generator-output=' + generation_dir
gyp_cmd += ' --format=' + gyp_generators
gyp_cmd += ' -G msvs_version=' + msvs_version
gyp_cmd += ' -D angle_build_tests=' + ('1' if build_tests else '0')
gyp_cmd += ' -D angle_build_samples=' + ('1' if build_samples else '0')
gyp_cmd += ' ' + os.path.join(script_dir, 'all.gyp')
print 'Generating projects to' + generation_dir + ' from gyp files...'
print gyp_cmd
sys.stdout.flush()
os.system(gyp_cmd)
git_patch_cmd = 'git apply ' + express_patch_script
print '\nPatching Visual Studio projects to Visual Studio Express...'
print git_patch_cmd
sys.stdout.flush()
os.system(git_patch_cmd)
git_add_cmd = 'git add ' + generation_dir + ' -u'
print '\nRunning git add on updated Visual Studio projects...'
print git_add_cmd
sys.stdout.flush()
os.system(git_add_cmd)
From a2b7ac4ae39c2892f9121c247637813f5dcd554e Mon Sep 17 00:00:00 2001
From 4527c32cebbae4df9b4b9f1692fa99a3321943b7 Mon Sep 17 00:00:00 2001
From: Geoff Lang <geofflang@chromium.org>
Date: Thu, 17 Oct 2013 11:58:55 -0400
Date: Mon, 21 Oct 2013 13:31:23 -0400
Subject: [PATCH] Convert visual studio solutions to express.
---
build/all.sln | 4 +---
samples/samples.sln | 4 +---
src/angle.sln | 4 +---
projects/build/all.sln | 4 +---
projects/samples/samples.sln | 4 +---
projects/src/angle.sln | 4 +---
3 files changed, 3 insertions(+), 9 deletions(-)
diff --git a/build/all.sln b/build/all.sln
index b43dce0..28063ce 100644
--- a/build/all.sln
+++ b/build/all.sln
diff --git a/projects/build/all.sln b/projects/build/all.sln
index 0a609cb..5275049 100644
--- a/projects/build/all.sln
+++ b/projects/build/all.sln
@@ -1,5 +1,5 @@
Microsoft Visual Studio Solution File, Format Version 11.00
-# Visual Studio 2010
+# Visual C++ Express 2010
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "all", "all.vcxproj", "{F38E9C0E-E1F0-6C2F-966A-BAB0A9C226A9}"
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "all", "all.vcxproj", "{AF905A46-5AC8-AEE6-AA99-39440E4E660E}"
ProjectSection(ProjectDependencies) = postProject
{7642CFD5-F187-3E3F-F8FF-859949B9F13E} = {7642CFD5-F187-3E3F-F8FF-859949B9F13E}
{C7BAF548-697D-2DCB-9DF3-9D1506A7B444} = {C7BAF548-697D-2DCB-9DF3-9D1506A7B444}
@@ -213,6 +213,4 @@ Global
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
......@@ -27,17 +27,17 @@ index b43dce0..28063ce 100644
- GlobalSection(NestedProjects) = preSolution
- EndGlobalSection
EndGlobal
diff --git a/samples/samples.sln b/samples/samples.sln
index 4d44b1a..f0fbc99 100644
--- a/samples/samples.sln
+++ b/samples/samples.sln
diff --git a/projects/samples/samples.sln b/projects/samples/samples.sln
index 0fc65a5..d97ccca 100644
--- a/projects/samples/samples.sln
+++ b/projects/samples/samples.sln
@@ -1,5 +1,5 @@
Microsoft Visual Studio Solution File, Format Version 11.00
-# Visual Studio 2010
+# Visual C++ Express 2010
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "es_util", "es_util.vcxproj", "{A3860D3E-C52F-F6AC-4B16-067147646E4D}"
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "es_util", "es_util.vcxproj", "{80E5C3D9-93C2-943E-176F-C9A903E27BC9}"
ProjectSection(ProjectDependencies) = postProject
{777AC703-C49D-E67C-F2EA-2BEDE272A25F} = {777AC703-C49D-E67C-F2EA-2BEDE272A25F}
{FBAEE4F6-562A-588F-01F9-72DCABB3B061} = {FBAEE4F6-562A-588F-01F9-72DCABB3B061}
@@ -181,6 +181,4 @@ Global
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
......@@ -45,17 +45,17 @@ index 4d44b1a..f0fbc99 100644
- GlobalSection(NestedProjects) = preSolution
- EndGlobalSection
EndGlobal
diff --git a/src/angle.sln b/src/angle.sln
index 294e81a..1bd6d59 100644
--- a/src/angle.sln
+++ b/src/angle.sln
diff --git a/projects/src/angle.sln b/projects/src/angle.sln
index dfe9be6..da59f8b 100644
--- a/projects/src/angle.sln
+++ b/projects/src/angle.sln
@@ -1,5 +1,5 @@
Microsoft Visual Studio Solution File, Format Version 11.00
-# Visual Studio 2010
+# Visual C++ Express 2010
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libEGL", "libEGL.vcxproj", "{777AC703-C49D-E67C-F2EA-2BEDE272A25F}"
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libEGL", "libEGL.vcxproj", "{FBAEE4F6-562A-588F-01F9-72DCABB3B061}"
ProjectSection(ProjectDependencies) = postProject
{D5D676ED-C189-2A6B-8DE3-F4CA6175550F} = {D5D676ED-C189-2A6B-8DE3-F4CA6175550F}
{7FBD6F69-B9A4-69F1-A12B-8DACB3F8CD81} = {7FBD6F69-B9A4-69F1-A12B-8DACB3F8CD81}
@@ -47,6 +47,4 @@ Global
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
......@@ -64,5 +64,5 @@ index 294e81a..1bd6d59 100644
- EndGlobalSection
EndGlobal
--
1.8.3.msysgit.0
1.8.0.msysgit.0
@ECHO OFF
REM
REM Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
REM Use of this source code is governed by a BSD-style license that can be
REM found in the LICENSE file.
REM
REM This script regenerates the canonical visual studio project files that
REM are distributed with the ANGLE repository. It requires that depot_tools
REM is installed. The project files are generated and then git added so they
REM can be committed.
set oldGYPDefines=%GYP_DEFINES%
set oldGYPMSVS=%GYP_MSVS_VERSION%
set oldGYPGenerators=%GYP_GENERATORS%
set GYP_DEFINES=angle_build_tests=0 angle_build_samples=1
set GYP_MSVS_VERSION=2010e
set GYP_GENERATORS=msvs
call gclient sync
call git apply convert_solutions_to_express.patch
call git add build/*.sln
call git add build/*.vcxproj
call git add build/*.vcxproj.filters
call git add src/*.sln
call git add src/*.vcxproj
call git add src/*.vcxproj.filters
call git add samples/*.sln
call git add samples/*.vcxproj
call git add samples/*.vcxproj.filters
set GYP_DEFINES=%oldGYPDefines%
set GYP_MSVS_VERSION=%oldGYPMSVS%
set GYP_GENERATORS=%oldGYPGenerators%
call gclient runhooks
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment