premake: update to 5.0beta1

* Remove upstream 0001-contrib-curl-pollfd-conflict.patch and 0002-fix-for-mingw.patch files.
  commit b3de107f4c
* Import 0439fc0a66
  to fix 32 bit builds.
This commit is contained in:
Biswapriyo Nath
2022-05-02 17:25:32 +05:30
parent 9463a60107
commit bf3b2b0e5d
4 changed files with 8 additions and 67 deletions

View File

@@ -1,12 +0,0 @@
--- a/contrib/curl/lib/select.h
+++ b/contrib/curl/lib/select.h
@@ -36,7 +36,8 @@
#if !defined(HAVE_STRUCT_POLLFD) && \
!defined(HAVE_SYS_POLL_H) && \
- !defined(HAVE_POLL_H)
+ !defined(HAVE_POLL_H) && \
+ !defined(POLLIN)
#define POLLIN 0x01
#define POLLPRI 0x02

View File

@@ -1,43 +0,0 @@
--- a/src/host/os_getversion.c
+++ b/src/host/os_getversion.c
@@ -55,7 +55,9 @@
#if defined(PLATFORM_WINDOWS)
+#ifdef _MSC_VER
#pragma comment(lib, "version.lib")
+#endif
int getKernelVersion(struct OsVersionInfo* info)
{
--- a/src/host/os_isdir.c
+++ b/src/host/os_isdir.c
@@ -9,7 +9,7 @@
#include "premake.h"
#ifdef _WIN32
-#include <Windows.h>
+#include <windows.h>
#endif
int os_isdir(lua_State* L)
@@ -17,7 +17,7 @@
struct stat buf;
const char* path = luaL_checkstring(L, 1);
#ifdef _WIN32
- int attr;
+ DWORD attr;
wchar_t wide_path[PATH_MAX];
if (MultiByteToWideChar(CP_UTF8, 0, path, -1, wide_path, PATH_MAX) == 0)
--- a/src/host/os_uuid.c
+++ b/src/host/os_uuid.c
@@ -7,7 +7,7 @@
#include "premake.h"
#if PLATFORM_WINDOWS
-#include <Objbase.h>
+#include <objbase.h>
#endif

View File

@@ -22,4 +22,4 @@
+ mkdir -p build/bootstrap
$(CC) -o build/bootstrap/premake_bootstrap -DPREMAKE_NO_BUILTIN_SCRIPTS -I"$(LUA_DIR)" -I"$(LUASHIM_DIR)" $(SRC) -lole32 -lversion
./build/bootstrap/premake_bootstrap embed
./build/bootstrap/premake_bootstrap --os=windows --to=build/bootstrap --cc=mingw gmake2
./build/bootstrap/premake_bootstrap --arch=$(PLATFORM) --os=windows --to=build/bootstrap --cc=mingw gmake2

View File

@@ -4,8 +4,8 @@
_realname=premake
pkgbase=mingw-w64-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
pkgver=5.0a16
_realver=5.0.0-alpha16
pkgver=5.0beta1
_realver=5.0.0-beta1
pkgrel=1
pkgdesc="A simple build configuration and project generation tool (mingw-w64)"
arch=('any')
@@ -14,22 +14,18 @@ url="https://premake.github.io/"
license=('BSD')
makedepends=("${MINGW_PACKAGE_PREFIX}-cc")
source=("${_realname}-${pkgver}.tar.gz::https://github.com/premake/premake-core/archive/v${_realver}.tar.gz"
"0001-contrib-curl-pollfd-conflict.patch"
"0002-fix-for-mingw.patch"
"https://github.com/premake/premake-core/commit/0439fc0.patch"
"0003-bootstrap-use-nix-commands.patch")
sha256sums=('a2cfa24642ac50acb57ffcde48c23986348c174a24926736c37b2918778bd881'
'270d13c8c02b805a02cbf2fdd32ed6ac1cd9ebd6b51a3e91270c3ab88e0cb4f7'
'3d50ca9ac5b71349f24ef60652a8d73b72081e28db8932d6533f6a09165ecd5d'
'07f9d76c078ae2b995f1acffebeb934cee973df82335497e5df328c056de05fe')
sha256sums=('97fa4cef9fb6459c39da4e70756c0e13ae7b090fffe9442306c768b8b62e1589'
'4aca23f96871b42d74bee24d83e236cfe67eab077179f4e6be0c38c23df265e3'
'bb1ba52fad8ad8a7a8995b31c50da473067f101d23bf9aac901add6fb9a52995')
prepare() {
rm -rf "build-${MSYSTEM}"
cp -r "${_realname}-core-${_realver}" "build-${MSYSTEM}"
cd "build-${MSYSTEM}"
# https://github.com/premake/premake-core/pull/1680
patch -Np1 -i "${srcdir}/0001-contrib-curl-pollfd-conflict.patch"
patch -Np1 -i "${srcdir}/0002-fix-for-mingw.patch"
patch -Np1 -i "${srcdir}/0439fc0.patch"
patch -Np1 -i "${srcdir}/0003-bootstrap-use-nix-commands.patch"
}