From owner-dev-commits-ports-main@freebsd.org Mon Jun 28 14:39:48 2021 Return-Path: Delivered-To: dev-commits-ports-main@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id BDC93656F4E; Mon, 28 Jun 2021 14:39:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4GD9HS50vHz3KsB; Mon, 28 Jun 2021 14:39:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 9045026E20; Mon, 28 Jun 2021 14:39:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 15SEdmHK023317; Mon, 28 Jun 2021 14:39:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 15SEdm3I023316; Mon, 28 Jun 2021 14:39:48 GMT (envelope-from git) Date: Mon, 28 Jun 2021 14:39:48 GMT Message-Id: <202106281439.15SEdm3I023316@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Adriaan de Groot Subject: git: ed9df2d08f78 - main - devel/libsoup: make samba a (not registered) runtime dep MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: adridg X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ed9df2d08f7837c866f525515b8fc8c83a919694 Auto-Submitted: auto-generated X-BeenThere: dev-commits-ports-main@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Commits to the main branch of the FreeBSD ports repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 28 Jun 2021 14:39:48 -0000 The branch main has been updated by adridg: URL: https://cgit.FreeBSD.org/ports/commit/?id=ed9df2d08f7837c866f525515b8fc8c83a919694 commit ed9df2d08f7837c866f525515b8fc8c83a919694 Author: Adriaan de Groot AuthorDate: 2021-06-12 14:19:46 +0000 Commit: Adriaan de Groot CommitDate: 2021-06-28 14:39:46 +0000 devel/libsoup: make samba a (not registered) runtime dep This picks up an idea from PR 235207 again, where NTLM authentication is optional. Previous commits made samba a build-dependency so that the --enable-ntlm option would work. The meson build -- even though the dep is entirely runtime -- would check for the presence of ntlm_auth at build-time, to be able to pass in the path to ntlm_auth to the build. Re-jig this to not do the check, accept the option as-is, and use a likely path to ntlm_auth instead (which is what the original patch in 235207 did). A circular dependency from samba41[23] -> libsoup and back can be triggered by setting option SMB in libsoup and option SPOTLIGHT in samba. Originally the runtime dependency was registered as USES= samba:run A _RUN dependency still wants to build, though, and package and index builds failed. Cut the circular dependency by **not** registering samba as a runtime dependency and using a pkg-message to tell users to possibly install samba. Anyone who now has "but my samba is installed in a different prefix" can file a PR with a patch fixing meson better. PR: 256076 Reported by: Dimitry Andric --- devel/libsoup/Makefile | 31 +++++++++++++++++++++++-------- devel/libsoup/files/patch-meson.build | 17 +++++++++++++++++ devel/libsoup/pkg-message | 10 ++++++++++ 3 files changed, 50 insertions(+), 8 deletions(-) diff --git a/devel/libsoup/Makefile b/devel/libsoup/Makefile index ab65d9a4bc01..be036f740e3d 100644 --- a/devel/libsoup/Makefile +++ b/devel/libsoup/Makefile @@ -2,7 +2,7 @@ PORTNAME= libsoup PORTVERSION= 2.72.0 -PORTREVISION= 3 +PORTREVISION= 4 CATEGORIES= devel gnome MASTER_SITES= GNOME DIST_SUBDIR= gnome @@ -18,14 +18,27 @@ LIB_DEPENDS= libgcrypt.so:security/libgcrypt \ libpsl.so:dns/libpsl RUN_DEPENDS= glib-networking>=2.29.18:net/glib-networking -PORTSCOUT= limitw:1,even +USES= gettext gnome localbase meson \ + pkgconfig python:3.6+,build sqlite ssl tar:xz +USE_GNOME= glib20 intlhack introspection:build \ + libxml2 +USE_LDCONFIG= yes OPTIONS_DEFINE= SMB OPTIONS_SINGLE= GSSAPI OPTIONS_SINGLE_GSSAPI= GSSAPI_BASE GSSAPI_HEIMDAL GSSAPI_MIT GSSAPI_NONE OPTIONS_DEFAULT= SMB GSSAPI_${${SSL_DEFAULT} == base :?BASE :NONE} -SMB_USES= samba:build +# Circular dependency samba -> tracker -> libsoup if the SPOTLIGHT +# option is turned on in samba. Since samba is a **runtime** only +# dependency, we can just tell it to be used. However, the Meson +# build does a **build** time check for samba (even though the code does +# a run-time check, too). +# +# Runtime deps still trigger a build / a dependency cycle, so as +# a stopgap, patch it in, don't build anything, and inform the +# user via pkg-message. +# SMB_USES= samba:run SMB_MESON_ENABLED= ntlm GSSAPI_BASE_USES= gssapi @@ -39,11 +52,6 @@ GSSAPI_MIT_MESON_ON= -Dgssapi=enabled -Dkrb5_config=${KRB5CONFIG} GSSAPI_NONE_MESON_DISABLED= gssapi -USES= gettext gnome localbase meson \ - pkgconfig python:3.6+,build sqlite ssl tar:xz -USE_GNOME= glib20 intlhack introspection:build \ - libxml2 -USE_LDCONFIG= yes MESON_ARGS= -Dvapi=disabled \ -Dsysprof=disabled \ -Dtests=false \ @@ -53,4 +61,11 @@ MESON_ARGS= -Dvapi=disabled \ LIBVERSION= 1.11.0 PLIST_SUB= VERSION="2.4" LIBVERSION=${LIBVERSION} +PORTSCOUT= limitw:1,even + +post-patch: + ${REINPLACE_CMD} \ + -e 's+@@NTLM_AUTH@@+${LOCALBASE}/bin/ntlm_auth+' \ + ${WRKSRC}/meson.build + .include diff --git a/devel/libsoup/files/patch-meson.build b/devel/libsoup/files/patch-meson.build new file mode 100644 index 000000000000..a5c6a02454bb --- /dev/null +++ b/devel/libsoup/files/patch-meson.build @@ -0,0 +1,17 @@ +--- meson.build.orig 2021-06-12 13:43:16 UTC ++++ meson.build +@@ -340,11 +340,11 @@ endif + ################ + # NTLM not supported on Windows + if host_machine.system() != 'windows' +- ntlm_auth = find_program(get_option('ntlm_auth'), required: get_option('ntlm')) ++ # ntlm_auth = find_program(get_option('ntlm_auth'), required: get_option('ntlm')) + +- if ntlm_auth.found() ++ if get_option('ntlm').enabled() + add_project_arguments('-DUSE_NTLM_AUTH=1', language : 'c') +- add_project_arguments('-DNTLM_AUTH="' + ntlm_auth.path() + '"', language : 'c') ++ add_project_arguments('-DNTLM_AUTH="@@NTLM_AUTH@@"', language : 'c') + endif + endif + diff --git a/devel/libsoup/pkg-message b/devel/libsoup/pkg-message new file mode 100644 index 000000000000..3b9b3c2e1209 --- /dev/null +++ b/devel/libsoup/pkg-message @@ -0,0 +1,10 @@ +[ +{ + type: install + message: <