Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified)) by mollari.NetBSD.org (Postfix) with ESMTPS id 0988F1A9217 for ; Tue, 20 Oct 2020 18:40:35 +0000 (UTC) Received: by mail.netbsd.org (Postfix, from userid 605) id 9BA0984DDE; Tue, 20 Oct 2020 18:40:34 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by mail.netbsd.org (Postfix) with ESMTP id 2264E84DBE for ; Tue, 20 Oct 2020 18:40:34 +0000 (UTC) X-Virus-Scanned: amavisd-new at netbsd.org Received: from mail.netbsd.org ([127.0.0.1]) by localhost (mail.netbsd.org [127.0.0.1]) (amavisd-new, port 10025) with ESMTP id vQdvOs7sFXu5 for ; Tue, 20 Oct 2020 18:40:33 +0000 (UTC) Received: from cvs.NetBSD.org (ivanova.netbsd.org [199.233.217.197]) by mail.netbsd.org (Postfix) with ESMTP id 53F9984D02 for ; Tue, 20 Oct 2020 18:40:33 +0000 (UTC) Received: by cvs.NetBSD.org (Postfix, from userid 500) id DA5DCFB28; Tue, 20 Oct 2020 18:40:31 +0000 (UTC) Content-Transfer-Encoding: 7bit Content-Type: multipart/mixed; boundary="_----------=_1603219231145030" MIME-Version: 1.0 Date: Tue, 20 Oct 2020 18:40:31 +0000 From: "Tobias Nygren" Subject: CVS commit: pkgsrc/audio/ncspot To: pkgsrc-changes@NetBSD.org Reply-To: tnn@netbsd.org X-Mailer: log_accum Message-Id: <20201020184031.DA5DCFB28@cvs.NetBSD.org> Sender: pkgsrc-changes-owner@NetBSD.org List-Id: pkgsrc-changes.NetBSD.org Precedence: bulk List-Unsubscribe: This is a multi-part message in MIME format. --_----------=_1603219231145030 Content-Disposition: inline Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII" Module Name: pkgsrc Committed By: tnn Date: Tue Oct 20 18:40:31 UTC 2020 Modified Files: pkgsrc/audio/ncspot: Makefile distinfo Added Files: pkgsrc/audio/ncspot: options.mk Removed Files: pkgsrc/audio/ncspot/patches: patch-Cargo.toml Log Message: ncspot: use PKG_OPTIONS framework In particular allow building w/o dbus and wide curses but also add options for the various supported audio backends while here (untested). Also promote libxcb to full dependency because it failed with "ld: cannot find -lxcb" when disabling dbus. To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 pkgsrc/audio/ncspot/Makefile cvs rdiff -u -r1.4 -r1.5 pkgsrc/audio/ncspot/distinfo cvs rdiff -u -r0 -r1.1 pkgsrc/audio/ncspot/options.mk cvs rdiff -u -r1.4 -r0 pkgsrc/audio/ncspot/patches/patch-Cargo.toml Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. --_----------=_1603219231145030 Content-Disposition: inline Content-Length: 4827 Content-Transfer-Encoding: binary Content-Type: text/x-diff; charset=us-ascii Modified files: Index: pkgsrc/audio/ncspot/Makefile diff -u pkgsrc/audio/ncspot/Makefile:1.5 pkgsrc/audio/ncspot/Makefile:1.6 --- pkgsrc/audio/ncspot/Makefile:1.5 Mon Oct 12 12:04:13 2020 +++ pkgsrc/audio/ncspot/Makefile Tue Oct 20 18:40:31 2020 @@ -1,6 +1,7 @@ -# $NetBSD: Makefile,v 1.5 2020/10/12 12:04:13 pin Exp $ +# $NetBSD: Makefile,v 1.6 2020/10/20 18:40:31 tnn Exp $ DISTNAME= ncspot-0.2.3 +PKGREVISION= 1 CATEGORIES= audio MASTER_SITES= ${MASTER_SITE_GITHUB:=hrkfdn/} GITHUB_TAG= v${PKGVERSION_NOREV} @@ -15,8 +16,6 @@ USE_TOOLS+= pkg-config PYTHON_VERSIONS_ACCEPTED= 37 PYTHON_FOR_BUILD_ONLY= tool -USE_NCURSES= yes # NCURSES_MOUSE_VERSION, also needs wide support - CARGO_CRATE_DEPENDS+= addr2line-0.13.0 CARGO_CRATE_DEPENDS+= adler-0.2.3 CARGO_CRATE_DEPENDS+= aes-0.3.2 @@ -425,19 +424,21 @@ CARGO_CRATE_DEPENDS+= xml-rs-0.6.1 INSTALLATION_DIRS= bin MAKE_ENV+= OPENSSL_DIR=${BUILDLINK_PREFIX.openssl:Q} -RUSTFLAGS+= -C link-arg=${COMPILER_RPATH_FLAG}${BUILDLINK_PREFIX.ncursesw}/lib RUSTFLAGS+= -C link-arg=${COMPILER_RPATH_FLAG}${BUILDLINK_PREFIX.openssl}/lib -RUSTFLAGS+= -C link-arg=${COMPILER_RPATH_FLAG}${BUILDLINK_PREFIX.portaudio}/${BUILDLINK_LIBDIRS.portaudio} +RUSTFLAGS+= -C link-arg=${COMPILER_RPATH_FLAG}${BUILDLINK_PREFIX.libxcb}/lib +RUSTFLAGS+= -C link-arg=-L${BUILDLINK_PREFIX.libxcb}/lib MAKE_ENV+= RUSTFLAGS=${RUSTFLAGS:Q} +CARGO_ARGS= ${DEFAULT_CARGO_ARGS} --no-default-features --features ${CARGO_FEATURES:S/ /,/Wg} + +CARGO_FEATURES+= share_clipboard + +.include "options.mk" do-install: ${INSTALL_PROGRAM} ${WRKSRC}/target/release/ncspot ${DESTDIR}${PREFIX}/bin -.include "../../audio/portaudio/buildlink3.mk" -.include "../../devel/ncursesw/buildlink3.mk" +.include "../../lang/python/tool.mk" +.include "../../lang/rust/cargo.mk" .include "../../security/openssl/buildlink3.mk" -.include "../../sysutils/dbus/buildlink3.mk" -BUILDLINK_DEPMETHOD.libxcb?= build .include "../../x11/libxcb/buildlink3.mk" -.include "../../lang/rust/cargo.mk" .include "../../mk/bsd.pkg.mk" Index: pkgsrc/audio/ncspot/distinfo diff -u pkgsrc/audio/ncspot/distinfo:1.4 pkgsrc/audio/ncspot/distinfo:1.5 --- pkgsrc/audio/ncspot/distinfo:1.4 Mon Oct 12 12:04:13 2020 +++ pkgsrc/audio/ncspot/distinfo Tue Oct 20 18:40:31 2020 @@ -1,4 +1,4 @@ -$NetBSD: distinfo,v 1.4 2020/10/12 12:04:13 pin Exp $ +$NetBSD: distinfo,v 1.5 2020/10/20 18:40:31 tnn Exp $ SHA1 (addr2line-0.13.0.crate) = c7a6843df774a95b4db5a5511b58ab22c44f228a RMD160 (addr2line-0.13.0.crate) = 22c733c5358313e9ca7fb95d1dbd695d03fcb552 @@ -1616,4 +1616,3 @@ SHA1 (xml-rs-0.6.1.crate) = 6e27cecdbbc1 RMD160 (xml-rs-0.6.1.crate) = 470f5a78a46aac7c503aad7a8a00c006c69d898d SHA512 (xml-rs-0.6.1.crate) = 27bba3095a92162f4e0b9f27c2c4c49bd61433ccbbd36957c8347aa25f397d7902253b755f0e70809b96db178cee02620b14e120a80111d4e3da4b40cf2203ab Size (xml-rs-0.6.1.crate) = 50922 bytes -SHA1 (patch-Cargo.toml) = cce572043d1ccd8b59f133487e34a6f6b9a099ed Added files: Index: pkgsrc/audio/ncspot/options.mk diff -u /dev/null pkgsrc/audio/ncspot/options.mk:1.1 --- /dev/null Tue Oct 20 18:40:31 2020 +++ pkgsrc/audio/ncspot/options.mk Tue Oct 20 18:40:31 2020 @@ -0,0 +1,53 @@ +# $NetBSD: options.mk,v 1.1 2020/10/20 18:40:31 tnn Exp $ + +PKG_OPTIONS_VAR= PKG_OPTIONS.ncspot +PKG_OPTIONS_OPTIONAL_GROUPS= backend ui +PKG_OPTIONS_GROUP.backend= alsa portaudio pulseaudio rodio +PKG_OPTIONS_GROUP.ui= ncursesw termion + +PKG_SUPPORTED_OPTIONS= dbus +PKG_SUGGESTED_OPTIONS= portaudio ncursesw + +.include "../../mk/bsd.options.mk" + +.if !empty(PKG_OPTIONS:Malsa) +CARGO_FEATURES+= alsa_backend +RUSTFLAGS+= -C link-arg=${COMPILER_RPATH_FLAG}${BUILDLINK_PREFIX.alsa-lib}/lib +.include "../../audio/alsa-lib/buildlink3.mk" +.endif + +.if !empty(PKG_OPTIONS:Mportaudio) +CARGO_FEATURES+= portaudio_backend +RUSTFLAGS+= -C link-arg=${COMPILER_RPATH_FLAG}${BUILDLINK_PREFIX.portaudio}/${BUILDLINK_LIBDIRS.portaudio} +.include "../../audio/portaudio/buildlink3.mk" +.endif + +.if !empty(PKG_OPTIONS:Mpulseaudio) +CARGO_FEATURES+= pulseaudio_backend +RUSTFLAGS+= -C link-arg=${COMPILER_RPATH_FLAG}${BUILDLINK_PREFIX.pulseaudio}/lib +.include "../../audio/pulseaudio/buildlink3.mk" +.endif + +.if !empty(PKG_OPTIONS:Mrodio) +CARGO_FEATURES+= rodio_backend +.endif + +.if !empty(PKG_OPTIONS:Mncursesw) +USE_NCURSES= yes # NCURSES_MOUSE_VERSION +CARGO_FEATURES+= cursive/pancurses-backend +RUSTFLAGS+= -C link-arg=${COMPILER_RPATH_FLAG}${BUILDLINK_PREFIX.ncursesw}/lib +.include "../../devel/ncursesw/buildlink3.mk" +.endif + +.if !empty(PKG_OPTIONS:Mtermion) +CARGO_FEATURES+= cursive/termion-backend +.endif + +.if !empty(PKG_OPTIONS:Mdbus) +CARGO_FEATURES+= mpris +CARGO_FEATURES+= notif +RUSTFLAGS+= -C link-arg=${COMPILER_RPATH_FLAG}${BUILDLINK_PREFIX.dbus}/lib +. include "../../sysutils/dbus/buildlink3.mk" +.else + +.endif --_----------=_1603219231145030--