public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: media-libs/opencolorio/files/, media-libs/opencolorio/
Date: Mon,  7 Jun 2021 17:26:07 +0000 (UTC)	[thread overview]
Message-ID: <1623086742.3533aee04be15a96cc9c0f783e3e94a9c217b430.sam@gentoo> (raw)

commit:     3533aee04be15a96cc9c0f783e3e94a9c217b430
Author:     Bernd Waibel <waebbl-gentoo <AT> posteo <DOT> net>
AuthorDate: Sun Jun  6 18:55:46 2021 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Jun  7 17:25:42 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3533aee0

media-libs/opencolorio: respect python sitedir

Pass certain variables to cmake and add a patch to respect the python
site-packages dir.

Closes: https://bugs.gentoo.org/794604
Package-Manager: Portage-3.0.19, Repoman-3.0.3
Signed-off-by: Bernd Waibel <waebbl-gentoo <AT> posteo.net>
Closes: https://github.com/gentoo/gentoo/pull/21143
Signed-off-by: Sam James <sam <AT> gentoo.org>

 ...ecific-OCIOMacros.cmake-remove-LIB_SUFFIX.patch | 38 ++++++++++++++++++++++
 media-libs/opencolorio/opencolorio-1.1.1.ebuild    |  8 +++++
 2 files changed, 46 insertions(+)

diff --git a/media-libs/opencolorio/files/opencolorio-1.1.1-Gentoo-specific-OCIOMacros.cmake-remove-LIB_SUFFIX.patch b/media-libs/opencolorio/files/opencolorio-1.1.1-Gentoo-specific-OCIOMacros.cmake-remove-LIB_SUFFIX.patch
new file mode 100644
index 00000000000..0f0fb4e649d
--- /dev/null
+++ b/media-libs/opencolorio/files/opencolorio-1.1.1-Gentoo-specific-OCIOMacros.cmake-remove-LIB_SUFFIX.patch
@@ -0,0 +1,38 @@
+From 80c08e5bee5bd9fc37a6aeff4b7b7bb8edb3c831 Mon Sep 17 00:00:00 2001
+From: Bernd Waibel <waebbl-gentoo@posteo.net>
+Date: Sun, 6 Jun 2021 20:42:48 +0200
+Subject: [PATCH] [Gentoo specific]OCIOMacros.cmake: remove LIB_SUFFIX
+
+We don't use LIB_SUFFIX for python's site-packages dir, so remove it
+from the PYTHON_VARIANT_PATH to ensure, python modules are installed
+to the correct location.
+
+Signed-off-by: Bernd Waibel <waebbl-gentoo@posteo.net>
+---
+ share/cmake/OCIOMacros.cmake | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/share/cmake/OCIOMacros.cmake b/share/cmake/OCIOMacros.cmake
+index b9fb239..0ce9e62 100644
+--- a/share/cmake/OCIOMacros.cmake
++++ b/share/cmake/OCIOMacros.cmake
+@@ -241,14 +241,14 @@ MACRO(OCIOFindPython)
+         if(WIN32)
+             set(PYTHON_VARIANT_PATH "lib${LIB_SUFFIX}/${PYTHON_UCS}/site-packages")
+         else()
+-            set(PYTHON_VARIANT_PATH "lib${LIB_SUFFIX}/python${PYTHON_VERSION}/${PYTHON_UCS}/site-packages")
++            set(PYTHON_VARIANT_PATH "lib/python${PYTHON_VERSION}/${PYTHON_UCS}/site-packages")
+         endif()
+     else()
+         # Ignore UCS value and install into lib/python2.6/site-packages dir
+         if(WIN32)
+             set(PYTHON_VARIANT_PATH "lib${LIB_SUFFIX}/site-packages")
+         else()
+-            set(PYTHON_VARIANT_PATH "lib${LIB_SUFFIX}/python${PYTHON_VERSION}/site-packages")
++            set(PYTHON_VARIANT_PATH "lib/python${PYTHON_VERSION}/site-packages")
+         endif()
+     endif()
+ 
+-- 
+2.31.1
+

diff --git a/media-libs/opencolorio/opencolorio-1.1.1.ebuild b/media-libs/opencolorio/opencolorio-1.1.1.ebuild
index 8d00c38a853..8fb845a03b7 100644
--- a/media-libs/opencolorio/opencolorio-1.1.1.ebuild
+++ b/media-libs/opencolorio/opencolorio-1.1.1.ebuild
@@ -54,6 +54,7 @@ PATCHES=(
 	"${FILESDIR}/${PN}-1.1.1-yaml-cpp-boost-check.patch"
 	"${FILESDIR}/${P}-fix-self-assign-clang.patch"
 	"${FILESDIR}/${P}-no-werror.patch"
+	"${FILESDIR}/${P}-Gentoo-specific-OCIOMacros.cmake-remove-LIB_SUFFIX.patch"
 )
 
 pkg_setup() {
@@ -90,6 +91,13 @@ src_configure() {
 		-DOCIO_BUILD_TESTS=$(usex test)
 	)
 
+	if use python; then
+		mycmakeargs+=(
+			-DPYTHON=${PYTHON}
+			-DPYTHON_LIBRARY=$(python_get_library_path)
+		)
+	fi
+
 	use doc && mycmakeargs+=( -DCMAKE_DISABLE_FIND_PACKAGE_LATEX=ON ) # broken
 	cmake_src_configure
 }


             reply	other threads:[~2021-06-07 17:26 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-07 17:26 Sam James [this message]
  -- strict thread matches above, loose matches on Subject: below --
2025-01-05 20:35 [gentoo-commits] repo/gentoo:master commit in: media-libs/opencolorio/files/, media-libs/opencolorio/ Sam James
2024-10-04 21:40 Andreas Sturmlechner
2023-10-28 21:46 Sam James
2023-09-26 20:48 Sam James
2022-02-12  3:55 Sam James
2020-11-18 19:21 Sam James
2020-10-10 13:35 Sam James
2019-05-19 17:54 Andreas Sturmlechner
2018-05-26 11:01 Johannes Huber
2018-05-20 22:36 Johannes Huber
2018-01-19 11:57 David Seifert
2018-01-19 11:57 David Seifert
2017-09-23  8:38 David Seifert
2016-11-02 14:44 Sergey Popov
2016-05-30 20:16 Sergey Popov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1623086742.3533aee04be15a96cc9c0f783e3e94a9c217b430.sam@gentoo \
    --to=sam@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox