Skip to content
Extraits de code Groupes Projets
Valider a58ed734 rédigé par Thomas Goyne's avatar Thomas Goyne
Parcourir les fichiers

Add Aegisub's include dirs before the system ones rather than after

parent a11da335
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
......@@ -123,20 +123,21 @@ namespace agi { namespace lua {
// set the module load path to include_path
lua_getglobal(L, "package");
push_value(L, "path");
#ifdef _WIN32
// No point in checking any of the default locations on Windows since
// there won't be anything there
push_value(L, "");
#else
push_value(L, "path");
lua_gettable(L, -3);
#endif
push_value(L, "");
for (auto const& path : include_path) {
lua_pushfstring(L, ";%s/?.lua;%s/?/init.lua", path.string().c_str(), path.string().c_str());
lua_pushfstring(L, "%s/?.lua;%s/?/init.lua;", path.string().c_str(), path.string().c_str());
lua_concat(L, 2);
}
#ifndef _WIN32
// No point in checking any of the default locations on Windows since
// there won't be anything there
push_value(L, "path");
lua_gettable(L, -4);
lua_concat(L, 2);
#endif
lua_settable(L, -3);
// Replace the default lua module loader with our unicode compatible one
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter