* Fix up Samba thanks in part to @CoreELEC.

* Add PC/handheld device to separate X86_64 for other purposes.
* Move emulation packages into device options.
* Add Docker packages for future use thanks to @CoreELEC.
This commit is contained in:
fewtarius 2022-08-28 19:47:36 -04:00
parent 4a0baf46a9
commit a8e3d11475
No known key found for this signature in database
GPG key ID: F4AE55305D1B8C1A
42 changed files with 8607 additions and 316 deletions

View file

@ -3,15 +3,21 @@
PKG_NAME="libunwind"
PKG_VERSION="1.6.2"
PKG_SHA256="4a6aec666991fb45d0889c44aede8ad6eb108071c3554fcdff671f9c94794976"
PKG_LICENSE="GPL"
PKG_SITE="http://www.nongnu.org/libunwind/"
PKG_URL="http://download.savannah.nongnu.org/releases/libunwind/libunwind-${PKG_VERSION}.tar.gz"
PKG_DEPENDS_TARGET="gcc:host"
PKG_DEPENDS_TARGET="toolchain zlib"
PKG_LONGDESC="library to determine the call-chain of a program"
PKG_BUILD_FLAGS="+pic"
PKG_TOOLCHAIN="autotools"
PKG_CONFIGURE_OPTS_TARGET="--enable-static \
--disable-shared"
--disable-shared \
--disable-minidebuginfo \
--disable-documentation \
--disable-tests"
makeinstall_target() {
make DESTDIR=$SYSROOT_PREFIX install
make DESTDIR=${SYSROOT_PREFIX} install
}

View file

@ -0,0 +1,26 @@
From f40db1e2562934fd21485ba7f62e4521945f17e4 Mon Sep 17 00:00:00 2001
From: MilhouseVH <milhouseVH.github@nmacleod.com>
Date: Mon, 17 Feb 2020 05:52:10 +0000
Subject: [PATCH] fix multiple definition
https://lists.nongnu.org/archive/html/libunwind-devel/2017-08/msg00039.html
https://github.com/libunwind/libunwind/commit/0e74e583ae18d6852835f327921ee130a5fa3e6f
---
include/tdep-arm/ex_tables.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/include/tdep-arm/ex_tables.h b/include/tdep-arm/ex_tables.h
index 9df5e0a..0b5388a 100644
--- a/include/tdep-arm/ex_tables.h
+++ b/include/tdep-arm/ex_tables.h
@@ -47,6 +47,7 @@ struct arm_exbuf_data
#define arm_exidx_extract UNW_OBJ(arm_exidx_extract)
#define arm_exidx_decode UNW_OBJ(arm_exidx_decode)
#define arm_exidx_apply_cmd UNW_OBJ(arm_exidx_apply_cmd)
+#define arm_search_unwind_table UNW_OBJ(arm_search_unwind_table)
int arm_exidx_extract (struct dwarf_cursor *c, uint8_t *buf);
int arm_exidx_decode (const uint8_t *buf, uint8_t len, struct dwarf_cursor *c);
--
2.7.4

View file

@ -0,0 +1,10 @@
--- a/src/unwind/libunwind.pc.in 2020-11-10 16:14:18.000000000 +0000
+++ b/src/unwind/libunwind.pc.in 2021-12-05 08:16:04.467881118 +0000
@@ -6,6 +6,6 @@
Name: libunwind
Description: libunwind base library
Version: @VERSION@
-Libs: -L${libdir} -lunwind
+Libs: -L${libdir} -lunwind @LIBLZMA@ @LIBZ@
Libs.private: @LIBLZMA@ @LIBZ@
Cflags: -I${includedir}

View file

@ -0,0 +1,11 @@
# SPDX-License-Identifier: GPL-2.0
# Copyright (C) 2022-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="asn1c"
PKG_VERSION="0.9.28"
PKG_SHA256="8007440b647ef2dd9fb73d931c33ac11764e6afb2437dbe638bb4e5fc82386b9"
PKG_LICENSE="BSD"
PKG_SITE="http://lionet.info/asn1c/blog/"
PKG_URL="https://github.com/vlm/asn1c/releases/download/v${PKG_VERSION}/${PKG_NAME}-${PKG_VERSION}.tar.gz"
PKG_DEPENDS_HOST="ccache:host"
PKG_LONGDESC="The ASN.1 Compiler"

View file

@ -3,12 +3,12 @@
# Copyright (C) 2018-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="heimdal"
PKG_VERSION="7.7.0"
PKG_SHA256="f7d414d0914abb0e151a276b4de22cf4977fd6c28bd9ecdd990407b1138a945c"
PKG_VERSION="c0bc8beb07d9733d4c8c17d120916552fe172f50"
PKG_SHA256="601e9a772063c72b391d593df8ae5e05ec779fefdf1502b7d88fbbe016ceb4dd"
PKG_LICENSE="BSD-3c"
PKG_SITE="http://www.h5l.org/"
PKG_URL="https://github.com/heimdal/heimdal/archive/${PKG_NAME}-${PKG_VERSION}.tar.gz"
PKG_DEPENDS_HOST="toolchain:host Python3:host ncurses:host"
PKG_URL="https://github.com/heimdal/heimdal/archive/${PKG_VERSION}.tar.gz"
PKG_DEPENDS_HOST="toolchain:host Python3:host ncurses:host asn1c:host"
PKG_LONGDESC="Kerberos 5, PKIX, CMS, GSS-API, SPNEGO, NTLM, Digest-MD5 and, SASL implementation."
PKG_TOOLCHAIN="autotools"
PKG_BUILD_FLAGS="-parallel"

View file

@ -1,52 +0,0 @@
From 872222db35384f343a8a566a56a28c4eb73d38ed Mon Sep 17 00:00:00 2001
From: Damir Franusic <df@release14.org>
Date: Sun, 9 Dec 2018 19:50:47 +0100
Subject: [PATCH] AC_FIND_FUNC_NO_LIBS should check libtinfo for tgetent
---
configure.ac | 2 +-
lib/libedit/config.h.in | 3 +++
lib/libedit/configure.ac | 3 ++-
3 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/configure.ac b/configure.ac
index f1e8d7b15e..f98a3c555e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -456,7 +456,7 @@ AC_FIND_FUNC_NO_LIBS(openpty, util,[
#endif
],[0,0,0,0,0])
-AC_FIND_FUNC_NO_LIBS(tgetent, termcap ncurses curses,[
+AC_FIND_FUNC_NO_LIBS(tgetent, termcap ncurses curses tinfo,[
#ifdef HAVE_TERMCAP_H
#include <termcap.h>
#endif
diff --git a/lib/libedit/config.h.in b/lib/libedit/config.h.in
index ba283cc39f..059e5abc6a 100644
--- a/lib/libedit/config.h.in
+++ b/lib/libedit/config.h.in
@@ -42,6 +42,9 @@
/* Define to 1 if you have the `ncurses' library (-lncurses). */
#undef HAVE_LIBNCURSES
+/* Define to 1 if you have the `tinfo' library (-ltinfo). */
+#undef HAVE_LIBTINFO
+
/* Define to 1 if you have the <limits.h> header file. */
#undef HAVE_LIMITS_H
diff --git a/lib/libedit/configure.ac b/lib/libedit/configure.ac
index 90c8ca57d7..89a9376b06 100644
--- a/lib/libedit/configure.ac
+++ b/lib/libedit/configure.ac
@@ -36,7 +36,8 @@ EL_MANTYPE
AC_CHECK_LIB(curses, tgetent,,
[AC_CHECK_LIB(ncurses, tgetent,,
- [AC_MSG_ERROR([libcurses or libncurses are required!])] )] )
+ [AC_CHECK_LIB(tinfo, tgetent,,
+ [AC_MSG_ERROR([libcurses or libncurses are required!])] )] )] )
# Checks for header files.

View file

@ -1,24 +0,0 @@
From 5e7bc8d8811fa401fa14adb9787504c0b460c7df Mon Sep 17 00:00:00 2001
From: Earl Chew <earl_chew@yahoo.com>
Date: Wed, 20 May 2020 09:46:28 -0700
Subject: [PATCH] [libedit/configure.ac] Refactor tgetent message to reflect
libraries searched
Signed-off-by: Earl Chew <earl_chew@yahoo.com>
---
lib/libedit/configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/libedit/configure.ac b/lib/libedit/configure.ac
index 89a9376b06..b94bafc6b9 100644
--- a/lib/libedit/configure.ac
+++ b/lib/libedit/configure.ac
@@ -37,7 +37,7 @@ EL_MANTYPE
AC_CHECK_LIB(curses, tgetent,,
[AC_CHECK_LIB(ncurses, tgetent,,
[AC_CHECK_LIB(tinfo, tgetent,,
- [AC_MSG_ERROR([libcurses or libncurses are required!])] )] )] )
+ [AC_MSG_ERROR([libcurses, libncurses, or tinfo are required!])] )] )] )
# Checks for header files.

View file

@ -1,29 +0,0 @@
From 22352b90e78e2d162b98b5ef6c84672c397be40a Mon Sep 17 00:00:00 2001
From: Lars Wendler <polynomial-c@gentoo.org>
Date: Wed, 17 Mar 2021 17:49:18 +0100
Subject: [PATCH] autoconf-2.70 fix
autoconf-2.70 and newer are more strict with quoting etc. and thus generate
a broken configure file:
configure: 20855: Syntax error: ")" unexpected (expecting "fi")
Gentoo-bug: https://bugs.gentoo.org/776241
Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
---
cf/check-var.m4 | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/cf/check-var.m4 b/cf/check-var.m4
index 2fd7bca6f0..71d6f70ca8 100644
--- a/cf/check-var.m4
+++ b/cf/check-var.m4
@@ -20,7 +20,7 @@ AC_MSG_RESULT($ac_foo)
if test "$ac_foo" = yes; then
AC_DEFINE_UNQUOTED(AS_TR_CPP(HAVE_[]$1), 1,
[Define if you have the `]$1[' variable.])
- m4_ifval([$2], AC_CHECK_DECLS([$1],[],[],[$2]))
+ m4_ifval([$2], [AC_CHECK_DECLS([$1],[],[],[$2])])
fi
])

View file

@ -1,22 +0,0 @@
From c4cff6859d183a40fb35a76e2bc1ce084b3a6d67 Mon Sep 17 00:00:00 2001
From: Luke Howard <lukeh@padl.com>
Date: Mon, 24 Dec 2018 02:21:32 +0000
Subject: [PATCH] hx509: fix dependency, hxtool requires ASN.1 headers
---
lib/hx509/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/hx509/Makefile.am b/lib/hx509/Makefile.am
index c7ef53182d..b21d85202c 100644
--- a/lib/hx509/Makefile.am
+++ b/lib/hx509/Makefile.am
@@ -164,7 +164,7 @@ hxtool-commands.c hxtool-commands.h: hxtool-commands.in $(SLC)
dist_hxtool_SOURCES = hxtool.c
nodist_hxtool_SOURCES = hxtool-commands.c hxtool-commands.h
-$(hxtool_OBJECTS): hxtool-commands.h hx509_err.h
+$(hxtool_OBJECTS): hxtool-commands.h $(nodist_include_HEADERS)
hxtool_LDADD = \
libhx509.la \

View file

@ -1,22 +0,0 @@
From cc6a3f337bac0411d0bb1c924fd857603a258d2f Mon Sep 17 00:00:00 2001
From: Nicolas Williams <nico@twosigma.com>
Date: Tue, 17 Mar 2020 19:46:37 -0500
Subject: [PATCH] hcrypto: Fix Makefile build race
---
lib/hcrypto/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/hcrypto/Makefile.am b/lib/hcrypto/Makefile.am
index 195117d174..3c6ee3ca84 100644
--- a/lib/hcrypto/Makefile.am
+++ b/lib/hcrypto/Makefile.am
@@ -298,7 +298,7 @@ ltmsources = \
libtommath/bn_mp_to_unsigned_bin_n.c
-$(libhcrypto_la_OBJECTS): hcrypto-link
+$(libhcrypto_la_OBJECTS) $(test_rand_OBJECTS): hcrypto-link
libhcrypto_la_CPPFLAGS = -DBUILD_HCRYPTO_LIB $(AM_CPPFLAGS)

View file

@ -1,83 +0,0 @@
From 79b8337d54b2d85f73eff2d033ca592447ac5fce Mon Sep 17 00:00:00 2001
From: heitbaum <rudi@heitbaum.com>
Date: Fri, 10 Sep 2021 00:28:16 +1000
Subject: [PATCH] yyerror: update to POSIX standard
To comply with the latest POSIX standard, in Yacc compatibility mode
(options `-y`/`--yacc`) Bison now generates prototypes for yyerror and
yylex. In some situations, this is breaking compatibility: if the user
has already declared these functions but with some differences (e.g., to
declare them as static, or to use specific attributes), the generated
parser will fail to compile. To disable these prototypes, #define yyerror
(to `yyerror`), and likewise for yylex.
refer: https://git.savannah.gnu.org/cgit/bison.git/tree/NEWS
GNU Bison 3.8
---
lib/asn1/asn1parse.y | 1 +
lib/com_err/parse.y | 5 +++--
lib/sl/slc-lex.l | 2 +-
lib/sl/slc.h | 3 ++-
4 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/lib/asn1/asn1parse.y b/lib/asn1/asn1parse.y
index 9d8b76f582..91b163a28b 100644
--- a/lib/asn1/asn1parse.y
+++ b/lib/asn1/asn1parse.y
@@ -65,6 +65,7 @@ static void validate_object_set(IOSObjectSet *);
static struct constraint_spec *new_constraint_spec(enum ctype);
static Type *new_tag(int tagclass, int tagvalue, int tagenv, Type *oldtype);
void yyerror (const char *);
+#define yyerror yyerror
static struct objid *new_objid(const char *label, int value);
static void add_oid_to_tail(struct objid *, struct objid *);
static void fix_labels(Symbol *s);
diff --git a/lib/com_err/parse.y b/lib/com_err/parse.y
index 0c2e5084b5..bcb9b05204 100644
--- a/lib/com_err/parse.y
+++ b/lib/com_err/parse.y
@@ -35,7 +35,8 @@
#include "compile_et.h"
#include "lex.h"
-void yyerror (char *s);
+void yyerror (const char *s);
+#define yyerror yyerror
static long name2number(const char *str);
extern char *yytext;
@@ -168,7 +169,7 @@ name2number(const char *str)
}
void
-yyerror (char *s)
+yyerror (const char *s)
{
_lex_error_message ("%s\n", s);
}
diff --git a/lib/sl/slc-lex.l b/lib/sl/slc-lex.l
index 50965bccd7..3a37302336 100644
--- a/lib/sl/slc-lex.l
+++ b/lib/sl/slc-lex.l
@@ -78,7 +78,7 @@ error_message (const char *format, ...)
}
void
-yyerror (char *s)
+yyerror (const char *s)
{
error_message("%s\n", s);
}
diff --git a/lib/sl/slc.h b/lib/sl/slc.h
index 6e45ed2f15..e4dc2cba6b 100644
--- a/lib/sl/slc.h
+++ b/lib/sl/slc.h
@@ -51,5 +51,6 @@ extern char *filename;
extern int error_flag;
void error_message (const char *format, ...);
int yylex(void);
-void yyerror (char *s);
+void yyerror (const char *s);
+#define yyerror yyerror
extern unsigned lineno;

View file

@ -3,16 +3,14 @@
# Copyright (C) 2017-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="ncurses"
PKG_VERSION="6.1-20181215"
PKG_SHA256="08b07c3e792961f300829512c283d5fefc0b1c421a57b76922c3d13303ed677d"
PKG_VERSION="6.3-20220827"
PKG_LICENSE="MIT"
PKG_SITE="http://www.gnu.org/software/ncurses/"
PKG_URL="http://invisible-mirror.net/archives/ncurses/current/ncurses-${PKG_VERSION}.tgz"
PKG_DEPENDS_HOST="ccache:host"
PKG_DEPENDS_TARGET="toolchain zlib ncurses:host"
PKG_LONGDESC="A library is a free software emulation of curses in System V Release 4.0, and more."
# causes some segmentation fault's (dialog) when compiled with gcc's link time optimization.
PKG_BUILD_FLAGS="+pic"
PKG_BUILD_FLAGS="+pic +pic:host"
PKG_TOOLCHAIN="auto"
pre_configure_target() {
@ -66,6 +64,13 @@ PKG_CONFIGURE_OPTS_TARGET="
--disable-home-terminfo \
--disable-assertions"
PKG_CONFIGURE_OPTS_HOST="--enable-termcap \
--without-termlib \
--without-shared \
--enable-pc-files \
--without-tests \
--without-manpages"
post_makeinstall_target() {
#cp -rf ${INSTALL}/usr/lib/* ${TOOLCHAIN}/${TARGET_ARCH}-libreelec-linux-gnu${TARGET_ABI}/lib
cp misc/ncurses-config ${TOOLCHAIN}/bin

View file

@ -1,16 +1,16 @@
Remove recent xterm terminfo features to be compatible with other emulations
--- a/misc/terminfo.src 2018-12-21 18:53:11.000000000 +0100
+++ a/misc/terminfo.src 2018-12-22 22:56:47.000000000 +0100
@@ -4335,8 +4335,8 @@ xterm-xfree86|xterm terminal emulator (X
xterm-new|modern xterm terminal emulator,
--- a/misc/terminfo.src 2021-03-20 22:45:39.000000000 +0100
+++ b/misc/terminfo.src 2021-06-01 23:53:10.335516419 +0200
@@ -4808,8 +4808,8 @@ xterm-xfree86|xterm terminal emulator (X
xterm+nofkeys|building block for xterm fkey-variants,
npc,
indn=\E[%p1%dS, kb2=\EOE, kcbt=\E[Z, kent=\EOM,
- rin=\E[%p1%dT, use=ansi+rep, use=ecma+strikeout,
- use=xterm+sm+1006, use=xterm+pcfkeys, use=xterm+tmux,
+ rin=\E[%p1%dT, use=ecma+strikeout,
+ use=xterm+sm+1005, use=xterm+pcfkeys, use=xterm+tmux,
use=xterm-basic,
kcbt=\E[Z, kent=\EOM, nel=\EE, use=ecma+index,
- use=ansi+rep, use=ecma+strikeout, use=vt420+lrmm,
- use=xterm+sm+1006, use=xterm+tmux, use=ecma+italics,
+ use=ecma+strikeout, use=vt420+lrmm,
+ use=xterm+sm+1005, use=xterm+tmux, use=ecma+italics,
use=xterm+keypad, use=xterm-basic,
# This fragment is for people who cannot agree on what the backspace key
# This version reflects the current xterm features.

View file

@ -1,19 +1,8 @@
Fix freeing not allocated fallback entries by allocating a copy.
--- a/ncurses/tinfo/lib_setup.c 2018-11-24 23:13:16.000000000 +0100
+++ b/ncurses/tinfo/lib_setup.c 2018-12-29 10:31:01.000000000 +0100
@@ -756,6 +756,8 @@ TINFO_SETUP_TERM(TERMINAL **tp,
if (status != TGETENT_YES) {
const TERMTYPE2 *fallback = _nc_fallback2(tname);
+ if (fallback)
+ fallback = _nc_copy_entry(fallback);
if (fallback) {
T(("found fallback entry"));
TerminalType(termp) = *fallback;
--- a/ncurses/tinfo/tinfo_driver.c 2018-11-24 23:17:03.000000000 +0100
+++ b/ncurses/tinfo/tinfo_driver.c 2018-12-29 10:27:19.000000000 +0100
@@ -172,6 +172,8 @@ drv_CanHandle(TERMINAL_CONTROL_BLOCK * T
@@ -180,6 +180,8 @@ drv_CanHandle(TERMINAL_CONTROL_BLOCK * T
if (status != TGETENT_YES) {
const TERMTYPE2 *fallback = _nc_fallback2(tname);

View file

@ -0,0 +1,18 @@
Fix USE_SCROLL_HINTS/USE_HASHMAP logic
--- a/ncurses/curses.priv.h 2018-12-16 02:16:58.000000000 +0100
+++ a/ncurses/curses.priv.h 2021-05-30 00:12:14.086528124 +0200
@@ -258,10 +258,9 @@ extern NCURSES_EXPORT(void *) _nc_memmov
/*
* Scroll hints are useless when hashmap is used
*/
-#if !USE_SCROLL_HINTS
-#if !USE_HASHMAP
-#define USE_SCROLL_HINTS 1
-#else
+#if USE_SCROLL_HINTS
+#if USE_HASHMAP
+#undef USE_SCROLL_HINTS
#define USE_SCROLL_HINTS 0
#endif
#endif

View file

@ -3,20 +3,23 @@
# Copyright (C) 2019-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="readline"
PKG_VERSION="8.0"
PKG_SHA256="e339f51971478d369f8a053a330a190781acb9864cf4c541060f12078948e461"
PKG_VERSION="8.1.2"
PKG_SHA256="7589a2381a8419e68654a47623ce7dfcb756815c8fee726b98f90bf668af7bc6"
PKG_LICENSE="MIT"
PKG_SITE="http://www.gnu.org/software/readline/"
PKG_URL="http://ftpmirror.gnu.org/readline/$PKG_NAME-$PKG_VERSION.tar.gz"
PKG_URL="http://ftpmirror.gnu.org/readline/${PKG_NAME}-${PKG_VERSION}.tar.gz"
PKG_DEPENDS_TARGET="toolchain ncurses"
PKG_LONGDESC="The GNU Readline library provides a set of functions for use by applications that allow users to edit command lines as they are typed in."
PKG_BUILD_FLAGS="+pic"
PKG_CONFIGURE_OPTS_TARGET="bash_cv_wcwidth_broken=no \
--disable-shared \
--enable-static \
--enable-shared \
--disable-static \
--with-curses"
post_makeinstall_target() {
rm -rf $INSTALL/usr/share/readline
# fix static library
sed -i 's/-lreadline/-lreadline -lncursesw/' ${SYSROOT_PREFIX}/usr/lib/pkgconfig/readline.pc
rm -rf ${INSTALL}/usr/share/readline
}

View file

@ -50,14 +50,6 @@ case "${PROJECT}" in
;;
esac
### Device specific variables
case "${DEVICE}" in
RG552|RG503|RG353P|RG351P|RG351V|RG351MP|X86_64)
PKG_SOFTWARE+=" emulators gamesupport"
PKG_TOOLS+=" 351files"
;;
esac
if [ ! -z "${BASE_ONLY}" ]
then
PKG_DEPENDS_TARGET+=" ${PKG_BASEOS} ${PKG_TOOLS} ${PKG_UI}"

View file

@ -43,4 +43,6 @@ Checking value of GNUTLS_CIPHER_AES_128_CFB8: OK
Checking value of GNUTLS_MAC_AES_CMAC_128: OK
Checking whether fcntl supports flags to send direct I/O availability signals: OK
Checking whether fcntl supports setting/geting hints: OK
Checking for gnutls fips mode support: NO
Checking for readlink breakage: NO

View file

@ -3,11 +3,12 @@
# Copyright (C) 2017-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="samba"
PKG_VERSION="4.14.12"
PKG_VERSION="4.16.4"
PKG_SHA256="9532f848fb125a17e4e5d98e1ae8b42f210ed4433835e815b97c5dde6dc4702f"
PKG_LICENSE="GPLv3+"
PKG_SITE="https://www.samba.org"
PKG_URL="https://download.samba.org/pub/samba/stable/${PKG_NAME}-${PKG_VERSION}.tar.gz"
PKG_DEPENDS_TARGET="toolchain attr heimdal:host e2fsprogs Python3 zlib readline popt libaio connman gnutls"
PKG_DEPENDS_TARGET="toolchain attr heimdal:host e2fsprogs Python3 libunwind zlib readline popt libaio ncurses connman gnutls wsdd2"
PKG_NEED_UNPACK="$(get_pkg_directory heimdal) $(get_pkg_directory e2fsprogs)"
PKG_LONGDESC="A free SMB / CIFS fileserver and client."
PKG_BUILD_FLAGS="-gold"
@ -44,7 +45,6 @@ configure_package() {
--cross-answers=${PKG_BUILD}/cache.txt \
--hostcc=gcc \
--enable-fhs \
--with-static-modules=vfs_widelinks \
--without-dmapi \
--disable-glusterfs \
--disable-rpath \
@ -61,7 +61,6 @@ configure_package() {
--without-ad-dc \
--without-automount \
--without-cluster-support \
--without-dnsupdate \
--without-fam \
--without-gettext \
--without-gpgme \
@ -95,7 +94,7 @@ pre_configure_target() {
rm -rf .${TARGET_NAME}
# work around link issues
export LDFLAGS="${LDFLAGS} -lreadline -lncurses -ltinfo"
export LDFLAGS="${LDFLAGS} -lreadline -lncurses"
# support 64-bit offsets and seeks on 32-bit platforms
if [ "${TARGET_ARCH}" = "arm" ]; then
@ -123,12 +122,12 @@ pre_make_target() {
}
make_target() {
./buildtools/bin/waf build ${PKG_WAF_VERBOSE} --targets=${PKG_SAMBA_TARGET} -j${CONCURRENCY_MAKE_LEVEL}
make ${PKG_SAMBA_TARGET} -j${CONCURRENCY_MAKE_LEVEL}
}
makeinstall_target() {
./buildtools/bin/waf install ${PKG_WAF_VERBOSE} --destdir=${SYSROOT_PREFIX} --targets=smbclient -j${CONCURRENCY_MAKE_LEVEL}
./buildtools/bin/waf install ${PKG_WAF_VERBOSE} --destdir=${INSTALL} --targets=${PKG_SAMBA_TARGET} -j${CONCURRENCY_MAKE_LEVEL}
PYTHONHASHSEED=1 WAF_MAKE=1 ./buildtools/bin/waf install ${PKG_WAF_VERBOSE} --destdir=${SYSROOT_PREFIX} --targets=smbclient -j${CONCURRENCY_MAKE_LEVEL}
PYTHONHASHSEED=1 WAF_MAKE=1 ./buildtools/bin/waf install ${PKG_WAF_VERBOSE} --destdir=${INSTALL} --targets=${PKG_SAMBA_TARGET} -j${CONCURRENCY_MAKE_LEVEL}
}
copy_directory_of_links() {

View file

@ -0,0 +1,733 @@
From cf43283d9dac9116e178364b1005a32756fffa75 Mon Sep 17 00:00:00 2001
From: Andreas Schneider <asn@samba.org>
Date: Sat, 19 Feb 2022 08:52:17 +0100
Subject: [PATCH 1/8] buildtools: Reformat shell scripts
shfmt -f buildtools | xargs shfmt -w -p -i 0 -fn
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
(cherry picked from commit 2d5d88ff34532ba2d78997467e5720bba480f07e)
---
buildtools/compare_config_h4.sh | 4 +-
buildtools/compare_generated.sh | 59 ++++++++++++++-------------
buildtools/compare_install.sh | 4 +-
buildtools/scripts/abi_gen.sh | 22 +++++------
buildtools/scripts/autogen-waf.sh | 6 +--
buildtools/testwaf.sh | 66 +++++++++++++++----------------
6 files changed, 80 insertions(+), 81 deletions(-)
diff --git a/buildtools/compare_config_h4.sh b/buildtools/compare_config_h4.sh
index b78b36fdd0fa..fee8abfbd503 100755
--- a/buildtools/compare_config_h4.sh
+++ b/buildtools/compare_config_h4.sh
@@ -3,8 +3,8 @@
# compare the generated config.h from a waf build with existing samba
# build
-grep "^.define" bin/default/source4/include/config.h | sort > waf-config.h
-grep "^.define" $HOME/samba_old/source4/include/config.h | sort > old-config.h
+grep "^.define" bin/default/source4/include/config.h | sort >waf-config.h
+grep "^.define" $HOME/samba_old/source4/include/config.h | sort >old-config.h
comm -23 old-config.h waf-config.h
diff --git a/buildtools/compare_generated.sh b/buildtools/compare_generated.sh
index ebef8a979bde..e62657958139 100755
--- a/buildtools/compare_generated.sh
+++ b/buildtools/compare_generated.sh
@@ -10,41 +10,40 @@ gen_files=$(cd bin/default && find . -type f -name '*.[ch]')
strip_file()
{
- in_file=$1
- out_file=$2
- cat $in_file |
- grep -v 'The following definitions come from' |
- grep -v 'Automatically generated at' |
- grep -v 'Generated from' |
- sed 's|/home/tnagy/samba/source4||g' |
- sed 's|/home/tnagy/samba/|../|g' |
- sed 's|bin/default/source4/||g' |
- sed 's|bin/default/|../|g' |
- sed 's/define _____/define ___/g' |
- sed 's/define __*/define _/g' |
- sed 's/define _DEFAULT_/define _/g' |
- sed 's/define _SOURCE4_/define ___/g' |
- sed 's/define ___/define _/g' |
- sed 's/ifndef ___/ifndef _/g' |
- sed 's|endif /* ____|endif /* __|g' |
- sed s/__DEFAULT_SOURCE4/__/ |
- sed s/__DEFAULT_SOURCE4/__/ |
- sed s/__DEFAULT/____/ > $out_file
+ in_file=$1
+ out_file=$2
+ cat $in_file |
+ grep -v 'The following definitions come from' |
+ grep -v 'Automatically generated at' |
+ grep -v 'Generated from' |
+ sed 's|/home/tnagy/samba/source4||g' |
+ sed 's|/home/tnagy/samba/|../|g' |
+ sed 's|bin/default/source4/||g' |
+ sed 's|bin/default/|../|g' |
+ sed 's/define _____/define ___/g' |
+ sed 's/define __*/define _/g' |
+ sed 's/define _DEFAULT_/define _/g' |
+ sed 's/define _SOURCE4_/define ___/g' |
+ sed 's/define ___/define _/g' |
+ sed 's/ifndef ___/ifndef _/g' |
+ sed 's|endif /* ____|endif /* __|g' |
+ sed s/__DEFAULT_SOURCE4/__/ |
+ sed s/__DEFAULT_SOURCE4/__/ |
+ sed s/__DEFAULT/____/ >$out_file
}
compare_file()
{
- f=$f
- bname=$(basename $f)
- t1=/tmp/$bname.old.$$
- t2=/tmp/$bname.new.$$
- strip_file $old_build/$f $t1
- strip_file bin/default/$f $t2
- diff -u -b $t1 $t2 2>&1
- rm -f $t1 $t2
+ f=$f
+ bname=$(basename $f)
+ t1=/tmp/$bname.old.$$
+ t2=/tmp/$bname.new.$$
+ strip_file $old_build/$f $t1
+ strip_file bin/default/$f $t2
+ diff -u -b $t1 $t2 2>&1
+ rm -f $t1 $t2
}
for f in $gen_files; do
- compare_file $f
+ compare_file $f
done
-
diff --git a/buildtools/compare_install.sh b/buildtools/compare_install.sh
index b964117550b6..37772a46a4ca 100755
--- a/buildtools/compare_install.sh
+++ b/buildtools/compare_install.sh
@@ -3,6 +3,6 @@
prefix1="$1"
prefix2="$2"
-(cd $prefix1 && find . ) | sort > p1.txt
-(cd $prefix2 && find . ) | sort > p2.txt
+(cd $prefix1 && find .) | sort >p1.txt
+(cd $prefix2 && find .) | sort >p2.txt
diff -u p[12].txt
diff --git a/buildtools/scripts/autogen-waf.sh b/buildtools/scripts/autogen-waf.sh
index 7a6e94c5ec4d..a0ed80c33fa6 100755
--- a/buildtools/scripts/autogen-waf.sh
+++ b/buildtools/scripts/autogen-waf.sh
@@ -1,6 +1,6 @@
#!/bin/sh
-p=`dirname $0`
+p=$(dirname $0)
echo "Setting up for waf build"
@@ -13,12 +13,12 @@ echo "Found buildtools in $p/$d"
echo "Setting up configure"
rm -f $p/configure $p/include/config*.h*
-sed "s|BUILDTOOLS|$d|g;s|BUILDPATH|$p|g" < "$p/$d/scripts/configure.waf" > $p/configure
+sed "s|BUILDTOOLS|$d|g;s|BUILDPATH|$p|g" <"$p/$d/scripts/configure.waf" >$p/configure
chmod +x $p/configure
echo "Setting up Makefile"
rm -f $p/makefile $p/Makefile
-sed "s|BUILDTOOLS|$d|g" < "$p/$d/scripts/Makefile.waf" > $p/Makefile
+sed "s|BUILDTOOLS|$d|g" <"$p/$d/scripts/Makefile.waf" >$p/Makefile
echo "done. Now run $p/configure or $p/configure.developer then make."
if [ $p != "." ]; then
diff --git a/buildtools/testwaf.sh b/buildtools/testwaf.sh
index 127e52589103..3e8e6431c783 100755
--- a/buildtools/testwaf.sh
+++ b/buildtools/testwaf.sh
@@ -9,52 +9,52 @@ cd $d/..
PREFIX=$HOME/testprefix
if [ $# -gt 0 ]; then
- tests="$*"
+ tests="$*"
else
- tests="lib/replace lib/talloc lib/tevent lib/tdb lib/ldb"
+ tests="lib/replace lib/talloc lib/tevent lib/tdb lib/ldb"
fi
echo "testing in dirs $tests"
for d in $tests; do
- echo "`date`: testing $d"
- pushd $d
- rm -rf bin
- type waf
- waf dist
- ./configure -C --enable-developer --prefix=$PREFIX
- time make
- make install
- make distcheck
- case $d in
+ echo "$(date): testing $d"
+ pushd $d
+ rm -rf bin
+ type waf
+ waf dist
+ ./configure -C --enable-developer --prefix=$PREFIX
+ time make
+ make install
+ make distcheck
+ case $d in
"lib/ldb")
- ldd bin/ldbadd
- ;;
+ ldd bin/ldbadd
+ ;;
"lib/replace")
- ldd bin/replace_testsuite
- ;;
+ ldd bin/replace_testsuite
+ ;;
"lib/talloc")
- ldd bin/talloc_testsuite
- ;;
+ ldd bin/talloc_testsuite
+ ;;
"lib/tdb")
- ldd bin/tdbtool
- ;;
- esac
- popd
+ ldd bin/tdbtool
+ ;;
+ esac
+ popd
done
echo "testing python portability"
pushd lib/talloc
versions="python2.4 python2.5 python2.6 python3.0 python3.1"
for p in $versions; do
- ret=$(which $p || echo "failed")
- if [ $ret = "failed" ]; then
- echo "$p not found, skipping"
- continue
- fi
- echo "Testing $p"
- $p ../../buildtools/bin/waf configure -C --enable-developer --prefix=$PREFIX
- $p ../../buildtools/bin/waf build install
+ ret=$(which $p || echo "failed")
+ if [ $ret = "failed" ]; then
+ echo "$p not found, skipping"
+ continue
+ fi
+ echo "Testing $p"
+ $p ../../buildtools/bin/waf configure -C --enable-developer --prefix=$PREFIX
+ $p ../../buildtools/bin/waf build install
done
popd
@@ -62,9 +62,9 @@ echo "testing cross compiling"
pushd lib/talloc
ret=$(which arm-linux-gnueabi-gcc || echo "failed")
if [ $ret != "failed" ]; then
- CC=arm-linux-gnueabi-gcc ./configure -C --prefix=$PREFIX --cross-compile --cross-execute='runarm'
- make && make install
+ CC=arm-linux-gnueabi-gcc ./configure -C --prefix=$PREFIX --cross-compile --cross-execute='runarm'
+ make && make install
else
- echo "Cross-compiler not installed, skipping test"
+ echo "Cross-compiler not installed, skipping test"
fi
popd
--
2.25.1
From bccb8b807bb1c00ffc2cd95cadfee253eb0d0cff Mon Sep 17 00:00:00 2001
From: Stefan Metzmacher <metze@samba.org>
Date: Mon, 28 Mar 2022 12:38:02 +0200
Subject: [PATCH 2/8] buildtools: remove unused testwaf.sh
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
(cherry picked from commit 42eeed05f1aed10b48f7008a18e47cf15ac2c010)
---
buildtools/testwaf.sh | 70 -------------------------------------------
1 file changed, 70 deletions(-)
delete mode 100755 buildtools/testwaf.sh
diff --git a/buildtools/testwaf.sh b/buildtools/testwaf.sh
deleted file mode 100755
index 3e8e6431c783..000000000000
--- a/buildtools/testwaf.sh
+++ /dev/null
@@ -1,70 +0,0 @@
-#!/bin/bash
-
-set -e
-set -x
-
-d=$(dirname $0)
-
-cd $d/..
-PREFIX=$HOME/testprefix
-
-if [ $# -gt 0 ]; then
- tests="$*"
-else
- tests="lib/replace lib/talloc lib/tevent lib/tdb lib/ldb"
-fi
-
-echo "testing in dirs $tests"
-
-for d in $tests; do
- echo "$(date): testing $d"
- pushd $d
- rm -rf bin
- type waf
- waf dist
- ./configure -C --enable-developer --prefix=$PREFIX
- time make
- make install
- make distcheck
- case $d in
- "lib/ldb")
- ldd bin/ldbadd
- ;;
- "lib/replace")
- ldd bin/replace_testsuite
- ;;
- "lib/talloc")
- ldd bin/talloc_testsuite
- ;;
- "lib/tdb")
- ldd bin/tdbtool
- ;;
- esac
- popd
-done
-
-echo "testing python portability"
-pushd lib/talloc
-versions="python2.4 python2.5 python2.6 python3.0 python3.1"
-for p in $versions; do
- ret=$(which $p || echo "failed")
- if [ $ret = "failed" ]; then
- echo "$p not found, skipping"
- continue
- fi
- echo "Testing $p"
- $p ../../buildtools/bin/waf configure -C --enable-developer --prefix=$PREFIX
- $p ../../buildtools/bin/waf build install
-done
-popd
-
-echo "testing cross compiling"
-pushd lib/talloc
-ret=$(which arm-linux-gnueabi-gcc || echo "failed")
-if [ $ret != "failed" ]; then
- CC=arm-linux-gnueabi-gcc ./configure -C --prefix=$PREFIX --cross-compile --cross-execute='runarm'
- make && make install
-else
- echo "Cross-compiler not installed, skipping test"
-fi
-popd
--
2.25.1
From 8b609eb416bd737578a79beabb3bd736d341e326 Mon Sep 17 00:00:00 2001
From: Stefan Metzmacher <metze@samba.org>
Date: Mon, 28 Mar 2022 12:49:24 +0200
Subject: [PATCH 3/8] lib/fuzzing/README.md: don't use waf directly
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
(cherry picked from commit 10d69da1d34b2b11920d9bf051f5a26dbbcadf02)
---
lib/fuzzing/README.md | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/lib/fuzzing/README.md b/lib/fuzzing/README.md
index 33d33b923905..d3e34bd79a36 100644
--- a/lib/fuzzing/README.md
+++ b/lib/fuzzing/README.md
@@ -17,9 +17,9 @@ Example command line to build binaries for use with
[honggfuzz](https://github.com/google/honggfuzz/):
```sh
-buildtools/bin/waf -C --without-gettext --enable-debug --enable-developer \
+./configure -C --without-gettext --enable-debug --enable-developer \
--address-sanitizer --enable-libfuzzer --abi-check-disable \
- CC=.../honggfuzz/hfuzz_cc/hfuzz-clang configure \
+ CC=.../honggfuzz/hfuzz_cc/hfuzz-clang \
LINK_CC=.../honggfuzz/hfuzz_cc/hfuzz-clang
```
@@ -30,7 +30,7 @@ Example for fuzzing `tiniparser` using `honggfuzz` (see `--help` for more
options):
```sh
-buildtools/bin/waf --targets=fuzz_tiniparser build && \
+make bin/fuzz_tiniparser && \
.../honggfuzz/honggfuzz --sanitizers --timeout 3 --max_file_size 256 \
--rlimit_rss 100 -f .../tiniparser-corpus -- bin/fuzz_tiniparser
```
@@ -43,9 +43,9 @@ Example command line to build binaries for use with
[afl](http://lcamtuf.coredump.cx/afl/)
```sh
-buildtools/bin/waf -C --without-gettext --enable-debug --enable-developer \
+./configure -C --without-gettext --enable-debug --enable-developer \
--enable-afl-fuzzer --abi-check-disable \
- CC=afl-gcc configure
+ CC=afl-gcc
```
## Fuzzing tiniparser
@@ -54,7 +54,7 @@ Example for fuzzing `tiniparser` using `afl-fuzz` (see `--help` for more
options):
```sh
-buildtools/bin/waf --targets=fuzz_tiniparser build && \
+make bin/fuzz_tiniparser build && \
afl-fuzz -m 200 -i inputdir -o outputdir -- bin/fuzz_tiniparser
```
--
2.25.1
From 16d566b1139f56686fac969d3bc362be162bad28 Mon Sep 17 00:00:00 2001
From: Stefan Metzmacher <metze@samba.org>
Date: Mon, 28 Mar 2022 12:50:55 +0200
Subject: [PATCH 5/8] wafsamba: let test_duplicate_symbol.sh export
PYTHONHASHSEED=1
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
(cherry picked from commit a6b1e4b5766205b7337e0e4b00944184289bfc36)
---
buildtools/wafsamba/test_duplicate_symbol.sh | 3 +++
1 file changed, 3 insertions(+)
diff --git a/buildtools/wafsamba/test_duplicate_symbol.sh b/buildtools/wafsamba/test_duplicate_symbol.sh
index 46f44a67dcf8..dffac7570022 100755
--- a/buildtools/wafsamba/test_duplicate_symbol.sh
+++ b/buildtools/wafsamba/test_duplicate_symbol.sh
@@ -5,6 +5,9 @@
subunit_start_test duplicate_symbols
+PYTHONHASHSEED=1
+export PYTHONHASHSEED
+
if $PYTHON ./buildtools/bin/waf build --dup-symbol-check; then
subunit_pass_test duplicate_symbols
else
--
2.25.1
From 73295e83a14b1ed662ca842b531c1f84143301ca Mon Sep 17 00:00:00 2001
From: Stefan Metzmacher <metze@samba.org>
Date: Mon, 28 Mar 2022 12:59:12 +0200
Subject: [PATCH 6/8] configure/Makefile: export PYTHONHASHSEED=1 in all
'configure/Makefile' scripts
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
(cherry picked from commit 22c46d9f41876d9ec7187148e658d1692bf37cdd)
---
buildtools/scripts/Makefile.waf | 4 ++--
buildtools/scripts/configure.waf | 11 +++++++++--
configure | 4 ++++
ctdb/Makefile | 2 +-
ctdb/configure | 7 +++++++
lib/ldb/configure | 7 +++++++
lib/replace/configure | 7 +++++++
lib/talloc/configure | 7 +++++++
lib/tdb/configure | 7 +++++++
lib/tevent/configure | 7 +++++++
10 files changed, 58 insertions(+), 5 deletions(-)
diff --git a/buildtools/scripts/Makefile.waf b/buildtools/scripts/Makefile.waf
index 5fc939c99e03..a15a5f87607e 100644
--- a/buildtools/scripts/Makefile.waf
+++ b/buildtools/scripts/Makefile.waf
@@ -1,7 +1,7 @@
# simple makefile wrapper to run waf
-WAF_BINARY=BUILDTOOLS/bin/waf
-WAF=WAF_MAKE=1 $(WAF_BINARY)
+WAF_BINARY=$(PYTHON) BUILDTOOLS/bin/waf
+WAF=PYTHONHASHSEED=1 WAF_MAKE=1 $(WAF_BINARY)
all:
$(WAF) build
diff --git a/buildtools/scripts/configure.waf b/buildtools/scripts/configure.waf
index a7d8d1dbd641..ccb62849a54f 100755
--- a/buildtools/scripts/configure.waf
+++ b/buildtools/scripts/configure.waf
@@ -1,6 +1,6 @@
#!/bin/sh
-PREVPATH=`dirname $0`
+PREVPATH=$(dirname $0)
WAF=BUILDTOOLS/bin/waf
@@ -9,6 +9,13 @@ WAF=BUILDTOOLS/bin/waf
JOBS=1
export JOBS
+# Make sure we don't have any library preloaded.
+unset LD_PRELOAD
+
+# Make sure we get stable hashes
+PYTHONHASHSEED=1
+export PYTHONHASHSEED
+
cd BUILDPATH || exit 1
-$WAF configure "$@" || exit 1
+$PYTHON $WAF configure "$@" || exit 1
cd $PREVPATH
diff --git a/configure b/configure
index a6ca50feb470..9153c0e5f784 100755
--- a/configure
+++ b/configure
@@ -12,6 +12,10 @@ export JOBS
# Make sure we don't have any library preloaded.
unset LD_PRELOAD
+# Make sure we get stable hashes
+PYTHONHASHSEED=1
+export PYTHONHASHSEED
+
cd . || exit 1
$PYTHON $WAF configure "$@" || exit 1
cd $PREVPATH
diff --git a/ctdb/Makefile b/ctdb/Makefile
index ec362e294082..5dbc7acdc54e 100644
--- a/ctdb/Makefile
+++ b/ctdb/Makefile
@@ -1,7 +1,7 @@
# simple makefile wrapper to run waf
WAF_BINARY=$(PYTHON) ../buildtools/bin/waf
-WAF=WAF_MAKE=1 $(WAF_BINARY)
+WAF=PYTHONHASHSEED=1 WAF_MAKE=1 $(WAF_BINARY)
all:
$(WAF) build
diff --git a/ctdb/configure b/ctdb/configure
index dbb0c1446b51..48b786b1612d 100755
--- a/ctdb/configure
+++ b/ctdb/configure
@@ -10,6 +10,13 @@ WAF=buildtools/bin/waf
JOBS=1
export JOBS
+# Make sure we don't have any library preloaded.
+unset LD_PRELOAD
+
+# Make sure we get stable hashes
+PYTHONHASHSEED=1
+export PYTHONHASHSEED
+
cd . || exit 1
$PYTHON $WAF configure "$@" || exit 1
cd $PREVPATH
diff --git a/lib/ldb/configure b/lib/ldb/configure
index 6c931bfbf5e2..28d62ab27ae2 100755
--- a/lib/ldb/configure
+++ b/lib/ldb/configure
@@ -16,6 +16,13 @@ fi
JOBS=1
export JOBS
+# Make sure we don't have any library preloaded.
+unset LD_PRELOAD
+
+# Make sure we get stable hashes
+PYTHONHASHSEED=1
+export PYTHONHASHSEED
+
cd . || exit 1
$PYTHON $WAF configure "$@" || exit 1
cd $PREVPATH
diff --git a/lib/replace/configure b/lib/replace/configure
index d8a8d2ac2f39..091f814e5f2c 100755
--- a/lib/replace/configure
+++ b/lib/replace/configure
@@ -16,6 +16,13 @@ fi
JOBS=1
export JOBS
+# Make sure we don't have any library preloaded.
+unset LD_PRELOAD
+
+# Make sure we get stable hashes
+PYTHONHASHSEED=1
+export PYTHONHASHSEED
+
cd . || exit 1
$PYTHON $WAF configure "$@" || exit 1
cd $PREVPATH
diff --git a/lib/talloc/configure b/lib/talloc/configure
index d8a8d2ac2f39..091f814e5f2c 100755
--- a/lib/talloc/configure
+++ b/lib/talloc/configure
@@ -16,6 +16,13 @@ fi
JOBS=1
export JOBS
+# Make sure we don't have any library preloaded.
+unset LD_PRELOAD
+
+# Make sure we get stable hashes
+PYTHONHASHSEED=1
+export PYTHONHASHSEED
+
cd . || exit 1
$PYTHON $WAF configure "$@" || exit 1
cd $PREVPATH
diff --git a/lib/tdb/configure b/lib/tdb/configure
index d8a8d2ac2f39..091f814e5f2c 100755
--- a/lib/tdb/configure
+++ b/lib/tdb/configure
@@ -16,6 +16,13 @@ fi
JOBS=1
export JOBS
+# Make sure we don't have any library preloaded.
+unset LD_PRELOAD
+
+# Make sure we get stable hashes
+PYTHONHASHSEED=1
+export PYTHONHASHSEED
+
cd . || exit 1
$PYTHON $WAF configure "$@" || exit 1
cd $PREVPATH
diff --git a/lib/tevent/configure b/lib/tevent/configure
index c3c444754e3d..0dc9bace4356 100755
--- a/lib/tevent/configure
+++ b/lib/tevent/configure
@@ -16,6 +16,13 @@ fi
JOBS=1
export JOBS
+# Make sure we don't have any library preloaded.
+unset LD_PRELOAD
+
+# Make sure we get stable hashes
+PYTHONHASHSEED=1
+export PYTHONHASHSEED
+
cd . || exit 1
$PYTHON $WAF configure "$@" || exit 1
cd $PREVPATH
--
2.25.1
From 2cd1e53284c0c212c62d909028c5bd9872493934 Mon Sep 17 00:00:00 2001
From: Stefan Metzmacher <metze@samba.org>
Date: Mon, 28 Mar 2022 12:38:36 +0200
Subject: [PATCH 7/8] ctdb/packaging/RPM: don't use waf directly
./configure && make && make install is will always work.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
(cherry picked from commit aa02cf3c4449cb0a22da8f359f0b3edc4f1d9bb7)
---
ctdb/packaging/RPM/ctdb.spec.in | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/ctdb/packaging/RPM/ctdb.spec.in b/ctdb/packaging/RPM/ctdb.spec.in
index 80eb2945e419..ea5c5a256ec9 100644
--- a/ctdb/packaging/RPM/ctdb.spec.in
+++ b/ctdb/packaging/RPM/ctdb.spec.in
@@ -88,7 +88,7 @@ fi
export CC
CFLAGS="$RPM_OPT_FLAGS $EXTRA -D_GNU_SOURCE" \
-$PYTHON ./buildtools/bin/waf configure \
+./configure \
--builtin-libraries=replace,popt \
--bundled-libraries=!talloc,!tevent,!tdb \
--minimum-library-version=talloc:%libtalloc_version,tdb:%libtdb_version,tevent:%libtevent_version \
@@ -103,7 +103,7 @@ $PYTHON ./buildtools/bin/waf configure \
--mandir=%{_mandir} \
--localstatedir=%{_localstatedir}
-$PYTHON ./buildtools/bin/waf build
+make -j
%install
# Clean up in case there is trash left from a previous build
@@ -112,7 +112,7 @@ rm -rf $RPM_BUILD_ROOT
# Create the target build directory hierarchy
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/sudoers.d
-DESTDIR=$RPM_BUILD_ROOT $PYTHON ./buildtools/bin/waf install
+DESTDIR=$RPM_BUILD_ROOT make -j install
install -m644 config/ctdb.conf $RPM_BUILD_ROOT%{_sysconfdir}/ctdb
install -m644 config/ctdb.tunables $RPM_BUILD_ROOT%{_sysconfdir}/ctdb
--
2.25.1
From 5a6029aa55d806647fe1e2e0c3a6ca58aaf79ca0 Mon Sep 17 00:00:00 2001
From: Stefan Metzmacher <metze@samba.org>
Date: Mon, 28 Mar 2022 13:00:03 +0200
Subject: [PATCH 8/8] wafsamba: require PYTHONHASHSEED=1 to be exported
This avoids a lot of trouble with random build failures,
if people try to use waf directly.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Tue Mar 29 23:31:38 UTC 2022 on sn-devel-184
(cherry picked from commit 420bbb1d92fd2a28725b53f425ba3d214831b660)
The last 8 patches are backported to avoid people running into:
https://bugzilla.samba.org/show_bug.cgi?id=15033
and
https://bugzilla.samba.org/show_bug.cgi?id=15037
---
buildtools/wafsamba/wscript | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/buildtools/wafsamba/wscript b/buildtools/wafsamba/wscript
index a4d6f3e5c49e..8729b0829daa 100644
--- a/buildtools/wafsamba/wscript
+++ b/buildtools/wafsamba/wscript
@@ -8,6 +8,10 @@ import wafsamba
from samba_utils import symlink
from optparse import SUPPRESS_HELP
+phs = os.environ.get("PYTHONHASHSEED", None)
+if phs != "1":
+ raise Errors.WafError('''PYTHONHASHSEED=1 missing! Don't use waf directly, use ./configure and make!''')
+
# this forces configure to be re-run if any of the configure
# sections of the build scripts change. We have to check
# for this in sys.argv as options have not yet been parsed when
--
2.25.1

View file

@ -41,8 +41,10 @@ diff --git a/wscript_configure_embedded_heimdal b/wscript_configure_embedded_hei
index 8c55ae2..4fdae80 100644
--- a/wscript_configure_embedded_heimdal
+++ b/wscript_configure_embedded_heimdal
@@ -1 +1,12 @@
conf.RECURSE('source4/heimdal_build')
@@ -6,3 +6,14 @@
conf.define('USING_EMBEDDED_HEIMDAL', 1)
conf.RECURSE('third_party/heimdal_build')
+
+def check_system_heimdal_binary(name):
+ if conf.LIB_MAY_BE_BUNDLED(name):
@ -73,14 +75,14 @@ index 235fa19..4f4a83cd 100644
check_system_heimdal_lib("com_err", "com_right_r com_err", "com_err.h")
if check_system_heimdal_lib("roken", "rk_socket_set_reuseaddr", "roken.h"):
@@ -96,7 +88,4 @@ finally:
@@ -86,7 +78,4 @@ finally:
#if conf.CHECK_BUNDLED_SYSTEM('tommath', checkfunctions='mp_init', headers='tommath.h'):
# conf.define('USING_SYSTEM_TOMMATH', 1)
-check_system_heimdal_binary("compile_et")
-check_system_heimdal_binary("asn1_compile")
-
conf.define('USING_SYSTEM_KRB5', 1)
conf.env.KRB5_VENDOR = 'heimdal'
--
2.20.1

View file

@ -1,7 +1,7 @@
diff --git a/docs-xml/wscript_build b/docs-xml/wscript_build
--- a/docs-xml/wscript_build 2020-12-05 09:01:19.652459634 +0000
+++ b/docs-xml/wscript_build 2020-12-05 09:10:10.639446971 +0000
@@ -153,28 +153,3 @@
@@ -154,31 +154,3 @@
target=parameter_all,
rule=smbdotconf_generate_parameter_list,
dep_vars=bld.dynconfig_varnames())
@ -27,6 +27,9 @@ diff --git a/docs-xml/wscript_build b/docs-xml/wscript_build
- if conf.env.build_winexe == True:
- bld.SAMBAMANPAGES(winexe_manpages)
-
- if bld.CONFIG_SET('ENABLE_SELFTEST'):
- bld.SAMBAMANPAGES('manpages/vfstest.1')
-
- for manpage in vfs_module_manpages:
- if bld.SAMBA3_IS_ENABLED_MODULE(manpage):
- bld.SAMBAMANPAGES('manpages/%s.8' % manpage)

View file

@ -0,0 +1,47 @@
# SPDX-License-Identifier: GPL-2.0
# Copyright (C) 2022-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="cli"
PKG_VERSION="$(get_pkg_version moby)"
PKG_SHA256="2f5949173515b70daa0b78fea7185ffd219ca31f7381a0e1218eeefc7f70199c"
PKG_LICENSE="ASL"
PKG_SITE="https://github.com/docker/cli"
PKG_URL="https://github.com/docker/cli/archive/v${PKG_VERSION}.tar.gz"
PKG_DEPENDS_TARGET="toolchain go:host"
PKG_LONGDESC="The Docker CLI"
PKG_TOOLCHAIN="manual"
# Git commit of the matching release https://github.com/docker/cli/releases
export PKG_GIT_COMMIT="3e9117b7e241439e314eaf6fe944b4019fbaa941"
configure_target() {
go_configure
export LDFLAGS="-w -linkmode external -extldflags -Wl,--unresolved-symbols=ignore-in-shared-libs -extld ${CC}"
# used for docker version
export GITCOMMIT=${PKG_GIT_COMMIT}
export VERSION=${PKG_VERSION}
export BUILDTIME="$(date --utc)"
cat > "${PKG_BUILD}/go.mod" << EOF
module github.com/docker/cli
go 1.18
EOF
GO111MODULE=auto ${GOLANG} mod tidy -modfile 'vendor.mod' -compat 1.18
GO111MODULE=auto ${GOLANG} mod vendor -modfile vendor.mod
}
make_target() {
mkdir -p bin
PKG_CLI_FLAGS="-X 'github.com/docker/cli/cli/version.Version=${VERSION}'"
PKG_CLI_FLAGS+=" -X 'github.com/docker/cli/cli/version.GitCommit=${GITCOMMIT}'"
PKG_CLI_FLAGS+=" -X 'github.com/docker/cli/cli/version.BuildTime=${BUILDTIME}'"
${GOLANG} build -mod=mod -modfile=vendor.mod -v -o bin/docker -a -tags "${PKG_DOCKER_BUILDTAGS}" -ldflags "${LDFLAGS} ${PKG_CLI_FLAGS}" ./cmd/docker
}
makeinstall_target() {
:
}

View file

@ -0,0 +1,41 @@
# SPDX-License-Identifier: GPL-2.0-or-later
# Copyright (C) 2009-2016 Lukas Rusak (lrusak@libreelec.tv)
# Copyright (C) 2016-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="containerd"
PKG_VERSION="1.6.8"
PKG_SHA256="f5f938513c28377f64f85e84f2750d39f26b01262f3a062b7e8ce35b560ca407"
PKG_LICENSE="APL"
PKG_SITE="https://containerd.io"
PKG_URL="https://github.com/containerd/containerd/archive/v${PKG_VERSION}.tar.gz"
PKG_DEPENDS_TARGET="toolchain go:host"
PKG_LONGDESC="A daemon to control runC, built for performance and density."
PKG_TOOLCHAIN="manual"
# Git commit of the matching release https://github.com/containerd/containerd/releases
PKG_GIT_COMMIT="10c12954828e7c7c9b6e0ea9b0c02b01407d3ae1"
pre_make_target() {
go_configure
export CONTAINERD_VERSION=${PKG_VERSION}
export CONTAINERD_REVISION=${PKG_GIT_COMMIT}
export CONTAINERD_PKG=github.com/containerd/containerd
export LDFLAGS="-w -extldflags -static -X ${CONTAINERD_PKG}/version.Version=${CONTAINERD_VERSION} -X ${CONTAINERD_PKG}/version.Revision=${CONTAINERD_REVISION} -X ${CONTAINERD_PKG}/version.Package=${CONTAINERD_PKG} -extld ${CC}"
export GO111MODULE=off
mkdir -p ${GOPATH}
if [ -d ${PKG_BUILD}/vendor ]; then
mv ${PKG_BUILD}/vendor ${GOPATH}/src
fi
ln -fs ${PKG_BUILD} ${GOPATH}/src/github.com/containerd/containerd
}
make_target() {
mkdir -p bin
${GOLANG} build -v -o bin/containerd -a -tags "static_build no_btrfs" -ldflags "${LDFLAGS}" ./cmd/containerd
${GOLANG} build -v -o bin/containerd-shim -a -tags "static_build no_btrfs" -ldflags "${LDFLAGS}" ./cmd/containerd-shim
${GOLANG} build -v -o bin/containerd-shim-runc-v2 -a -tags "static_build no_btrfs" -ldflags "${LDFLAGS}" ./cmd/containerd-shim-runc-v2
}

View file

@ -0,0 +1,54 @@
# SPDX-License-Identifier: GPL-2.0
# Copyright (C) 2022-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="moby"
PKG_VERSION="22.06.0-beta.0"
PKG_SHA256="d0221f0b1c0eda2629ed8b7f08b4ec86e61cf38e0cf699f5bd01a2b662273b87"
PKG_LICENSE="ASL"
PKG_SITE="https://mobyproject.org/"
PKG_URL="https://github.com/moby/moby/archive/v${PKG_VERSION}.tar.gz"
PKG_DEPENDS_TARGET="toolchain go:host systemd"
PKG_LONGDESC="Moby is an open-source project created by Docker to enable and accelerate software containerization."
PKG_TOOLCHAIN="manual"
# Git commit of the matching release https://github.com/moby/moby
export PKG_GIT_COMMIT="a89b84221c8560e7a3dee2a653353429e7628424"
PKG_MOBY_BUILDTAGS="daemon \
autogen \
exclude_graphdriver_devicemapper \
exclude_graphdriver_aufs \
exclude_graphdriver_btrfs \
journald"
configure_target() {
go_configure
export LDFLAGS="-w -linkmode external -extldflags -Wl,--unresolved-symbols=ignore-in-shared-libs -extld ${CC}"
# used for docker version
export GITCOMMIT=${PKG_GIT_COMMIT}
export VERSION=${PKG_VERSION}
export BUILDTIME="$(date --utc)"
cat > "${PKG_BUILD}/go.mod" << EOF
module github.com/docker/docker
go 1.18
EOF
GO111MODULE=auto ${GOLANG} mod tidy -modfile 'vendor.mod' -compat 1.18
GO111MODULE=auto ${GOLANG} mod vendor -modfile vendor.mod
bash hack/make/.go-autogen
}
make_target() {
mkdir -p bin
${GOLANG} build -mod=mod -modfile=vendor.mod -v -o bin/docker-proxy -a -ldflags "${LDFLAGS}" ./cmd/docker-proxy
${GOLANG} build -mod=mod -modfile=vendor.mod -v -o bin/dockerd -a -tags "${PKG_MOBY_BUILDTAGS}" -ldflags "${LDFLAGS}" ./cmd/dockerd
}
makeinstall_target() {
:
}

View file

@ -0,0 +1,284 @@
# when updating this patch just create it from scratch using this command
#
# find . -name "*.go" -print | xargs sed -i 's/\/etc\/docker/\/storage\/.kodi\/userdata\/addon_data\/service.system.docker\/config/g'
#
#
diff -Naur a/cmd/dockerd/daemon_unix.go b/cmd/dockerd/daemon_unix.go
--- a/cmd/dockerd/daemon_unix.go 2022-06-03 10:30:24.000000000 -0700
+++ b/cmd/dockerd/daemon_unix.go 2022-06-07 14:28:05.510327911 -0700
@@ -25,7 +25,7 @@
func getDefaultDaemonConfigDir() (string, error) {
if !honorXDG {
- return "/etc/docker", nil
+ return "/storage/.kodi/userdata/addon_data/service.system.docker/config", nil
}
// NOTE: CLI uses ~/.docker while the daemon uses ~/.config/docker, because
// ~/.docker was not designed to store daemon configurations.
diff -Naur a/integration/plugin/authz/authz_plugin_test.go b/integration/plugin/authz/authz_plugin_test.go
--- a/integration/plugin/authz/authz_plugin_test.go 2022-06-03 10:30:24.000000000 -0700
+++ b/integration/plugin/authz/authz_plugin_test.go 2022-06-07 14:28:05.570328822 -0700
@@ -56,15 +56,15 @@
ctrl = &authorizationController{}
teardown := setupTest(t)
- err := os.MkdirAll("/etc/docker/plugins", 0755)
+ err := os.MkdirAll("/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins", 0755)
assert.NilError(t, err)
- fileName := fmt.Sprintf("/etc/docker/plugins/%s.spec", testAuthZPlugin)
+ fileName := fmt.Sprintf("/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins/%s.spec", testAuthZPlugin)
err = os.WriteFile(fileName, []byte(server.URL), 0644)
assert.NilError(t, err)
return func() {
- err := os.RemoveAll("/etc/docker/plugins")
+ err := os.RemoveAll("/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins")
assert.NilError(t, err)
teardown()
diff -Naur a/integration/plugin/graphdriver/external_test.go b/integration/plugin/graphdriver/external_test.go
--- a/integration/plugin/graphdriver/external_test.go 2022-06-03 10:30:24.000000000 -0700
+++ b/integration/plugin/graphdriver/external_test.go 2022-06-07 14:28:05.570328822 -0700
@@ -80,7 +80,7 @@
sserver.Close()
jserver.Close()
- err := os.RemoveAll("/etc/docker/plugins")
+ err := os.RemoveAll("/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins")
assert.NilError(t, err)
}
@@ -345,10 +345,10 @@
respond(w, &graphDriverResponse{Size: size})
})
- err = os.MkdirAll("/etc/docker/plugins", 0755)
+ err = os.MkdirAll("/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins", 0755)
assert.NilError(t, err)
- specFile := "/etc/docker/plugins/" + name + "." + ext
+ specFile := "/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins/" + name + "." + ext
err = os.WriteFile(specFile, b, 0644)
assert.NilError(t, err)
}
diff -Naur a/integration-cli/docker_cli_daemon_test.go b/integration-cli/docker_cli_daemon_test.go
--- a/integration-cli/docker_cli_daemon_test.go 2022-06-03 10:30:24.000000000 -0700
+++ b/integration-cli/docker_cli_daemon_test.go 2022-06-07 14:28:05.556328610 -0700
@@ -558,12 +558,12 @@
func (s *DockerDaemonSuite) TestDaemonKeyGeneration(c *testing.T) {
// TODO: skip or update for Windows daemon
- os.Remove("/etc/docker/key.json")
+ os.Remove("/storage/.kodi/userdata/addon_data/service.system.docker/config/key.json")
c.Setenv("DOCKER_ALLOW_SCHEMA1_PUSH_DONOTUSE", "1")
s.d.Start(c)
s.d.Stop(c)
- k, err := libtrust.LoadKeyFile("/etc/docker/key.json")
+ k, err := libtrust.LoadKeyFile("/storage/.kodi/userdata/addon_data/service.system.docker/config/key.json")
if err != nil {
c.Fatalf("Error opening key file")
}
@@ -1212,13 +1212,13 @@
Y string `json:"y"`
}
- os.Remove("/etc/docker/key.json")
+ os.Remove("/storage/.kodi/userdata/addon_data/service.system.docker/config/key.json")
c.Setenv("DOCKER_ALLOW_SCHEMA1_PUSH_DONOTUSE", "1")
s.d.Start(c)
s.d.Stop(c)
config := &Config{}
- bytes, err := os.ReadFile("/etc/docker/key.json")
+ bytes, err := os.ReadFile("/storage/.kodi/userdata/addon_data/service.system.docker/config/key.json")
if err != nil {
c.Fatalf("Error reading key.json file: %s", err)
}
@@ -1238,11 +1238,11 @@
}
// write back
- if err := os.WriteFile("/etc/docker/key.json", newBytes, 0400); err != nil {
+ if err := os.WriteFile("/storage/.kodi/userdata/addon_data/service.system.docker/config/key.json", newBytes, 0400); err != nil {
c.Fatalf("Error os.WriteFile: %s", err)
}
- defer os.Remove("/etc/docker/key.json")
+ defer os.Remove("/storage/.kodi/userdata/addon_data/service.system.docker/config/key.json")
if err := s.d.StartWithError(); err == nil {
c.Fatalf("It should not be successful to start daemon with wrong key: %v", err)
diff -Naur a/integration-cli/docker_cli_external_volume_driver_test.go b/integration-cli/docker_cli_external_volume_driver_test.go
--- a/integration-cli/docker_cli_external_volume_driver_test.go 2022-06-03 10:30:24.000000000 -0700
+++ b/integration-cli/docker_cli_external_volume_driver_test.go 2022-06-07 14:28:05.556328610 -0700
@@ -258,10 +258,10 @@
send(w, `{"Capabilities": { "Scope": "global" }}`)
})
- err := os.MkdirAll("/etc/docker/plugins", 0755)
+ err := os.MkdirAll("/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins", 0755)
assert.NilError(c, err)
- err = os.WriteFile("/etc/docker/plugins/"+name+".spec", []byte(s.Server.URL), 0644)
+ err = os.WriteFile("/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins/"+name+".spec", []byte(s.Server.URL), 0644)
assert.NilError(c, err)
return s
}
@@ -269,7 +269,7 @@
func (s *DockerExternalVolumeSuite) TearDownSuite(c *testing.T) {
s.volumePlugin.Close()
- err := os.RemoveAll("/etc/docker/plugins")
+ err := os.RemoveAll("/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins")
assert.NilError(c, err)
}
@@ -359,7 +359,7 @@
// Make sure a request to use a down driver doesn't block other requests
func (s *DockerExternalVolumeSuite) TestExternalVolumeDriverLookupNotBlocked(c *testing.T) {
- specPath := "/etc/docker/plugins/down-driver.spec"
+ specPath := "/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins/down-driver.spec"
err := os.WriteFile(specPath, []byte("tcp://127.0.0.7:9999"), 0644)
assert.NilError(c, err)
defer os.RemoveAll(specPath)
diff -Naur a/integration-cli/docker_cli_network_unix_test.go b/integration-cli/docker_cli_network_unix_test.go
--- a/integration-cli/docker_cli_network_unix_test.go 2022-06-03 10:30:24.000000000 -0700
+++ b/integration-cli/docker_cli_network_unix_test.go 2022-06-07 14:28:05.558328640 -0700
@@ -196,14 +196,14 @@
}
})
- err := os.MkdirAll("/etc/docker/plugins", 0755)
+ err := os.MkdirAll("/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins", 0755)
assert.NilError(c, err)
- fileName := fmt.Sprintf("/etc/docker/plugins/%s.spec", netDrv)
+ fileName := fmt.Sprintf("/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins/%s.spec", netDrv)
err = os.WriteFile(fileName, []byte(url), 0644)
assert.NilError(c, err)
- ipamFileName := fmt.Sprintf("/etc/docker/plugins/%s.spec", ipamDrv)
+ ipamFileName := fmt.Sprintf("/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins/%s.spec", ipamDrv)
err = os.WriteFile(ipamFileName, []byte(url), 0644)
assert.NilError(c, err)
}
@@ -215,7 +215,7 @@
s.server.Close()
- err := os.RemoveAll("/etc/docker/plugins")
+ err := os.RemoveAll("/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins")
assert.NilError(c, err)
}
diff -Naur a/integration-cli/docker_cli_swarm_test.go b/integration-cli/docker_cli_swarm_test.go
--- a/integration-cli/docker_cli_swarm_test.go 2022-06-03 10:30:24.000000000 -0700
+++ b/integration-cli/docker_cli_swarm_test.go 2022-06-07 14:28:05.561328685 -0700
@@ -770,14 +770,14 @@
}
})
- err := os.MkdirAll("/etc/docker/plugins", 0755)
+ err := os.MkdirAll("/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins", 0755)
assert.NilError(c, err)
- fileName := fmt.Sprintf("/etc/docker/plugins/%s.spec", netDrv)
+ fileName := fmt.Sprintf("/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins/%s.spec", netDrv)
err = os.WriteFile(fileName, []byte(url), 0644)
assert.NilError(c, err)
- ipamFileName := fmt.Sprintf("/etc/docker/plugins/%s.spec", ipamDrv)
+ ipamFileName := fmt.Sprintf("/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins/%s.spec", ipamDrv)
err = os.WriteFile(ipamFileName, []byte(url), 0644)
assert.NilError(c, err)
}
@@ -789,7 +789,7 @@
setupRemoteGlobalNetworkPlugin(c, mux, s.server.URL, globalNetworkPlugin, globalIPAMPlugin)
defer func() {
s.server.Close()
- err := os.RemoveAll("/etc/docker/plugins")
+ err := os.RemoveAll("/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins")
assert.NilError(c, err)
}()
diff -Naur a/libnetwork/drivers/remote/driver_test.go b/libnetwork/drivers/remote/driver_test.go
--- a/libnetwork/drivers/remote/driver_test.go 2022-06-03 10:30:24.000000000 -0700
+++ b/libnetwork/drivers/remote/driver_test.go 2022-06-07 14:28:05.586329065 -0700
@@ -41,7 +41,7 @@
}
func setupPlugin(t *testing.T, name string, mux *http.ServeMux) func() {
- specPath := "/etc/docker/plugins"
+ specPath := "/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins"
if runtime.GOOS == "windows" {
specPath = filepath.Join(os.Getenv("programdata"), "docker", "plugins")
}
diff -Naur a/libnetwork/ipams/remote/remote_test.go b/libnetwork/ipams/remote/remote_test.go
--- a/libnetwork/ipams/remote/remote_test.go 2022-06-03 10:30:24.000000000 -0700
+++ b/libnetwork/ipams/remote/remote_test.go 2022-06-07 14:28:05.591329141 -0700
@@ -36,7 +36,7 @@
}
func setupPlugin(t *testing.T, name string, mux *http.ServeMux) func() {
- specPath := "/etc/docker/plugins"
+ specPath := "/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins"
if runtime.GOOS == "windows" {
specPath = filepath.Join(os.Getenv("programdata"), "docker", "plugins")
}
diff -Naur a/libnetwork/libnetwork_unix_test.go b/libnetwork/libnetwork_unix_test.go
--- a/libnetwork/libnetwork_unix_test.go 2022-06-03 10:30:24.000000000 -0700
+++ b/libnetwork/libnetwork_unix_test.go 2022-06-07 14:28:05.592329156 -0700
@@ -3,4 +3,4 @@
package libnetwork_test
-var specPath = "/etc/docker/plugins"
+var specPath = "/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins"
diff -Naur a/pkg/plugins/discovery_unix.go b/pkg/plugins/discovery_unix.go
--- a/pkg/plugins/discovery_unix.go 2022-06-03 10:30:24.000000000 -0700
+++ b/pkg/plugins/discovery_unix.go 2022-06-07 14:28:05.615329505 -0700
@@ -3,4 +3,4 @@
package plugins // import "github.com/docker/docker/pkg/plugins"
-var specsPaths = []string{"/etc/docker/plugins", "/usr/lib/docker/plugins"}
+var specsPaths = []string{"/storage/.kodi/userdata/addon_data/service.system.docker/config/plugins", "/usr/lib/docker/plugins"}
diff -Naur a/pkg/plugins/plugins.go b/pkg/plugins/plugins.go
--- a/pkg/plugins/plugins.go 2022-06-03 10:30:24.000000000 -0700
+++ b/pkg/plugins/plugins.go 2022-06-07 14:28:05.616329521 -0700
@@ -4,7 +4,7 @@
// Docker discovers plugins by looking for them in the plugin directory whenever
// a user or container tries to use one by name. UNIX domain socket files must
// be located under /run/docker/plugins, whereas spec files can be located
-// either under /etc/docker/plugins or /usr/lib/docker/plugins. This is handled
+// either under /storage/.kodi/userdata/addon_data/service.system.docker/config/plugins or /usr/lib/docker/plugins. This is handled
// by the Registry interface, which lets you list all plugins or get a plugin by
// its name if it exists.
//
diff -Naur a/registry/config_unix.go b/registry/config_unix.go
--- a/registry/config_unix.go 2022-06-03 10:30:24.000000000 -0700
+++ b/registry/config_unix.go 2022-06-07 14:28:05.626329672 -0700
@@ -6,7 +6,7 @@
// defaultCertsDir is the platform-specific default directory where certificates
// are stored. On Linux, it may be overridden through certsDir, for example, when
// running in rootless mode.
-const defaultCertsDir = "/etc/docker/certs.d"
+const defaultCertsDir = "/storage/.kodi/userdata/addon_data/service.system.docker/config/certs.d"
// cleanPath is used to ensure that a directory name is valid on the target
// platform. It will be passed in something *similar* to a URL such as
diff -Naur a/registry/endpoint_v1.go b/registry/endpoint_v1.go
--- a/registry/endpoint_v1.go 2022-06-03 10:30:24.000000000 -0700
+++ b/registry/endpoint_v1.go 2022-06-07 14:28:05.627329688 -0700
@@ -63,7 +63,7 @@
if endpoint.IsSecure {
// If registry is secure and HTTPS failed, show user the error and tell them about `--insecure-registry`
// in case that's what they need. DO NOT accept unknown CA certificates, and DO NOT fallback to HTTP.
- return invalidParamf("invalid registry endpoint %s: %v. If this private registry supports only HTTP or HTTPS with an unknown CA certificate, please add `--insecure-registry %s` to the daemon's arguments. In the case of HTTPS, if you have access to the registry's CA certificate, no need for the flag; simply place the CA certificate at /etc/docker/certs.d/%s/ca.crt", endpoint, err, endpoint.URL.Host, endpoint.URL.Host)
+ return invalidParamf("invalid registry endpoint %s: %v. If this private registry supports only HTTP or HTTPS with an unknown CA certificate, please add `--insecure-registry %s` to the daemon's arguments. In the case of HTTPS, if you have access to the registry's CA certificate, no need for the flag; simply place the CA certificate at /storage/.kodi/userdata/addon_data/service.system.docker/config/certs.d/%s/ca.crt", endpoint, err, endpoint.URL.Host, endpoint.URL.Host)
}
// If registry is insecure and HTTPS failed, fallback to HTTP.

View file

@ -0,0 +1,22 @@
--- a/daemon/config/config.go 2022-06-03 10:30:24.000000000 -0700
+++ b/daemon/config/config.go 2022-06-07 14:29:36.755713207 -0700
@@ -59,7 +59,7 @@
LinuxV2RuntimeName = "io.containerd.runc.v2"
// SeccompProfileDefault is the built-in default seccomp profile.
- SeccompProfileDefault = "builtin"
+ SeccompProfileDefault = "unconfined"
// SeccompProfileUnconfined is a special profile name for seccomp to use an
// "unconfined" seccomp profile.
SeccompProfileUnconfined = "unconfined"
--- a/daemon/daemon_unix.go 2022-06-03 10:30:24.000000000 -0700
+++ b/daemon/daemon_unix.go 2022-06-07 14:34:55.315558083 -0700
@@ -1711,8 +1711,6 @@
func (daemon *Daemon) setupSeccompProfile() error {
switch profile := daemon.configStore.SeccompProfile; profile {
- case "", config.SeccompProfileDefault:
- daemon.seccompProfilePath = config.SeccompProfileDefault
case config.SeccompProfileUnconfined:
daemon.seccompProfilePath = config.SeccompProfileUnconfined
default:

View file

@ -0,0 +1,34 @@
# SPDX-License-Identifier: GPL-2.0-or-later
# Copyright (C) 2009-2016 Lukas Rusak (lrusak@libreelec.tv)
# Copyright (C) 2016-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="runc"
PKG_VERSION="1.1.4"
PKG_SHA256="4f02077432642eebd768fc857318ae7929290b3a3511eb1be338005e360cfa34"
PKG_LICENSE="APL"
PKG_SITE="https://github.com/opencontainers/runc"
PKG_URL="https://github.com/opencontainers/runc/archive/v${PKG_VERSION}.tar.gz"
PKG_DEPENDS_TARGET="toolchain go:host"
PKG_LONGDESC="A CLI tool for spawning and running containers according to the OCI specification."
PKG_TOOLCHAIN="manual"
# Git commit of the matching release https://github.com/opencontainers/runc/releases
PKG_GIT_COMMIT="6724737f999df9ee0d8ca5c6d7b81f97adc34374"
pre_make_target() {
go_configure
export LDFLAGS="-w -extldflags -static -X main.gitCommit=${PKG_GIT_COMMIT} -X main.version=$(cat ./VERSION) -extld ${CC}"
mkdir -p ${GOPATH}
if [ -d ${PKG_BUILD}/vendor ]; then
mv ${PKG_BUILD}/vendor ${GOPATH}/src
fi
ln -fs ${PKG_BUILD} ${GOPATH}/src/github.com/opencontainers/runc
}
make_target() {
mkdir -p bin
${GOLANG} build -v -o bin/runc -a -tags "cgo static_build" -ldflags "${LDFLAGS}" ./
}

View file

@ -0,0 +1,22 @@
# SPDX-License-Identifier: GPL-2.0-or-later
# Copyright (C) 2009-2016 Lukas Rusak (lrusak@libreelec.tv)
# Copyright (C) 2016-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="tini"
PKG_VERSION="0.19.0"
PKG_SHA256="0fd35a7030052acd9f58948d1d900fe1e432ee37103c5561554408bdac6bbf0d"
PKG_LICENSE="MIT"
PKG_SITE="https://github.com/krallin/tini"
PKG_URL="https://github.com/krallin/tini/archive/v${PKG_VERSION}.tar.gz"
PKG_DEPENDS_TARGET="toolchain"
PKG_LONGDESC="Tini is a simplest init system."
PKG_MAKE_OPTS_TARGET="tini-static"
pre_configure_target(){
sed -i "s|@tini_VERSION_GIT@| - git.${PKG_VERSION}|" ${PKG_BUILD}/src/tiniConfig.h.in
}
makeinstall_target() {
:
}

View file

@ -182,7 +182,7 @@ post_install() {
echo "chmod 4755 ${INSTALL}/usr/bin/busybox" >> $FAKEROOT_SCRIPT
echo "chmod 000 ${INSTALL}/usr/cache/shadow" >> $FAKEROOT_SCRIPT
add_user root "${ROOT}_PWD" 0 0 "Root User" "/storage" "/bin/sh"
add_user root "${ROOT}_PWD" 0 0 "Root User" "/storage" "/bin/bash"
add_group root 0
add_group users 100

View file

@ -1,3 +1,12 @@
DEVICE_BRIGHTNESS="100"
SPLASH_LOADER="imagemagick"
#UI_SERVICE="systemctl start emustation.service"
# FREQ Governors
CPU_FREQ=("/sys/devices/system/cpu/cpufreq/policy0" \
"/sys/devices/system/cpu/cpufreq/policy1" \
"/sys/devices/system/cpu/cpufreq/policy2" \
"/sys/devices/system/cpu/cpufreq/policy3")
# Affinity
SLOW_CORES="taskset -c 0-3"
FAST_CORES="${SLOW_CORES}"

View file

@ -1,30 +1,113 @@
# kernel command line
# kernel command line
EXTRA_CMDLINE="quiet console=tty0 ssh consoleblank=0 systemd.show_status=0 loglevel=0 panic=20"
# Partition label
# Partition label
PARTITION_TABLE="msdos"
# OpenGL(X) implementation to use (mesa / no)
# OpenGL(X) implementation to use (mesa / no)
OPENGL="mesa"
# OpenGL-ES implementation to use (mesa / no)
# OpenGL-ES implementation to use (mesa / no)
OPENGLES="mesa"
# Vulkan implementation to use (vulkan-loader / no)
# Vulkan implementation to use (vulkan-loader / no)
VULKAN="vulkan-loader"
# VULKAN_SUPPORT
# VULKAN_SUPPORT
VULKAN_SUPPORT="yes"
# Displayserver to use (weston / x11 / no)
# Displayserver to use (weston / x11 / no)
DISPLAYSERVER="wl"
# Windowmanager to use (fluxbox / weston / no)
# Windowmanager to use (fluxbox / weston / no)
WINDOWMANAGER="weston"
# Mesa 3D Graphic drivers to use (all / crocus,i915,iris,r300,r600,radeonsi,vmware,virtio)
# Space separated list is supported,
# e.g. GRAPHIC_DRIVERS="crocus i915 iris r300 r600 radeonsi vmware virtio"
# Mesa 3D Graphic drivers to use (all / crocus,i915,iris,r300,r600,radeonsi,vmware,virtio)
# Space separated list is supported,
# e.g. GRAPHIC_DRIVERS="crocus i915 iris r300 r600 radeonsi vmware virtio"
GRAPHIC_DRIVERS="crocus i915 iris r300 r600 radeonsi vmware virtio"
#VAAPI_SUPPORT="yes"
# additional packages to install
# ADDITIONAL_PACKAGES=""
# additional Firmware to use (dvb-firmware, misc-firmware, wlan-firmware)
# Space separated list is supported,
# e.g. FIRMWARE="dvb-firmware misc-firmware wlan-firmware"
FIRMWARE="misc-firmware wlan-firmware" #rockchip-firmware
# additional drivers to install:
# for a list of additional drivers see packages/linux-drivers
# Space separated list is supported,
# e.g. ADDITIONAL_DRIVERS="DRIVER1 DRIVER2"
# ADDITIONAL_DRIVERS=""
# build and install driver addons (yes / no)
DRIVER_ADDONS_SUPPORT="no"
# driver addons to install:
# for a list of additinoal drivers see packages/linux-driver-addons
# Space separated list is supported,
DRIVER_ADDONS=""
# debug tty path
DEBUG_TTY="/dev/ttyFIQ0"
# build and install PulseAudio support (yes / no)
PULSEAUDIO_SUPPORT="yes"
# build and install bluetooth support (yes / no)
BLUETOOTH_SUPPORT="no"
# build and install Avahi (Zeroconf) daemon (yes / no)
AVAHI_DAEMON="no"
# build with NFS support (mounting nfs shares via the OS) (yes / no)
NFS_SUPPORT="no"
# build with Samba Client support (mounting samba shares via the OS) (yes / no)
SAMBA_SUPPORT="no"
# build and install Samba Server (yes / no)
SAMBA_SERVER="yes"
# build and install SFTP Server (yes / no)
SFTP_SERVER="yes"
# build and install OpenVPN support (yes / no)
OPENVPN_SUPPORT="no"
# build and install diskmounter support (udevil)
# this service provide auto mounting support for external drives in the
# mediacenter also automount internally drives at boottime via udev (yes / no)
UDEVIL="yes"
# build and install exFAT fuse support (yes / no)
EXFAT="yes"
# build and install NTFS-3G fuse support (yes / no)
NTFS3G="yes"
# build and install hfs filesystem utilities (yes / no)
HFSTOOLS="no"
# Support for partitioning and formating disks in initramfs (yes / no)
# This adds support for parted and mkfs.ext3/4 to initramfs for OEM usage
INITRAMFS_PARTED_SUPPORT="yes"
# build with swap support (yes / no)
SWAP_SUPPORT="yes"
# swap support enabled per default (yes / no)
SWAP_ENABLED_DEFAULT="yes"
# swapfile size if SWAP_SUPPORT=yes in MB
SWAPFILESIZE="1024"
# cron support (yes / no)
CRON_SUPPORT="no"
# Settings package name - blank if not required
DISTRO_PKG_SETTINGS=""
# htop tool (yes / no)
HTOP_TOOL="yes"

View file

@ -0,0 +1,12 @@
DEVICE_BRIGHTNESS="100"
SPLASH_LOADER="imagemagick"
# FREQ Governors
CPU_FREQ=("/sys/devices/system/cpu/cpufreq/policy0" \
"/sys/devices/system/cpu/cpufreq/policy1" \
"/sys/devices/system/cpu/cpufreq/policy2" \
"/sys/devices/system/cpu/cpufreq/policy3")
# Affinity
SLOW_CORES="taskset -c 0-3"
FAST_CORES="${SLOW_CORES}"

View file

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,118 @@
# kernel command line
EXTRA_CMDLINE="quiet console=tty0 ssh consoleblank=0 systemd.show_status=0 loglevel=0 panic=20"
# Partition label
PARTITION_TABLE="msdos"
# OpenGL(X) implementation to use (mesa / no)
OPENGL="mesa"
# OpenGL-ES implementation to use (mesa / no)
OPENGLES="mesa"
# Vulkan implementation to use (vulkan-loader / no)
VULKAN="vulkan-loader"
# VULKAN_SUPPORT
VULKAN_SUPPORT="yes"
# Displayserver to use (weston / x11 / no)
DISPLAYSERVER="wl"
# Windowmanager to use (fluxbox / weston / no)
WINDOWMANAGER="weston"
# Mesa 3D Graphic drivers to use (all / crocus,i915,iris,r300,r600,radeonsi,vmware,virtio)
# Space separated list is supported,
# e.g. GRAPHIC_DRIVERS="crocus i915 iris r300 r600 radeonsi vmware virtio"
GRAPHIC_DRIVERS="crocus i915 iris r300 r600 radeonsi vmware virtio"
# additional packages to install
# ADDITIONAL_PACKAGES=""
if [ ! -z "${BASE_ONLY}" ]
then
ADDITIONAL_PACKAGES=" emulators gamesupport 351files"
fi
# additional Firmware to use (dvb-firmware, misc-firmware, wlan-firmware)
# Space separated list is supported,
# e.g. FIRMWARE="dvb-firmware misc-firmware wlan-firmware"
FIRMWARE="misc-firmware wlan-firmware" #rockchip-firmware
# additional drivers to install:
# for a list of additional drivers see packages/linux-drivers
# Space separated list is supported,
# e.g. ADDITIONAL_DRIVERS="DRIVER1 DRIVER2"
# ADDITIONAL_DRIVERS=""
# build and install driver addons (yes / no)
DRIVER_ADDONS_SUPPORT="no"
# driver addons to install:
# for a list of additinoal drivers see packages/linux-driver-addons
# Space separated list is supported,
DRIVER_ADDONS=""
# debug tty path
DEBUG_TTY="/dev/ttyFIQ0"
# build and install PulseAudio support (yes / no)
PULSEAUDIO_SUPPORT="yes"
# build and install bluetooth support (yes / no)
BLUETOOTH_SUPPORT="no"
# build and install Avahi (Zeroconf) daemon (yes / no)
AVAHI_DAEMON="no"
# build with NFS support (mounting nfs shares via the OS) (yes / no)
NFS_SUPPORT="no"
# build with Samba Client support (mounting samba shares via the OS) (yes / no)
SAMBA_SUPPORT="no"
# build and install Samba Server (yes / no)
SAMBA_SERVER="yes"
# build and install SFTP Server (yes / no)
SFTP_SERVER="yes"
# build and install OpenVPN support (yes / no)
OPENVPN_SUPPORT="no"
# build and install diskmounter support (udevil)
# this service provide auto mounting support for external drives in the
# mediacenter also automount internally drives at boottime via udev (yes / no)
UDEVIL="yes"
# build and install exFAT fuse support (yes / no)
EXFAT="yes"
# build and install NTFS-3G fuse support (yes / no)
NTFS3G="yes"
# build and install hfs filesystem utilities (yes / no)
HFSTOOLS="no"
# Support for partitioning and formating disks in initramfs (yes / no)
# This adds support for parted and mkfs.ext3/4 to initramfs for OEM usage
INITRAMFS_PARTED_SUPPORT="yes"
# build with swap support (yes / no)
SWAP_SUPPORT="yes"
# swap support enabled per default (yes / no)
SWAP_ENABLED_DEFAULT="yes"
# swapfile size if SWAP_SUPPORT=yes in MB
SWAPFILESIZE="1024"
# cron support (yes / no)
CRON_SUPPORT="no"
# Settings package name - blank if not required
DISTRO_PKG_SETTINGS=""
# htop tool (yes / no)
HTOP_TOOL="yes"

View file

@ -61,6 +61,10 @@
# additional packages to install
# ADDITIONAL_PACKAGES=""
if [ ! -z "${BASE_ONLY}" ]
then
ADDITIONAL_PACKAGES=" emulators gamesupport 351files"
fi
# additional Firmware to use (dvb-firmware, misc-firmware, wlan-firmware)
# Space separated list is supported,

View file

@ -61,6 +61,10 @@
# additional packages to install
# ADDITIONAL_PACKAGES=""
if [ ! -z "${BASE_ONLY}" ]
then
ADDITIONAL_PACKAGES=" emulators gamesupport 351files"
fi
# additional Firmware to use (dvb-firmware, misc-firmware, wlan-firmware)
# Space separated list is supported,

View file

@ -61,6 +61,10 @@
# additional packages to install
# ADDITIONAL_PACKAGES=""
if [ ! -z "${BASE_ONLY}" ]
then
ADDITIONAL_PACKAGES=" emulators gamesupport 351files"
fi
# additional Firmware to use (dvb-firmware, misc-firmware, wlan-firmware)
# Space separated list is supported,

View file

@ -63,6 +63,10 @@
# additional packages to install
#ADDITIONAL_PACKAGES=""
if [ ! -z "${BASE_ONLY}" ]
then
ADDITIONAL_PACKAGES=" emulators gamesupport 351files"
fi
# additional Firmware to use (dvb-firmware, misc-firmware, wlan-firmware)
# Space separated list is supported,

View file

@ -63,6 +63,10 @@
# additional packages to install
#ADDITIONAL_PACKAGES=""
if [ ! -z "${BASE_ONLY}" ]
then
ADDITIONAL_PACKAGES=" emulators gamesupport 351files"
fi
# additional Firmware to use (dvb-firmware, misc-firmware, wlan-firmware)
# Space separated list is supported,

View file

@ -60,6 +60,10 @@
# additional packages to install
#ADDITIONAL_PACKAGES=""
if [ ! -z "${BASE_ONLY}" ]
then
ADDITIONAL_PACKAGES=" emulators gamesupport 351files"
fi
# additional Firmware to use (dvb-firmware, misc-firmware, wlan-firmware)
# Space separated list is supported,