public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: media-libs/lensfun/files/, media-libs/lensfun/
@ 2016-01-12 20:26 Markus Meier
  0 siblings, 0 replies; 4+ messages in thread
From: Markus Meier @ 2016-01-12 20:26 UTC (permalink / raw
  To: gentoo-commits

commit:     2ef3e2a81df0af9e2bc420859a702f90d4904c72
Author:     Markus Meier <maekke <AT> gentoo <DOT> org>
AuthorDate: Tue Jan 12 20:25:56 2016 +0000
Commit:     Markus Meier <maekke <AT> gentoo <DOT> org>
CommitDate: Tue Jan 12 20:25:56 2016 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2ef3e2a8

media-libs/lensfun: remove old

Package-Manager: portage-2.2.26

 media-libs/lensfun/Manifest                        |  1 -
 .../lensfun/files/lensfun-0.3.0-rst2man.patch      | 12 ------
 media-libs/lensfun/lensfun-0.3.0.ebuild            | 48 ----------------------
 3 files changed, 61 deletions(-)

diff --git a/media-libs/lensfun/Manifest b/media-libs/lensfun/Manifest
index 556fd47..b7f089a 100644
--- a/media-libs/lensfun/Manifest
+++ b/media-libs/lensfun/Manifest
@@ -1,3 +1,2 @@
-DIST lensfun-0.3.0.tar.bz2 636694 SHA256 c2c3c03873cb549d49d42f118fcb0ffa95d1e45b9ff395e19facb63bf699bec1 SHA512 2b0a57b3ae48401908d51372814424c1076d4219400935990af917f131e34261c44122773114c045a39db9062d6a0146cd44e20e3942d2bf3c281a5cc1494cc7 WHIRLPOOL 898b19dcfc70e8721bba45a8782f9e33a17180ab4ce21eef06b874f1bcf76bc0cae8231fdcff797ceb0bdd086266a42a47ebe6d63d20d0595aee11bbe713484a
 DIST lensfun-0.3.1.tar.gz 761892 SHA256 216c23754212e051c8b834437e46af3812533bd770c09714e8c06c9d91cdb535 SHA512 cd0f142bb7d6aa154f587d89502da35473a7a02660246bd025ccd5d1982f55425359405898e11ce9094351ad44a2d6786b9ff07d227f75699e99e4de8f40938c WHIRLPOOL f71fc6452253dd4bb5f40cab8079bdb7a0d36a0ef1ad969261c997ce2b944f4ffd8116b3f4f522567c630099bb84b5cb8b4a57f5ea7141e2b8a0cdc2ceab5c20
 DIST lensfun-0.3.2.tar.gz 784825 SHA256 ae8bcad46614ca47f5bda65b00af4a257a9564a61725df9c74cb260da544d331 SHA512 9c6f546fa70e6dc692e66ef378447345be6d3383812934780d326d772d775c1918cbf3447cd91c067655044cf659025763bf47ba2d938a82a3c2de4d60127446 WHIRLPOOL d9e79ed01d75e6653bb82017a8ee683a56eabae71bc229f55e2572fc96dcf0d9e081ce84e47171b423b149a41a3bf0f4157709243d0e27b2fd68b2efb6eff17c

diff --git a/media-libs/lensfun/files/lensfun-0.3.0-rst2man.patch b/media-libs/lensfun/files/lensfun-0.3.0-rst2man.patch
deleted file mode 100644
index 1f2382f..0000000
--- a/media-libs/lensfun/files/lensfun-0.3.0-rst2man.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-diff -r -U1 lensfun-0.3.0.orig/docs/CMakeLists.txt lensfun-0.3.0/docs/CMakeLists.txt
---- lensfun-0.3.0.orig/docs/CMakeLists.txt	2014-10-01 00:37:34.000000000 +0700
-+++ lensfun-0.3.0/docs/CMakeLists.txt	2014-10-08 15:50:44.135182005 +0700
-@@ -28,5 +28,5 @@
-   TARGET man
--  COMMAND rst2man ${CMAKE_CURRENT_SOURCE_DIR}/man/g-lensfun-update-data.1.rst > ${CMAKE_CURRENT_BINARY_DIR}/g-lensfun-update-data.1
--  COMMAND rst2man ${CMAKE_CURRENT_SOURCE_DIR}/man/lensfun-update-data.1.rst > ${CMAKE_CURRENT_BINARY_DIR}/lensfun-update-data.1
--  COMMAND rst2man ${CMAKE_CURRENT_SOURCE_DIR}/man/lensfun-add-adapter.1.rst > ${CMAKE_CURRENT_BINARY_DIR}/lensfun-add-adapter.1
-+  COMMAND rst2man.py ${CMAKE_CURRENT_SOURCE_DIR}/man/g-lensfun-update-data.1.rst > ${CMAKE_CURRENT_BINARY_DIR}/g-lensfun-update-data.1
-+  COMMAND rst2man.py ${CMAKE_CURRENT_SOURCE_DIR}/man/lensfun-update-data.1.rst > ${CMAKE_CURRENT_BINARY_DIR}/lensfun-update-data.1
-+  COMMAND rst2man.py ${CMAKE_CURRENT_SOURCE_DIR}/man/lensfun-add-adapter.1.rst > ${CMAKE_CURRENT_BINARY_DIR}/lensfun-add-adapter.1
-   WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}"

diff --git a/media-libs/lensfun/lensfun-0.3.0.ebuild b/media-libs/lensfun/lensfun-0.3.0.ebuild
deleted file mode 100644
index 57dc113..0000000
--- a/media-libs/lensfun/lensfun-0.3.0.ebuild
+++ /dev/null
@@ -1,48 +0,0 @@
-# Copyright 1999-2015 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=5
-
-PYTHON_COMPAT=( python2_7 )
-
-inherit multilib python-single-r1 cmake-utils
-
-DESCRIPTION="lensfun: A library for rectifying and simulating photographic lens distortions"
-HOMEPAGE="http://lensfun.sourceforge.net/"
-SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2"
-
-LICENSE="LGPL-3 CC-BY-SA-3.0" # See README for reasoning.
-SLOT="0"
-KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~amd64-linux ~x86-linux"
-IUSE="doc cpu_flags_x86_sse cpu_flags_x86_sse2"
-
-RDEPEND=">=dev-libs/glib-2.28
-	media-libs/libpng:0=
-	sys-libs/zlib:="
-DEPEND="${RDEPEND}
-	doc? (
-		app-doc/doxygen
-		dev-python/docutils
-	)"
-
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-PATCHES=( "${FILESDIR}"/${P}-rst2man.patch )
-
-DOCS=( README docs/mounts.txt ChangeLog )
-
-src_configure() {
-	local mycmakeargs=(
-		-DDOCDIR="${EPREFIX}"/usr/share/doc/${PF}/html
-		-DLIBDIR="${EPREFIX}"/usr/$(get_libdir)
-		-DBUILD_AUXFUN=ON
-		$(cmake-utils_use_build doc)
-		$(cmake-utils_use_build cpu_flags_x86_sse FOR_SSE)
-		$(cmake-utils_use_build cpu_flags_x86_sse2 FOR_SSE2)
-		-DBUILD_STATIC=OFF
-		-DBUILD_TESTS=OFF
-		)
-
-	cmake-utils_src_configure
-}


^ permalink raw reply related	[flat|nested] 4+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-libs/lensfun/files/, media-libs/lensfun/
@ 2020-09-20  9:41 Andreas K. Hüttel
  0 siblings, 0 replies; 4+ messages in thread
From: Andreas K. Hüttel @ 2020-09-20  9:41 UTC (permalink / raw
  To: gentoo-commits

commit:     70f7e67a191e3ac05a2c7df1c4ecdaf766e4f38d
Author:     Andreas K. Hüttel <dilfridge <AT> gentoo <DOT> org>
AuthorDate: Sun Sep 20 09:40:29 2020 +0000
Commit:     Andreas K. Hüttel <dilfridge <AT> gentoo <DOT> org>
CommitDate: Sun Sep 20 09:40:48 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=70f7e67a

media-libs/lensfun: Fix warnings that clang turns into errors

Closes: https://bugs.gentoo.org/740072
Package-Manager: Portage-3.0.4, Repoman-3.0.1
Signed-off-by: Andreas K. Hüttel <dilfridge <AT> gentoo.org>

 .../lensfun/files/lensfun-0.3.2-warnings.patch     | 48 ++++++++++++++++++++++
 media-libs/lensfun/lensfun-0.3.2-r1.ebuild         |  4 ++
 2 files changed, 52 insertions(+)

diff --git a/media-libs/lensfun/files/lensfun-0.3.2-warnings.patch b/media-libs/lensfun/files/lensfun-0.3.2-warnings.patch
new file mode 100644
index 00000000000..a1aad34d9d2
--- /dev/null
+++ b/media-libs/lensfun/files/lensfun-0.3.2-warnings.patch
@@ -0,0 +1,48 @@
+Adapted from upstream commit
+
+From 694542f350fc7c9ccafa2d9acb4d4e00e690cbdc Mon Sep 17 00:00:00 2001
+From: Sebastian Kraft <mail@sebastiankraft.net>
+Date: Thu, 22 Dec 2016 18:51:29 +0100
+Subject: [PATCH] Fix some warnings which were introduced when swithcing to
+ C++11 mode
+
+---
+ libs/lensfun/cpuid.cpp  | 4 ++--
+ libs/lensfun/mod-pc.cpp | 8 ++++----
+ tests/test_modifier.cpp | 4 ++--
+ 3 files changed, 8 insertions(+), 8 deletions(-)
+
+diff --git a/libs/lensfun/cpuid.cpp b/libs/lensfun/cpuid.cpp
+index c435f8ac..d2d63972 100644
+--- a/libs/lensfun/cpuid.cpp
++++ b/libs/lensfun/cpuid.cpp
+@@ -92,9 +92,9 @@ guint _lf_detect_cpu_features ()
+ {
+ #define cpuid(cmd) \
+     __asm volatile ( \
+-        "push %%"R_BX"\n" \
++        "push %%" R_BX "\n" \
+         "cpuid\n" \
+-        "pop %%"R_BX"\n" \
++        "pop %%" R_BX "\n" \
+        : "=a" (ax), "=c" (cx),  "=d" (dx) \
+        : "0" (cmd))
+ 
+diff --git a/tests/test_modifier.cpp b/tests/test_modifier.cpp
+index f087917c..ffa3d4d7 100644
+--- a/tests/test_modifier.cpp
++++ b/tests/test_modifier.cpp
+@@ -78,8 +78,8 @@ void test_mod_projection_center(lfFixture* lfFix, gconstpointer data)
+ // check if output becomes NaN when processing geometry conversion
+ void test_mod_projection_borders(lfFixture* lfFix, gconstpointer data)
+ {
+-    float in[2]  = {lfFix->img_width, lfFix->img_height};
+-    float in2[2] = {(lfFix->img_width-1)/2, (lfFix->img_height-1)/2};
++    float in[2]  = {(float) lfFix->img_width, (float) lfFix->img_height};
++    float in2[2] = {(float) (lfFix->img_width-1)/2, (float) (lfFix->img_height-1)/2};
+     float res[2] = {0, 0};
+ 
+     lfLensType geom_types [] = {LF_RECTILINEAR, LF_PANORAMIC, LF_EQUIRECTANGULAR, LF_FISHEYE_STEREOGRAPHIC, LF_FISHEYE, LF_FISHEYE_EQUISOLID, LF_FISHEYE_ORTHOGRAPHIC, LF_FISHEYE_THOBY, LF_UNKNOWN};
+-- 
+2.26.2
+

diff --git a/media-libs/lensfun/lensfun-0.3.2-r1.ebuild b/media-libs/lensfun/lensfun-0.3.2-r1.ebuild
index 528d11db736..ef48ba8d722 100644
--- a/media-libs/lensfun/lensfun-0.3.2-r1.ebuild
+++ b/media-libs/lensfun/lensfun-0.3.2-r1.ebuild
@@ -34,6 +34,10 @@ DEPEND="${RDEPEND}"
 
 DOCS=( README.md docs/mounts.txt ChangeLog )
 
+PATCHES=(
+	"${FILESDIR}/${P}-warnings.patch"
+)
+
 src_configure() {
 	local mycmakeargs=(
 		-DCMAKE_INSTALL_DOCDIR="${EPREFIX}"/usr/share/doc/${PF}/html


^ permalink raw reply related	[flat|nested] 4+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-libs/lensfun/files/, media-libs/lensfun/
@ 2023-05-04 13:13 Andreas Sturmlechner
  0 siblings, 0 replies; 4+ messages in thread
From: Andreas Sturmlechner @ 2023-05-04 13:13 UTC (permalink / raw
  To: gentoo-commits

commit:     eb3a94ce38c855b3c23bb56dff7da1801b7ea6ac
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Thu May  4 13:04:29 2023 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Thu May  4 13:12:59 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=eb3a94ce

media-libs/lensfun: drop 0.3.3

Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 media-libs/lensfun/Manifest                        |  1 -
 .../lensfun/files/lensfun-0.3.2-warnings.patch     | 48 ----------------
 media-libs/lensfun/lensfun-0.3.3.ebuild            | 65 ----------------------
 3 files changed, 114 deletions(-)

diff --git a/media-libs/lensfun/Manifest b/media-libs/lensfun/Manifest
index 840f1fad16b7..9e7627debe2a 100644
--- a/media-libs/lensfun/Manifest
+++ b/media-libs/lensfun/Manifest
@@ -1,2 +1 @@
-DIST lensfun-0.3.3.tar.gz 992432 BLAKE2B 174f9a34195ca8d7f09de43a2f0d1015bc766579607c44541f631142386a3b5c27c823f9f54f08d462946a0809610b6a87e61cd093b69339fa7d57d28cc833ae SHA512 2d913e3d121ac069f4cb7acb3f09c9cf11c5d0069e743500631bd4b6007a1b19ebccf871a4ac8cfc2797a03066f8a678ea9d70feba0f7d6a05c28cef61f7d9cf
 DIST lensfun-0.3.4_rc1.tar.gz 1045616 BLAKE2B fee14b97dcda98be4e8a32443ff71347ba75e46192f8437be580cb6697f6ef2eca92ef57cfcb2de5bd87fe7ba96542a6b5551b12f50fec09a035c69d6f4b427f SHA512 0d034c6996e5650b022d33a7e00ef7e0e00dfa99155aa62c6c3ab48b9ac936e46f812ceea46e2070514e2c77150a1d7c827831686b1cf73e2acf88b6b3dfb6c5

diff --git a/media-libs/lensfun/files/lensfun-0.3.2-warnings.patch b/media-libs/lensfun/files/lensfun-0.3.2-warnings.patch
deleted file mode 100644
index a1aad34d9d28..000000000000
--- a/media-libs/lensfun/files/lensfun-0.3.2-warnings.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-Adapted from upstream commit
-
-From 694542f350fc7c9ccafa2d9acb4d4e00e690cbdc Mon Sep 17 00:00:00 2001
-From: Sebastian Kraft <mail@sebastiankraft.net>
-Date: Thu, 22 Dec 2016 18:51:29 +0100
-Subject: [PATCH] Fix some warnings which were introduced when swithcing to
- C++11 mode
-
----
- libs/lensfun/cpuid.cpp  | 4 ++--
- libs/lensfun/mod-pc.cpp | 8 ++++----
- tests/test_modifier.cpp | 4 ++--
- 3 files changed, 8 insertions(+), 8 deletions(-)
-
-diff --git a/libs/lensfun/cpuid.cpp b/libs/lensfun/cpuid.cpp
-index c435f8ac..d2d63972 100644
---- a/libs/lensfun/cpuid.cpp
-+++ b/libs/lensfun/cpuid.cpp
-@@ -92,9 +92,9 @@ guint _lf_detect_cpu_features ()
- {
- #define cpuid(cmd) \
-     __asm volatile ( \
--        "push %%"R_BX"\n" \
-+        "push %%" R_BX "\n" \
-         "cpuid\n" \
--        "pop %%"R_BX"\n" \
-+        "pop %%" R_BX "\n" \
-        : "=a" (ax), "=c" (cx),  "=d" (dx) \
-        : "0" (cmd))
- 
-diff --git a/tests/test_modifier.cpp b/tests/test_modifier.cpp
-index f087917c..ffa3d4d7 100644
---- a/tests/test_modifier.cpp
-+++ b/tests/test_modifier.cpp
-@@ -78,8 +78,8 @@ void test_mod_projection_center(lfFixture* lfFix, gconstpointer data)
- // check if output becomes NaN when processing geometry conversion
- void test_mod_projection_borders(lfFixture* lfFix, gconstpointer data)
- {
--    float in[2]  = {lfFix->img_width, lfFix->img_height};
--    float in2[2] = {(lfFix->img_width-1)/2, (lfFix->img_height-1)/2};
-+    float in[2]  = {(float) lfFix->img_width, (float) lfFix->img_height};
-+    float in2[2] = {(float) (lfFix->img_width-1)/2, (float) (lfFix->img_height-1)/2};
-     float res[2] = {0, 0};
- 
-     lfLensType geom_types [] = {LF_RECTILINEAR, LF_PANORAMIC, LF_EQUIRECTANGULAR, LF_FISHEYE_STEREOGRAPHIC, LF_FISHEYE, LF_FISHEYE_EQUISOLID, LF_FISHEYE_ORTHOGRAPHIC, LF_FISHEYE_THOBY, LF_UNKNOWN};
--- 
-2.26.2
-

diff --git a/media-libs/lensfun/lensfun-0.3.3.ebuild b/media-libs/lensfun/lensfun-0.3.3.ebuild
deleted file mode 100644
index 8f6feb38a3d5..000000000000
--- a/media-libs/lensfun/lensfun-0.3.3.ebuild
+++ /dev/null
@@ -1,65 +0,0 @@
-# Copyright 1999-2023 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-PYTHON_COMPAT=( python3_{9..10} )
-inherit python-single-r1 cmake
-
-DESCRIPTION="Library for rectifying and simulating photographic lens distortions"
-HOMEPAGE="https://lensfun.github.io"
-SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
-
-LICENSE="LGPL-3 CC-BY-SA-3.0" # See README for reasoning.
-SLOT="0"
-KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~loong ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux"
-IUSE="doc cpu_flags_x86_sse cpu_flags_x86_sse2 test"
-
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-RESTRICT="!test? ( test )"
-
-BDEPEND="
-	doc? (
-		app-doc/doxygen
-		dev-python/docutils
-	)
-"
-RDEPEND="${PYTHON_DEPS}
-	>=dev-libs/glib-2.40
-	media-libs/libpng:0=
-	sys-libs/zlib
-"
-DEPEND="${RDEPEND}"
-
-DOCS=( README.md docs/mounts.txt ChangeLog )
-
-PATCHES=(
-	"${FILESDIR}/${PN}-0.3.2-warnings.patch"
-)
-
-src_configure() {
-	local mycmakeargs=(
-		-DCMAKE_INSTALL_DOCDIR="${EPREFIX}"/usr/share/doc/${PF}/html
-		-DSETUP_PY_INSTALL_PREFIX=/usr
-		-DBUILD_LENSTOOL=ON
-		-DBUILD_STATIC=OFF
-		-DBUILD_DOC=$(usex doc)
-		-DBUILD_FOR_SSE=$(usex cpu_flags_x86_sse)
-		-DBUILD_FOR_SSE2=$(usex cpu_flags_x86_sse2)
-		-DBUILD_TESTS=$(usex test)
-	)
-	cmake_src_configure
-}
-
-src_test() {
-	mkdir -p "${T}/db/lensfun" || die
-	cp data/db/* "${T}/db/lensfun/" || die
-
-	XDG_DATA_HOME="${T}/db" cmake_src_test
-}
-
-src_install() {
-	cmake_src_install
-	python_optimize
-}


^ permalink raw reply related	[flat|nested] 4+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: media-libs/lensfun/files/, media-libs/lensfun/
@ 2024-01-12 16:53 Sam James
  0 siblings, 0 replies; 4+ messages in thread
From: Sam James @ 2024-01-12 16:53 UTC (permalink / raw
  To: gentoo-commits

commit:     7008130fcca0eb7a631eececdf121bd7e1d90fa8
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Fri Jan 12 16:51:53 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Jan 12 16:52:00 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7008130f

media-libs/lensfun: add 0.3.4, fix Python handling

Closes: https://bugs.gentoo.org/901997
Signed-off-by: Sam James <sam <AT> gentoo.org>

 media-libs/lensfun/Manifest                        |  1 +
 .../lensfun/files/lensfun-0.3.4-python-egg.patch   | 11 ++++
 .../lensfun/files/lensfun-0.3.4-python.patch       | 66 +++++++++++++++++++++
 media-libs/lensfun/lensfun-0.3.4.ebuild            | 68 ++++++++++++++++++++++
 4 files changed, 146 insertions(+)

diff --git a/media-libs/lensfun/Manifest b/media-libs/lensfun/Manifest
index 9e7627debe2a..57067af3c912 100644
--- a/media-libs/lensfun/Manifest
+++ b/media-libs/lensfun/Manifest
@@ -1 +1,2 @@
+DIST lensfun-0.3.4.tar.gz 1058791 BLAKE2B e68cb72eb730a23c3e2dd691a49606ea92a8b89c4665d62dff126404010c8c7e1162d5906a69fce52eb8fb121da8930bb2e42d74bbd8bb6d2631ed4e97405fa3 SHA512 4db9a08d51ba50c7c2ff528d380bb28e34698b2bb5c40e5f3deeaa5544c888ac7e0f638bbc3f33a4f75dbb67e0425ca36ce6d8cd1d8c043a4173a2df47de08c6
 DIST lensfun-0.3.4_rc1.tar.gz 1045616 BLAKE2B fee14b97dcda98be4e8a32443ff71347ba75e46192f8437be580cb6697f6ef2eca92ef57cfcb2de5bd87fe7ba96542a6b5551b12f50fec09a035c69d6f4b427f SHA512 0d034c6996e5650b022d33a7e00ef7e0e00dfa99155aa62c6c3ab48b9ac936e46f812ceea46e2070514e2c77150a1d7c827831686b1cf73e2acf88b6b3dfb6c5

diff --git a/media-libs/lensfun/files/lensfun-0.3.4-python-egg.patch b/media-libs/lensfun/files/lensfun-0.3.4-python-egg.patch
new file mode 100644
index 000000000000..292a0e4186d5
--- /dev/null
+++ b/media-libs/lensfun/files/lensfun-0.3.4-python-egg.patch
@@ -0,0 +1,11 @@
+https://bugs.gentoo.org/901997
+https://sources.debian.org/patches/lensfun/0.3.4-1/python-setuptools.diff/
+--- a/apps/CMakeLists.txt
++++ b/apps/CMakeLists.txt
+@@ -48,5 +48,5 @@ IF(INSTALL_PYTHON_MODULE)
+     IF(NOT DEFINED SETUP_PY_INSTALL_PREFIX)
+       SET(SETUP_PY_INSTALL_PREFIX "${CMAKE_INSTALL_PREFIX}")
+     ENDIF()
+-    INSTALL(CODE "execute_process(COMMAND ${Python3_EXECUTABLE} ${SETUP_PY} install --prefix=\$ENV{DESTDIR}${SETUP_PY_INSTALL_PREFIX})")
++    INSTALL(CODE "execute_process(COMMAND ${Python3_EXECUTABLE} ${SETUP_PY} install --prefix=${SETUP_PY_INSTALL_PREFIX} --single-version-externally-managed --root=\$ENV{DESTDIR})")
+ ENDIF()

diff --git a/media-libs/lensfun/files/lensfun-0.3.4-python.patch b/media-libs/lensfun/files/lensfun-0.3.4-python.patch
new file mode 100644
index 000000000000..2520a99e0b8e
--- /dev/null
+++ b/media-libs/lensfun/files/lensfun-0.3.4-python.patch
@@ -0,0 +1,66 @@
+https://bugs.gentoo.org/901997
+https://github.com/lensfun/lensfun/commit/6e0e92b03f90a264d764f696ba02344ab96b5576
+https://github.com/lensfun/lensfun/commit/c54d9bfda1397d3b9deaac1e27d94b0231fdd26a
+https://github.com/lensfun/lensfun/commit/011de2e85813ff496a85404b30891352555de077
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -1,5 +1,5 @@
+-# require at least cmake 2.8.12
+-CMAKE_MINIMUM_REQUIRED(VERSION 2.8.12 FATAL_ERROR )
++# require at least cmake 3.12
++CMAKE_MINIMUM_REQUIRED(VERSION 3.12 FATAL_ERROR)
+ 
+ # path for helper modules
+ set(CMAKE_MODULE_PATH "${CMAKE_MODULE_PATH}" "${CMAKE_SOURCE_DIR}/cmake/modules")
+--- a/apps/CMakeLists.txt
++++ b/apps/CMakeLists.txt
+@@ -20,27 +20,33 @@ ENDIF(INSTALL_HELPER_SCRIPTS)
+ 
+ 
+ # Inspired by http://bloerg.net/2012/11/10/cmake-and-distutils.html
++IF(INSTALL_PYTHON_MODULE)
++    FIND_PACKAGE (Python3 COMPONENTS Interpreter REQUIRED)
++    # Windows has a dummy python.exe in the PATH which opens the Microsoft Store, so check if Python is real.
++    EXECUTE_PROCESS(COMMAND ${Python3_EXECUTABLE} --version RESULT_VARIABLE PY_RESULT OUTPUT_QUIET)
++    IF (NOT PY_RESULT EQUAL 0)
++      MESSAGE(FATAL_ERROR "Python3 not found, it might be a dummy python.exe")
++    ENDIF()
+ 
+-FIND_PROGRAM(PYTHON "python3")
+-IF(PYTHON)
+     SET(SETUP_PY_IN "${CMAKE_CURRENT_SOURCE_DIR}/setup.py.in")
+     SET(SETUP_PY    "${CMAKE_CURRENT_BINARY_DIR}/setup.py")
+     SET(DEPS_IN     "${CMAKE_CURRENT_SOURCE_DIR}/lensfun/__init__.py.in")
+     SET(DEPS        "${CMAKE_CURRENT_BINARY_DIR}/lensfun/__init__.py")
+     SET(OUTPUT      "${CMAKE_CURRENT_BINARY_DIR}/build/timestamp")
+ 
++    FILE(TO_NATIVE_PATH "${CMAKE_CURRENT_BINARY_DIR}" PY_PACKAGE_DIR)
+     CONFIGURE_FILE(${SETUP_PY_IN} ${SETUP_PY})
+     CONFIGURE_FILE(${DEPS_IN} ${DEPS})
+ 
+     ADD_CUSTOM_COMMAND(OUTPUT ${OUTPUT}
+-                       COMMAND ${PYTHON} ${SETUP_PY} build
++                       COMMAND ${Python3_EXECUTABLE} ${SETUP_PY} build
+                        COMMAND ${CMAKE_COMMAND} -E touch ${OUTPUT}
+-                       DEPENDS ${DEPS_IN})
++                       DEPENDS ${SETUP_PY_IN} ${DEPS_IN})
+ 
+     ADD_CUSTOM_TARGET(python-package ALL DEPENDS ${OUTPUT})
+ 
+     IF(NOT DEFINED SETUP_PY_INSTALL_PREFIX)
+       SET(SETUP_PY_INSTALL_PREFIX "${CMAKE_INSTALL_PREFIX}")
+     ENDIF()
+-    INSTALL(CODE "execute_process(COMMAND ${PYTHON} ${SETUP_PY} install --prefix=\$ENV{DESTDIR}${SETUP_PY_INSTALL_PREFIX})")
+-ENDIF(PYTHON)
++    INSTALL(CODE "execute_process(COMMAND ${Python3_EXECUTABLE} ${SETUP_PY} install --prefix=\$ENV{DESTDIR}${SETUP_PY_INSTALL_PREFIX})")
++ENDIF()
+--- a/tests/CMakeLists.txt
++++ b/tests/CMakeLists.txt
+@@ -29,5 +29,5 @@ ADD_EXECUTABLE(test_modifier_coord_geometry test_modifier_coord_geometry.cpp)
+ TARGET_LINK_LIBRARIES(test_modifier_coord_geometry lensfun ${COMMON_LIBS})
+ ADD_TEST(Modifier_coord_geometry test_modifier_coord_geometry)
+ 
+-FIND_PACKAGE(PythonInterp REQUIRED)
+-ADD_TEST(NAME Database_integrity COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_SOURCE_DIR}/tools/check_database/check_database.py ${CMAKE_SOURCE_DIR}/data/db)
++FIND_PACKAGE(Python3 COMPONENTS Interpreter REQUIRED)
++ADD_TEST(NAME Database_integrity COMMAND ${Python3_EXECUTABLE} ${CMAKE_SOURCE_DIR}/tools/check_database/check_database.py ${CMAKE_SOURCE_DIR}/data/db)

diff --git a/media-libs/lensfun/lensfun-0.3.4.ebuild b/media-libs/lensfun/lensfun-0.3.4.ebuild
new file mode 100644
index 000000000000..d5a949263eb4
--- /dev/null
+++ b/media-libs/lensfun/lensfun-0.3.4.ebuild
@@ -0,0 +1,68 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{10..11} )
+inherit python-single-r1 cmake
+
+DESCRIPTION="Library for rectifying and simulating photographic lens distortions"
+HOMEPAGE="https://lensfun.github.io"
+SRC_URI="https://github.com/${PN}/${PN}/archive/refs/tags/v${PV/_rc/-RC}.tar.gz -> ${P}.tar.gz"
+S="${WORKDIR}/${P/_rc/-RC}"
+
+LICENSE="LGPL-3 CC-BY-SA-3.0" # See README for reasoning.
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
+IUSE="doc cpu_flags_x86_sse cpu_flags_x86_sse2 test"
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+	${PYTHON_DEPS}
+	>=dev-libs/glib-2.40
+	media-libs/libpng:=
+	sys-libs/zlib
+"
+DEPEND="${RDEPEND}"
+BDEPEND="
+	doc? (
+		app-text/doxygen
+		dev-python/docutils
+	)
+"
+
+DOCS=( README.md docs/mounts.txt ChangeLog )
+
+PATCHES=(
+	"${FILESDIR}"/lensfun-0.3.4-python.patch
+	"${FILESDIR}"/lensfun-0.3.4-python-egg.patch
+)
+
+src_configure() {
+	local mycmakeargs=(
+		-DCMAKE_INSTALL_DOCDIR="${EPREFIX}"/usr/share/doc/${PF}/html
+		-DPython3_EXECUTABLE="${PYTHON}"
+		-DSETUP_PY_INSTALL_PREFIX=/usr
+		-DBUILD_LENSTOOL=ON
+		-DBUILD_STATIC=OFF
+		-DBUILD_DOC=$(usex doc)
+		-DBUILD_FOR_SSE=$(usex cpu_flags_x86_sse)
+		-DBUILD_FOR_SSE2=$(usex cpu_flags_x86_sse2)
+		-DBUILD_TESTS=$(usex test)
+	)
+	cmake_src_configure
+}
+
+src_test() {
+	mkdir -p "${T}/db/lensfun" || die
+	cp data/db/* "${T}/db/lensfun/" || die
+
+	XDG_DATA_HOME="${T}/db" cmake_src_test
+}
+
+src_install() {
+	cmake_src_install
+	python_fix_shebang "${ED}"/usr/bin
+	python_optimize
+}


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-01-12 16:53 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-01-12 20:26 [gentoo-commits] repo/gentoo:master commit in: media-libs/lensfun/files/, media-libs/lensfun/ Markus Meier
  -- strict thread matches above, loose matches on Subject: below --
2020-09-20  9:41 Andreas K. Hüttel
2023-05-04 13:13 Andreas Sturmlechner
2024-01-12 16:53 Sam James

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox