LunarG / LunarGLASS

LLVM IR and optimizer for shaders, including front-end adapters for GLSL and SPIR-V and back-end adapter for GLSL
Other
173 stars 21 forks source link

Appreciate for you to shared your program. #67

Open SakuraXiaMF opened 5 years ago

SakuraXiaMF commented 5 years ago

I am so sorry to bother you a lots of times in issues.I try a lots of times to build LunarGLASS,but I failed a lots of times.The most error is something in namespace glslang doesn't name a type or something is not a member of glslang. For example: LunarGLASS/Frontends/glslang/GlslangToTopVisitor.cpp:105:86: error: ‘TCrackedTextureOp’ in namespace ‘glslang’ does not name a type LunarGLASS/Frontends/glslang/GlslangToTopVisitor.cpp:447:19: error: ‘EbvVertexIndex’ is not a member of ‘glslang’ This program is very important for my reasearch. I don't know how to fix this error. Thank you very much!

greg-lunarg commented 5 years ago

One solution to your problems is to get an old enough version of glslang so that the builds will work. It could be that your version of glslang is not old enough. You may have to go back several years to get a version that is compatible with the current state of LunarGlass.

How are you obtaining your glslang? If from the glslang github repo, what commit are you currently using?

SakuraXiaMF commented 5 years ago

One solution to your problems is to get an old enough version of glslang so that the builds will work. It could be that your version of glslang is not old enough. You may have to go back several years to get a version that is compatible with the current state of LunarGlass.

How are you obtaining your glslang? If from the glslang github repo, what commit are you currently using?

I used to get the glslang using the git clone command, I will try the old version of glslang now.

SakuraXiaMF commented 5 years ago

The glslang I am using is the master commit. The url is https://github.com/KhronosGroup/glslang

SakuraXiaMF commented 5 years ago

I am using the cmake .. command and the make command to build LunarGLASS in the LunarGLASS/build folder. For example: ~/Documents/LunarGLASS/buidl$ cmake ../ ~/Documents/LunarGLASS/buidl$ make

SakuraXiaMF commented 5 years ago

Thank you for your review !

I just tried a lots of old version of glslang as readme.td. Obviously it doesn't work.When my testing,I got a regullar of version which is when you glslang version is higher than 5.0, you get the error is

~/LunarGLASS/Frontends/glslang/GlslangToTopVisitor.cpp:3072: error: no maching function for call to 'glslang::TIntermediate::computeTypeLocationSize(const glslang::TType&) const'

but on the contrary,if you glslang version is lower than 5.0,you get the error is : ~/LunarGLASS/Frontends/glslang/GlslangToTopVisitor.cpp:2780: error: 'EOpLdexp' is not a member of 'glslang'

I followed the readme.md file for all my tests.

SakuraXiaMF commented 5 years ago

Thank you very much! I was complete to build glslang. The glslang version is 6.0,LLVM version is 3.4.I will write a blog to explicate how to build this program.