bump(main/ninja): 1.12.0

This commit is contained in:
Jia Yuan Lo 2024-04-14 09:39:16 +08:00 committed by finagolfin
parent f5986716d2
commit dd66468728
2 changed files with 33 additions and 4 deletions

View File

@ -2,11 +2,11 @@ TERMUX_PKG_HOMEPAGE=https://ninja-build.org
TERMUX_PKG_DESCRIPTION="A small build system with a focus on speed"
TERMUX_PKG_LICENSE="Apache-2.0"
TERMUX_PKG_MAINTAINER="@termux"
TERMUX_PKG_VERSION="1.11.1"
TERMUX_PKG_SRCURL=https://github.com/ninja-build/ninja/archive/v${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_SHA256=31747ae633213f1eda3842686f83c2aa1412e0f5691d1c14dbbcc67fe7400cea
TERMUX_PKG_VERSION="1.12.0"
TERMUX_PKG_SRCURL=https://github.com/ninja-build/ninja/archive/refs/tags/v${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_SHA256=8b2c86cd483dc7fcb7975c5ec7329135d210099a89bc7db0590a07b0bbfe49a5
TERMUX_PKG_DEPENDS="libandroid-spawn, libc++"
TERMUX_PKG_AUTO_UPDATE=true
TERMUX_PKG_DEPENDS="libc++, libandroid-spawn"
termux_step_pre_configure() {
CXXFLAGS+=" $CPPFLAGS"

View File

@ -0,0 +1,29 @@
--- a/src/util.cc
+++ b/src/util.cc
@@ -47,7 +47,7 @@
#include <sys/loadavg.h>
#elif defined(_AIX) && !defined(__PASE__)
#include <libperfstat.h>
-#elif defined(linux) || defined(__GLIBC__)
+#elif defined(__linux__) || defined(__GLIBC__)
#include <sys/sysinfo.h>
#include <fstream>
#include <map>
@@ -589,7 +589,7 @@
return stripped;
}
-#if defined(linux) || defined(__GLIBC__)
+#if defined(__linux__) || defined(__GLIBC__)
std::pair<int64_t, bool> readCount(const std::string& path) {
std::ifstream file(path.c_str());
if (!file.is_open())
@@ -789,7 +789,7 @@
#else
int cgroupCount = -1;
int schedCount = -1;
-#if defined(linux) || defined(__GLIBC__)
+#if defined(__linux__) || defined(__GLIBC__)
cgroupCount = ParseCPUFromCGroup();
#endif
// The number of exposed processors might not represent the actual number of