Skip to content

Commit

Permalink
Update scripts for 3.4 branch
Browse files Browse the repository at this point in the history
  • Loading branch information
chesik-amd committed Jul 10, 2019
1 parent 7c28a0c commit 233be88
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 21 deletions.
18 changes: 9 additions & 9 deletions Scripts/UpdateCommon.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,13 +99,6 @@ def UpdateGitHubRepo(repoRootUrl, location, commit):
except subprocess.CalledProcessError as e:
print ("'git pull' failed with returncode: %d\n" % e.returncode)
sys.exit(1)
sys.stdout.flush()

try:
subprocess.check_call(["git", "-C", targetPath, "checkout", reqdCommit], shell=SHELLARG)
except subprocess.CalledProcessError as e:
print ("'git checkout' failed with returncode: %d\n" % e.returncode)
sys.exit(1)
sys.stderr.flush()
sys.stdout.flush()
else:
Expand All @@ -115,13 +108,20 @@ def UpdateGitHubRepo(repoRootUrl, location, commit):
print("Directory " + targetPath + " does not exist. \n\tUsing 'git clone' to get from " + ghRepoSource)
sys.stdout.flush()
try:
subprocess.check_call(["git", "-C", scriptRoot, "clone", ghRepoSource, targetPath, "--branch", reqdCommit], shell=SHELLARG)
subprocess.check_call(["git", "-C", scriptRoot, "clone", ghRepoSource, targetPath], shell=SHELLARG)
except subprocess.CalledProcessError as e:
print("'git clone' failed with returncode: %d\n" % e.returncode)
sys.exit(1)
sys.stderr.flush()
sys.stdout.flush()

try:
subprocess.check_call(["git", "-C", targetPath, "checkout", reqdCommit], shell=SHELLARG)
except subprocess.CalledProcessError as e:
print ("'git checkout' failed with returncode: %d\n" % e.returncode)
sys.exit(1)
sys.stderr.flush()
sys.stdout.flush()

for key in gitMapping:
UpdateGitHubRepo(ghAmdRoot, gitMapping[key][0], gitMapping[key][1])

Expand Down
24 changes: 12 additions & 12 deletions Scripts/UpdateCommonMap.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,19 @@
# "git repo name" : ["Directory for clone relative to parent project directory", "branch or commit to checkout (or None for top of tree)"]
gitMapping = {
# Lib.
"common-lib-amd-ADL" : ["../Common/Lib/AMD/ADL", None],
"common-lib-amd-APPSDK-3.0" : ["../Common/Lib/AMD/APPSDK", None],
"common-lib-ext-OpenGL" : ["../Common/Lib/Ext/OpenGL", None],
"common-lib-ext-WindowsKits" : ["../Common/Lib/Ext/Windows-Kits", None],
"googletest" : ["../Common/Lib/Ext/GoogleTest", "v1.8.x"],
"common-lib-amd-ADL" : ["../Common/Lib/AMD/ADL", "da98d7a9d2b8a6222d32c82952ee44bdfc827b2e"],
"common-lib-amd-APPSDK-3.0" : ["../Common/Lib/AMD/APPSDK", "4fad89c430a886d2e4723e617d821386eb634ec7"],
"common-lib-ext-OpenGL" : ["../Common/Lib/Ext/OpenGL", "63cd62c8b25e165b0e6f3307b998ed0cf3810edf"],
"common-lib-ext-WindowsKits" : ["../Common/Lib/Ext/Windows-Kits", "2c99b88d6a8a9b672464436dad771b9799056a8a"],
"googletest" : ["../Common/Lib/Ext/GoogleTest", "542e057c6c5bf45454b43764b881397b71164d62"],
# Src.
"common-src-ADLUtil" : ["../Common/Src/ADLUtil", None],
"common-src-AmdDxExt" : ["../Common/Src/AmdDxExt", None],
"common-src-AmdVkExt" : ["../Common/Src/AmdVkExt", None],
"common-src-DeviceInfo" : ["../Common/Src/DeviceInfo", None],
"common-src-DynamicLibraryModule" : ["../Common/Src/DynamicLibraryModule", None],
"common-src-TSingleton" : ["../Common/Src/TSingleton", None],
"common-src-CMakeModules" : ["../Common/Src/CMakeModules", None],
"common-src-ADLUtil" : ["../Common/Src/ADLUtil", "d62c94514326775c83fc129bb89d299c8749ebd1"],
"common-src-AmdDxExt" : ["../Common/Src/AmdDxExt", "9caab274b792ecb3a8d0db4b03315d6564a12eca"],
"common-src-AmdVkExt" : ["../Common/Src/AmdVkExt", "95c1039d849f2a61ba61facf175b866175169819"],
"common-src-DeviceInfo" : ["../Common/Src/DeviceInfo", "8f62f981b950d052fe2549bfc9c3b678f3160c13"],
"common-src-DynamicLibraryModule" : ["../Common/Src/DynamicLibraryModule", "ab1e854a6596e2f4d01c0b99096be11bbcd57ab8"],
"common-src-TSingleton" : ["../Common/Src/TSingleton", "02e8fa7d98f33cdbd0e1f77d1a8a403a32e35882"],
"common-src-CMakeModules" : ["../Common/Src/CMakeModules", "4d593266f3bb8916b15834050744659d0b86fc65"],
}

# Name : Source , Destination, version, Copied/Installation location wrt to Script root
Expand Down

0 comments on commit 233be88

Please sign in to comment.