mirror of
https://github.com/lubosz/overte.git
synced 2025-04-23 20:34:07 +02:00
Added a hack to force referencing of shader source on Android
This commit is contained in:
parent
420b58fd5b
commit
98a47e56fc
1 changed files with 3 additions and 1 deletions
|
@ -127,7 +127,7 @@ int main (int argc, char** argv) {
|
|||
return 0;
|
||||
}
|
||||
|
||||
// Define targetName: if none, get destFilenmae, if none get srcFilename
|
||||
// Define targetName: if none, get destFilename, if none get srcFilename
|
||||
if (targetName.empty()) {
|
||||
if (destFilename.empty()) {
|
||||
targetName = srcFilename;
|
||||
|
@ -216,6 +216,8 @@ int main (int argc, char** argv) {
|
|||
targetStringStream << "R\"SCRIBE(\n" << page->str() << "\n)SCRIBE\"\n";
|
||||
}
|
||||
targetStringStream << ";\n" << std::endl << std::endl;
|
||||
targetStringStream << "// Hack to fix Android link error by forcing a reference to global variable\n";
|
||||
targetStringStream << "class " << targetName << "_used {\npublic:\nstatic const char* get() { return " << targetName << "; }\n};\n" << std::endl;
|
||||
} else {
|
||||
targetStringStream << destStringStream.str();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue