Fix remaining MinGW build issues

This commit is contained in:
Jason Perkins 2020-03-30 17:00:38 -04:00 committed by starkos
parent f29f8b2030
commit ac874b91a4
3 changed files with 5 additions and 6 deletions

View File

@ -45,7 +45,7 @@ none:
@echo "Please do"
@echo " nmake -f Bootstrap.mak windows"
@echo "or"
@echo " CC=mingw32-gcc mingw32-make -f Bootstrap.mak mingw"
@echo " CC=mingw32-gcc mingw32-make -f Bootstrap.mak mingw CONFIG=x64"
@echo "or"
@echo " make -f Bootstrap.mak HOST_PLATFORM"
@echo "where HOST_PLATFORM is one of these:"
@ -58,7 +58,7 @@ mingw: $(SRC)
if not exist build\bootstrap (mkdir build\bootstrap)
$(CC) -o build/bootstrap/premake_bootstrap -DPREMAKE_NO_BUILTIN_SCRIPTS -I"$(LUA_DIR)" -I"$(LUASHIM_DIR)" $? -lole32 -lversion
./build/bootstrap/premake_bootstrap embed
./build/bootstrap/premake_bootstrap --os=windows --to=build/bootstrap gmake2 --cc=mingw
./build/bootstrap/premake_bootstrap --os=windows --to=build/bootstrap --cc=mingw gmake2
$(MAKE) -C build/bootstrap config=$(CONFIG)_$(PLATFORM)
macosx: osx

View File

@ -172,9 +172,10 @@
targetdir "bin/release"
filter "system:windows"
links { "ole32", "ws2_32", "advapi32" }
links { "ole32", "ws2_32", "advapi32", "version" }
filter "toolset:mingw"
links { "version", "crypt32" }
links { "crypt32" }
filter "system:linux or bsd or hurd"
defines { "LUA_USE_POSIX", "LUA_USE_DLOPEN" }

View File

@ -55,8 +55,6 @@ int os_getversion(lua_State* L)
#if defined(PLATFORM_WINDOWS)
#pragma comment(lib, "version.lib")
int getKernelVersion(struct OsVersionInfo* info)
{
DWORD size = GetFileVersionInfoSizeA("kernel32.dll", NULL);