Gtk: Fix compile with moved deps.

This commit is contained in:
BearOso 2022-03-18 15:15:53 -05:00
parent 88f4d66de8
commit fe5fbb0c80
2 changed files with 63 additions and 63 deletions

View File

@ -75,92 +75,92 @@ slang = get_option('slang')
if slang and opengl if slang and opengl
glslang_args = ['-w', '-fno-exceptions', '-DNV_EXTENSIONS', '-DAMD_EXTENSIONS', '-DGLSLANG_OSINCLUDE_UNIX', '-DENABLE_OPT=0'] glslang_args = ['-w', '-fno-exceptions', '-DNV_EXTENSIONS', '-DAMD_EXTENSIONS', '-DGLSLANG_OSINCLUDE_UNIX', '-DENABLE_OPT=0']
OSDependent_src = ['../shaders/glslang/glslang/OSDependent/Unix/ossource.cpp'] OSDependent_src = ['../external/glslang/glslang/OSDependent/Unix/ossource.cpp']
OSDependent_lib = static_library('OSDependent', OSDependent_lib = static_library('OSDependent',
OSDependent_src, OSDependent_src,
include_directories: include_directories('../shaders/glslang'), include_directories: include_directories('../external/glslang'),
cpp_args: glslang_args) cpp_args: glslang_args)
libs += OSDependent_lib libs += OSDependent_lib
glslang_src = [ glslang_src = [
'../shaders/glslang/glslang/MachineIndependent/glslang_tab.cpp', '../external/glslang/glslang/MachineIndependent/glslang_tab.cpp',
'../shaders/glslang/glslang/MachineIndependent/attribute.cpp', '../external/glslang/glslang/MachineIndependent/attribute.cpp',
'../shaders/glslang/glslang/MachineIndependent/Constant.cpp', '../external/glslang/glslang/MachineIndependent/Constant.cpp',
'../shaders/glslang/glslang/MachineIndependent/iomapper.cpp', '../external/glslang/glslang/MachineIndependent/iomapper.cpp',
'../shaders/glslang/glslang/MachineIndependent/InfoSink.cpp', '../external/glslang/glslang/MachineIndependent/InfoSink.cpp',
'../shaders/glslang/glslang/MachineIndependent/Initialize.cpp', '../external/glslang/glslang/MachineIndependent/Initialize.cpp',
'../shaders/glslang/glslang/MachineIndependent/IntermTraverse.cpp', '../external/glslang/glslang/MachineIndependent/IntermTraverse.cpp',
'../shaders/glslang/glslang/MachineIndependent/Intermediate.cpp', '../external/glslang/glslang/MachineIndependent/Intermediate.cpp',
'../shaders/glslang/glslang/MachineIndependent/ParseContextBase.cpp', '../external/glslang/glslang/MachineIndependent/ParseContextBase.cpp',
'../shaders/glslang/glslang/MachineIndependent/ParseHelper.cpp', '../external/glslang/glslang/MachineIndependent/ParseHelper.cpp',
'../shaders/glslang/glslang/MachineIndependent/PoolAlloc.cpp', '../external/glslang/glslang/MachineIndependent/PoolAlloc.cpp',
'../shaders/glslang/glslang/MachineIndependent/RemoveTree.cpp', '../external/glslang/glslang/MachineIndependent/RemoveTree.cpp',
'../shaders/glslang/glslang/MachineIndependent/Scan.cpp', '../external/glslang/glslang/MachineIndependent/Scan.cpp',
'../shaders/glslang/glslang/MachineIndependent/ShaderLang.cpp', '../external/glslang/glslang/MachineIndependent/ShaderLang.cpp',
'../shaders/glslang/glslang/MachineIndependent/SymbolTable.cpp', '../external/glslang/glslang/MachineIndependent/SymbolTable.cpp',
'../shaders/glslang/glslang/MachineIndependent/Versions.cpp', '../external/glslang/glslang/MachineIndependent/Versions.cpp',
'../shaders/glslang/glslang/MachineIndependent/intermOut.cpp', '../external/glslang/glslang/MachineIndependent/intermOut.cpp',
'../shaders/glslang/glslang/MachineIndependent/limits.cpp', '../external/glslang/glslang/MachineIndependent/limits.cpp',
'../shaders/glslang/glslang/MachineIndependent/linkValidate.cpp', '../external/glslang/glslang/MachineIndependent/linkValidate.cpp',
'../shaders/glslang/glslang/MachineIndependent/parseConst.cpp', '../external/glslang/glslang/MachineIndependent/parseConst.cpp',
'../shaders/glslang/glslang/MachineIndependent/reflection.cpp', '../external/glslang/glslang/MachineIndependent/reflection.cpp',
'../shaders/glslang/glslang/MachineIndependent/preprocessor/Pp.cpp', '../external/glslang/glslang/MachineIndependent/preprocessor/Pp.cpp',
'../shaders/glslang/glslang/MachineIndependent/preprocessor/PpAtom.cpp', '../external/glslang/glslang/MachineIndependent/preprocessor/PpAtom.cpp',
'../shaders/glslang/glslang/MachineIndependent/preprocessor/PpContext.cpp', '../external/glslang/glslang/MachineIndependent/preprocessor/PpContext.cpp',
'../shaders/glslang/glslang/MachineIndependent/preprocessor/PpScanner.cpp', '../external/glslang/glslang/MachineIndependent/preprocessor/PpScanner.cpp',
'../shaders/glslang/glslang/MachineIndependent/preprocessor/PpTokens.cpp', '../external/glslang/glslang/MachineIndependent/preprocessor/PpTokens.cpp',
'../shaders/glslang/glslang/MachineIndependent/propagateNoContraction.cpp', '../external/glslang/glslang/MachineIndependent/propagateNoContraction.cpp',
'../shaders/glslang/glslang/GenericCodeGen/CodeGen.cpp', '../external/glslang/glslang/GenericCodeGen/CodeGen.cpp',
'../shaders/glslang/glslang/GenericCodeGen/Link.cpp', '../external/glslang/glslang/GenericCodeGen/Link.cpp',
'../shaders/glslang/StandAlone/ResourceLimits.cpp' '../external/glslang/StandAlone/ResourceLimits.cpp'
] ]
glslang_lib = static_library('glslang', glslang_lib = static_library('glslang',
glslang_src, glslang_src,
include_directories: include_directories('../shaders/glslang'), include_directories: include_directories('../external/glslang'),
cpp_args: glslang_args) cpp_args: glslang_args)
libs += glslang_lib libs += glslang_lib
OGLCompilersDLL_src = ['../shaders/glslang/OGLCompilersDLL/InitializeDll.cpp'] OGLCompilersDLL_src = ['../external/glslang/OGLCompilersDLL/InitializeDll.cpp']
OGLCompilersDLL_lib = static_library('OGLCompilersDLL', OGLCompilersDLL_lib = static_library('OGLCompilersDLL',
OGLCompilersDLL_src, OGLCompilersDLL_src,
include_directories: include_directories('../shaders/glslang'), include_directories: include_directories('../external/glslang'),
cpp_args: glslang_args) cpp_args: glslang_args)
libs += OGLCompilersDLL_lib libs += OGLCompilersDLL_lib
SPIRV_src = [ SPIRV_src = [
'../shaders/glslang/SPIRV/GlslangToSpv.cpp', '../external/glslang/SPIRV/GlslangToSpv.cpp',
'../shaders/glslang/SPIRV/InReadableOrder.cpp', '../external/glslang/SPIRV/InReadableOrder.cpp',
'../shaders/glslang/SPIRV/Logger.cpp', '../external/glslang/SPIRV/Logger.cpp',
'../shaders/glslang/SPIRV/SpvBuilder.cpp', '../external/glslang/SPIRV/SpvBuilder.cpp',
'../shaders/glslang/SPIRV/SpvPostProcess.cpp', '../external/glslang/SPIRV/SpvPostProcess.cpp',
'../shaders/glslang/SPIRV/SpvTools.cpp', '../external/glslang/SPIRV/SpvTools.cpp',
'../shaders/glslang/SPIRV/disassemble.cpp', '../external/glslang/SPIRV/disassemble.cpp',
'../shaders/glslang/SPIRV/SPVRemapper.cpp', '../external/glslang/SPIRV/SPVRemapper.cpp',
'../shaders/glslang/SPIRV/doc.cpp' '../external/glslang/SPIRV/doc.cpp'
] ]
SPIRV_lib = static_library('SPIRV', SPIRV_lib = static_library('SPIRV',
SPIRV_src, SPIRV_src,
include_directories: include_directories('../shaders/glslang'), include_directories: include_directories('../external/glslang'),
cpp_args: glslang_args) cpp_args: glslang_args)
libs += SPIRV_lib libs += SPIRV_lib
args += ['-DUSE_SLANG', args += ['-DUSE_SLANG',
'-DSPIRV_CROSS_EXCEPTIONS_TO_ASSERTIONS'] '-DSPIRV_CROSS_EXCEPTIONS_TO_ASSERTIONS']
srcs += ['../shaders/slang.cpp'] srcs += ['../shaders/slang.cpp']
srcs += ['../shaders/SPIRV-Cross/spirv_cfg.cpp', srcs += ['../external/SPIRV-Cross/spirv_cfg.cpp',
'../shaders/SPIRV-Cross/spirv_cfg.hpp', '../external/SPIRV-Cross/spirv_cfg.hpp',
'../shaders/SPIRV-Cross/spirv_common.hpp', '../external/SPIRV-Cross/spirv_common.hpp',
'../shaders/SPIRV-Cross/spirv_cross.cpp', '../external/SPIRV-Cross/spirv_cross.cpp',
'../shaders/SPIRV-Cross/spirv_cross.hpp', '../external/SPIRV-Cross/spirv_cross.hpp',
'../shaders/SPIRV-Cross/spirv_glsl.cpp', '../external/SPIRV-Cross/spirv_glsl.cpp',
'../shaders/SPIRV-Cross/spirv_glsl.hpp', '../external/SPIRV-Cross/spirv_glsl.hpp',
'../shaders/SPIRV-Cross/spirv_cross_parsed_ir.cpp', '../external/SPIRV-Cross/spirv_cross_parsed_ir.cpp',
'../shaders/SPIRV-Cross/spirv_cross_parsed_ir.hpp', '../external/SPIRV-Cross/spirv_cross_parsed_ir.hpp',
'../shaders/SPIRV-Cross/spirv_parser.cpp', '../external/SPIRV-Cross/spirv_parser.cpp',
'../shaders/SPIRV-Cross/spirv_parser.hpp', '../external/SPIRV-Cross/spirv_parser.hpp',
'../shaders/SPIRV-Cross/spirv.hpp'] '../external/SPIRV-Cross/spirv.hpp']
includes += '../shaders/glslang' includes += '../external/glslang'
endif endif
wayland = get_option('wayland') wayland = get_option('wayland')

View File

@ -9,11 +9,11 @@
#include <vector> #include <vector>
#include <string> #include <string>
#include <sstream> #include <sstream>
#include "glslang/glslang/Public/ShaderLang.h" #include "external/glslang/glslang/Public/ShaderLang.h"
#include "glslang/SPIRV/GlslangToSpv.h" #include "external/glslang/SPIRV/GlslangToSpv.h"
#include "glslang/StandAlone/ResourceLimits.h" #include "external/glslang/StandAlone/ResourceLimits.h"
#include "SPIRV-Cross/spirv_cross.hpp" #include "external/SPIRV-Cross/spirv_cross.hpp"
#include "SPIRV-Cross/spirv_glsl.hpp" #include "external/SPIRV-Cross/spirv_glsl.hpp"
std::string GLSLShader::slang_get_stage(std::vector<std::string> &lines, std::string GLSLShader::slang_get_stage(std::vector<std::string> &lines,
std::string name) std::string name)