Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
This commit is contained in:
commit
6a95ba90e6
@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
|
|||||||
|
|
||||||
PKG_NAME:=json-c
|
PKG_NAME:=json-c
|
||||||
PKG_VERSION:=0.16
|
PKG_VERSION:=0.16
|
||||||
PKG_RELEASE:=2
|
PKG_RELEASE:=3
|
||||||
|
|
||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-nodoc.tar.gz
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-nodoc.tar.gz
|
||||||
PKG_SOURCE_URL:=https://s3.amazonaws.com/json-c_releases/releases/
|
PKG_SOURCE_URL:=https://s3.amazonaws.com/json-c_releases/releases/
|
||||||
|
|||||||
184
package/libs/libjson-c/patches/010-fix-build-with-clang-15.patch
Normal file
184
package/libs/libjson-c/patches/010-fix-build-with-clang-15.patch
Normal file
@ -0,0 +1,184 @@
|
|||||||
|
From 6eca65617aacd19f4928acd5766b8dd20eda0b34 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Khem Raj <raj.khem@gmail.com>
|
||||||
|
Date: Sat, 13 Aug 2022 20:37:03 -0700
|
||||||
|
Subject: [PATCH] Fix build with clang-15+
|
||||||
|
|
||||||
|
Fixes
|
||||||
|
json_util.c:63:35: error: a function declaration without a prototype is deprecated in all versions of C [-We
|
||||||
|
rror,-Wstrict-prototypes]
|
||||||
|
const char *json_util_get_last_err()
|
||||||
|
^
|
||||||
|
void
|
||||||
|
|
||||||
|
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
||||||
|
---
|
||||||
|
json_util.c | 2 +-
|
||||||
|
tests/test1.c | 6 +++---
|
||||||
|
tests/test4.c | 2 +-
|
||||||
|
tests/test_cast.c | 2 +-
|
||||||
|
tests/test_charcase.c | 2 +-
|
||||||
|
tests/test_parse.c | 8 ++++----
|
||||||
|
tests/test_printbuf.c | 4 ++--
|
||||||
|
tests/test_util_file.c | 6 +++---
|
||||||
|
8 files changed, 16 insertions(+), 16 deletions(-)
|
||||||
|
|
||||||
|
--- a/json_util.c
|
||||||
|
+++ b/json_util.c
|
||||||
|
@@ -60,7 +60,7 @@ static int _json_object_to_fd(int fd, st
|
||||||
|
|
||||||
|
static char _last_err[256] = "";
|
||||||
|
|
||||||
|
-const char *json_util_get_last_err()
|
||||||
|
+const char *json_util_get_last_err(void)
|
||||||
|
{
|
||||||
|
if (_last_err[0] == '\0')
|
||||||
|
return NULL;
|
||||||
|
--- a/tests/test1.c
|
||||||
|
+++ b/tests/test1.c
|
||||||
|
@@ -58,7 +58,7 @@ static const char *to_json_string(json_o
|
||||||
|
#endif
|
||||||
|
|
||||||
|
json_object *make_array(void);
|
||||||
|
-json_object *make_array()
|
||||||
|
+json_object *make_array(void)
|
||||||
|
{
|
||||||
|
json_object *my_array;
|
||||||
|
|
||||||
|
@@ -74,7 +74,7 @@ json_object *make_array()
|
||||||
|
}
|
||||||
|
|
||||||
|
void test_array_del_idx(void);
|
||||||
|
-void test_array_del_idx()
|
||||||
|
+void test_array_del_idx(void)
|
||||||
|
{
|
||||||
|
int rc;
|
||||||
|
size_t ii;
|
||||||
|
@@ -140,7 +140,7 @@ void test_array_del_idx()
|
||||||
|
}
|
||||||
|
|
||||||
|
void test_array_list_expand_internal(void);
|
||||||
|
-void test_array_list_expand_internal()
|
||||||
|
+void test_array_list_expand_internal(void)
|
||||||
|
{
|
||||||
|
int rc;
|
||||||
|
size_t ii;
|
||||||
|
--- a/tests/test4.c
|
||||||
|
+++ b/tests/test4.c
|
||||||
|
@@ -28,7 +28,7 @@ void print_hex(const char *s)
|
||||||
|
}
|
||||||
|
|
||||||
|
static void test_lot_of_adds(void);
|
||||||
|
-static void test_lot_of_adds()
|
||||||
|
+static void test_lot_of_adds(void)
|
||||||
|
{
|
||||||
|
int ii;
|
||||||
|
char key[50];
|
||||||
|
--- a/tests/test_cast.c
|
||||||
|
+++ b/tests/test_cast.c
|
||||||
|
@@ -94,7 +94,7 @@ static void getit(struct json_object *ne
|
||||||
|
printf("new_obj.%s json_object_get_double()=%f\n", field, json_object_get_double(o));
|
||||||
|
}
|
||||||
|
|
||||||
|
-static void checktype_header()
|
||||||
|
+static void checktype_header(void)
|
||||||
|
{
|
||||||
|
printf("json_object_is_type: %s,%s,%s,%s,%s,%s,%s\n", json_type_to_name(json_type_null),
|
||||||
|
json_type_to_name(json_type_boolean), json_type_to_name(json_type_double),
|
||||||
|
--- a/tests/test_charcase.c
|
||||||
|
+++ b/tests/test_charcase.c
|
||||||
|
@@ -19,7 +19,7 @@ int main(int argc, char **argv)
|
||||||
|
}
|
||||||
|
|
||||||
|
/* make sure only lowercase forms are parsed in strict mode */
|
||||||
|
-static void test_case_parse()
|
||||||
|
+static void test_case_parse(void)
|
||||||
|
{
|
||||||
|
struct json_tokener *tok;
|
||||||
|
json_object *new_obj;
|
||||||
|
--- a/tests/test_parse.c
|
||||||
|
+++ b/tests/test_parse.c
|
||||||
|
@@ -92,7 +92,7 @@ static void single_basic_parse(const cha
|
||||||
|
if (getenv("TEST_PARSE_CHUNKSIZE") != NULL)
|
||||||
|
single_incremental_parse(test_string, clear_serializer);
|
||||||
|
}
|
||||||
|
-static void test_basic_parse()
|
||||||
|
+static void test_basic_parse(void)
|
||||||
|
{
|
||||||
|
single_basic_parse("\"\003\"", 0);
|
||||||
|
single_basic_parse("/* hello */\"foo\"", 0);
|
||||||
|
@@ -195,7 +195,7 @@ static void test_basic_parse()
|
||||||
|
single_basic_parse("[18446744073709551616]", 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
-static void test_utf8_parse()
|
||||||
|
+static void test_utf8_parse(void)
|
||||||
|
{
|
||||||
|
// json_tokener_parse doesn't support checking for byte order marks.
|
||||||
|
// It's the responsibility of the caller to detect and skip a BOM.
|
||||||
|
@@ -222,7 +222,7 @@ static int clear_serializer(json_object
|
||||||
|
return JSON_C_VISIT_RETURN_CONTINUE;
|
||||||
|
}
|
||||||
|
|
||||||
|
-static void test_verbose_parse()
|
||||||
|
+static void test_verbose_parse(void)
|
||||||
|
{
|
||||||
|
json_object *new_obj;
|
||||||
|
enum json_tokener_error error = json_tokener_success;
|
||||||
|
@@ -562,7 +562,7 @@ struct incremental_step
|
||||||
|
{NULL, -1, -1, json_tokener_success, 0},
|
||||||
|
};
|
||||||
|
|
||||||
|
-static void test_incremental_parse()
|
||||||
|
+static void test_incremental_parse(void)
|
||||||
|
{
|
||||||
|
json_object *new_obj;
|
||||||
|
enum json_tokener_error jerr;
|
||||||
|
--- a/tests/test_printbuf.c
|
||||||
|
+++ b/tests/test_printbuf.c
|
||||||
|
@@ -16,7 +16,7 @@ static void test_printbuf_memset_length(
|
||||||
|
#define __func__ __FUNCTION__
|
||||||
|
#endif
|
||||||
|
|
||||||
|
-static void test_basic_printbuf_memset()
|
||||||
|
+static void test_basic_printbuf_memset(void)
|
||||||
|
{
|
||||||
|
struct printbuf *pb;
|
||||||
|
|
||||||
|
@@ -29,7 +29,7 @@ static void test_basic_printbuf_memset()
|
||||||
|
printf("%s: end test\n", __func__);
|
||||||
|
}
|
||||||
|
|
||||||
|
-static void test_printbuf_memset_length()
|
||||||
|
+static void test_printbuf_memset_length(void)
|
||||||
|
{
|
||||||
|
struct printbuf *pb;
|
||||||
|
|
||||||
|
--- a/tests/test_util_file.c
|
||||||
|
+++ b/tests/test_util_file.c
|
||||||
|
@@ -35,7 +35,7 @@ static void test_read_fd_equal(const cha
|
||||||
|
#define PATH_MAX 256
|
||||||
|
#endif
|
||||||
|
|
||||||
|
-static void test_write_to_file()
|
||||||
|
+static void test_write_to_file(void)
|
||||||
|
{
|
||||||
|
json_object *jso;
|
||||||
|
|
||||||
|
@@ -231,7 +231,7 @@ static void test_read_valid_nested_with_
|
||||||
|
close(d);
|
||||||
|
}
|
||||||
|
|
||||||
|
-static void test_read_nonexistant()
|
||||||
|
+static void test_read_nonexistant(void)
|
||||||
|
{
|
||||||
|
const char *filename = "./not_present.json";
|
||||||
|
|
||||||
|
@@ -249,7 +249,7 @@ static void test_read_nonexistant()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
-static void test_read_closed()
|
||||||
|
+static void test_read_closed(void)
|
||||||
|
{
|
||||||
|
// Test reading from a closed fd
|
||||||
|
int d = open("/dev/null", O_RDONLY, 0);
|
||||||
@ -8,12 +8,12 @@
|
|||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=f2fs-tools
|
PKG_NAME:=f2fs-tools
|
||||||
PKG_VERSION:=1.15.0
|
PKG_VERSION:=1.16.0
|
||||||
PKG_RELEASE:=2
|
PKG_RELEASE:=1
|
||||||
|
|
||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||||
PKG_SOURCE_URL:=https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs-tools.git/snapshot/
|
PKG_SOURCE_URL:=https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs-tools.git/snapshot/
|
||||||
PKG_HASH:=147d471040b44900283ce2c935f1d35d13d7f40008e7cb8fab2b69f54da01a4f
|
PKG_HASH:=208c7a07e95383fbd7b466b5681590789dcb41f41bf197369c41a95383b57c5e
|
||||||
|
|
||||||
PKG_MAINTAINER:=Felix Fietkau <nbd@nbd.name>
|
PKG_MAINTAINER:=Felix Fietkau <nbd@nbd.name>
|
||||||
PKG_LICENSE:=GPL-2.0-only
|
PKG_LICENSE:=GPL-2.0-only
|
||||||
@ -143,7 +143,6 @@ Package/f2fsck-selinux/install = $(Package/f2fsck/install)
|
|||||||
|
|
||||||
define Package/f2fs-tools/install
|
define Package/f2fs-tools/install
|
||||||
$(INSTALL_DIR) $(1)/usr/sbin
|
$(INSTALL_DIR) $(1)/usr/sbin
|
||||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/f2fstat $(1)/usr/sbin
|
|
||||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/fibmap.f2fs $(1)/usr/sbin
|
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/fibmap.f2fs $(1)/usr/sbin
|
||||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/parse.f2fs $(1)/usr/sbin
|
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/parse.f2fs $(1)/usr/sbin
|
||||||
endef
|
endef
|
||||||
|
|||||||
@ -1,88 +0,0 @@
|
|||||||
From 9af8ee5baceab59d46154c96da62b52935f363fe Mon Sep 17 00:00:00 2001
|
|
||||||
From: Nick Hainke <vincent@systemli.org>
|
|
||||||
Date: Mon, 27 Jun 2022 20:43:11 +0200
|
|
||||||
Subject: [PATCH] configure.ac: fix AC_ARG_WITH
|
|
||||||
|
|
||||||
In the new version the configuration no longer respects the
|
|
||||||
--without/--with blkid/selinux parameters. Add the tests for
|
|
||||||
"with_blkid" and "with_selinux" back to configure.ac as described
|
|
||||||
in the manual.
|
|
||||||
|
|
||||||
Link: https://www.gnu.org/software/autoconf/manual/autoconf-2.60/html_node/External-Software.html
|
|
||||||
|
|
||||||
Fixes: c48335416a09 ("configure.ac: Enable cross-compilation")
|
|
||||||
|
|
||||||
Signed-off-by: Nick Hainke <vincent@systemli.org>
|
|
||||||
---
|
|
||||||
configure.ac | 44 ++++++++++++++++++++++++++++++--------------
|
|
||||||
1 file changed, 30 insertions(+), 14 deletions(-)
|
|
||||||
|
|
||||||
--- a/configure.ac
|
|
||||||
+++ b/configure.ac
|
|
||||||
@@ -39,12 +39,16 @@ AM_INIT_AUTOMAKE([-Wall -Werror foreign
|
|
||||||
|
|
||||||
# Test configure options.
|
|
||||||
AC_ARG_WITH([selinux],
|
|
||||||
- AS_HELP_STRING([--without-selinux],
|
|
||||||
- [Ignore presence of libselinux and disable selinux support]))
|
|
||||||
+ [AS_HELP_STRING([--without-selinux],
|
|
||||||
+ [Ignore presence of libselinux and disable selinux support])],
|
|
||||||
+ [],
|
|
||||||
+ [with_selinux=check])
|
|
||||||
|
|
||||||
AC_ARG_WITH([blkid],
|
|
||||||
- AS_HELP_STRING([--without-blkid],
|
|
||||||
- [Ignore presence of libblkid and disable blkid support]))
|
|
||||||
+ [AS_HELP_STRING([--without-blkid],
|
|
||||||
+ [Ignore presence of libblkid and disable blkid support])],
|
|
||||||
+ [],
|
|
||||||
+ [with_blkid=check])
|
|
||||||
|
|
||||||
# Checks for programs.
|
|
||||||
AC_PROG_CC
|
|
||||||
@@ -55,11 +59,17 @@ AC_PATH_PROG([LDCONFIG], [ldconfig],
|
|
||||||
[$PATH:/sbin])
|
|
||||||
|
|
||||||
# Checks for libraries.
|
|
||||||
-AC_CHECK_LIB([blkid], [blkid_probe_all],
|
|
||||||
- [AC_SUBST([libblkid_LIBS], ["-lblkid"])
|
|
||||||
- AC_DEFINE([HAVE_LIBBLKID], [1],
|
|
||||||
- [Define if you have libblkid])
|
|
||||||
- ], [], [])
|
|
||||||
+AS_IF([test "x$with_blkid" != xno],
|
|
||||||
+ [AC_CHECK_LIB([blkid], [blkid_probe_all],
|
|
||||||
+ [AC_SUBST([libblkid_LIBS], ["-lblkid"])
|
|
||||||
+ AC_DEFINE([HAVE_LIBBLKID], [1],
|
|
||||||
+ [Define if you have libblkid])
|
|
||||||
+ ],
|
|
||||||
+ [if test "x$with_blkid" != xcheck; then
|
|
||||||
+ AC_MSG_FAILURE(
|
|
||||||
+ [--with-blkid was given, but test for blkid failed])
|
|
||||||
+ fi
|
|
||||||
+ ], -lblkid)])
|
|
||||||
|
|
||||||
AC_CHECK_LIB([lzo2], [main],
|
|
||||||
[AC_SUBST([liblzo2_LIBS], ["-llzo2"])
|
|
||||||
@@ -73,11 +83,17 @@ AC_CHECK_LIB([lz4], [main],
|
|
||||||
[Define if you have liblz4])
|
|
||||||
], [], [])
|
|
||||||
|
|
||||||
-AC_CHECK_LIB([selinux], [getcon],
|
|
||||||
- [AC_SUBST([libselinux_LIBS], ["-lselinux"])
|
|
||||||
- AC_DEFINE([HAVE_LIBSELINUX], [1],
|
|
||||||
- [Define if you have libselinux])
|
|
||||||
- ], [], [])
|
|
||||||
+AS_IF([test "x$with_selinux" != xno],
|
|
||||||
+ [AC_CHECK_LIB([selinux], [getcon],
|
|
||||||
+ [AC_SUBST([libselinux_LIBS], ["-lselinux"])
|
|
||||||
+ AC_DEFINE([HAVE_LIBSELINUX], [1],
|
|
||||||
+ [Define if you have libselinux])
|
|
||||||
+ ],
|
|
||||||
+ [if test "x$with_selinux" != xcheck; then
|
|
||||||
+ AC_MSG_FAILURE(
|
|
||||||
+ [--with-selinux was given, but test for selinux failed])
|
|
||||||
+ fi
|
|
||||||
+ ], -lselinux)])
|
|
||||||
|
|
||||||
AC_CHECK_LIB([uuid], [uuid_clear],
|
|
||||||
[AC_SUBST([libuuid_LIBS], ["-luuid"])
|
|
||||||
@ -1,80 +0,0 @@
|
|||||||
From 821a1d3fcce31c234512a8f4dc4fc97dfbd7ae32 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Nick Hainke <vincent@systemli.org>
|
|
||||||
Date: Mon, 4 Jul 2022 09:46:10 +0200
|
|
||||||
Subject: [PATCH] configure.ac: fix cross compilation
|
|
||||||
|
|
||||||
AC_CHECK_LIB seems to not work correctly with OpenWrt. Add possibility
|
|
||||||
to disable lz4 and lzo2 manually.
|
|
||||||
|
|
||||||
Fixes errors in the form of:
|
|
||||||
Package f2fsck is missing dependencies for the following libraries:
|
|
||||||
liblz4.so.1
|
|
||||||
liblzo2.so.2
|
|
||||||
|
|
||||||
Signed-off-by: Nick Hainke <vincent@systemli.org>
|
|
||||||
---
|
|
||||||
configure.ac | 44 ++++++++++++++++++++++++++++++++++----------
|
|
||||||
1 file changed, 34 insertions(+), 10 deletions(-)
|
|
||||||
|
|
||||||
--- a/configure.ac
|
|
||||||
+++ b/configure.ac
|
|
||||||
@@ -50,6 +50,18 @@ AC_ARG_WITH([blkid],
|
|
||||||
[],
|
|
||||||
[with_blkid=check])
|
|
||||||
|
|
||||||
+AC_ARG_WITH([lzo2],
|
|
||||||
+ [AS_HELP_STRING([--without-lzo2],
|
|
||||||
+ [Ignore presence of liblzo2 and disable lzo2 support])],
|
|
||||||
+ [],
|
|
||||||
+ [with_lzo2=check])
|
|
||||||
+
|
|
||||||
+AC_ARG_WITH([lz4],
|
|
||||||
+ [AS_HELP_STRING([--without-lz4],
|
|
||||||
+ [Ignore presence of liblz4 and disable lz4 support])],
|
|
||||||
+ [],
|
|
||||||
+ [with_lz4=check])
|
|
||||||
+
|
|
||||||
# Checks for programs.
|
|
||||||
AC_PROG_CC
|
|
||||||
AM_PROG_AR
|
|
||||||
@@ -71,17 +83,29 @@ AS_IF([test "x$with_blkid" != xno],
|
|
||||||
fi
|
|
||||||
], -lblkid)])
|
|
||||||
|
|
||||||
-AC_CHECK_LIB([lzo2], [main],
|
|
||||||
- [AC_SUBST([liblzo2_LIBS], ["-llzo2"])
|
|
||||||
- AC_DEFINE([HAVE_LIBLZO2], [1],
|
|
||||||
- [Define if you have liblzo2])
|
|
||||||
- ], [], [])
|
|
||||||
-
|
|
||||||
-AC_CHECK_LIB([lz4], [main],
|
|
||||||
- [AC_SUBST([liblz4_LIBS], ["-llz4"])
|
|
||||||
- AC_DEFINE([HAVE_LIBLZ4], [1],
|
|
||||||
- [Define if you have liblz4])
|
|
||||||
- ], [], [])
|
|
||||||
+AS_IF([test "x$with_lzo2" != xno],
|
|
||||||
+ [AC_CHECK_LIB([lzo2], [main],
|
|
||||||
+ [AC_SUBST([liblzo2_LIBS], ["-llzo2"])
|
|
||||||
+ AC_DEFINE([HAVE_LIBLZO2], [1],
|
|
||||||
+ [Define if you have liblzo2])
|
|
||||||
+ ],
|
|
||||||
+ [if test "x$with_lzo2" != xcheck; then
|
|
||||||
+ AC_MSG_FAILURE(
|
|
||||||
+ [--with-lzo2 was given, but test for lzo2 failed])
|
|
||||||
+ fi
|
|
||||||
+ ], -llzo2)])
|
|
||||||
+
|
|
||||||
+AS_IF([test "x$with_lz4" != xno],
|
|
||||||
+ [AC_CHECK_LIB([lz4], [main],
|
|
||||||
+ [AC_SUBST([liblz4_LIBS], ["-llz4"])
|
|
||||||
+ AC_DEFINE([HAVE_LIBLZ4], [1],
|
|
||||||
+ [Define if you have liblz4])
|
|
||||||
+ ],
|
|
||||||
+ [if test "x$with_lz4" != xcheck; then
|
|
||||||
+ AC_MSG_FAILURE(
|
|
||||||
+ [--with-lz4 was given, but test for lz4 failed])
|
|
||||||
+ fi
|
|
||||||
+ ], -llz4)])
|
|
||||||
|
|
||||||
AS_IF([test "x$with_selinux" != xno],
|
|
||||||
[AC_CHECK_LIB([selinux], [getcon],
|
|
||||||
@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
|
|||||||
|
|
||||||
PKG_NAME:=util-linux
|
PKG_NAME:=util-linux
|
||||||
PKG_VERSION:=2.39
|
PKG_VERSION:=2.39
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=2
|
||||||
|
|
||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
|
||||||
PKG_SOURCE_URL:=@KERNEL/linux/utils/$(PKG_NAME)/v2.39
|
PKG_SOURCE_URL:=@KERNEL/linux/utils/$(PKG_NAME)/v2.39
|
||||||
@ -485,6 +485,7 @@ endef
|
|||||||
define Package/taskset
|
define Package/taskset
|
||||||
$(call Package/util-linux/Default)
|
$(call Package/util-linux/Default)
|
||||||
TITLE:=set or retrieve a process's CPU affinity
|
TITLE:=set or retrieve a process's CPU affinity
|
||||||
|
ALTERNATIVES:=200:/usr/bin/taskset:/usr/bin/util-linux-taskset
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/taskset/description
|
define Package/taskset/description
|
||||||
@ -851,7 +852,7 @@ endef
|
|||||||
|
|
||||||
define Package/taskset/install
|
define Package/taskset/install
|
||||||
$(INSTALL_DIR) $(1)/usr/bin
|
$(INSTALL_DIR) $(1)/usr/bin
|
||||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/taskset $(1)/usr/bin/
|
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/taskset $(1)/usr/bin/util-linux-taskset
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/unshare/install
|
define Package/unshare/install
|
||||||
|
|||||||
@ -1,24 +1,36 @@
|
|||||||
From 2558932c65524d953e4c86d7fda2282a582aa5ec Mon Sep 17 00:00:00 2001
|
From 2558932c65524d953e4c86d7fda2282a582aa5ec Mon Sep 17 00:00:00 2001
|
||||||
From: =?UTF-8?q?Thomas=20Wei=C3=9Fschuh?= <thomas@t-8ch.de>
|
From: =?UTF-8?q?Thomas=20Wei=C3=9Fschuh?= <thomas@t-8ch.de>
|
||||||
Date: Wed, 17 May 2023 16:50:47 +0200
|
Date: Wed, 17 May 2023 16:50:47 +0200
|
||||||
Subject: [PATCH] test_enosys: add support for mips
|
Subject: [PATCH] test_enosys: add support for mips, powerpc and arc
|
||||||
MIME-Version: 1.0
|
MIME-Version: 1.0
|
||||||
Content-Type: text/plain; charset=UTF-8
|
Content-Type: text/plain; charset=UTF-8
|
||||||
Content-Transfer-Encoding: 8bit
|
Content-Transfer-Encoding: 8bit
|
||||||
|
|
||||||
Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
|
Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
|
||||||
---
|
---
|
||||||
tests/helpers/test_enosys.c | 2 ++
|
tests/helpers/test_enosys.c | 14 ++
|
||||||
1 file changed, 2 insertions(+)
|
1 file changed, 2 insertions(+)
|
||||||
|
|
||||||
--- a/tests/helpers/test_enosys.c
|
--- a/tests/helpers/test_enosys.c
|
||||||
+++ b/tests/helpers/test_enosys.c
|
+++ b/tests/helpers/test_enosys.c
|
||||||
@@ -53,6 +53,8 @@
|
@@ -53,6 +53,20 @@
|
||||||
# else
|
# else
|
||||||
# define SECCOMP_ARCH_NATIVE AUDIT_ARCH_PPC64LE
|
# define SECCOMP_ARCH_NATIVE AUDIT_ARCH_PPC64LE
|
||||||
# endif
|
# endif
|
||||||
|
+#elif __powerpc__
|
||||||
|
+# define SECCOMP_ARCH_NATIVE AUDIT_ARCH_PPC
|
||||||
+#elif __mips__
|
+#elif __mips__
|
||||||
|
+# if __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||||
+# define SECCOMP_ARCH_NATIVE AUDIT_ARCH_MIPS
|
+# define SECCOMP_ARCH_NATIVE AUDIT_ARCH_MIPS
|
||||||
|
+# else
|
||||||
|
+# define SECCOMP_ARCH_NATIVE AUDIT_ARCH_MIPSEL
|
||||||
|
+# endif
|
||||||
|
+#elif __arc__
|
||||||
|
+# if __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||||
|
+# define SECCOMP_ARCH_NATIVE AUDIT_ARCH_ARCV2BE
|
||||||
|
+# else
|
||||||
|
+# define SECCOMP_ARCH_NATIVE AUDIT_ARCH_ARCV2
|
||||||
|
+# endif
|
||||||
#else
|
#else
|
||||||
# error Unknown target architecture
|
# error Unknown target architecture
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@ -1,14 +0,0 @@
|
|||||||
--- a/lib/randutils.c
|
|
||||||
+++ b/lib/randutils.c
|
|
||||||
@@ -26,6 +26,11 @@
|
|
||||||
#define THREAD_LOCAL static
|
|
||||||
#endif
|
|
||||||
|
|
||||||
+/* force /dev/urandom to avoid hanging on early boot */
|
|
||||||
+#undef HAVE_GETRANDOM
|
|
||||||
+#undef SYS_getrandom
|
|
||||||
+#undef __NR_getrandom
|
|
||||||
+
|
|
||||||
#ifdef HAVE_GETRANDOM
|
|
||||||
# include <sys/random.h>
|
|
||||||
#elif defined (__linux__)
|
|
||||||
@ -33,7 +33,7 @@
|
|||||||
+obj-$(CONFIG_NET_AR231X) += ar231x.o
|
+obj-$(CONFIG_NET_AR231X) += ar231x.o
|
||||||
--- /dev/null
|
--- /dev/null
|
||||||
+++ b/drivers/net/ethernet/atheros/ar231x/ar231x.c
|
+++ b/drivers/net/ethernet/atheros/ar231x/ar231x.c
|
||||||
@@ -0,0 +1,1119 @@
|
@@ -0,0 +1,1117 @@
|
||||||
+/*
|
+/*
|
||||||
+ * ar231x.c: Linux driver for the Atheros AR231x Ethernet device.
|
+ * ar231x.c: Linux driver for the Atheros AR231x Ethernet device.
|
||||||
+ *
|
+ *
|
||||||
@ -156,8 +156,6 @@
|
|||||||
+MODULE_DESCRIPTION("AR231x Ethernet driver");
|
+MODULE_DESCRIPTION("AR231x Ethernet driver");
|
||||||
+#endif
|
+#endif
|
||||||
+
|
+
|
||||||
+#define virt_to_phys(x) ((u32)(x) & 0x1fffffff)
|
|
||||||
+
|
|
||||||
+/* prototypes */
|
+/* prototypes */
|
||||||
+static void ar231x_halt(struct net_device *dev);
|
+static void ar231x_halt(struct net_device *dev);
|
||||||
+static void rx_tasklet_func(unsigned long data);
|
+static void rx_tasklet_func(unsigned long data);
|
||||||
|
|||||||
@ -350,13 +350,13 @@
|
|||||||
+ switch (read_len) {
|
+ switch (read_len) {
|
||||||
+ case 4:
|
+ case 4:
|
||||||
+ spi_data |= buf[3] << 24;
|
+ spi_data |= buf[3] << 24;
|
||||||
+ /* fall through */
|
+ fallthrough;
|
||||||
+ case 3:
|
+ case 3:
|
||||||
+ spi_data |= buf[2] << 16;
|
+ spi_data |= buf[2] << 16;
|
||||||
+ /* fall through */
|
+ fallthrough;
|
||||||
+ case 2:
|
+ case 2:
|
||||||
+ spi_data |= buf[1] << 8;
|
+ spi_data |= buf[1] << 8;
|
||||||
+ /* fall through */
|
+ fallthrough;
|
||||||
+ case 1:
|
+ case 1:
|
||||||
+ spi_data |= buf[0] & 0xff;
|
+ spi_data |= buf[0] & 0xff;
|
||||||
+ break;
|
+ break;
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
--- a/drivers/net/ethernet/atheros/ar231x/ar231x.c
|
--- a/drivers/net/ethernet/atheros/ar231x/ar231x.c
|
||||||
+++ b/drivers/net/ethernet/atheros/ar231x/ar231x.c
|
+++ b/drivers/net/ethernet/atheros/ar231x/ar231x.c
|
||||||
@@ -135,6 +135,7 @@ static int ar231x_mdiobus_write(struct m
|
@@ -133,6 +133,7 @@ static int ar231x_mdiobus_write(struct m
|
||||||
static int ar231x_mdiobus_reset(struct mii_bus *bus);
|
static int ar231x_mdiobus_reset(struct mii_bus *bus);
|
||||||
static int ar231x_mdiobus_probe(struct net_device *dev);
|
static int ar231x_mdiobus_probe(struct net_device *dev);
|
||||||
static void ar231x_adjust_link(struct net_device *dev);
|
static void ar231x_adjust_link(struct net_device *dev);
|
||||||
@ -8,7 +8,7 @@
|
|||||||
|
|
||||||
#ifndef ERR
|
#ifndef ERR
|
||||||
#define ERR(fmt, args...) printk("%s: " fmt, __func__, ##args)
|
#define ERR(fmt, args...) printk("%s: " fmt, __func__, ##args)
|
||||||
@@ -166,6 +167,32 @@ static const struct net_device_ops ar231
|
@@ -164,6 +165,32 @@ static const struct net_device_ops ar231
|
||||||
#endif
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -41,7 +41,7 @@
|
|||||||
static int ar231x_probe(struct platform_device *pdev)
|
static int ar231x_probe(struct platform_device *pdev)
|
||||||
{
|
{
|
||||||
struct net_device *dev;
|
struct net_device *dev;
|
||||||
@@ -273,6 +300,24 @@ static int ar231x_probe(struct platform_
|
@@ -271,6 +298,24 @@ static int ar231x_probe(struct platform_
|
||||||
|
|
||||||
mdiobus_register(sp->mii_bus);
|
mdiobus_register(sp->mii_bus);
|
||||||
|
|
||||||
@ -66,7 +66,7 @@
|
|||||||
if (ar231x_mdiobus_probe(dev) != 0) {
|
if (ar231x_mdiobus_probe(dev) != 0) {
|
||||||
printk(KERN_ERR "%s: mdiobus_probe failed\n", dev->name);
|
printk(KERN_ERR "%s: mdiobus_probe failed\n", dev->name);
|
||||||
rx_tasklet_cleanup(dev);
|
rx_tasklet_cleanup(dev);
|
||||||
@@ -326,8 +371,10 @@ static int ar231x_remove(struct platform
|
@@ -324,8 +369,10 @@ static int ar231x_remove(struct platform
|
||||||
rx_tasklet_cleanup(dev);
|
rx_tasklet_cleanup(dev);
|
||||||
ar231x_init_cleanup(dev);
|
ar231x_init_cleanup(dev);
|
||||||
unregister_netdev(dev);
|
unregister_netdev(dev);
|
||||||
@ -79,7 +79,7 @@
|
|||||||
kfree(dev);
|
kfree(dev);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
@@ -870,7 +917,8 @@ static int ar231x_open(struct net_device
|
@@ -868,7 +915,8 @@ static int ar231x_open(struct net_device
|
||||||
|
|
||||||
sp->eth_regs->mac_control |= MAC_CONTROL_RE;
|
sp->eth_regs->mac_control |= MAC_CONTROL_RE;
|
||||||
|
|
||||||
@ -89,7 +89,7 @@
|
|||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
@@ -951,7 +999,8 @@ static int ar231x_close(struct net_devic
|
@@ -949,7 +997,8 @@ static int ar231x_close(struct net_devic
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@ -99,7 +99,7 @@
|
|||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
@@ -995,6 +1044,9 @@ static int ar231x_ioctl(struct net_devic
|
@@ -993,6 +1042,9 @@ static int ar231x_ioctl(struct net_devic
|
||||||
{
|
{
|
||||||
struct ar231x_private *sp = netdev_priv(dev);
|
struct ar231x_private *sp = netdev_priv(dev);
|
||||||
|
|
||||||
|
|||||||
@ -58,9 +58,12 @@ metadata_gl_json = \
|
|||||||
|
|
||||||
define Build/append-gl-metadata
|
define Build/append-gl-metadata
|
||||||
$(if $(SUPPORTED_DEVICES),-echo $(call metadata_gl_json,$(SUPPORTED_DEVICES)) | fwtool -I - $@)
|
$(if $(SUPPORTED_DEVICES),-echo $(call metadata_gl_json,$(SUPPORTED_DEVICES)) | fwtool -I - $@)
|
||||||
[ ! -s "$(BUILD_KEY)" -o ! -s "$@" ] || { \
|
sha256sum "$@" | cut -d" " -f1 > "$@.sha256sum"
|
||||||
|
[ ! -s "$(BUILD_KEY)" -o ! -s "$(BUILD_KEY).ucert" -o ! -s "$@" ] || { \
|
||||||
|
cp "$(BUILD_KEY).ucert" "$@.ucert" ;\
|
||||||
usign -S -m "$@" -s "$(BUILD_KEY)" -x "$@.sig" ;\
|
usign -S -m "$@" -s "$(BUILD_KEY)" -x "$@.sig" ;\
|
||||||
fwtool -S "$@.sig" "$@" ;\
|
ucert -A -c "$@.ucert" -x "$@.sig" ;\
|
||||||
|
fwtool -S "$@.ucert" "$@" ;\
|
||||||
}
|
}
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
|||||||
@ -15,7 +15,7 @@ define Device/airlink101_ar670w
|
|||||||
DEVICE_VENDOR := Airlink
|
DEVICE_VENDOR := Airlink
|
||||||
DEVICE_MODEL := AR670W
|
DEVICE_MODEL := AR670W
|
||||||
IMAGE_SIZE := 3840k
|
IMAGE_SIZE := 3840k
|
||||||
KERNEL := $(KERNEL_DTB) | pad-to $$$$(BLOCKSIZE)
|
KERNEL := $(KERNEL_DTB) | pad-to $$(BLOCKSIZE)
|
||||||
IMAGES += factory.bin
|
IMAGES += factory.bin
|
||||||
IMAGE/factory.bin := $$(sysupgrade_bin) | check-size | \
|
IMAGE/factory.bin := $$(sysupgrade_bin) | check-size | \
|
||||||
wrg-header wrgn16a_airlink_ar670w
|
wrg-header wrgn16a_airlink_ar670w
|
||||||
|
|||||||
@ -7,7 +7,7 @@
|
|||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=cmake
|
PKG_NAME:=cmake
|
||||||
PKG_VERSION:=3.26.3
|
PKG_VERSION:=3.26.4
|
||||||
PKG_VERSION_MAJOR:=$(word 1,$(subst ., ,$(PKG_VERSION))).$(word 2,$(subst ., ,$(PKG_VERSION)))
|
PKG_VERSION_MAJOR:=$(word 1,$(subst ., ,$(PKG_VERSION))).$(word 2,$(subst ., ,$(PKG_VERSION)))
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=1
|
||||||
PKG_CPE_ID:=cpe:/a:kitware:cmake
|
PKG_CPE_ID:=cpe:/a:kitware:cmake
|
||||||
@ -15,7 +15,7 @@ PKG_CPE_ID:=cpe:/a:kitware:cmake
|
|||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||||
PKG_SOURCE_URL:=https://github.com/Kitware/CMake/releases/download/v$(PKG_VERSION)/ \
|
PKG_SOURCE_URL:=https://github.com/Kitware/CMake/releases/download/v$(PKG_VERSION)/ \
|
||||||
https://cmake.org/files/v$(PKG_VERSION_MAJOR)/
|
https://cmake.org/files/v$(PKG_VERSION_MAJOR)/
|
||||||
PKG_HASH:=bbd8d39217509d163cb544a40d6428ac666ddc83e22905d3e52c925781f0f659
|
PKG_HASH:=313b6880c291bd4fe31c0aa51d6e62659282a521e695f30d5cc0d25abbd5c208
|
||||||
|
|
||||||
HOST_BUILD_PARALLEL:=1
|
HOST_BUILD_PARALLEL:=1
|
||||||
HOST_CONFIGURE_PARALLEL:=1
|
HOST_CONFIGURE_PARALLEL:=1
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user