Removed FatalWarnings flag, to make sure it can build around new compiler warnings. Checked return values in os_getcwd
This commit is contained in:
parent
f3c5b1868f
commit
6383c30674
@ -4,11 +4,12 @@
|
||||
|
||||
This version is a complete rewrite of Premake.
|
||||
|
||||
- New, more readable and extensible syntax for projects
|
||||
- A new, more readable and extensible syntax for projects
|
||||
- More robust syntax validation
|
||||
- Better validation of command-line arguments
|
||||
- A new command-line format, with better argument validation
|
||||
- Improved path handling across all project settings
|
||||
- Upgraded to Lua 5.1.2
|
||||
- Upgraded to Lua 5.1.4
|
||||
- Many, many bug fixes
|
||||
|
||||
|
||||
-----
|
||||
|
@ -38,7 +38,7 @@ end
|
||||
targetname "premake4"
|
||||
language "C"
|
||||
kind "ConsoleApp"
|
||||
flags { "No64BitChecks", "ExtraWarnings", "FatalWarnings" }
|
||||
flags { "No64BitChecks", "ExtraWarnings" }
|
||||
includedirs { "src/host/lua-5.1.4/src" }
|
||||
location ( _OPTIONS["to"] )
|
||||
|
||||
|
@ -10,13 +10,17 @@ int os_getcwd(lua_State* L)
|
||||
{
|
||||
char buffer[0x4000];
|
||||
char* ch;
|
||||
int result;
|
||||
|
||||
#if PLATFORM_WINDOWS
|
||||
GetCurrentDirectory(0x4000, buffer);
|
||||
result = (GetCurrentDirectory(0x4000, buffer) != 0);
|
||||
#else
|
||||
getcwd(buffer, 0x4000);
|
||||
result = (getcwd(buffer, 0x4000) != 0);
|
||||
#endif
|
||||
|
||||
if (!result)
|
||||
return 0;
|
||||
|
||||
/* convert to platform-neutral directory separators */
|
||||
for (ch = buffer; *ch != '\0'; ++ch)
|
||||
{
|
||||
|
@ -8,8 +8,7 @@ package.kind = "exe"
|
||||
package.buildflags =
|
||||
{
|
||||
"no-64bit-checks",
|
||||
"extra-warnings",
|
||||
"fatal-warnings"
|
||||
"extra-warnings"
|
||||
}
|
||||
|
||||
package.config["Debug"].defines =
|
||||
|
Loading…
Reference in New Issue
Block a user