[wx] Unreviewed build fix, make sure the waf build checks the webKitBranchBuild
authorkevino@webkit.org <kevino@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 16 Jun 2011 17:41:10 +0000 (17:41 +0000)
committerkevino@webkit.org <kevino@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 16 Jun 2011 17:41:10 +0000 (17:41 +0000)
preference like the perl scripts do.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@89041 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Tools/ChangeLog
Tools/waf/build/build_utils.py
Tools/waf/build/settings.py

index e23579d..0e0c8f4 100644 (file)
@@ -1,3 +1,11 @@
+2011-06-16  Kevin Ollivier  <kevino@theolliviers.com>
+
+        [wx] Unreviewed build fix, make sure the waf build checks the webKitBranchBuild
+        preference like the perl scripts do.
+
+        * waf/build/build_utils.py:
+        * waf/build/settings.py:
+
 2011-06-16  Tommy Widenflycht  <tommyw@google.com>
 
         Reviewed by Tony Gentilcore.
 2011-06-16  Tommy Widenflycht  <tommyw@google.com>
 
         Reviewed by Tony Gentilcore.
index cc477df..937ecbc 100644 (file)
@@ -162,7 +162,6 @@ def flattenSources(sources):
 
     return flat_sources
 
 
     return flat_sources
 
-
 def git_branch_name():
     try:
         branches = commands.getoutput("git branch --no-color")
 def git_branch_name():
     try:
         branches = commands.getoutput("git branch --no-color")
@@ -174,10 +173,22 @@ def git_branch_name():
 
     return ""
 
 
     return ""
 
+def is_git_branch_build():
+    branch = git_branch_name()
+    is_branch_build = commands.getoutput("git config --bool branch.%s.webKitBranchBuild" % branch)
+    if is_branch_build == "true":
+        return True
+    elif is_branch_build == "false":
+        return False
+        
+    # not defined for this branch, use the default
+    is_branch_build = commands.getoutput("git config --bool core.webKitBranchBuild")
+    return is_branch_build == "true"
+
 def get_base_product_dir(wk_root):
     build_dir = os.path.join(wk_root, 'WebKitBuild')
     git_branch = git_branch_name()
 def get_base_product_dir(wk_root):
     build_dir = os.path.join(wk_root, 'WebKitBuild')
     git_branch = git_branch_name()
-    if git_branch != "":
+    if git_branch != "" and is_git_branch_build():
         build_dir = os.path.join(build_dir, git_branch)
         
     return build_dir
         build_dir = os.path.join(build_dir, git_branch)
         
     return build_dir
index a9d3f3e..3850bff 100644 (file)
@@ -161,11 +161,8 @@ webcore_dirs_common = [
 config = get_config(wk_root)
 arch = get_arch(wk_root)
 config_dir = config
 config = get_config(wk_root)
 arch = get_arch(wk_root)
 config_dir = config
-git_branch = git_branch_name()
-if git_branch != "":
-    config_dir = os.path.join(git_branch, config_dir)
 
 
-output_dir = os.path.join(wk_root, 'WebKitBuild', config_dir)
+output_dir = os.path.join(get_base_product_dir(wk_root), config_dir)
 
 building_on_win32 = sys.platform.startswith('win')
 
 
 building_on_win32 = sys.platform.startswith('win')