From 6fef1ca6f9ecbb4b2cea3a43280b4ed3a956c64c Mon Sep 17 00:00:00 2001 From: John Kessenich Date: Thu, 9 May 2019 03:43:26 -0600 Subject: [PATCH] Latest known-good SPIRV-Tools: WARNING: Needs python 3.x. You may need to install python 3.x and also [windows users] may need to get it in your path in front of python 2.7.x. If you don't need the external projects (i.e., SPIRV-Tools) and don't want to upgrade to python 3, don't create the External subdirectory and CMake won't require python 3. (CMake has a bug that makes it find the wrong one on a first pass if the top level does not require the version needed by lower levels.) --- .appveyor.yml | 1 + CMakeLists.txt | 6 ++++++ README.md | 2 +- glslang/Include/revision.h | 2 +- known_good.json | 4 ++-- 5 files changed, 11 insertions(+), 4 deletions(-) diff --git a/.appveyor.yml b/.appveyor.yml index 5765d9e6..e7c42827 100644 --- a/.appveyor.yml +++ b/.appveyor.yml @@ -32,6 +32,7 @@ matrix: # scripts that run after cloning repository install: - C:/Python27/python.exe update_glslang_sources.py + - set PATH=C:\ninja;C:\Python36;%PATH% - git clone https://github.com/google/googletest.git External/googletest - cd External/googletest - git checkout 440527a61e1c91188195f7de212c63c77e8f0a45 diff --git a/CMakeLists.txt b/CMakeLists.txt index aafa70ed..acbd266b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -114,6 +114,12 @@ function(glslang_set_link_args TARGET) endif() endfunction(glslang_set_link_args) +# CMake needs to find the right version of python, right from the beginning, +# otherwise, it will find the wrong version and fail later +if(IS_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/External) + find_package(PythonInterp 3 REQUIRED) +endif() + # We depend on these for later projects, so they should come first. add_subdirectory(External) diff --git a/README.md b/README.md index 7d4fe3a9..ff89e4c0 100755 --- a/README.md +++ b/README.md @@ -61,7 +61,7 @@ branch. (For MSVS: 2015 is recommended, 2013 is fully supported/tested, and 2010 support is attempted, but not tested.) * [CMake][cmake]: for generating compilation targets. * make: _Linux_, ninja is an alternative, if configured. -* [Python 2.7][python]: for executing SPIRV-Tools scripts. (Optional if not using SPIRV-Tools.) +* [Python 3.x][python]: for executing SPIRV-Tools scripts. (Optional if not using SPIRV-Tools and the 'External' subdirectory does not exist.) * [bison][bison]: _optional_, but needed when changing the grammar (glslang.y). * [googletest][googletest]: _optional_, but should use if making any changes to glslang. diff --git a/glslang/Include/revision.h b/glslang/Include/revision.h index 7550622c..76129f85 100644 --- a/glslang/Include/revision.h +++ b/glslang/Include/revision.h @@ -1,3 +1,3 @@ // This header is generated by the make-revision script. -#define GLSLANG_PATCH_LEVEL 3214 +#define GLSLANG_PATCH_LEVEL 3216 diff --git a/known_good.json b/known_good.json index a943c8fc..96b65dba 100644 --- a/known_good.json +++ b/known_good.json @@ -5,14 +5,14 @@ "site" : "github", "subrepo" : "KhronosGroup/SPIRV-Tools", "subdir" : "External/spirv-tools", - "commit" : "26c1b8878315a7a5c188df45e0bc236bb222b698" + "commit" : "89fe836fe22c3e5c2a062ebeade012e2c2f0839b" }, { "name" : "spirv-tools/external/spirv-headers", "site" : "github", "subrepo" : "KhronosGroup/SPIRV-Headers", "subdir" : "External/spirv-tools/external/spirv-headers", - "commit" : "2434b89345a50c018c84f42a310b0fad4f3fd94f" + "commit" : "c4f8f65792d4bf2657ca751904c511bbcf2ac77b" } ] }