From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id ED7941382C5 for ; Mon, 18 Jan 2021 21:10:14 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 40FFAE0875; Mon, 18 Jan 2021 21:10:14 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 27C29E0875 for ; Mon, 18 Jan 2021 21:10:14 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 25A01340CAA for ; Mon, 18 Jan 2021 21:10:12 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 989354A0 for ; Mon, 18 Jan 2021 21:10:10 +0000 (UTC) From: "Matt Turner" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Matt Turner" Message-ID: <1611004193.b5b8aa6d19de6653bf4c9e063f8ccfa2cc11cc46.mattst88@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: x11-misc/colord/ X-VCS-Repository: repo/gentoo X-VCS-Files: x11-misc/colord/colord-1.3.5.ebuild X-VCS-Directories: x11-misc/colord/ X-VCS-Committer: mattst88 X-VCS-Committer-Name: Matt Turner X-VCS-Revision: b5b8aa6d19de6653bf4c9e063f8ccfa2cc11cc46 X-VCS-Branch: master Date: Mon, 18 Jan 2021 21:10:10 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 01ddfa5b-687b-400d-b901-0a7010b4d9c4 X-Archives-Hash: 6f5480fed8e5308d76c3743628d4d2ca commit: b5b8aa6d19de6653bf4c9e063f8ccfa2cc11cc46 Author: David Michael gmail com> AuthorDate: Sat Dec 26 02:20:56 2020 +0000 Commit: Matt Turner gentoo org> CommitDate: Mon Jan 18 21:09:53 2021 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b5b8aa6d x11-misc/colord: GLEP 81, EAPI 7, support cross-compiling This package needs to compile two programs that are executable at build time, but its build system doesn't understand this. As a workaround, it starts a native build that overrides pkg-config results to skip having to add deps to BDEPEND for configure. The target build then specifies paths to the native build so everything executes as expected. Signed-off-by: David Michael gmail.com> Signed-off-by: Matt Turner gentoo.org> x11-misc/colord/colord-1.3.5.ebuild | 50 +++++++++++++++++++++++++++---------- 1 file changed, 37 insertions(+), 13 deletions(-) diff --git a/x11-misc/colord/colord-1.3.5.ebuild b/x11-misc/colord/colord-1.3.5.ebuild index ad4394daeb7..a58726ebee6 100644 --- a/x11-misc/colord/colord-1.3.5.ebuild +++ b/x11-misc/colord/colord-1.3.5.ebuild @@ -1,11 +1,11 @@ # Copyright 1999-2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=6 -GNOME2_LA_PUNT="yes" +EAPI=7 +GNOME2_EAUTORECONF="yes" VALA_USE_DEPEND="vapigen" -inherit autotools bash-completion-r1 check-reqs gnome2 user systemd udev vala multilib-minimal +inherit bash-completion-r1 check-reqs gnome2 systemd udev vala multilib-minimal toolchain-funcs DESCRIPTION="System service to accurately color manage input and output devices" HOMEPAGE="https://www.freedesktop.org/software/colord/" @@ -23,7 +23,7 @@ REQUIRED_USE=" vala? ( introspection ) " -COMMON_DEPEND=" +DEPEND=" dev-db/sqlite:3=[${MULTILIB_USEDEP}] >=dev-libs/glib-2.44.0:2[${MULTILIB_USEDEP}] >=media-libs/lcms-2.6:2=[${MULTILIB_USEDEP}] @@ -33,19 +33,24 @@ COMMON_DEPEND=" policykit? ( >=sys-auth/polkit-0.104 ) scanner? ( media-gfx/sane-backends - sys-apps/dbus ) + sys-apps/dbus + ) systemd? ( >=sys-apps/systemd-44:0= ) udev? ( dev-libs/libgudev:=[${MULTILIB_USEDEP}] - virtual/udev virtual/libudev:=[${MULTILIB_USEDEP}] + virtual/udev ) " -RDEPEND="${COMMON_DEPEND} - !media-gfx/shared-color-profiles +RDEPEND="${DEPEND} + acct-group/colord + acct-user/colord !<=media-gfx/colorhug-client-0.1.13 + !media-gfx/shared-color-profiles " -DEPEND="${COMMON_DEPEND} +BDEPEND=" + acct-group/colord + acct-user/colord dev-libs/libxslt >=dev-util/gtk-doc-am-1.9 >=dev-util/intltool-0.35 @@ -54,6 +59,11 @@ DEPEND="${COMMON_DEPEND} extra-print-profiles? ( media-gfx/argyllcms ) vala? ( $(vala_depend) ) " +# These dependencies are required to build native build-time programs. +BDEPEND="${BDEPEND} + dev-libs/glib:2 + media-libs/lcms +" # FIXME: needs pre-installed dbus service files RESTRICT="test" @@ -68,8 +78,6 @@ pkg_pretend() { pkg_setup() { use extra-print-profiles && check-reqs_pkg_setup - enewgroup colord - enewuser colord -1 -1 /var/lib/colord colord } src_prepare() { @@ -78,13 +86,21 @@ src_prepare() { src/sensors/cd-sensor-argyll.c \ configure.ac || die - eautoreconf use vala && vala_src_prepare gnome2_src_prepare multilib_copy_sources } multilib_src_configure() { + if multilib_is_native_abi && tc-is-cross-compiler; then + mkdir -p "${S}-native" + pushd "${S}-native" >/dev/null 2>&1 || die + ECONF_SOURCE="${S}" econf_build --enable-static \ + --disable-{argyllcms-sensor,print-profiles,shared,udev} \ + {BASH_COMPLETION,GUDEV,GUSB,POLKIT,SQLITE,UDEV}_{CFLAG,LIB}S=-DSKIP + popd >/dev/null 2>&1 || die + fi + # Reverse tools require gusb # bash-completion test does not work on gentoo local myconf=( @@ -115,7 +131,15 @@ multilib_src_configure() { multilib_src_compile() { if multilib_is_native_abi; then - gnome2_src_compile + if tc-is-cross-compiler; then + emake -C "${S}-native/lib/colord" libcolord.la + emake -C "${S}-native/client" cd-create-profile cd-it8 + emake \ + CD_CREATE_PROFILE="${S}-native/client/cd-create-profile" \ + CD_IT8="${S}-native/client/cd-it8" + else + emake + fi else emake -C lib/colord use gusb && emake -C lib/colorhug