forked from organicmaps/organicmaps
Fixed shaders compiler test on linux and possibly windows
This commit is contained in:
parent
526ead510e
commit
2135c325cf
4 changed files with 15 additions and 2 deletions
BIN
data/shaders_compiler/GLSLESCompiler_Series5
Executable file
BIN
data/shaders_compiler/GLSLESCompiler_Series5
Executable file
Binary file not shown.
BIN
data/shaders_compiler/GLSLESCompiler_Series5.exe
Executable file
BIN
data/shaders_compiler/GLSLESCompiler_Series5.exe
Executable file
Binary file not shown.
Binary file not shown.
|
@ -4,10 +4,23 @@
|
|||
|
||||
#include "../../platform/platform.hpp"
|
||||
#include "../../std/sstream.hpp"
|
||||
#include "../../std/target_os.hpp"
|
||||
|
||||
#include <QtCore/QProcess>
|
||||
#include <QtCore/QTextStream>
|
||||
|
||||
|
||||
#if defined (OMIM_OS_MAC)
|
||||
#define SHADERS_COMPILER "GLSLESCompiler_Series5.mac"
|
||||
#elif defined (OMIM_OS_LINUX)
|
||||
#define SHADERS_COMPILER "GLSLESCompiler_Series5"
|
||||
#elif defined (OMIM_OS_WINDOWS)
|
||||
#define SHADERS_COMPILER "GLSLESCompiler_Series5.exe"
|
||||
#else
|
||||
#error "Define shaders compiler for your platform"
|
||||
#endif
|
||||
|
||||
|
||||
string DebugPrint(QString const & s)
|
||||
{
|
||||
return s.toStdString();
|
||||
|
@ -16,10 +29,10 @@ string DebugPrint(QString const & s)
|
|||
UNIT_TEST(CompileShaders_Test)
|
||||
{
|
||||
Platform & platform = GetPlatform();
|
||||
string glslCompilerPath = platform.ResourcesDir() + "glslcompiler_sgx535";
|
||||
string glslCompilerPath = platform.ResourcesDir() + "shaders_compiler/" SHADERS_COMPILER;
|
||||
if (!platform.IsFileExistsByFullPath(glslCompilerPath))
|
||||
{
|
||||
glslCompilerPath = platform.WritableDir() + "glslcompiler_sgx535";
|
||||
glslCompilerPath = platform.WritableDir() + "shaders_compiler/" SHADERS_COMPILER;
|
||||
if (!platform.IsFileExistsByFullPath(glslCompilerPath))
|
||||
TEST_EQUAL(false, true, ("GLSL compiler not found"));
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue