Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
This commit is contained in:
commit
f895287396
@ -1,45 +0,0 @@
|
||||
--- a/math_compat.h
|
||||
+++ b/math_compat.h
|
||||
@@ -6,38 +6,9 @@
|
||||
* @brief Do not use, json-c internal, may be changed or removed at any time.
|
||||
*/
|
||||
|
||||
-/* Define isnan, isinf, infinity and nan on Windows/MSVC */
|
||||
-
|
||||
-#ifndef HAVE_DECL_ISNAN
|
||||
-#ifdef HAVE_DECL__ISNAN
|
||||
-#include <float.h>
|
||||
-#define isnan(x) _isnan(x)
|
||||
-#else
|
||||
-/* On platforms like AIX and "IBM i" we need to provide our own isnan */
|
||||
-#define isnan(x) ((x) != (x))
|
||||
-#endif
|
||||
-#endif
|
||||
-
|
||||
-#ifndef HAVE_DECL_ISINF
|
||||
-#ifdef HAVE_DECL__FINITE
|
||||
-#include <float.h>
|
||||
-#define isinf(x) (!_finite(x))
|
||||
-#else
|
||||
-#include <float.h>
|
||||
-/* On platforms like AIX and "IBM i" we need to provide our own isinf */
|
||||
-#define isinf(x) ((x) < -DBL_MAX || (x) > DBL_MAX)
|
||||
-#endif
|
||||
-#endif
|
||||
-
|
||||
-#ifndef HAVE_DECL_INFINITY
|
||||
-#include <float.h>
|
||||
-#define INFINITY (DBL_MAX + DBL_MAX)
|
||||
-#define HAVE_DECL_INFINITY
|
||||
-#endif
|
||||
-
|
||||
-#ifndef HAVE_DECL_NAN
|
||||
-#define NAN (INFINITY - INFINITY)
|
||||
-#define HAVE_DECL_NAN
|
||||
-#endif
|
||||
+#undef isnan
|
||||
+#define isnan(x) __builtin_isnan(x)
|
||||
+#undef isinf
|
||||
+#define isinf(x) __builtin_isinf(x)
|
||||
|
||||
#endif
|
||||
11
package/libs/libjson-c/patches/010-clang.patch
Normal file
11
package/libs/libjson-c/patches/010-clang.patch
Normal file
@ -0,0 +1,11 @@
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -265,7 +265,7 @@ message(STATUS "Wrote ${PROJECT_BINARY_D
|
||||
configure_file(${PROJECT_SOURCE_DIR}/cmake/json_config.h.in ${PROJECT_BINARY_DIR}/json_config.h)
|
||||
message(STATUS "Wrote ${PROJECT_BINARY_DIR}/json_config.h")
|
||||
|
||||
-if ("${CMAKE_C_COMPILER_ID}" STREQUAL "GNU")
|
||||
+if ("${CMAKE_C_COMPILER_ID}" STREQUAL "GNU" OR "${CMAKE_C_COMPILER_ID}" STREQUAL "Clang")
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -ffunction-sections -fdata-sections")
|
||||
if ("${DISABLE_WERROR}" STREQUAL "OFF")
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Werror")
|
||||
@ -9,9 +9,9 @@ PKG_RELEASE:=1
|
||||
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_SOURCE_URL=$(PROJECT_GIT)/project/firewall4.git
|
||||
PKG_SOURCE_DATE:=2021-03-31
|
||||
PKG_SOURCE_VERSION:=29fba840201287b9265888adba6298779b750af5
|
||||
PKG_MIRROR_HASH:=1d26a611aeecdf37f09e4cdee6b192e5da087abf6e0fc7a9ca97a80e58d14222
|
||||
PKG_SOURCE_DATE:=2021-09-01
|
||||
PKG_SOURCE_VERSION:=cf835cecc8a449b2d2019f1ef4f085e535d5c1c1
|
||||
PKG_MIRROR_HASH:=5798b76846107dde69a2a1ff3467f735b9a91a74106fbd6299d8a26eff70b9c2
|
||||
PKG_MAINTAINER:=Jo-Philipp Wich <jo@mein.io>
|
||||
PKG_LICENSE:=ISC
|
||||
|
||||
|
||||
@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=ethtool
|
||||
PKG_VERSION:=5.13
|
||||
PKG_RELEASE:=1
|
||||
PKG_RELEASE:=2
|
||||
|
||||
PKG_MAINTAINER:=Felix Fietkau <nbd@nbd.name>
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
|
||||
@ -31,6 +31,7 @@ define Package/ethtool
|
||||
TITLE:=Display or change ethernet card settings
|
||||
URL:=http://www.kernel.org/pub/software/network/ethtool/
|
||||
VARIANT:=tiny
|
||||
CONFLICTS:=ethtool-full
|
||||
endef
|
||||
|
||||
define Package/ethtool-full
|
||||
@ -39,6 +40,7 @@ define Package/ethtool-full
|
||||
VARIANT:=full
|
||||
PROVIDES:=ethtool
|
||||
DEPENDS:=+libmnl
|
||||
CONFLICTS:=
|
||||
endef
|
||||
|
||||
define Package/ethtool/description
|
||||
|
||||
@ -12,15 +12,19 @@ PKG_RELEASE:=1
|
||||
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_SOURCE_URL=https://github.com/jow-/ucode.git
|
||||
PKG_SOURCE_DATE:=2021-03-31
|
||||
PKG_SOURCE_VERSION:=973cc6c865dcf6075c493125313058b650b08234
|
||||
PKG_MIRROR_HASH:=fb4d3e231c79a9122743f0ced7fd4fdcf81903de5c721d3c18d5779e44d50bdf
|
||||
PKG_SOURCE_DATE:=2021-07-30
|
||||
PKG_SOURCE_VERSION:=929c8627cf077c3e348fb12b02553d4a444c5e48
|
||||
PKG_MIRROR_HASH:=
|
||||
PKG_MAINTAINER:=Jo-Philipp Wich <jo@mein.io>
|
||||
PKG_LICENSE:=ISC
|
||||
|
||||
PKG_ABI_VERSION:=20210730
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
include $(INCLUDE_DIR)/cmake.mk
|
||||
|
||||
CMAKE_OPTIONS += -DSOVERSION=$(PKG_ABI_VERSION)
|
||||
|
||||
define Package/ucode/default
|
||||
SECTION:=utils
|
||||
CATEGORY:=Utilities
|
||||
@ -29,7 +33,7 @@ endef
|
||||
|
||||
define Package/ucode
|
||||
$(Package/ucode/default)
|
||||
DEPENDS:=+libjson-c
|
||||
DEPENDS:=+libucode
|
||||
endef
|
||||
|
||||
define Package/ucode/description
|
||||
@ -38,6 +42,18 @@ define Package/ucode/description
|
||||
endef
|
||||
|
||||
|
||||
define Package/libucode
|
||||
$(Package/ucode/default)
|
||||
TITLE+= - runtime library
|
||||
ABI_VERSION:=$(PKG_ABI_VERSION)
|
||||
DEPENDS:=+libjson-c
|
||||
endef
|
||||
|
||||
define Package/libucode/description
|
||||
The libucode package provides the shared runtime library for the ucode interpreter.
|
||||
endef
|
||||
|
||||
|
||||
define Package/ucode-mod-fs
|
||||
$(Package/ucode/default)
|
||||
TITLE+= (filesystem module)
|
||||
@ -83,33 +99,46 @@ define Package/ucode-mod-uci/description
|
||||
endef
|
||||
|
||||
|
||||
define Build/InstallDev
|
||||
$(INSTALL_DIR) $(1)/usr/lib $(1)/usr/include/ucode
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/include/ucode/*.h $(1)/usr/include/ucode/
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libucode.so* $(1)/usr/lib/
|
||||
endef
|
||||
|
||||
|
||||
define Package/ucode/install
|
||||
$(INSTALL_DIR) $(1)/usr/bin
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/ucode $(1)/usr/bin/ucode
|
||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/ucode $(1)/usr/bin/ucode
|
||||
endef
|
||||
|
||||
define Package/libucode/install
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libucode.so.* $(1)/usr/lib/
|
||||
endef
|
||||
|
||||
define Package/ucode-mod-fs/install
|
||||
$(INSTALL_DIR) $(1)/usr/lib/ucode
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/lib/fs.so $(1)/usr/lib/ucode/
|
||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/ucode/fs.so $(1)/usr/lib/ucode/
|
||||
endef
|
||||
|
||||
define Package/ucode-mod-math/install
|
||||
$(INSTALL_DIR) $(1)/usr/lib/ucode
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/lib/math.so $(1)/usr/lib/ucode/
|
||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/ucode/math.so $(1)/usr/lib/ucode/
|
||||
endef
|
||||
|
||||
define Package/ucode-mod-ubus/install
|
||||
$(INSTALL_DIR) $(1)/usr/lib/ucode
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/lib/ubus.so $(1)/usr/lib/ucode/
|
||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/ucode/ubus.so $(1)/usr/lib/ucode/
|
||||
endef
|
||||
|
||||
define Package/ucode-mod-uci/install
|
||||
$(INSTALL_DIR) $(1)/usr/lib/ucode
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/lib/uci.so $(1)/usr/lib/ucode/
|
||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/ucode/uci.so $(1)/usr/lib/ucode/
|
||||
endef
|
||||
|
||||
|
||||
$(eval $(call BuildPackage,ucode))
|
||||
$(eval $(call BuildPackage,libucode))
|
||||
$(eval $(call BuildPackage,ucode-mod-fs))
|
||||
$(eval $(call BuildPackage,ucode-mod-math))
|
||||
$(eval $(call BuildPackage,ucode-mod-ubus))
|
||||
|
||||
@ -286,7 +286,7 @@ foreach my $mirror (@ARGV) {
|
||||
|
||||
push @mirrors, "https://mirror01.download.immortalwrt.eu.org";
|
||||
push @mirrors, "https://mirror02.download.immortalwrt.eu.org";
|
||||
push @mirrors, "https://openwrt.cc/dl/immortalwrt/openwrt-18.06";
|
||||
push @mirrors, "https://openwrt.cc/dl/immortalwrt/immortalwrt";
|
||||
push @mirrors, 'https://sources.cdn.openwrt.org';
|
||||
push @mirrors, 'https://sources.openwrt.org';
|
||||
push @mirrors, 'https://mirror2.openwrt.org/sources';
|
||||
|
||||
Loading…
Reference in New Issue
Block a user