]> O.S.I.I.S - jp/vke.net.git/commitdiff
debug SpirVglslcPath global property usage in SpirVTasks
authorj-p <jp_bruyere@hotmail.com>
Tue, 28 Sep 2021 13:51:47 +0000 (15:51 +0200)
committerj-p <jp_bruyere@hotmail.com>
Tue, 28 Sep 2021 13:51:47 +0000 (15:51 +0200)
Directory.Build.props
SpirVTasks/CompileGLSLTask.cs
SpirVTasks/SpirVTasks.targets

index 12b32f3ef3ea8bb062f7bd592cbb6cc4b9851712..245737510337e46e290cf9c25dcd353edcf63ce9 100644 (file)
@@ -2,7 +2,7 @@
        <PropertyGroup>
                <RootDirectory>$(MSBuildThisFileDirectory)</RootDirectory>
                <RestoreAdditionalProjectSources Condition="Exists('$(SolutionDir)build\$(Configuration)\')">$(SolutionDir)build\$(Configuration)\</RestoreAdditionalProjectSources>
-               <SpirVTasksReleaseVersion>0.1.44</SpirVTasksReleaseVersion>
+               <SpirVTasksReleaseVersion>0.1.45</SpirVTasksReleaseVersion>
                <SpirVTasksPackageVersion>$(SpirVTasksReleaseVersion)</SpirVTasksPackageVersion>
                <VkeReleaseVersion>0.2.1</VkeReleaseVersion>
                <VkePackageVersion>$(VkeReleaseVersion)-beta</VkePackageVersion>
index 51e840cc31c12cad9b7be5187113fc5164e10644..db19af0ee19edaeb01c98d442f025fb82a369690 100644 (file)
@@ -139,8 +139,9 @@ namespace SpirVTasks {
                        glslcPath = "";
                        if (!string.IsNullOrEmpty (SpirVCompilerPath?.ItemSpec)) {
                                glslcPath = SpirVCompilerPath.ItemSpec;
-                               if (!File.Exists (glslcPath))
-                                       return false;
+                               glslcPath = glslcPath.Replace('"', ' ').Trim();
+                               if (File.Exists (glslcPath))
+                                       return true;
                        }
 
                        string glslcExec = "glslc";
index c1176e65a416e7ae90555734e1695e7131af9d96..0dfd391ed61fdfc6e984eefe1eac4cc31e6afbe2 100644 (file)
@@ -8,6 +8,7 @@
   </ItemGroup>
   <Target Name="CompileShaders" BeforeTargets="BeforeBuild" Condition="'@(GLSLShader)'!=''" Outputs="@(CompiledShaders)">                              
        <CompileGLSLTask SourceFile="%(GLSLShader.Identity)"
+                     SpirVCompilerPath="$(SpirVglslcPath)"
                                         AdditionalIncludeDirectories="%(GLSLShader.AdditionalIncludeDirectories);$(SpirVAdditionalIncludeDirectories)"
                                         DefineConstants="%(GLSLShader.DefineConstants);$(DefineConstants)"                                      
                                         TempDirectory="$(IntermediateOutputPath)"