samba: Bump to 4.15.11

This commit is contained in:
termux-pacman-bot
2022-10-26 04:31:45 +00:00
parent b52cccbb8a
commit bb33c34d36
5 changed files with 48 additions and 60 deletions

View File

@@ -131,21 +131,6 @@ diff -uNr samba-4.13.2/source3/modules/vfs_aio_pthread.c samba-4.13.2.mod/source
.openat_fn = aio_pthread_openat_fn,
#endif
};
diff -uNr samba-4.13.2/source3/modules/vfs_aio_pthread.c.rej samba-4.13.2.mod/source3/modules/vfs_aio_pthread.c.rej
--- samba-4.13.2/source3/modules/vfs_aio_pthread.c.rej 1970-01-01 00:00:00.000000000 +0000
+++ samba-4.13.2.mod/source3/modules/vfs_aio_pthread.c.rej 2020-11-23 13:26:08.058004764 +0000
@@ -0,0 +1,11 @@
+--- source3/modules/vfs_aio_pthread.c
++++ source3/modules/vfs_aio_pthread.c
+@@ -477,7 +466,7 @@ static int aio_pthread_open_fn(vfs_handle_struct *handle,
+ #endif
+
+ static struct vfs_fn_pointers vfs_aio_pthread_fns = {
+-#if defined(HAVE_OPENAT) && defined(HAVE_LINUX_THREAD_CREDENTIALS)
++#if defined(HAVE_OPENAT)
+ .open_fn = aio_pthread_open_fn,
+ #endif
+ };
diff -uNr samba-4.13.2/source3/modules/vfs_default.c samba-4.13.2.mod/source3/modules/vfs_default.c
--- samba-4.13.2/source3/modules/vfs_default.c 2020-07-09 09:33:56.000000000 +0000
+++ samba-4.13.2.mod/source3/modules/vfs_default.c 2020-11-23 13:26:08.059004828 +0000
@@ -295,9 +280,9 @@ diff -uNr samba-4.13.2/source3/wscript samba-4.13.2.mod/source3/wscript
- execute=True,
- mandatory=True,
- msg="Checking whether setuidx is available")
if Options.options.with_dnsupdate:
if not conf.CONFIG_SET('HAVE_KRB5'):
Logs.warn("--with-dnsupdate=yes but gssapi support not sufficient")
# valgrind.h or valgrind/valgrind.h is checked in lib/replace/wscript
if Options.options.developer:
if conf.CONFIG_SET('HAVE_VALGRIND_H') or conf.CONFIG_SET('HAVE_VALGRIND_VALGRIND_H'):
diff -uNr samba-4.13.2/tests/summary.c samba-4.13.2.mod/tests/summary.c
--- samba-4.13.2/tests/summary.c 2020-07-09 09:33:57.000000000 +0000
+++ samba-4.13.2.mod/tests/summary.c 2020-11-23 13:26:08.060004892 +0000

View File

@@ -2,10 +2,10 @@ TERMUX_PKG_HOMEPAGE=https://www.samba.org/
TERMUX_PKG_DESCRIPTION="SMB/CIFS fileserver"
TERMUX_PKG_LICENSE="GPL-3.0"
TERMUX_PKG_MAINTAINER="@termux"
TERMUX_PKG_VERSION=4.14.14
TERMUX_PKG_VERSION=4.15.11
TERMUX_PKG_SRCURL=https://download.samba.org/pub/samba/samba-${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_SHA256=abd5e9e6aa45e55114b188ba189ebdfc8fd3d7718d43f749e477ce7f791e5519
TERMUX_PKG_DEPENDS="libbsd, libcap, libcrypt, libgnutls, libiconv, libicu, libpopt, libtalloc, libtirpc, ncurses, openssl, readline, tdb-tools, zlib"
TERMUX_PKG_SHA256=2f305980d49c7723cbef281fff2b81a2eeafae51e58b5172bb43d9693ef8953b
TERMUX_PKG_DEPENDS="krb5, libandroid-spawn, libbsd, libcap, libcrypt, libgnutls, libiconv, libicu, libpopt, libtalloc, libtasn1, libtirpc, ncurses, openssl, readline, tdb-tools, zlib"
TERMUX_PKG_BUILD_DEPENDS="e2fsprogs"
TERMUX_PKG_BUILD_IN_SRC=true
@@ -21,15 +21,12 @@ share/man/man8/tdbrestore.8.gz
share/man/man8/tdbtool.8.gz
"
termux_step_pre_configure() {
CPPFLAGS+=" -D_FILE_OFFSET_BITS=64"
LDFLAGS+=" -landroid-spawn"
}
termux_step_configure() {
:
}
termux_step_make() {
:
}
termux_step_make_install() {
local _auth_modules='auth_server,auth_netlogond,auth_script'
local _pdb_modules='pdb_tdbsam,pdb_smbpasswd,pdb_wbc_sam'
local _vfs_modules='vfs_fake_perms,!vfs_recycle,!vfs_btrfs,!vfs_glusterfs_fuse'
@@ -87,11 +84,13 @@ Checking whether the realpath function allows a NULL argument: OK
Checking for ftruncate extend: OK
getcwd takes a NULL argument: OK
Checking for readlink breakage: NO
Checking for gnutls fips mode support: NO
Checking whether the WRFILE -keytab is supported: OK
EOF
USING_SYSTEM_ASN1_COMPILE=1 ASN1_COMPILE=/usr/bin/asn1_compile \
USING_SYSTEM_COMPILE_ET=1 COMPILE_ET=/usr/bin/compile_et \
CFLAGS="-D__ANDROID_API__=24 -D__USE_FILE_OFFSET64=1" \
CFLAGS="$CFLAGS" LINKFLAGS="$CFLAGS $LDFLAGS" \
./buildtools/bin/waf configure \
--jobs="$TERMUX_MAKE_PROCESSES" \
--bundled-libraries='!asn1_compile,!compile_et' \
@@ -118,7 +117,6 @@ EOF
--without-ads \
--without-automount \
--without-dmapi \
--without-dnsupdate \
--without-fam \
--without-gettext \
--with-gpfs=/dev/null \
@@ -128,10 +126,10 @@ EOF
--without-ldb-lmdb \
--without-libarchive \
--without-lttng \
--without-ntvfs-fileserver \
--without-pam \
--without-quotas \
--without-regedit \
--with-system-mitkrb5 "$TERMUX_PREFIX" \
--without-systemd \
--without-utmp \
--without-winbind \
@@ -140,10 +138,21 @@ EOF
# --disable-fault-handling \
# --disable-rpath-private-install \
# --with-logfilebase="$TERMUX_PREFIX/tmp/log/samba" \
(cat cross-answers.txt | grep UNKNOWN && return 1)
(cat cross-answers.txt | grep UNKNOWN && return 1)
}
termux_step_make() {
./buildtools/bin/waf build --jobs="$TERMUX_MAKE_PROCESSES"
}
termux_step_make_install() {
./buildtools/bin/waf install --jobs="$TERMUX_MAKE_PROCESSES"
}
termux_step_post_make_install() {
install -Dm700 -t "$TERMUX_PREFIX/bin" \
"$TERMUX_PKG_SRCDIR/examples/scripts/nmb/findsmb"
mkdir -p "$TERMUX_PREFIX/share/doc/samba"
sed -e "s|@TERMUX_PREFIX@|${TERMUX_PREFIX}|g" \
"$TERMUX_PKG_BUILDER_DIR/smb.conf.example.in" \

View File

@@ -0,0 +1,11 @@
--- a/examples/scripts/nmb/findsmb
+++ b/examples/scripts/nmb/findsmb
@@ -20,7 +20,7 @@
# -r add -r option to nmblookup when finding netbios name
#
-$SAMBABIN = "/usr/bin";
+$SAMBABIN = "@TERMUX_PREFIX@/bin";
for ($i = 0; $i < 2; $i++) { # test for -d and -r options
$_ = shift;

View File

@@ -57,7 +57,7 @@ diff --git a/source3/passdb/passdb.c b/source3/passdb/passdb.c
index a66b646..15c1251 100644
--- a/source3/passdb/passdb.c
+++ b/source3/passdb/passdb.c
@@ -148,21 +148,10 @@ static NTSTATUS samu_set_unix_internal(struct pdb_methods *methods,
@@ -148,24 +148,10 @@ static NTSTATUS samu_set_unix_internal(struct pdb_methods *methods,
fullname = NULL;
@@ -70,13 +70,16 @@ index a66b646..15c1251 100644
- fullname = talloc_strndup(
- talloc_tos(), pwd->pw_gecos,
- strchr(pwd->pw_gecos, ',') - pwd->pw_gecos);
- if (fullname == NULL) {
- return NT_STATUS_NO_MEMORY;
- }
- }
-
if (fullname != NULL) {
pdb_set_fullname(user, fullname, PDB_SET);
ok = pdb_set_fullname(user, fullname, PDB_SET);
} else {
- pdb_set_fullname(user, pwd->pw_gecos, PDB_SET);
+ pdb_set_fullname(user, pwd->pw_name, PDB_SET);
- ok = pdb_set_fullname(user, pwd->pw_gecos, PDB_SET);
+ ok = pdb_set_fullname(user, pwd->pw_name, PDB_SET);
}
TALLOC_FREE(fullname);
@@ -94,25 +97,3 @@ index 8dc09eb..52d1ecc 100644
tmp = talloc_sub_specified(
state, info->homedir, acct_name,
info->primary_group_name, info->domain_name,
diff --git a/source4/auth/ntlm/auth_unix.c b/source4/auth/ntlm/auth_unix.c
index 67cd5f3..bf1bc6d 100644
--- a/source4/auth/ntlm/auth_unix.c
+++ b/source4/auth/ntlm/auth_unix.c
@@ -83,7 +83,7 @@ static NTSTATUS authunix_make_user_info_dc(TALLOC_CTX *mem_ctx,
user_info_dc->user_session_key = data_blob(NULL,0);
user_info_dc->lm_session_key = data_blob(NULL,0);
- info->full_name = talloc_steal(info, pwd->pw_gecos);
+ info->full_name = talloc_strdup(info, pwd->pw_name); /* XXX: I _think_ talloc_steal here for pw_name would be wrong */
NT_STATUS_HAVE_NO_MEMORY(info->full_name);
info->logon_script = talloc_strdup(info, "");
NT_STATUS_HAVE_NO_MEMORY(info->logon_script);
@@ -132,8 +132,6 @@ static NTSTATUS talloc_getpwnam(TALLOC_CTX *ctx, const char *username, struct pa
ret->pw_uid = from->pw_uid;
ret->pw_gid = from->pw_gid;
- ret->pw_gecos = talloc_strdup(ctx, from->pw_gecos);
- NT_STATUS_HAVE_NO_MEMORY(ret->pw_gecos);
ret->pw_dir = talloc_strdup(ctx, from->pw_dir);
NT_STATUS_HAVE_NO_MEMORY(ret->pw_dir);

View File

@@ -30,11 +30,13 @@
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:
@@ -96,9 +88,6 @@ 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.env.KRB5_VENDOR = 'heimdal'
conf.define('USING_SYSTEM_KRB5', 1)
conf.define('USING_SYSTEM_HEIMDAL', 1)