From 1298a4ceda593a690c689d2905c574ce192a6071 Mon Sep 17 00:00:00 2001 From: Andy Walsh Date: Tue, 3 Dec 2019 16:06:07 +0100 Subject: [PATCH] samba4: make host-buildtools private/add suffix * fix openwrt/packages#10700 * add suffix to asn1_compile, compile_et to avoid krb5 conflicts * bundle samba's com_err Signed-off-by: Andy Walsh --- net/samba4/Makefile | 13 +++++++------ net/samba4/patches/012-add_host_tools_suffix.patch | 11 +++++++++++ 2 files changed, 18 insertions(+), 6 deletions(-) create mode 100644 net/samba4/patches/012-add_host_tools_suffix.patch diff --git a/net/samba4/Makefile b/net/samba4/Makefile index b4e7690f6..738522398 100644 --- a/net/samba4/Makefile +++ b/net/samba4/Makefile @@ -56,7 +56,7 @@ endef define Package/samba4-libs $(call Package/samba4/Default) TITLE+= libs - DEPENDS:= +zlib +libtirpc +libpopt +libcomerr +libreadline +libcap \ + DEPENDS:= +zlib +libtirpc +libpopt +libreadline +libcap \ +PACKAGE_libpthread:libpthread +PACKAGE_libnettle:libnettle +PACKAGE_libgcrypt:libgcrypt +PACKAGE_libpam:libpam +PACKAGE_dbus:dbus +PACKAGE_libavahi-client:libavahi-client \ +SAMBA4_SERVER_VFS:attr \ +SAMBA4_SERVER_ACL:acl +SAMBA4_SERVER_ACL:attr \ @@ -298,12 +298,12 @@ BUILD_TARGETS_UTILS :=smbstatus,smbtree,smbget,mvxattr,nmblookup # lib bundling # NOTE: bundle + make private, we want to avoid version configuration (build, link) conflicts -CONFIGURE_ARGS += --builtin-libraries=talloc,tevent,tevent-util,texpect,tdb,ldb,tdr,cmocka +CONFIGURE_ARGS += --builtin-libraries=talloc,tevent,tevent-util,texpect,tdb,ldb,tdr,cmocka,com_err HOST_CONFIGURE_ARGS += --builtin-libraries=replace --nonshared-binary=asn1_compile,compile_et #CONFIGURE_ARGS += --bundled-libraries=talloc,tevent,tevent-util,texpect,tdb,ldb,tdr,cmocka,replace,!asn1_compile,!compile_et,!popt -CONFIGURE_ARGS += --bundled-libraries=talloc,tevent,tevent-util,texpect,tdb,ldb,tdr,cmocka,replace,roken,wind,hx509,asn1,heimbase,hcrypto,krb5,gssapi,heimntlm,hdb,kdc,NONE +CONFIGURE_ARGS += --bundled-libraries=talloc,tevent,tevent-util,texpect,tdb,ldb,tdr,cmocka,replace,com_err,roken,wind,hx509,asn1,heimbase,hcrypto,krb5,gssapi,heimntlm,hdb,kdc,NONE # BUG: --private-libraries, Does not work for System possible libs, will not get "samba4" suffix! -CONFIGURE_ARGS += --private-libraries=talloc,tevent,tevent-util,texpect,tdb,ldb,tdr,cmocka,replace +CONFIGURE_ARGS += --private-libraries=talloc,tevent,tevent-util,texpect,tdb,ldb,tdr,cmocka,replace,com_err # CONFIGURE_ARGS += --disable-symbol-versions define Host/Compile @@ -315,8 +315,9 @@ endef define Host/Install $(INSTALL_DIR) $(STAGING_DIR_HOSTPKG)/bin/ - $(INSTALL_BIN) $(HOST_BUILD_DIR)/bin/asn1_compile $(STAGING_DIR_HOSTPKG)/bin/ - $(INSTALL_BIN) $(HOST_BUILD_DIR)/bin/compile_et $(STAGING_DIR_HOSTPKG)/bin/ + # add host tools suffix, prevent conflicts with krb5 + $(INSTALL_BIN) $(HOST_BUILD_DIR)/bin/asn1_compile $(STAGING_DIR_HOSTPKG)/bin/asn1_compile_samba + $(INSTALL_BIN) $(HOST_BUILD_DIR)/bin/compile_et $(STAGING_DIR_HOSTPKG)/bin/compile_et_samba endef define Build/Prepare diff --git a/net/samba4/patches/012-add_host_tools_suffix.patch b/net/samba4/patches/012-add_host_tools_suffix.patch new file mode 100644 index 000000000..383002ff5 --- /dev/null +++ b/net/samba4/patches/012-add_host_tools_suffix.patch @@ -0,0 +1,11 @@ +--- a/source4/heimdal_build/wscript_configure 2019-12-03 ++++ b/source4/heimdal_build/wscript_configure 2019-12-03 +@@ -199,7 +199,7 @@ def check_system_heimdal_lib(name, funct + def check_system_heimdal_binary(name): + if conf.LIB_MAY_BE_BUNDLED(name): + return False +- if not conf.find_program(name, var=name.upper()): ++ if not conf.find_program(name + '_samba', var=name.upper()): + return False + conf.define('USING_SYSTEM_%s' % name.upper(), 1) + return True