spirv-headers : Add file to restrict to commit

Restrict spirv-headers to a specific commit (just as we do to
spirv-tools and glslang) by creating a new file
(spirv-headers_revision) to track the commit we want to
syncrhonize to.  Also update the update_external_sources scripts
to use it.  This will make sure that we don't run into the
scenario where spirv-tools and spirv-headers are incompatible.

Change-Id: Ia4fdd921a5c1c500d7f751db08b6998b3d704f2d
diff --git a/spirv-headers_revision b/spirv-headers_revision
new file mode 100644
index 0000000..74846cc
--- /dev/null
+++ b/spirv-headers_revision
@@ -0,0 +1 @@
+3814effb879ab5a98a7b9288a4b4c7849d2bc8ac
diff --git a/update_external_sources.bat b/update_external_sources.bat
index d027313..62bded1 100644
--- a/update_external_sources.bat
+++ b/update_external_sources.bat
@@ -137,8 +137,10 @@
 
 set /p GLSLANG_REVISION= < glslang_revision
 set /p SPIRV_TOOLS_REVISION= < spirv-tools_revision
+set /p SPIRV_HEADERS_REVISION= < spirv-headers_revision
 echo GLSLANG_REVISION=%GLSLANG_REVISION%
 echo SPIRV_TOOLS_REVISION=%SPIRV_TOOLS_REVISION%
+echo SPIRV_HEADERS_REVISION=%SPIRV_HEADERS_REVISION%
 
 
 echo Creating and/or updating glslang, spirv-tools in %BASE_DIR%
@@ -235,6 +237,7 @@
    mkdir %SPIRV_TOOLS_DIR%\external\spirv-headers
    cd %SPIRV_TOOLS_DIR%\external\spirv-headers
    git clone https://github.com/KhronosGroup/SPIRV-HEADERS.git .
+   git checkout %SPIRV_HEADERS_REVISION%
    if not exist %SPIRV_TOOLS_DIR%\external\spirv-headers\README.md (
       echo spirv-headers download failed!
       set errorCode=1
@@ -247,16 +250,9 @@
    cd %SPIRV_TOOLS_DIR%
    git fetch --all
    git checkout %SPIRV_TOOLS_REVISION%
-   if not exist %SPIRV_TOOLS_DIR%\external\spirv-headers\README.md (
-      mkdir %SPIRV_TOOLS_DIR%\external
-      mkdir %SPIRV_TOOLS_DIR%\external\spirv-headers
-      cd %SPIRV_TOOLS_DIR%\external\spirv-headers
-      git clone https://github.com/KhronosGroup/SPIRV-HEADERS.git .
-      goto:eof
-   )
    cd %SPIRV_TOOLS_DIR%\external\spirv-headers
    git fetch --all
-   git pull
+   git checkout %SPIRV_HEADERS_REVISION%
 goto:eof
 
 :build_glslang
diff --git a/update_external_sources.sh b/update_external_sources.sh
index fa740a6..59197f0 100755
--- a/update_external_sources.sh
+++ b/update_external_sources.sh
@@ -5,8 +5,10 @@
 
 GLSLANG_REVISION=$(cat $PWD/glslang_revision)
 SPIRV_TOOLS_REVISION=$(cat $PWD/spirv-tools_revision)
+SPIRV_HEADERS_REVISION=$(cat $PWD/spirv-headers_revision)
 echo "GLSLANG_REVISION=$GLSLANG_REVISION"
 echo "SPIRV_TOOLS_REVISION=$SPIRV_TOOLS_REVISION"
+echo "SPIRV_HEADERS_REVISION=$SPIRV_HEADERS_REVISION"
 
 BUILDDIR=$PWD
 BASEDIR=$BUILDDIR/external
@@ -46,6 +48,7 @@
    mkdir -p $BASEDIR/spirv-tools/external/spirv-headers
    cd $BASEDIR/spirv-tools/external/spirv-headers
    git clone https://github.com/KhronosGroup/SPIRV-Headers .
+   git checkout $SPIRV_HEADERS_REVISION
 }
 
 function update_spirv-tools () {
@@ -60,9 +63,8 @@
    else
       cd $BASEDIR/spirv-tools/external/spirv-headers
       git fetch --all
-      git checkout master
-      git pull
    fi
+   git checkout $SPIRV_HEADERS_REVISION
 }
 
 function build_glslang () {