public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: media-libs/assimp/files/, media-libs/assimp/
@ 2018-05-16 12:09 Andreas Sturmlechner
  0 siblings, 0 replies; 11+ messages in thread
From: Andreas Sturmlechner @ 2018-05-16 12:09 UTC (permalink / raw
  To: gentoo-commits

commit:     02d2520b61e0c7d054020e6cbe63264bc8d2f5f9
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Wed May 16 11:11:21 2018 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Wed May 16 12:09:22 2018 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=02d2520b

media-libs/assimp: QA: Drop duplicate patch

 media-libs/assimp/assimp-4.0.0.ebuild          |  2 +-
 media-libs/assimp/files/findassimp-4.0.0.patch | 25 -------------------------
 2 files changed, 1 insertion(+), 26 deletions(-)

diff --git a/media-libs/assimp/assimp-4.0.0.ebuild b/media-libs/assimp/assimp-4.0.0.ebuild
index e051dd165ea..2518909a9b2 100644
--- a/media-libs/assimp/assimp-4.0.0.ebuild
+++ b/media-libs/assimp/assimp-4.0.0.ebuild
@@ -23,7 +23,7 @@ DEPEND="${RDEPEND}
 	test? ( dev-cpp/gtest )
 "
 
-PATCHES=( "${FILESDIR}/findassimp-${PV}.patch" )
+PATCHES=( "${FILESDIR}/findassimp-3.3.1.patch" )
 
 src_configure() {
 	local mycmakeargs=(

diff --git a/media-libs/assimp/files/findassimp-4.0.0.patch b/media-libs/assimp/files/findassimp-4.0.0.patch
deleted file mode 100644
index 2fbaa73a850..00000000000
--- a/media-libs/assimp/files/findassimp-4.0.0.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/cmake-modules/Findassimp.cmake	2017-07-24 08:21:12.436647541 +0200
-+++ b/cmake-modules/Findassimp.cmake	2017-07-24 08:21:30.139980768 +0200
-@@ -55,13 +55,13 @@
- 	find_path(
- 	  assimp_INCLUDE_DIRS
- 	  NAMES postprocess.h scene.h version.h config.h cimport.h
--	  PATHS /usr/local/include/
-+	  PATHS /usr/include/
- 	)
- 
- 	find_library(
- 	  assimp_LIBRARIES
- 	  NAMES assimp
--	  PATHS /usr/local/lib/
-+	  PATHS /usr/lib/
- 	)
- 
- 	if (assimp_INCLUDE_DIRS AND assimp_LIBRARIES)
-@@ -78,4 +78,4 @@
- 	  endif (assimp_FIND_REQUIRED)
- 	endif (assimp_FOUND)
- 	
--endif(WIN32)
-\ Brak znaku nowej linii na końcu pliku
-+endif(WIN32)


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

* [gentoo-commits] repo/gentoo:master commit in: media-libs/assimp/files/, media-libs/assimp/
@ 2018-08-26  0:00 Andreas Sturmlechner
  0 siblings, 0 replies; 11+ messages in thread
From: Andreas Sturmlechner @ 2018-08-26  0:00 UTC (permalink / raw
  To: gentoo-commits

commit:     07ba3535d053f2fbc1ca367a03457e8943089231
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Sat Aug 25 23:59:37 2018 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Sun Aug 26 00:00:38 2018 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=07ba3535

media-libs/assimp: Disable pointless test

Closes: https://bugs.gentoo.org/659122
Package-Manager: Portage-2.3.48, Repoman-2.3.10

 media-libs/assimp/assimp-4.0.1.ebuild                  |  1 +
 media-libs/assimp/files/assimp-4.0.1-disabletest.patch | 10 ++++++++++
 2 files changed, 11 insertions(+)

diff --git a/media-libs/assimp/assimp-4.0.1.ebuild b/media-libs/assimp/assimp-4.0.1.ebuild
index c3bb59596e5..8bd32676885 100644
--- a/media-libs/assimp/assimp-4.0.1.ebuild
+++ b/media-libs/assimp/assimp-4.0.1.ebuild
@@ -38,6 +38,7 @@ DEPEND="${RDEPEND}
 PATCHES=(
 	"${FILESDIR}/findassimp-3.3.1.patch"
 	"${FILESDIR}/${P}-qt-5.11.0.patch"
+	"${FILESDIR}/${P}-disabletest.patch" # bug 659122
 )
 
 src_configure() {

diff --git a/media-libs/assimp/files/assimp-4.0.1-disabletest.patch b/media-libs/assimp/files/assimp-4.0.1-disabletest.patch
new file mode 100644
index 00000000000..4afe5bbd26b
--- /dev/null
+++ b/media-libs/assimp/files/assimp-4.0.1-disabletest.patch
@@ -0,0 +1,10 @@
+--- a/test/unit/utVersion.cpp	2017-07-28 22:33:41.000000000 +0200
++++ b/test/unit/utVersion.cpp	2018-08-26 01:48:54.935116440 +0200
+@@ -65,7 +65,3 @@
+     EXPECT_NE( aiGetCompileFlags(), 0U );
+ }
+ 
+-TEST_F( utVersion, aiGetVersionRevisionTest ) {
+-    EXPECT_NE( aiGetVersionRevision(), 0U );
+-}
+-


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

* [gentoo-commits] repo/gentoo:master commit in: media-libs/assimp/files/, media-libs/assimp/
@ 2018-09-15  2:31 Andreas Sturmlechner
  0 siblings, 0 replies; 11+ messages in thread
From: Andreas Sturmlechner @ 2018-09-15  2:31 UTC (permalink / raw
  To: gentoo-commits

commit:     7bf97178eba827b7b8257a6e47d4236d9a2f32e2
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Wed Sep 12 21:02:26 2018 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Sat Sep 15 02:30:26 2018 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7bf97178

media-libs/assimp: Drop old

Closes: https://bugs.gentoo.org/571896
Package-Manager: Portage-2.3.49, Repoman-2.3.10

 media-libs/assimp/Manifest                    |  4 --
 media-libs/assimp/assimp-3.0.1270.ebuild      | 35 -----------------
 media-libs/assimp/assimp-3.1.1.ebuild         | 38 -------------------
 media-libs/assimp/assimp-3.2-r2.ebuild        | 44 ----------------------
 media-libs/assimp/assimp-3.2-r3.ebuild        | 54 ---------------------------
 media-libs/assimp/assimp-3.3.1.ebuild         | 50 -------------------------
 media-libs/assimp/files/findassimp.patch      | 18 ---------
 media-libs/assimp/files/test-cmakelists.patch | 35 -----------------
 media-libs/assimp/metadata.xml                |  1 -
 9 files changed, 279 deletions(-)

diff --git a/media-libs/assimp/Manifest b/media-libs/assimp/Manifest
index 1b8f5764121..6e8afcaf3dc 100644
--- a/media-libs/assimp/Manifest
+++ b/media-libs/assimp/Manifest
@@ -1,5 +1 @@
-DIST assimp--3.0.1270-source-only.zip 4042147 BLAKE2B 1a96a958304d8cdb635f00bb20629aa959d6b158e6d86a465c913cb86e8bf9bbb29d7619c0de685b67483dd1ec12561f1bce63e3cbd6594d99617c3697287145 SHA512 0c23e4eafbd2ff5eb6371b9a3b83ea2b0ef65110f6091a4e63e28b83a6dd1939f1f03607ad002cb5e9a632b821f65d1cc78b63d7792f45ed186071ef0a7ab820
-DIST assimp-3.1.1.zip 32869052 BLAKE2B 877b1a00a8e35eafb85c0f1b1c364c025a98c629da1797961f71df92ee0508b66606aca2b3f69d4da25ec6edef105776d8c4ef83335f3aa3cff1af5232be6745 SHA512 c466d312c0db53fa31b5d1e9b0f65e547a82fb28b1df0a6a96f0dcd876b636a6883d9d705d325193acc58910272b5f158ba37d824ecad29eccf7cf5731697527
-DIST assimp-3.2.tar.gz 33756081 BLAKE2B 76de8f74b7b2eae04ebd3d71b69709d601d249a4ed7e6102fffce376f67dfb2d433536556e7683bc79d092465940cd5d7750f7fecb54edd33b9e8bfa974f8de0 SHA512 d9c4b1efc319990726605664ef38fda49d23a8f169261dda007d912015f404737b2c2a8306bffb837827e4a62d5fb362dae384b85b865450a5622325fe13ad7a
-DIST assimp-3.3.1.tar.gz 36428380 BLAKE2B 5239648ea99e23a1f5f568fb22e6f9607b3f2e642fcdb480737c8813456fee699a4a07937c248ded01c27edd503f1a30ae8bde30ff49d8bac61e6363f12d1cc5 SHA512 660a720f1698e12e6505a554638b15108dfe94f081eb61c675bba9ae979fd80fe8552f6c4c366ff391be6cb34e799c5cf000f621f064105a161caedc82dd934a
 DIST assimp-4.0.1.tar.gz 44625148 BLAKE2B 50cbb6096e89fa311a67cf4f526be57a19f41fe48d59bcdd8d6fd309a988cb19c0f1a4c175301e4c299cb644882a6e8042b0d9281319424faf7504688764e97e SHA512 260b4c7e738f857d8364c4878ea4e789ca676180821943f6d9bff8f56e5f9377ea29660dca4e130c681a8aa12fc32f155adb1d78ca260ba242e68b8afa6cc1bb

diff --git a/media-libs/assimp/assimp-3.0.1270.ebuild b/media-libs/assimp/assimp-3.0.1270.ebuild
deleted file mode 100644
index 37368a1bb93..00000000000
--- a/media-libs/assimp/assimp-3.0.1270.ebuild
+++ /dev/null
@@ -1,35 +0,0 @@
-# Copyright 1999-2017 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=5
-
-inherit cmake-utils versionator
-
-DESCRIPTION="Importer library to import assets from 3D files"
-HOMEPAGE="http://assimp.sourceforge.net/"
-SRC_URI="mirror://sourceforge/${PN}/${PN}--${PV}-source-only.zip"
-
-LICENSE="BSD"
-KEYWORDS="~amd64 ~x86"
-IUSE="+boost samples static tools"
-SLOT="0"
-
-DEPEND="
-	boost? ( dev-libs/boost )
-	samples? ( x11-libs/libX11 virtual/opengl media-libs/freeglut )
-	sys-libs/zlib
-"
-RDEPEND="${DEPEND}"
-
-S=${WORKDIR}/${PN}--${PV}-source-only
-
-src_configure() {
-	local mycmakeargs=(
-		$(cmake-utils_use_build samples ASSIMP_SAMPLES) \
-		$(cmake-utils_use_build tools ASSIMP_TOOLS) \
-		$(cmake-utils_use_build static STATIC_LIB) \
-		$(cmake-utils_use_enable !boost BOOST_WORKAROUND)
-	)
-
-	cmake-utils_src_configure
-}

diff --git a/media-libs/assimp/assimp-3.1.1.ebuild b/media-libs/assimp/assimp-3.1.1.ebuild
deleted file mode 100644
index b3850b085c7..00000000000
--- a/media-libs/assimp/assimp-3.1.1.ebuild
+++ /dev/null
@@ -1,38 +0,0 @@
-# Copyright 1999-2017 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=5
-
-inherit cmake-utils versionator
-
-DESCRIPTION="Importer library to import assets from 3D files"
-HOMEPAGE="http://assimp.sourceforge.net/"
-SRC_URI="mirror://sourceforge/${PN}/${P}.zip"
-
-LICENSE="BSD"
-KEYWORDS="amd64 ~arm x86"
-IUSE="+boost samples static tools"
-SLOT="0"
-
-DEPEND="
-	boost? ( dev-libs/boost )
-	samples? ( x11-libs/libX11 virtual/opengl media-libs/freeglut )
-	sys-libs/zlib
-"
-RDEPEND="${DEPEND}"
-
-src_prepare() {
-	sed -i -e 's/ASSIMP_LIB_INSTALL_DIR "lib"/ASSIMP_LIB_INSTALL_DIR ${CMAKE_INSTALL_LIBDIR}/' CMakeLists.txt || die
-	cmake-utils_src_prepare
-}
-
-src_configure() {
-	local mycmakeargs=(
-		$(cmake-utils_use_build samples ASSIMP_SAMPLES) \
-		$(cmake-utils_use_build tools ASSIMP_TOOLS) \
-		$(cmake-utils_use_build static STATIC_LIB) \
-		$(cmake-utils_use_enable !boost BOOST_WORKAROUND)
-	)
-
-	cmake-utils_src_configure
-}

diff --git a/media-libs/assimp/assimp-3.2-r2.ebuild b/media-libs/assimp/assimp-3.2-r2.ebuild
deleted file mode 100644
index 0e5083ca247..00000000000
--- a/media-libs/assimp/assimp-3.2-r2.ebuild
+++ /dev/null
@@ -1,44 +0,0 @@
-# Copyright 1999-2017 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=5
-
-inherit cmake-utils versionator multilib
-
-DESCRIPTION="Importer library to import assets from 3D files"
-HOMEPAGE="https://github.com/assimp/assimp"
-SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
-
-LICENSE="BSD"
-KEYWORDS="~amd64 ~arm ~x86"
-IUSE="+boost samples static test tools"
-SLOT="0"
-
-RDEPEND="
-	boost? ( dev-libs/boost )
-	samples? ( x11-libs/libX11 virtual/opengl media-libs/freeglut )
-	sys-libs/zlib
-"
-DEPEND="${RDEPEND}
-	test? ( dev-cpp/gtest )
-"
-
-PATCHES=( "${FILESDIR}/test-cmakelists.patch" )
-
-src_configure() {
-	local mycmakeargs=(
-		$(cmake-utils_use_build samples ASSIMP_SAMPLES) \
-		$(cmake-utils_use_build tools ASSIMP_TOOLS) \
-		$(cmake-utils_use_build static STATIC_LIB) \
-		$(cmake-utils_use_enable !boost BOOST_WORKAROUND) \
-		$(cmake-utils_use_build test TESTS)
-		-DCMAKE_DEBUG_POSTFIX=""
-		-DASSIMP_LIB_INSTALL_DIR="${EPREFIX}/usr/$(get_libdir)/"
-	)
-
-	cmake-utils_src_configure
-}
-
-src_test() {
-	"${BUILD_DIR}/test/unit" || die
-}

diff --git a/media-libs/assimp/assimp-3.2-r3.ebuild b/media-libs/assimp/assimp-3.2-r3.ebuild
deleted file mode 100644
index 4fd114b62ed..00000000000
--- a/media-libs/assimp/assimp-3.2-r3.ebuild
+++ /dev/null
@@ -1,54 +0,0 @@
-# Copyright 1999-2017 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=5
-
-inherit cmake-utils versionator multilib
-
-DESCRIPTION="Importer library to import assets from 3D files"
-HOMEPAGE="https://github.com/assimp/assimp"
-SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
-
-LICENSE="BSD"
-KEYWORDS="~amd64 ~arm ~x86"
-IUSE="+boost samples static test tools"
-SLOT="0"
-
-RDEPEND="
-	boost? ( dev-libs/boost )
-	samples? ( x11-libs/libX11 virtual/opengl media-libs/freeglut )
-	sys-libs/zlib
-"
-DEPEND="${RDEPEND}
-	test? ( dev-cpp/gtest )
-"
-
-PATCHES=(
-	"${FILESDIR}/test-cmakelists.patch"
-	"${FILESDIR}/findassimp.patch"
-)
-
-src_configure() {
-	local mycmakeargs=(
-		$(cmake-utils_use_build samples ASSIMP_SAMPLES) \
-		$(cmake-utils_use_build tools ASSIMP_TOOLS) \
-		$(cmake-utils_use_build static STATIC_LIB) \
-		$(cmake-utils_use_enable !boost BOOST_WORKAROUND) \
-		$(cmake-utils_use_build test TESTS)
-		-DCMAKE_DEBUG_POSTFIX=""
-		-DASSIMP_LIB_INSTALL_DIR="${EPREFIX}/usr/$(get_libdir)/"
-	)
-
-	cmake-utils_src_configure
-}
-
-src_install() {
-	cmake-utils_src_install
-
-	insinto /usr/share/cmake/Modules
-	doins cmake-modules/Findassimp.cmake
-}
-
-src_test() {
-	"${BUILD_DIR}/test/unit" || die
-}

diff --git a/media-libs/assimp/assimp-3.3.1.ebuild b/media-libs/assimp/assimp-3.3.1.ebuild
deleted file mode 100644
index e051dd165ea..00000000000
--- a/media-libs/assimp/assimp-3.3.1.ebuild
+++ /dev/null
@@ -1,50 +0,0 @@
-# Copyright 1999-2017 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-inherit cmake-utils versionator multilib
-
-DESCRIPTION="Importer library to import assets from 3D files"
-HOMEPAGE="https://github.com/assimp/assimp"
-SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
-
-LICENSE="BSD"
-KEYWORDS="~amd64 ~arm ~x86"
-IUSE="samples static test tools"
-SLOT="0"
-
-RDEPEND="
-	dev-libs/boost
-	samples? ( x11-libs/libX11 virtual/opengl media-libs/freeglut )
-	sys-libs/zlib
-"
-DEPEND="${RDEPEND}
-	test? ( dev-cpp/gtest )
-"
-
-PATCHES=( "${FILESDIR}/findassimp-${PV}.patch" )
-
-src_configure() {
-	local mycmakeargs=(
-		-DASSIMP_BUILD_SAMPLES=$(usex samples) \
-		-DASSIMP_BUILD_ASSIMP_TOOLS=$(usex tools) \
-		-DASSIMP_BUILD_STATIC_LIB=$(usex static) \
-		-DASSIMP_BUILD_TESTS=$(usex test)
-		-DCMAKE_DEBUG_POSTFIX=""
-		-DASSIMP_LIB_INSTALL_DIR="${EPREFIX}/usr/$(get_libdir)/"
-	)
-
-	cmake-utils_src_configure
-}
-
-src_install() {
-	cmake-utils_src_install
-
-	insinto /usr/share/cmake/Modules
-	doins cmake-modules/Findassimp.cmake
-}
-
-src_test() {
-	"${BUILD_DIR}/test/unit" || die
-}

diff --git a/media-libs/assimp/files/findassimp.patch b/media-libs/assimp/files/findassimp.patch
deleted file mode 100644
index 1b62e7301ff..00000000000
--- a/media-libs/assimp/files/findassimp.patch
+++ /dev/null
@@ -1,18 +0,0 @@
---- cmake-modules/Findassimp.cmake.old	2016-09-06 08:26:35.107697600 +0200
-+++ cmake-modules/Findassimp.cmake	2016-09-06 08:29:25.337696582 +0200
-@@ -1,13 +1,13 @@
- FIND_PATH(
-   assimp_INCLUDE_DIRS
-   NAMES postprocess.h scene.h version.h config.h cimport.h
--  PATHS /usr/local/include/
-+  PATHS /usr/include/
- )
- 
- FIND_LIBRARY(
-   assimp_LIBRARIES
-   NAMES assimp
--  PATHS /usr/local/lib/
-+  PATHS /usr/lib/
- )
- 
- IF (assimp_INCLUDE_DIRS AND assimp_LIBRARIES)

diff --git a/media-libs/assimp/files/test-cmakelists.patch b/media-libs/assimp/files/test-cmakelists.patch
deleted file mode 100644
index 9a3471bbc36..00000000000
--- a/media-libs/assimp/files/test-cmakelists.patch
+++ /dev/null
@@ -1,35 +0,0 @@
---- test/CMakeLists.txt.old	2016-01-21 06:46:12.053363212 +0100
-+++ test/CMakeLists.txt	2016-01-21 06:46:51.126697143 +0100
-@@ -1,7 +1,5 @@
- cmake_minimum_required( VERSION 2.6 )
- 
--INCLUDE( AddGTest )
--
- INCLUDE_DIRECTORIES(
-   ${Assimp_SOURCE_DIR}/include
-   ${Assimp_SOURCE_DIR}/code
-@@ -47,7 +45,7 @@
- 
- SOURCE_GROUP( tests FILES  ${TEST_SRCS} )
- 
--if(AddGTest_FOUND)
-+if(BUILD_TESTS)
- add_executable( unit
-   unit/CCompilerTest.c
-   unit/Main.cpp
-@@ -56,13 +54,12 @@
- )
- 
- add_definitions(-DASSIMP_TEST_MODELS_DIR="${CMAKE_CURRENT_LIST_DIR}/models")
-+target_link_libraries( unit gtest )
- 
- SET_PROPERTY( TARGET assimp PROPERTY DEBUG_POSTFIX ${CMAKE_DEBUG_POSTFIX} )
- 
- add_dependencies( unit gtest )
- target_link_libraries( unit assimp
--  debug ${GTEST_DEBUG_LIBRARIES}
--  optimized ${GTEST_RELEASE_LIBRARIES}
- )
--endif(AddGTest_FOUND)
-+endif(BUILD_TESTS)
- add_subdirectory(headercheck)

diff --git a/media-libs/assimp/metadata.xml b/media-libs/assimp/metadata.xml
index b23d8815c4e..1480b57c125 100644
--- a/media-libs/assimp/metadata.xml
+++ b/media-libs/assimp/metadata.xml
@@ -5,7 +5,6 @@
 		<email>slis@gentoo.org</email>
 	</maintainer>
 	<use>
-		<flag name="boost">Build assimp with boost support</flag>
 		<flag name="samples">Build viewer library</flag>
 		<flag name="tools">Build assimp tool binary</flag>
 	</use>


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

* [gentoo-commits] repo/gentoo:master commit in: media-libs/assimp/files/, media-libs/assimp/
@ 2019-10-09  5:43 Slawek Lis
  0 siblings, 0 replies; 11+ messages in thread
From: Slawek Lis @ 2019-10-09  5:43 UTC (permalink / raw
  To: gentoo-commits

commit:     db332b8ddc3792f8177601f1c6c9040876862f37
Author:     Slawomir Lis <slis <AT> gentoo <DOT> org>
AuthorDate: Tue Oct  8 06:23:39 2019 +0000
Commit:     Slawek Lis <slis <AT> gentoo <DOT> org>
CommitDate: Wed Oct  9 05:43:45 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=db332b8d

media-libs/assimp: Patched findassimp cmake script

Package-Manager: Portage-2.3.76, Repoman-2.3.17
Signed-off-by: Slawek Lis <slis <AT> gentoo.org>

 media-libs/assimp/assimp-4.1.0.ebuild              |  1 +
 .../assimp/files/assimp-4.1.0-findassimp.patch     | 25 ++++++++++++++++++++++
 2 files changed, 26 insertions(+)

diff --git a/media-libs/assimp/assimp-4.1.0.ebuild b/media-libs/assimp/assimp-4.1.0.ebuild
index 05020030504..00b042528bb 100644
--- a/media-libs/assimp/assimp-4.1.0.ebuild
+++ b/media-libs/assimp/assimp-4.1.0.ebuild
@@ -38,6 +38,7 @@ DEPEND="${RDEPEND}
 PATCHES=(
 	"${FILESDIR}/${P}-disabletest.patch" # bug 659122
 	"${FILESDIR}/${P}-unzip-of.patch"
+	"${FILESDIR}/${P}-findassimp.patch"
 )
 
 src_configure() {

diff --git a/media-libs/assimp/files/assimp-4.1.0-findassimp.patch b/media-libs/assimp/files/assimp-4.1.0-findassimp.patch
new file mode 100644
index 00000000000..c2a32307746
--- /dev/null
+++ b/media-libs/assimp/files/assimp-4.1.0-findassimp.patch
@@ -0,0 +1,25 @@
+--- a/cmake-modules/Findassimp.cmake	2019-10-08 08:08:29.025321121 +0200
++++ b/cmake-modules/Findassimp.cmake	2019-10-08 08:09:47.976323079 +0200
+@@ -56,12 +56,15 @@
+ 	  assimp_INCLUDE_DIRS
+ 	  NAMES postprocess.h scene.h version.h config.h cimport.h
+ 	  PATHS /usr/local/include/
++	  PATHS /usr/include/
+ 	)
+ 
+ 	find_library(
+ 	  assimp_LIBRARIES
+ 	  NAMES assimp
+ 	  PATHS /usr/local/lib/
++	  PATHS /usr/lib/
++	  PATHS /usr/lib64/
+ 	)
+ 
+ 	if (assimp_INCLUDE_DIRS AND assimp_LIBRARIES)
+@@ -78,4 +81,4 @@
+ 	  endif (assimp_FIND_REQUIRED)
+ 	endif (assimp_FOUND)
+ 	
+-endif(WIN32)
+\ Brak znaku nowej linii na końcu pliku
++endif(WIN32)


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

* [gentoo-commits] repo/gentoo:master commit in: media-libs/assimp/files/, media-libs/assimp/
@ 2019-11-18 10:50 Slawek Lis
  0 siblings, 0 replies; 11+ messages in thread
From: Slawek Lis @ 2019-11-18 10:50 UTC (permalink / raw
  To: gentoo-commits

commit:     5d3c7dcb2b6201ac96a7685d8978afe8f9e54eb8
Author:     Slawomir Lis <slis <AT> gentoo <DOT> org>
AuthorDate: Mon Nov 18 10:49:05 2019 +0000
Commit:     Slawek Lis <slis <AT> gentoo <DOT> org>
CommitDate: Mon Nov 18 10:49:35 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5d3c7dcb

media-libs/assimp: version bump to 5.0.0

Package-Manager: Portage-2.3.77, Repoman-2.3.17
Signed-off-by: Slawek Lis <slis <AT> gentoo.org>

 media-libs/assimp/Manifest                         |  1 +
 media-libs/assimp/assimp-5.0.0.ebuild              | 66 ++++++++++++++++++++++
 .../assimp/files/assimp-5.0.0-disabletest.patch    | 13 +++++
 .../assimp/files/assimp-5.0.0-findassimp.patch     | 28 +++++++++
 .../assimp/files/assimp-5.0.0-unzip-of.patch       | 11 ++++
 5 files changed, 119 insertions(+)

diff --git a/media-libs/assimp/Manifest b/media-libs/assimp/Manifest
index 76d568f91e9..31741ac4ef0 100644
--- a/media-libs/assimp/Manifest
+++ b/media-libs/assimp/Manifest
@@ -1,2 +1,3 @@
 DIST assimp-4.0.1.tar.gz 44625148 BLAKE2B 50cbb6096e89fa311a67cf4f526be57a19f41fe48d59bcdd8d6fd309a988cb19c0f1a4c175301e4c299cb644882a6e8042b0d9281319424faf7504688764e97e SHA512 260b4c7e738f857d8364c4878ea4e789ca676180821943f6d9bff8f56e5f9377ea29660dca4e130c681a8aa12fc32f155adb1d78ca260ba242e68b8afa6cc1bb
 DIST assimp-4.1.0.tar.gz 45417293 BLAKE2B 74170ab48b64ab357ddd9da58f1218d0c3c0a4039345dcd7ae396aca3bb47c2f5ea2ee8b61b7d81c68c2e1237cd3ba516b816038400e9960b6c0cfe031a41e54 SHA512 5f1292de873ae16c9921d1d44f2871474d74c0ddfd76cc928a7d9b3e03aa6eca4cc72af0513da20a86d09c55d48646e610fd4a4f2b05364f08ad09cf27cbc67a
+DIST assimp-5.0.0.tar.gz 46604597 BLAKE2B 850c84cce6c24c01c2db00d76337797f3e4a4e819e133cf194cac0a7344fa58cb4805e0d5eb29b434f651c0b977e2c0fc5dbe083557f19bb9fe7ccb6977428d1 SHA512 0f73b6e961cd8455d6b6c8c10ed8b99485d846c96377b5d4fcc3b83f737647207c1306aa3dd51dad9654fbfa61bfe1119b34646f90288ae7ecab45efa6fa418a

diff --git a/media-libs/assimp/assimp-5.0.0.ebuild b/media-libs/assimp/assimp-5.0.0.ebuild
new file mode 100644
index 00000000000..00b042528bb
--- /dev/null
+++ b/media-libs/assimp/assimp-5.0.0.ebuild
@@ -0,0 +1,66 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit cmake-utils
+
+DESCRIPTION="Importer library to import assets from 3D files"
+HOMEPAGE="https://github.com/assimp/assimp"
+SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD"
+KEYWORDS="~amd64 ~arm ~arm64 ~x86"
+IUSE="samples static test tools"
+SLOT="0"
+
+RDEPEND="
+	dev-libs/boost:=
+	sys-libs/zlib:=[minizip]
+	samples? (
+		media-libs/freeglut
+		virtual/opengl
+		x11-libs/libX11
+	)
+	tools? (
+		dev-qt/qtcore:5
+		dev-qt/qtgui:5
+		dev-qt/qtopengl:5
+		dev-qt/qtwidgets:5
+		media-libs/devil
+		virtual/opengl
+	)
+"
+DEPEND="${RDEPEND}
+	test? ( dev-cpp/gtest )
+"
+
+PATCHES=(
+	"${FILESDIR}/${P}-disabletest.patch" # bug 659122
+	"${FILESDIR}/${P}-unzip-of.patch"
+	"${FILESDIR}/${P}-findassimp.patch"
+)
+
+src_configure() {
+	local mycmakeargs=(
+		-DASSIMP_BUILD_SAMPLES=$(usex samples)
+		-DASSIMP_BUILD_STATIC_LIB=$(usex static)
+		-DASSIMP_BUILD_TESTS=$(usex test)
+		-DASSIMP_BUILD_ASSIMP_TOOLS=$(usex tools)
+		-DCMAKE_DEBUG_POSTFIX=""
+		-DASSIMP_LIB_INSTALL_DIR="${EPREFIX}/usr/$(get_libdir)/"
+	)
+
+	cmake-utils_src_configure
+}
+
+src_install() {
+	cmake-utils_src_install
+
+	insinto /usr/share/cmake/Modules
+	doins cmake-modules/Findassimp.cmake
+}
+
+src_test() {
+	"${BUILD_DIR}/test/unit" || die
+}

diff --git a/media-libs/assimp/files/assimp-5.0.0-disabletest.patch b/media-libs/assimp/files/assimp-5.0.0-disabletest.patch
new file mode 100644
index 00000000000..d5343c11366
--- /dev/null
+++ b/media-libs/assimp/files/assimp-5.0.0-disabletest.patch
@@ -0,0 +1,13 @@
+--- a/test/unit/utVersion.cpp	2019-11-18 11:39:09.655298634 +0100
++++ b/test/unit/utVersion.cpp	2019-11-18 11:39:25.823299035 +0100
+@@ -66,10 +66,6 @@
+     EXPECT_NE( aiGetCompileFlags(), 0U );
+ }
+ 
+-TEST_F( utVersion, aiGetVersionRevisionTest ) {
+-    EXPECT_NE( aiGetVersionRevision(), 0U );
+-}
+-
+ TEST_F( utVersion, aiGetBranchNameTest ) {
+     EXPECT_NE( nullptr, aiGetBranchName() );
+ }

diff --git a/media-libs/assimp/files/assimp-5.0.0-findassimp.patch b/media-libs/assimp/files/assimp-5.0.0-findassimp.patch
new file mode 100644
index 00000000000..6056f4973c5
--- /dev/null
+++ b/media-libs/assimp/files/assimp-5.0.0-findassimp.patch
@@ -0,0 +1,28 @@
+--- a/cmake-modules/Findassimp.cmake	2019-10-08 08:08:29.025321121 +0200
++++ b/cmake-modules/Findassimp.cmake	2019-10-08 08:09:47.976323079 +0200
+@@ -54,14 +54,17 @@
+ 
+ 	find_path(
+ 	  assimp_INCLUDE_DIRS
+-	  NAMES postprocess.h scene.h version.h config.h cimport.h
++	  NAMES assimp/postprocess.h assimp/scene.h assimp/version.h assimp/config.h assimp/cimport.h
+ 	  PATHS /usr/local/include/
++	  PATHS /usr/include/
+ 	)
+ 
+ 	find_library(
+ 	  assimp_LIBRARIES
+ 	  NAMES assimp
+ 	  PATHS /usr/local/lib/
++	  PATHS /usr/lib/
++	  PATHS /usr/lib64/
+ 	)
+ 
+ 	if (assimp_INCLUDE_DIRS AND assimp_LIBRARIES)
+@@ -78,4 +81,4 @@
+ 	  endif (assimp_FIND_REQUIRED)
+ 	endif (assimp_FOUND)
+ 	
+-endif(WIN32)
+\ Brak znaku nowej linii na końcu pliku
++endif(WIN32)

diff --git a/media-libs/assimp/files/assimp-5.0.0-unzip-of.patch b/media-libs/assimp/files/assimp-5.0.0-unzip-of.patch
new file mode 100644
index 00000000000..e75b47a1af4
--- /dev/null
+++ b/media-libs/assimp/files/assimp-5.0.0-unzip-of.patch
@@ -0,0 +1,11 @@
+--- a/contrib/unzip/unzip.h	2019-08-21 21:38:10.991542891 +0200
++++ b/contrib/unzip/unzip.h	2019-08-21 21:38:24.507543226 +0200
+@@ -45,6 +45,8 @@
+ #ifndef _unz_H
+ #define _unz_H
+ 
++#define OF _Z_OF
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif


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

* [gentoo-commits] repo/gentoo:master commit in: media-libs/assimp/files/, media-libs/assimp/
@ 2020-06-05 12:48 Andreas Sturmlechner
  0 siblings, 0 replies; 11+ messages in thread
From: Andreas Sturmlechner @ 2020-06-05 12:48 UTC (permalink / raw
  To: gentoo-commits

commit:     6110fc259680b841e7c2a7d6a168b7666d6d90bf
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Fri Jun  5 12:21:45 2020 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Fri Jun  5 12:48:43 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6110fc25

media-libs/assimp: 5.0.1 version bump, switch to cmake.eclass, EAPI-7

- Add IUSE="doc"
- Drop IUSE="tools" as Qt5 based viewer was removed upstream
  commit 13586eb0739146dc609fa83bcd71fee1bb66f4b7
- GNUInstallDirs++
  patch from commit cbf94fd62ff831879d10f99aa7766d391ae8a9b7

Thanks-to: Victor Mataré <matare <AT> fh-aachen.de>
Closes: https://bugs.gentoo.org/701912
Package-Manager: Portage-2.3.100, Repoman-2.3.22
Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 media-libs/assimp/Manifest                         |   2 +
 media-libs/assimp/assimp-5.0.1.ebuild              |  62 ++++++
 .../assimp/files/assimp-5.0.1-GNUInstallDirs.patch | 239 +++++++++++++++++++++
 3 files changed, 303 insertions(+)

diff --git a/media-libs/assimp/Manifest b/media-libs/assimp/Manifest
index 31741ac4ef0..90527fbe192 100644
--- a/media-libs/assimp/Manifest
+++ b/media-libs/assimp/Manifest
@@ -1,3 +1,5 @@
 DIST assimp-4.0.1.tar.gz 44625148 BLAKE2B 50cbb6096e89fa311a67cf4f526be57a19f41fe48d59bcdd8d6fd309a988cb19c0f1a4c175301e4c299cb644882a6e8042b0d9281319424faf7504688764e97e SHA512 260b4c7e738f857d8364c4878ea4e789ca676180821943f6d9bff8f56e5f9377ea29660dca4e130c681a8aa12fc32f155adb1d78ca260ba242e68b8afa6cc1bb
 DIST assimp-4.1.0.tar.gz 45417293 BLAKE2B 74170ab48b64ab357ddd9da58f1218d0c3c0a4039345dcd7ae396aca3bb47c2f5ea2ee8b61b7d81c68c2e1237cd3ba516b816038400e9960b6c0cfe031a41e54 SHA512 5f1292de873ae16c9921d1d44f2871474d74c0ddfd76cc928a7d9b3e03aa6eca4cc72af0513da20a86d09c55d48646e610fd4a4f2b05364f08ad09cf27cbc67a
 DIST assimp-5.0.0.tar.gz 46604597 BLAKE2B 850c84cce6c24c01c2db00d76337797f3e4a4e819e133cf194cac0a7344fa58cb4805e0d5eb29b434f651c0b977e2c0fc5dbe083557f19bb9fe7ccb6977428d1 SHA512 0f73b6e961cd8455d6b6c8c10ed8b99485d846c96377b5d4fcc3b83f737647207c1306aa3dd51dad9654fbfa61bfe1119b34646f90288ae7ecab45efa6fa418a
+DIST assimp-5.0.1.tar.gz 46607553 BLAKE2B 7f8cdf2bc602398fbdb675094d135e955716deb8f6469a4b68f7a8c735ecaa3120ee023c5c1f95c5a79c0606ed9a3cb3491c5011e2b409da523b56cd193ebb60 SHA512 51b704ffea778638b9e228578650f62691c56ee1a90337f8bbbee37e807455466d818234be24852334e5806260e5690932c9bd8e00f055c5c26782e0636538f0
+DIST assimp-docs-5.0.1.pdf 315941 BLAKE2B 06b2d3a68b6f70fd2ca3daee6cbcd79da255ec8ba00383077b775a1e032ab9675b5f70f2c5e9c1a6f51a4c65b482dfd7bce6c8be3c0288d6f6a653feaa7dfd84 SHA512 f37b8eb8d3a3c6198a91f03fd712a911990aa2d5f50e5039d54349dd673e5270e11ff55aa430f7c3ccbb142cb3b9530684157c25d8a533861b6de34064ab339e

diff --git a/media-libs/assimp/assimp-5.0.1.ebuild b/media-libs/assimp/assimp-5.0.1.ebuild
new file mode 100644
index 00000000000..96281b1fd32
--- /dev/null
+++ b/media-libs/assimp/assimp-5.0.1.ebuild
@@ -0,0 +1,62 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit cmake
+
+DESCRIPTION="Importer library to import assets from 3D files"
+HOMEPAGE="https://github.com/assimp/assimp"
+SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz
+doc? ( https://github.com/${PN}/${PN}/releases/download/v${PV}/${PN}-docs-${PV}.pdf )"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~x86"
+IUSE="doc samples test"
+
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+	dev-libs/boost:=
+	sys-libs/zlib[minizip]
+	samples? (
+		media-libs/freeglut
+		virtual/opengl
+		x11-libs/libX11
+	)
+"
+DEPEND="${RDEPEND}
+	test? ( dev-cpp/gtest )
+"
+
+PATCHES=(
+	"${FILESDIR}/${PN}-5.0.0-disabletest.patch" # bug 659122
+	"${FILESDIR}/${PN}-5.0.0-unzip-of.patch"
+	"${FILESDIR}/${PN}-5.0.0-findassimp.patch"
+	"${FILESDIR}/${P}-GNUInstallDirs.patch" # bug 701912
+)
+
+src_configure() {
+	local mycmakeargs=(
+		-DASSIMP_BUILD_STATIC_LIB=OFF
+		-DCMAKE_DEBUG_POSTFIX=""
+		-DASSIMP_BUILD_SAMPLES=$(usex samples)
+		-DASSIMP_BUILD_TESTS=$(usex test)
+	)
+
+	cmake_src_configure
+}
+
+src_install() {
+	cmake_src_install
+
+	use doc && dodoc "${DISTDIR}"/${PN}-docs-${PV}.pdf
+
+	insinto /usr/share/cmake/Modules
+	doins cmake-modules/Findassimp.cmake
+}
+
+src_test() {
+	"${BUILD_DIR}/test/unit" || die
+}

diff --git a/media-libs/assimp/files/assimp-5.0.1-GNUInstallDirs.patch b/media-libs/assimp/files/assimp-5.0.1-GNUInstallDirs.patch
new file mode 100644
index 00000000000..134edc7d7da
--- /dev/null
+++ b/media-libs/assimp/files/assimp-5.0.1-GNUInstallDirs.patch
@@ -0,0 +1,239 @@
+From cbf94fd62ff831879d10f99aa7766d391ae8a9b7 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Victor=20Matar=C3=A9?= <matare@fh-aachen.de>
+Date: Tue, 31 Mar 2020 21:30:07 +0200
+Subject: [PATCH] use GNUInstallDirs where possible
+
+Emulate the CMAKE_INSTALL_FULL_* variables on non-Unix systems and
+disable redefining FHS-mandated install locations via user-editable
+ASSIMP_*_INSTALL_DIR variables. Instead, if it REALLY proves necessary,
+Unix users can edit the advanced, canonical CMAKE_INSTALL_* variables.
+---
+ CMakeLists.txt                 | 36 ++++++++++++++++++++++------------
+ assimp.pc.in                   |  6 ++----
+ assimpTargets-debug.cmake.in   | 20 +++++++++----------
+ assimpTargets-release.cmake.in | 18 ++++++++---------
+ assimpTargets.cmake.in         | 15 +-------------
+ 5 files changed, 45 insertions(+), 50 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index dcafb649f5..c23c0df33e 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -230,11 +230,6 @@ SET(LIBASSIMP-DEV_COMPONENT "libassimp${ASSIMP_VERSION_MAJOR}.${ASSIMP_VERSION_M
+ SET(CPACK_COMPONENTS_ALL assimp-bin ${LIBASSIMP_COMPONENT} ${LIBASSIMP-DEV_COMPONENT} assimp-dev)
+ SET(ASSIMP_LIBRARY_SUFFIX "" CACHE STRING "Suffix to append to library names")
+ 
+-IF( UNIX )
+-  # Use GNUInstallDirs for Unix predefined directories
+-  INCLUDE(GNUInstallDirs)
+-ENDIF( UNIX )
+-
+ # Grouped compiler settings
+ IF ((CMAKE_C_COMPILER_ID MATCHES "GNU") AND NOT CMAKE_COMPILER_IS_MINGW)
+   IF(NOT HUNTER_ENABLED)
+@@ -329,14 +324,6 @@ IF ( CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR )
+   SET( CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_HOME_DIRECTORY}/bin" )
+ ENDIF ( CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR )
+ 
+-# Cache these to allow the user to override them manually.
+-SET( ASSIMP_LIB_INSTALL_DIR "lib" CACHE STRING
+-  "Path the built library files are installed to." )
+-SET( ASSIMP_INCLUDE_INSTALL_DIR "include" CACHE STRING
+-  "Path the header files are installed to." )
+-SET( ASSIMP_BIN_INSTALL_DIR "bin" CACHE STRING
+-  "Path the tool executables are installed to." )
+-
+ get_cmake_property(is_multi_config GENERATOR_IS_MULTI_CONFIG)
+ 
+ IF (INJECT_DEBUG_POSTFIX AND (is_multi_config OR CMAKE_BUILD_TYPE STREQUAL "Debug"))
+@@ -391,6 +378,29 @@ IF(HUNTER_ENABLED)
+   )
+ ELSE(HUNTER_ENABLED)
+   # cmake configuration files
++
++  IF( UNIX )
++    # Use GNUInstallDirs for Unix predefined directories
++    INCLUDE(GNUInstallDirs)
++
++    SET( ASSIMP_LIB_INSTALL_DIR ${CMAKE_INSTALL_LIBDIR})
++    SET( ASSIMP_INCLUDE_INSTALL_DIR ${CMAKE_INSTALL_INCLUDEDIR})
++    SET( ASSIMP_BIN_INSTALL_DIR ${CMAKE_INSTALL_BINDIR})
++  ELSE( UNIX )
++    # Cache these to allow the user to override them on non-Unix platforms
++    SET( ASSIMP_LIB_INSTALL_DIR "lib" CACHE STRING
++      "Path the built library files are installed to." )
++    SET( ASSIMP_INCLUDE_INSTALL_DIR "include" CACHE STRING
++      "Path the header files are installed to." )
++    SET( ASSIMP_BIN_INSTALL_DIR "bin" CACHE STRING
++      "Path the tool executables are installed to." )
++
++    SET(CMAKE_INSTALL_FULL_INCLUDEDIR ${CMAKE_INSTALL_PREFIX}/${ASSIMP_INCLUDE_INSTALL_DIR})
++    SET(CMAKE_INSTALL_FULL_LIBDIR ${CMAKE_INSTALL_PREFIX}/${ASSIMP_LIB_INSTALL_DIR})
++    SET(CMAKE_INSTALL_FULL_BINDIR ${CMAKE_INSTALL_PREFIX}/${ASSIMP_BIN_INSTALL_DIR})
++  ENDIF( UNIX )
++
++
+   CONFIGURE_FILE("${CMAKE_CURRENT_SOURCE_DIR}/assimp-config.cmake.in"         "${CMAKE_CURRENT_BINARY_DIR}/assimp-config.cmake" @ONLY IMMEDIATE)
+   CONFIGURE_FILE("${CMAKE_CURRENT_SOURCE_DIR}/assimpTargets.cmake.in"         "${CMAKE_CURRENT_BINARY_DIR}/assimpTargets.cmake" @ONLY IMMEDIATE)
+   IF (is_multi_config)
+diff --git a/assimp.pc.in b/assimp.pc.in
+index c659e19f2c..555a3a1d3b 100644
+--- a/assimp.pc.in
++++ b/assimp.pc.in
+@@ -1,7 +1,5 @@
+-prefix=@CMAKE_INSTALL_PREFIX@
+-exec_prefix=@CMAKE_INSTALL_PREFIX@/
+-libdir=@CMAKE_INSTALL_PREFIX@/@ASSIMP_LIB_INSTALL_DIR@
+-includedir=@CMAKE_INSTALL_PREFIX@/../include/@ASSIMP_INCLUDE_INSTALL_DIR@
++libdir=@CMAKE_INSTALL_FULL_LIBDIR@
++includedir=@CMAKE_INSTALL_FULL_INCLUDEDIR@
+ 
+ Name: @CMAKE_PROJECT_NAME@
+ Description: Import various well-known 3D model formats in an uniform manner.
+diff --git a/assimpTargets-debug.cmake.in b/assimpTargets-debug.cmake.in
+index 1ebe2a6081..f5034c9349 100644
+--- a/assimpTargets-debug.cmake.in
++++ b/assimpTargets-debug.cmake.in
+@@ -42,22 +42,22 @@ if(MSVC)
+     # Import target "assimp::assimp" for configuration "Debug"
+     set_property(TARGET assimp::assimp APPEND PROPERTY IMPORTED_CONFIGURATIONS DEBUG)
+     set_target_properties(assimp::assimp PROPERTIES
+-      IMPORTED_IMPLIB_DEBUG "${_IMPORT_PREFIX}/lib/${importLibraryName}"
+-      IMPORTED_LOCATION_DEBUG "${_IMPORT_PREFIX}/bin/${sharedLibraryName}"
++      IMPORTED_IMPLIB_DEBUG "@CMAKE_INSTALL_FULL_LIBDIR@/${importLibraryName}"
++      IMPORTED_LOCATION_DEBUG "@CMAKE_INSTALL_FULL_BINDIR@/${sharedLibraryName}"
+     )
+     list(APPEND _IMPORT_CHECK_TARGETS assimp::assimp )
+-    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "${_IMPORT_PREFIX}/lib/${importLibraryName}")
+-    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "${_IMPORT_PREFIX}/bin/${sharedLibraryName}" )
++    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "@CMAKE_INSTALL_FULL_LIBDIR@/${importLibraryName}")
++    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "@CMAKE_INSTALL_FULL_BINDIR@/${sharedLibraryName}" )
+   else()
+     set(staticLibraryName "assimp${ASSIMP_LIBRARY_SUFFIX}@CMAKE_DEBUG_POSTFIX@@CMAKE_STATIC_LIBRARY_SUFFIX@")
+ 
+     # Import target "assimp::assimp" for configuration "Debug"
+     set_property(TARGET assimp::assimp APPEND PROPERTY IMPORTED_CONFIGURATIONS DEBUG)
+     set_target_properties(assimp::assimp PROPERTIES
+-      IMPORTED_LOCATION_DEBUG "${_IMPORT_PREFIX}/lib/${staticLibraryName}"
++      IMPORTED_LOCATION_DEBUG "@CMAKE_INSTALL_FULL_LIBDIR@/${staticLibraryName}"
+     )
+     list(APPEND _IMPORT_CHECK_TARGETS assimp::assimp )
+-    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "${_IMPORT_PREFIX}/lib/${staticLibraryName}")
++    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "@CMAKE_INSTALL_FULL_LIBDIR@/${staticLibraryName}")
+   endif()
+ 
+ else()
+@@ -66,17 +66,17 @@ else()
+     set(sharedLibraryName "libassimp${ASSIMP_LIBRARY_SUFFIX}@CMAKE_DEBUG_POSTFIX@@CMAKE_SHARED_LIBRARY_SUFFIX@.@ASSIMP_VERSION_MAJOR@")
+     set_target_properties(assimp::assimp PROPERTIES
+       IMPORTED_SONAME_DEBUG "${sharedLibraryName}"
+-      IMPORTED_LOCATION_DEBUG "${_IMPORT_PREFIX}/lib/${sharedLibraryName}"
++      IMPORTED_LOCATION_DEBUG "@CMAKE_INSTALL_FULL_LIBDIR@/${sharedLibraryName}"
+     )
+     list(APPEND _IMPORT_CHECK_TARGETS assimp::assimp )
+-    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "${_IMPORT_PREFIX}/lib/${sharedLibraryName}" )
++    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "@CMAKE_INSTALL_FULL_LIBDIR@/${sharedLibraryName}" )
+   else()
+     set(staticLibraryName "libassimp${ASSIMP_LIBRARY_SUFFIX}@CMAKE_DEBUG_POSTFIX@@CMAKE_STATIC_LIBRARY_SUFFIX@")
+     set_target_properties(assimp::assimp PROPERTIES
+-      IMPORTED_LOCATION_DEBUG "${_IMPORT_PREFIX}/lib/${staticLibraryName}"
++      IMPORTED_LOCATION_DEBUG "@CMAKE_INSTALL_FULL_LIBDIR@/${staticLibraryName}"
+     )
+     list(APPEND _IMPORT_CHECK_TARGETS assimp::assimp )
+-    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "${_IMPORT_PREFIX}/lib/${staticLibraryName}" )
++    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "@CMAKE_INSTALL_FULL_LIBDIR@/${staticLibraryName}" )
+   endif()
+ endif()
+ 
+diff --git a/assimpTargets-release.cmake.in b/assimpTargets-release.cmake.in
+index f3db8f12cd..a416e8899b 100644
+--- a/assimpTargets-release.cmake.in
++++ b/assimpTargets-release.cmake.in
+@@ -42,12 +42,12 @@ if(MSVC)
+     # Import target "assimp::assimp" for configuration "Release"
+     set_property(TARGET assimp::assimp APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE)
+     set_target_properties(assimp::assimp PROPERTIES
+-      IMPORTED_IMPLIB_RELEASE "${_IMPORT_PREFIX}/lib/${importLibraryName}"
+-      IMPORTED_LOCATION_RELEASE "${_IMPORT_PREFIX}/bin/${sharedLibraryName}"
++      IMPORTED_IMPLIB_RELEASE "@CMAKE_INSTALL_FULL_LIBDIR@/${importLibraryName}"
++      IMPORTED_LOCATION_RELEASE "@CMAKE_INSTALL_FULL_BINDIR@/${sharedLibraryName}"
+     )
+     list(APPEND _IMPORT_CHECK_TARGETS assimp::assimp )
+-    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "${_IMPORT_PREFIX}/lib/${importLibraryName}")
+-    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "${_IMPORT_PREFIX}/bin/${sharedLibraryName}" )
++    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "@CMAKE_INSTALL_FULL_LIBDIR@/${importLibraryName}")
++    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "@CMAKE_INSTALL_FULL_BINDIR@/${sharedLibraryName}" )
+   else()
+     set(staticLibraryName "assimp${ASSIMP_LIBRARY_SUFFIX}@CMAKE_STATIC_LIBRARY_SUFFIX@")
+ 
+@@ -57,7 +57,7 @@ if(MSVC)
+       IMPORTED_LOCATION_RELEASE "${_IMPORT_PREFIX}/lib/${staticLibraryName}"
+     )
+     list(APPEND _IMPORT_CHECK_TARGETS assimp::assimp )
+-    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "${_IMPORT_PREFIX}/lib/${staticLibraryName}")
++    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "@CMAKE_INSTALL_FULL_LIBDIR@/${staticLibraryName}")
+   endif()
+ 
+ else()
+@@ -70,17 +70,17 @@ else()
+     endif()
+     set_target_properties(assimp::assimp PROPERTIES
+       IMPORTED_SONAME_RELEASE "${sharedLibraryName}"
+-      IMPORTED_LOCATION_RELEASE "${_IMPORT_PREFIX}/lib/${sharedLibraryName}"
++      IMPORTED_LOCATION_RELEASE "@CMAKE_INSTALL_FULL_LIBDIR@/${sharedLibraryName}"
+     )
+     list(APPEND _IMPORT_CHECK_TARGETS assimp::assimp )
+-    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "${_IMPORT_PREFIX}/lib/${sharedLibraryName}" )
++    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "@CMAKE_INSTALL_FULL_LIBDIR@/${sharedLibraryName}" )
+   else()
+     set(staticLibraryName "libassimp${ASSIMP_LIBRARY_SUFFIX}@CMAKE_STATIC_LIBRARY_SUFFIX@")
+     set_target_properties(assimp::assimp PROPERTIES
+-      IMPORTED_LOCATION_RELEASE "${_IMPORT_PREFIX}/lib/${staticLibraryName}"
++      IMPORTED_LOCATION_RELEASE "@CMAKE_INSTALL_FULL_LIBDIR@/${staticLibraryName}"
+     )
+     list(APPEND _IMPORT_CHECK_TARGETS assimp::assimp )
+-    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "${_IMPORT_PREFIX}/lib/${staticLibraryName}" )
++    list(APPEND _IMPORT_CHECK_FILES_FOR_assimp::assimp "@CMAKE_INSTALL_FULL_LIBDIR@/${staticLibraryName}" )
+   endif()
+ endif()
+ 
+diff --git a/assimpTargets.cmake.in b/assimpTargets.cmake.in
+index ab1a8d2c7b..ef90c834a6 100644
+--- a/assimpTargets.cmake.in
++++ b/assimpTargets.cmake.in
+@@ -40,16 +40,6 @@ unset(_targetsDefined)
+ unset(_targetsNotDefined)
+ unset(_expectedTargets)
+ 
+-
+-# Compute the installation prefix relative to this file.
+-get_filename_component(_IMPORT_PREFIX "${CMAKE_CURRENT_LIST_FILE}" PATH)
+-get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH)
+-get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH)
+-get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH)
+-if(_IMPORT_PREFIX STREQUAL "/")
+-  set(_IMPORT_PREFIX "")
+-endif()
+-
+ # Create imported target assimp::assimp
+ if(@BUILD_SHARED_LIBS@)
+   add_library(assimp::assimp SHARED IMPORTED)
+@@ -60,7 +50,7 @@ endif()
+ set_target_properties(assimp::assimp PROPERTIES
+   COMPATIBLE_INTERFACE_STRING "assimp_MAJOR_VERSION"
+   INTERFACE_assimp_MAJOR_VERSION "1"
+-  INTERFACE_INCLUDE_DIRECTORIES "${_IMPORT_PREFIX}/include;${_IMPORT_PREFIX}/include"
++  INTERFACE_INCLUDE_DIRECTORIES "@CMAKE_INSTALL_FULL_INCLUDEDIR@"
+   #INTERFACE_LINK_LIBRARIES "TxtUtils::TxtUtils;MealyMachine::MealyMachine"
+ )
+ 
+@@ -75,9 +65,6 @@ foreach(f ${CONFIG_FILES})
+   include(${f})
+ endforeach()
+ 
+-# Cleanup temporary variables.
+-set(_IMPORT_PREFIX)
+-
+ # Loop over all imported files and verify that they actually exist
+ foreach(target ${_IMPORT_CHECK_TARGETS} )
+   foreach(file ${_IMPORT_CHECK_FILES_FOR_${target}} )


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

* [gentoo-commits] repo/gentoo:master commit in: media-libs/assimp/files/, media-libs/assimp/
@ 2022-04-29  2:22 Sam James
  0 siblings, 0 replies; 11+ messages in thread
From: Sam James @ 2022-04-29  2:22 UTC (permalink / raw
  To: gentoo-commits

commit:     3c7abed13a49d96d90fdeda81bba828271cace87
Author:     Bernd Waibel <waebbl-gentoo <AT> posteo <DOT> net>
AuthorDate: Thu Apr 28 06:06:12 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Apr 29 02:22:31 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3c7abed1

media-libs/assimp: build with gcc-12

Fix an -Werror=array-bounds issue with gcc-12, by patching out the
global -Werror flag used by upstream.
Drop failing tests for x86_32.

Closes: https://bugs.gentoo.org/840616
Closes: https://bugs.gentoo.org/840767
Bug: https://github.com/assimp/assimp/issues/4438
Bug: https://github.com/assimp/assimp/issues/4433
Signed-off-by: Bernd Waibel <waebbl-gentoo <AT> posteo.net>
Closes: https://github.com/gentoo/gentoo/pull/25234
Signed-off-by: Sam James <sam <AT> gentoo.org>

 media-libs/assimp/assimp-5.2.3.ebuild              |   9 ++
 .../assimp-5.2.3-drop-Werror-gcc-option.patch      |  22 ++++
 ...p-5.2.3-drop-failing-tests-for-abi_x86_32.patch | 131 +++++++++++++++++++++
 3 files changed, 162 insertions(+)

diff --git a/media-libs/assimp/assimp-5.2.3.ebuild b/media-libs/assimp/assimp-5.2.3.ebuild
index ba654ddd393f..451858172fc2 100644
--- a/media-libs/assimp/assimp-5.2.3.ebuild
+++ b/media-libs/assimp/assimp-5.2.3.ebuild
@@ -32,11 +32,20 @@ BDEPEND="
 
 PATCHES=(
 	"${FILESDIR}"/${PN}-5.2.2-fix-usage-of-incompatible-minizip-data-structure.patch
+	"${FILESDIR}"/${P}-drop-Werror-gcc-option.patch
 	"${FILESDIR}"/${PN}-5.2.2-disable-failing-tests.patch
 )
 
 DOCS=( CodeConventions.md Readme.md )
 
+src_prepare() {
+	if use abi_x86_32; then
+		eapply "${FILESDIR}"/${P}-drop-failing-tests-for-abi_x86_32.patch
+	fi
+
+	cmake_src_prepare
+}
+
 src_configure() {
 	local mycmakeargs=(
 		-DASSIMP_ASAN=OFF

diff --git a/media-libs/assimp/files/assimp-5.2.3-drop-Werror-gcc-option.patch b/media-libs/assimp/files/assimp-5.2.3-drop-Werror-gcc-option.patch
new file mode 100644
index 000000000000..708f45ee3503
--- /dev/null
+++ b/media-libs/assimp/files/assimp-5.2.3-drop-Werror-gcc-option.patch
@@ -0,0 +1,22 @@
+From dea8b4d8c533c131bd546c316f8df8af8897ac75 Mon Sep 17 00:00:00 2001
+From: Bernd Waibel <waebbl-gentoo@posteo.net>
+Date: Mon, 25 Apr 2022 17:39:33 +0200
+Subject: [PATCH] drop -Werror gcc option
+
+Temporary hack to allow building with gcc-12
+
+Signed-off-by: Bernd Waibel <waebbl-gentoo@posteo.net>
+--- a/code/CMakeLists.txt
++++ b/code/CMakeLists.txt
+@@ -1179,8 +1179,6 @@ TARGET_USE_COMMON_OUTPUT_DIRECTORY(assimp)
+ # enable warnings as errors ########################################
+ IF (MSVC)
+   TARGET_COMPILE_OPTIONS(assimp PRIVATE /WX)
+-ELSE()
+-  TARGET_COMPILE_OPTIONS(assimp PRIVATE -Werror)
+ ENDIF()
+ 
+ # adds C_FLAGS required to compile zip.c on old GCC 4.x compiler
+-- 
+2.35.1
+

diff --git a/media-libs/assimp/files/assimp-5.2.3-drop-failing-tests-for-abi_x86_32.patch b/media-libs/assimp/files/assimp-5.2.3-drop-failing-tests-for-abi_x86_32.patch
new file mode 100644
index 000000000000..4c4ea0486a2f
--- /dev/null
+++ b/media-libs/assimp/files/assimp-5.2.3-drop-failing-tests-for-abi_x86_32.patch
@@ -0,0 +1,131 @@
+From f963a15bbbcfa1e3c4bd0c24173f90151e023469 Mon Sep 17 00:00:00 2001
+From: Bernd Waibel <waebbl-gentoo@posteo.net>
+Date: Thu, 28 Apr 2022 07:59:26 +0200
+Subject: [PATCH] drop failing tests for abi_x86_32
+
+Signed-off-by: Bernd Waibel <waebbl-gentoo@posteo.net>
+--- a/test/unit/AssimpAPITest_aiMatrix3x3.cpp
++++ b/test/unit/AssimpAPITest_aiMatrix3x3.cpp
+@@ -68,13 +68,6 @@ TEST_F(AssimpAPITest_aiMatrix3x3, aiMatrix3FromMatrix4Test) {
+     EXPECT_EQ(result_cpp, result_c);
+ }
+ 
+-TEST_F(AssimpAPITest_aiMatrix3x3, aiMatrix3FromQuaternionTest) {
+-    const auto q = random_quat();
+-    result_cpp = q.GetMatrix();
+-    aiMatrix3FromQuaternion(&result_c, &q);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+ TEST_F(AssimpAPITest_aiMatrix3x3, aiMatrix3AreEqualTest) {
+     result_c = result_cpp = random_mat3();
+     EXPECT_EQ(result_cpp == result_c,
+--- a/test/unit/AssimpAPITest_aiMatrix4x4.cpp
++++ b/test/unit/AssimpAPITest_aiMatrix4x4.cpp
+@@ -78,15 +78,6 @@ TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4FromMatrix3Test) {
+     EXPECT_EQ(result_cpp, result_c);
+ }
+ 
+-TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4FromScalingQuaternionPositionTest) {
+-    const aiVector3D s = random_vec3();
+-    const aiQuaternion q = random_quat();
+-    const aiVector3D t = random_vec3();
+-    result_cpp = aiMatrix4x4(s, q, t);
+-    aiMatrix4FromScalingQuaternionPosition(&result_c, &s, &q, &t);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+ TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4AddTest) {
+     const aiMatrix4x4 temp = random_mat4();
+     result_c = result_cpp = random_mat4();
+@@ -135,12 +126,6 @@ TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4InverseTest) {
+     EXPECT_EQ(result_cpp, result_c);
+ }
+ 
+-TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4DeterminantTest) {
+-    result_c = result_cpp = random_mat4();
+-    EXPECT_EQ(result_cpp.Determinant(),
+-        aiMatrix4Determinant(&result_c));
+-}
+-
+ TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4IsIdentityTest) {
+     EXPECT_EQ(result_cpp.IsIdentity(),
+         (bool)aiMatrix4IsIdentity(&result_c));
+--- a/test/unit/AssimpAPITest_aiQuaternion.cpp
++++ b/test/unit/AssimpAPITest_aiQuaternion.cpp
+@@ -54,19 +54,6 @@ protected:
+     aiQuaternion result_c, result_cpp;
+ };
+ 
+-TEST_F(AssimpAPITest_aiQuaternion, aiCreateQuaternionFromMatrixTest) {
+-    // Use a predetermined transformation matrix
+-    // to prevent running into division by zero.
+-    aiMatrix3x3 m, r;
+-    aiMatrix3x3::Translation(aiVector2D(14,-25), m);
+-    aiMatrix3x3::RotationZ(Math::aiPi<float>() / 4.0f, r);
+-    m = m * r;
+-
+-    result_cpp = aiQuaternion(m);
+-    aiCreateQuaternionFromMatrix(&result_c, &m);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+ TEST_F(AssimpAPITest_aiQuaternion, aiQuaternionFromEulerAnglesTest) {
+     const float x(RandPI.next()),
+         y(RandPI.next()),
+--- a/test/unit/AssimpAPITest_aiVector2D.cpp
++++ b/test/unit/AssimpAPITest_aiVector2D.cpp
+@@ -67,28 +67,6 @@ TEST_F(AssimpAPITest_aiVector2D, aiVector2AreEqualEpsilonTest) {
+         (bool)aiVector2AreEqualEpsilon(&result_cpp, &result_c, Epsilon));
+ }
+ 
+-TEST_F(AssimpAPITest_aiVector2D, aiVector2AddTest) {
+-    result_c = result_cpp = random_vec2();
+-    result_cpp += temp;
+-    aiVector2Add(&result_c, &temp);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+-TEST_F(AssimpAPITest_aiVector2D, aiVector2SubtractTest) {
+-    result_c = result_cpp = random_vec2();
+-    result_cpp -= temp;
+-    aiVector2Subtract(&result_c, &temp);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+-TEST_F(AssimpAPITest_aiVector2D, aiVector2ScaleTest) {
+-    const float FACTOR = RandNonZero.next();
+-    result_c = result_cpp = random_vec2();
+-    result_cpp *= FACTOR;
+-    aiVector2Scale(&result_c, FACTOR);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+ TEST_F(AssimpAPITest_aiVector2D, aiVector2SymMulTest) {
+     result_c = result_cpp = random_vec2();
+     result_cpp = result_cpp.SymMul(temp);
+@@ -96,21 +74,6 @@ TEST_F(AssimpAPITest_aiVector2D, aiVector2SymMulTest) {
+     EXPECT_EQ(result_cpp, result_c);
+ }
+ 
+-TEST_F(AssimpAPITest_aiVector2D, aiVector2DivideByScalarTest) {
+-    const float DIVISOR = RandNonZero.next();
+-    result_c = result_cpp = random_vec2();
+-    result_cpp /= DIVISOR;
+-    aiVector2DivideByScalar(&result_c, DIVISOR);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+-TEST_F(AssimpAPITest_aiVector2D, aiVector2DivideByVectorTest) {
+-    result_c = result_cpp = random_vec2();
+-    result_cpp = result_cpp / temp;
+-    aiVector2DivideByVector(&result_c, &temp);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+ TEST_F(AssimpAPITest_aiVector2D, aiVector2LengthTest) {
+     result_c = result_cpp = random_vec2();
+     EXPECT_EQ(result_cpp.Length(), aiVector2Length(&result_c));
+-- 
+2.35.1
+


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

* [gentoo-commits] repo/gentoo:master commit in: media-libs/assimp/files/, media-libs/assimp/
@ 2022-08-23  5:11 Sam James
  0 siblings, 0 replies; 11+ messages in thread
From: Sam James @ 2022-08-23  5:11 UTC (permalink / raw
  To: gentoo-commits

commit:     586bd49181ad3b91291ac4d9bdd05f70b7dc2dce
Author:     Bernd Waibel <waebbl-gentoo <AT> posteo <DOT> net>
AuthorDate: Sun Jul 24 14:33:40 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Tue Aug 23 05:10:55 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=586bd491

media-libs/assimp: fix version mismatch in pkg-config and cmake files

Closes: https://bugs.gentoo.org/859862
Bug: https://github.com/assimp/assimp/issues/4655
Signed-off-by: Bernd Waibel <waebbl-gentoo <AT> posteo.net>
Closes: https://github.com/gentoo/gentoo/pull/26566
Signed-off-by: Sam James <sam <AT> gentoo.org>

 media-libs/assimp/assimp-5.2.4-r1.ebuild           | 67 ++++++++++++++++++++++
 .../assimp/files/assimp-5.2.4-update-version.patch | 34 +++++++++++
 2 files changed, 101 insertions(+)

diff --git a/media-libs/assimp/assimp-5.2.4-r1.ebuild b/media-libs/assimp/assimp-5.2.4-r1.ebuild
new file mode 100644
index 000000000000..a6b0a428bfd5
--- /dev/null
+++ b/media-libs/assimp/assimp-5.2.4-r1.ebuild
@@ -0,0 +1,67 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake
+
+DESCRIPTION="Importer library to import assets from 3D files"
+HOMEPAGE="https://github.com/assimp/assimp"
+SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0/5.2.4"
+KEYWORDS="~amd64 ~arm ~arm64 ~riscv ~x86"
+IUSE="samples test"
+
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+	dev-libs/boost:=
+	sys-libs/zlib[minizip]
+	samples? (
+		media-libs/freeglut
+		virtual/opengl
+		x11-libs/libX11
+	)
+"
+DEPEND="${RDEPEND}"
+
+PATCHES=(
+	"${FILESDIR}"/${PN}-5.2.2-fix-usage-of-incompatible-minizip-data-structure.patch
+	"${FILESDIR}"/${PN}-5.2.2-disable-failing-tests.patch
+	"${FILESDIR}"/${P}-update-version.patch
+)
+
+DOCS=( CodeConventions.md Readme.md )
+
+src_prepare() {
+	if use x86 ; then
+		eapply "${FILESDIR}"/${P}-drop-failing-tests-for-abi_x86_32.patch
+	fi
+
+	cmake_src_prepare
+}
+
+src_configure() {
+	local mycmakeargs=(
+		-DASSIMP_ASAN=OFF
+		-DASSIMP_BUILD_DOCS=OFF
+		-DASSIMP_BUILD_SAMPLES=$(usex samples)
+		-DASSIMP_BUILD_TESTS=$(usex test)
+		-DASSIMP_INJECT_DEBUG_POSTFIX=OFF
+		-DASSIMP_IGNORE_GIT_HASH=ON
+		-DASSIMP_UBSAN=OFF
+		-DASSIMP_WARNINGS_AS_ERRORS=OFF
+	)
+
+	if use samples; then
+		mycmakeargs+=( -DOpenGL_GL_PREFERENCE="GLVND" )
+	fi
+
+	cmake_src_configure
+}
+
+src_test() {
+	"${BUILD_DIR}/bin/unit" || die
+}

diff --git a/media-libs/assimp/files/assimp-5.2.4-update-version.patch b/media-libs/assimp/files/assimp-5.2.4-update-version.patch
new file mode 100644
index 000000000000..cc70165bc2e0
--- /dev/null
+++ b/media-libs/assimp/files/assimp-5.2.4-update-version.patch
@@ -0,0 +1,34 @@
+https://github.com/assimp/assimp/issues/4655
+https://github.com/assimp/assimp/pull/4656
+
+From 304b0f61d7c9ef7e2e5ca2eed185b32a2951aa90 Mon Sep 17 00:00:00 2001
+From: Bernd Waibel <waebbl-gentoo@posteo.net>
+Date: Sat, 30 Jul 2022 09:39:12 +0200
+Subject: [PATCH] update version
+
+Signed-off-by: Bernd Waibel <waebbl-gentoo@posteo.net>
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,7 +56,7 @@ IF(ASSIMP_HUNTER_ENABLED)
+   add_definitions(-DASSIMP_USE_HUNTER)
+ ENDIF()
+ 
+-PROJECT(Assimp VERSION 5.2.0)
++PROJECT(Assimp VERSION 5.2.4)
+ 
+ # All supported options ###############################################
+ 
+--- a/test/unit/utVersion.cpp
++++ b/test/unit/utVersion.cpp
+@@ -61,7 +61,7 @@ TEST_F( utVersion, aiGetVersionMajorTest ) {
+ }
+ 
+ TEST_F( utVersion, aiGetVersionPatchTest ) {
+-    EXPECT_EQ(aiGetVersionPatch(), 0U );   
++    EXPECT_EQ(aiGetVersionPatch(), 4U );
+ }
+ 
+ TEST_F( utVersion, aiGetCompileFlagsTest ) {
+-- 
+2.35.1
+


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

* [gentoo-commits] repo/gentoo:master commit in: media-libs/assimp/files/, media-libs/assimp/
@ 2023-01-09  7:02 Viorel Munteanu
  0 siblings, 0 replies; 11+ messages in thread
From: Viorel Munteanu @ 2023-01-09  7:02 UTC (permalink / raw
  To: gentoo-commits

commit:     eac45bbb9fdd3b54c4ddd3f9427feb9c672118e5
Author:     Bernd Waibel <waebbl-gentoo <AT> posteo <DOT> net>
AuthorDate: Sun Dec 25 08:56:48 2022 +0000
Commit:     Viorel Munteanu <ceamac <AT> gentoo <DOT> org>
CommitDate: Mon Jan  9 07:01:39 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=eac45bbb

media-libs/assimp: disable failing tests

Closes: https://bugs.gentoo.org/879147
Signed-off-by: Bernd Waibel <waebbl-gentoo <AT> posteo.net>
Closes: https://github.com/gentoo/gentoo/pull/28796
Signed-off-by: Viorel Munteanu <ceamac <AT> gentoo.org>

 media-libs/assimp/assimp-5.2.5.ebuild              |   8 +-
 .../files/assimp-5.2.5-disable-failing-tests.patch |  95 ++++++++++++++
 ...p-5.2.5-drop-failing-tests-for-abi_x86_32.patch | 143 +++++++++++++++++++++
 3 files changed, 242 insertions(+), 4 deletions(-)

diff --git a/media-libs/assimp/assimp-5.2.5.ebuild b/media-libs/assimp/assimp-5.2.5.ebuild
index 05540699b679..d002d8d91eaf 100644
--- a/media-libs/assimp/assimp-5.2.5.ebuild
+++ b/media-libs/assimp/assimp-5.2.5.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2022 Gentoo Authors
+# Copyright 1999-2023 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=8
@@ -28,15 +28,15 @@ RDEPEND="
 DEPEND="${RDEPEND}"
 
 PATCHES=(
-	"${FILESDIR}"/${PN}-5.2.2-disable-failing-tests.patch
-	"${FILESDIR}"/${P}-fix-version.patch
+	"${FILESDIR}"/${PN}-5.2.5-fix-version.patch
+	"${FILESDIR}"/${PN}-5.2.5-disable-failing-tests.patch
 )
 
 DOCS=( CodeConventions.md Readme.md )
 
 src_prepare() {
 	if use x86 ; then
-		eapply "${FILESDIR}"/${P}-drop-failing-tests-for-abi_x86_32.patch
+		eapply "${FILESDIR}"/${PN}-5.2.5-drop-failing-tests-for-abi_x86_32.patch
 	fi
 
 	cmake_src_prepare

diff --git a/media-libs/assimp/files/assimp-5.2.5-disable-failing-tests.patch b/media-libs/assimp/files/assimp-5.2.5-disable-failing-tests.patch
new file mode 100644
index 000000000000..92936e6442eb
--- /dev/null
+++ b/media-libs/assimp/files/assimp-5.2.5-disable-failing-tests.patch
@@ -0,0 +1,95 @@
+From aaace4ca2e2d4f46b7dce0940af6e332563c5a21 Mon Sep 17 00:00:00 2001
+From: Bernd Waibel <waebbl-gentoo@posteo.net>
+Date: Sat, 24 Dec 2022 11:19:17 +0100
+Subject: [PATCH] disable failing tests
+
+Signed-off-by: Bernd Waibel <waebbl-gentoo@posteo.net>
+--- a/test/unit/AssimpAPITest_aiMatrix3x3.cpp
++++ b/test/unit/AssimpAPITest_aiMatrix3x3.cpp
+@@ -127,25 +127,9 @@ TEST_F(AssimpAPITest_aiMatrix3x3, aiMatrix3RotationZTest) {
+     EXPECT_EQ(result_cpp, result_c);
+ }
+ 
+-TEST_F(AssimpAPITest_aiMatrix3x3, aiMatrix3FromRotationAroundAxisTest) {
+-    const float angle(RandPI.next());
+-    const auto axis = random_unit_vec3();
+-    aiMatrix3x3::Rotation(angle, axis, result_cpp);
+-    aiMatrix3FromRotationAroundAxis(&result_c, &axis, angle);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+ TEST_F(AssimpAPITest_aiMatrix3x3, aiMatrix3TranslationTest) {
+     const auto axis = random_vec2();
+     aiMatrix3x3::Translation(axis, result_cpp);
+     aiMatrix3Translation(&result_c, &axis);
+     EXPECT_EQ(result_cpp, result_c);
+ }
+-
+-TEST_F(AssimpAPITest_aiMatrix3x3, aiMatrix3FromToTest) {
+-    // Use predetermined vectors to prevent running into division by zero.
+-    const auto from = aiVector3D(1,2,1).Normalize(), to = aiVector3D(-1,1,1).Normalize();
+-    aiMatrix3x3::FromToMatrix(from, to, result_cpp);
+-    aiMatrix3FromTo(&result_c, &from, &to);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+--- a/test/unit/AssimpAPITest_aiMatrix4x4.cpp
++++ b/test/unit/AssimpAPITest_aiMatrix4x4.cpp
+@@ -228,14 +228,6 @@ TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4RotationZTest) {
+     EXPECT_EQ(result_cpp, result_c);
+ }
+ 
+-TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4FromRotationAroundAxisTest) {
+-    const float angle(RandPI.next());
+-    const auto axis = random_unit_vec3();
+-    aiMatrix4x4::Rotation(angle, axis, result_cpp);
+-    aiMatrix4FromRotationAroundAxis(&result_c, &axis, angle);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+ TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4TranslationTest) {
+     const auto axis = random_vec3();
+     aiMatrix4x4::Translation(axis, result_cpp);
+@@ -249,11 +241,3 @@ TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4ScalingTest) {
+     aiMatrix4Scaling(&result_c, &scaling);
+     EXPECT_EQ(result_cpp, result_c);
+ }
+-
+-TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4FromToTest) {
+-    // Use predetermined vectors to prevent running into division by zero.
+-    const auto from = aiVector3D(1,2,1).Normalize(), to = aiVector3D(-1,1,1).Normalize();
+-    aiMatrix4x4::FromToMatrix(from, to, result_cpp);
+-    aiMatrix4FromTo(&result_c, &from, &to);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+--- a/test/unit/AssimpAPITest_aiQuaternion.cpp
++++ b/test/unit/AssimpAPITest_aiQuaternion.cpp
+@@ -84,13 +84,6 @@ TEST_F(AssimpAPITest_aiQuaternion, aiQuaternionFromAxisAngleTest) {
+     EXPECT_EQ(result_cpp, result_c);
+ }
+ 
+-TEST_F(AssimpAPITest_aiQuaternion, aiQuaternionFromNormalizedQuaternionTest) {
+-    const auto qvec3 = random_unit_vec3();
+-    result_cpp = aiQuaternion(qvec3);
+-    aiQuaternionFromNormalizedQuaternion(&result_c, &qvec3);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+ TEST_F(AssimpAPITest_aiQuaternion, aiQuaternionAreEqualTest) {
+     result_c = result_cpp = random_quat();
+     EXPECT_EQ(result_cpp == result_c,
+--- a/test/unit/utVersion.cpp
++++ b/test/unit/utVersion.cpp
+@@ -68,10 +68,6 @@ TEST_F( utVersion, aiGetCompileFlagsTest ) {
+     EXPECT_NE( aiGetCompileFlags(), 0U );
+ }
+ 
+-TEST_F( utVersion, aiGetVersionRevisionTest ) {
+-    EXPECT_NE( aiGetVersionRevision(), 0U );
+-}
+-
+ TEST_F( utVersion, aiGetBranchNameTest ) {
+     EXPECT_NE( nullptr, aiGetBranchName() );
+ }
+-- 
+2.39.0
+

diff --git a/media-libs/assimp/files/assimp-5.2.5-drop-failing-tests-for-abi_x86_32.patch b/media-libs/assimp/files/assimp-5.2.5-drop-failing-tests-for-abi_x86_32.patch
new file mode 100644
index 000000000000..1ee315ab28be
--- /dev/null
+++ b/media-libs/assimp/files/assimp-5.2.5-drop-failing-tests-for-abi_x86_32.patch
@@ -0,0 +1,143 @@
+From f3d40e0bd8b7134f963adc08b8c2bb043a385c6f Mon Sep 17 00:00:00 2001
+From: Bernd Waibel <waebbl-gentoo@posteo.net>
+Date: Sun, 25 Dec 2022 09:46:58 +0100
+Subject: [PATCH] drop failing tests for abi_x86_32
+
+Signed-off-by: Bernd Waibel <waebbl-gentoo@posteo.net>
+--- a/test/unit/AssimpAPITest_aiMatrix3x3.cpp
++++ b/test/unit/AssimpAPITest_aiMatrix3x3.cpp
+@@ -68,13 +68,6 @@ TEST_F(AssimpAPITest_aiMatrix3x3, aiMatrix3FromMatrix4Test) {
+     EXPECT_EQ(result_cpp, result_c);
+ }
+ 
+-TEST_F(AssimpAPITest_aiMatrix3x3, aiMatrix3FromQuaternionTest) {
+-    const auto q = random_quat();
+-    result_cpp = q.GetMatrix();
+-    aiMatrix3FromQuaternion(&result_c, &q);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+ TEST_F(AssimpAPITest_aiMatrix3x3, aiMatrix3AreEqualTest) {
+     result_c = result_cpp = random_mat3();
+     EXPECT_EQ(result_cpp == result_c,
+@@ -102,18 +95,6 @@ TEST_F(AssimpAPITest_aiMatrix3x3, aiTransposeMatrix3Test) {
+     EXPECT_EQ(result_cpp, result_c);
+ }
+ 
+-TEST_F(AssimpAPITest_aiMatrix3x3, aiMatrix3InverseTest) {
+-    // Use a predetermined matrix to prevent arbitrary
+-    // cases where it could have a null determinant.
+-    result_c = result_cpp = aiMatrix3x3(
+-        5, 2, 7,
+-        4, 6, 9,
+-        1, 8, 3);
+-    result_cpp.Inverse();
+-    aiMatrix3Inverse(&result_c);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+ TEST_F(AssimpAPITest_aiMatrix3x3, aiMatrix3DeterminantTest) {
+     result_c = result_cpp = random_mat3();
+     EXPECT_EQ(result_cpp.Determinant(),
+--- a/test/unit/AssimpAPITest_aiMatrix4x4.cpp
++++ b/test/unit/AssimpAPITest_aiMatrix4x4.cpp
+@@ -78,15 +78,6 @@ TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4FromMatrix3Test) {
+     EXPECT_EQ(result_cpp, result_c);
+ }
+ 
+-TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4FromScalingQuaternionPositionTest) {
+-    const aiVector3D s = random_vec3();
+-    const aiQuaternion q = random_quat();
+-    const aiVector3D t = random_vec3();
+-    result_cpp = aiMatrix4x4(s, q, t);
+-    aiMatrix4FromScalingQuaternionPosition(&result_c, &s, &q, &t);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+ TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4AddTest) {
+     const aiMatrix4x4 temp = random_mat4();
+     result_c = result_cpp = random_mat4();
+@@ -135,12 +126,6 @@ TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4InverseTest) {
+     EXPECT_EQ(result_cpp, result_c);
+ }
+ 
+-TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4DeterminantTest) {
+-    result_c = result_cpp = random_mat4();
+-    EXPECT_EQ(result_cpp.Determinant(),
+-        aiMatrix4Determinant(&result_c));
+-}
+-
+ TEST_F(AssimpAPITest_aiMatrix4x4, aiMatrix4IsIdentityTest) {
+     EXPECT_EQ(result_cpp.IsIdentity(),
+         (bool)aiMatrix4IsIdentity(&result_c));
+--- a/test/unit/AssimpAPITest_aiQuaternion.cpp
++++ b/test/unit/AssimpAPITest_aiQuaternion.cpp
+@@ -54,19 +54,6 @@ protected:
+     aiQuaternion result_c, result_cpp;
+ };
+ 
+-TEST_F(AssimpAPITest_aiQuaternion, aiCreateQuaternionFromMatrixTest) {
+-    // Use a predetermined transformation matrix
+-    // to prevent running into division by zero.
+-    aiMatrix3x3 m, r;
+-    aiMatrix3x3::Translation(aiVector2D(14,-25), m);
+-    aiMatrix3x3::RotationZ(Math::aiPi<float>() / 4.0f, r);
+-    m = m * r;
+-
+-    result_cpp = aiQuaternion(m);
+-    aiCreateQuaternionFromMatrix(&result_c, &m);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+ TEST_F(AssimpAPITest_aiQuaternion, aiQuaternionFromEulerAnglesTest) {
+     const float x(RandPI.next()),
+         y(RandPI.next()),
+@@ -115,14 +102,3 @@ TEST_F(AssimpAPITest_aiQuaternion, aiQuaternionMultiplyTest) {
+     aiQuaternionMultiply(&result_c, &temp);
+     EXPECT_EQ(result_cpp, result_c);
+ }
+-
+-TEST_F(AssimpAPITest_aiQuaternion, aiQuaternionInterpolateTest) {
+-    // Use predetermined quaternions to prevent division by zero
+-    // during slerp calculations.
+-    const float INTERPOLATION(0.5f);
+-    const auto q1 = aiQuaternion(aiVector3D(-1,1,1).Normalize(), Math::aiPi<float>() / 4.0f);
+-    const auto q2 = aiQuaternion(aiVector3D(1,2,1).Normalize(), Math::aiPi<float>() / 2.0f);
+-    aiQuaternion::Interpolate(result_cpp, q1, q2, INTERPOLATION);
+-    aiQuaternionInterpolate(&result_c, &q1, &q2, INTERPOLATION);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+--- a/test/unit/AssimpAPITest_aiVector2D.cpp
++++ b/test/unit/AssimpAPITest_aiVector2D.cpp
+@@ -74,28 +74,6 @@ TEST_F(AssimpAPITest_aiVector2D, aiVector2AddTest) {
+     EXPECT_EQ(result_cpp, result_c);
+ }
+ 
+-TEST_F(AssimpAPITest_aiVector2D, aiVector2SubtractTest) {
+-    result_c = result_cpp = random_vec2();
+-    result_cpp -= temp;
+-    aiVector2Subtract(&result_c, &temp);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+-TEST_F(AssimpAPITest_aiVector2D, aiVector2ScaleTest) {
+-    const float FACTOR = RandNonZero.next();
+-    result_c = result_cpp = random_vec2();
+-    result_cpp *= FACTOR;
+-    aiVector2Scale(&result_c, FACTOR);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+-TEST_F(AssimpAPITest_aiVector2D, aiVector2SymMulTest) {
+-    result_c = result_cpp = random_vec2();
+-    result_cpp = result_cpp.SymMul(temp);
+-    aiVector2SymMul(&result_c, &temp);
+-    EXPECT_EQ(result_cpp, result_c);
+-}
+-
+ TEST_F(AssimpAPITest_aiVector2D, aiVector2DivideByScalarTest) {
+     const float DIVISOR = RandNonZero.next();
+     result_c = result_cpp = random_vec2();
+-- 
+2.39.0
+


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

* [gentoo-commits] repo/gentoo:master commit in: media-libs/assimp/files/, media-libs/assimp/
@ 2023-02-05  9:13 Joonas Niilola
  0 siblings, 0 replies; 11+ messages in thread
From: Joonas Niilola @ 2023-02-05  9:13 UTC (permalink / raw
  To: gentoo-commits

commit:     abea5e37fe1b382f5809945fef52c18306cea76c
Author:     Bernd Waibel <waebbl-gentoo <AT> posteo <DOT> net>
AuthorDate: Mon Jan 23 18:15:48 2023 +0000
Commit:     Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Sun Feb  5 09:12:52 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=abea5e37

media-libs/assimp: don't build COLLADA module

Avoid a security issue when processing COLLADA files.
Don't build the module until fixed upstream.
Need to drop additional collada related tests as well.

Bug: https://github.com/assimp/assimp/issues/4286
Bug: https://bugs.gentoo.org/891787
Signed-off-by: Bernd Waibel <waebbl-gentoo <AT> posteo.net>
Closes: https://github.com/gentoo/gentoo/pull/29231
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>

 ...{assimp-5.2.5.ebuild => assimp-5.2.5-r1.ebuild} |  4 ++++
 .../files/assimp-5.2.5-disable-collada-tests.patch | 28 ++++++++++++++++++++++
 2 files changed, 32 insertions(+)

diff --git a/media-libs/assimp/assimp-5.2.5.ebuild b/media-libs/assimp/assimp-5.2.5-r1.ebuild
similarity index 88%
rename from media-libs/assimp/assimp-5.2.5.ebuild
rename to media-libs/assimp/assimp-5.2.5-r1.ebuild
index d002d8d91eaf..83391bc9adf2 100644
--- a/media-libs/assimp/assimp-5.2.5.ebuild
+++ b/media-libs/assimp/assimp-5.2.5-r1.ebuild
@@ -30,6 +30,7 @@ DEPEND="${RDEPEND}"
 PATCHES=(
 	"${FILESDIR}"/${PN}-5.2.5-fix-version.patch
 	"${FILESDIR}"/${PN}-5.2.5-disable-failing-tests.patch
+	"${FILESDIR}"/${PN}-5.2.5-disable-collada-tests.patch
 )
 
 DOCS=( CodeConventions.md Readme.md )
@@ -55,6 +56,9 @@ src_configure() {
 		-DASSIMP_IGNORE_GIT_HASH=ON
 		-DASSIMP_UBSAN=OFF
 		-DASSIMP_WARNINGS_AS_ERRORS=OFF
+		# bug #891787, intentionally not in alphabetic ordering
+		-DASSIMP_BUILD_COLLADA_IMPORTER=OFF
+		-DASSIMP_BUILD_COLLADA_EXPORTER=OFF
 	)
 
 	if use samples; then

diff --git a/media-libs/assimp/files/assimp-5.2.5-disable-collada-tests.patch b/media-libs/assimp/files/assimp-5.2.5-disable-collada-tests.patch
new file mode 100644
index 000000000000..971578f0016f
--- /dev/null
+++ b/media-libs/assimp/files/assimp-5.2.5-disable-collada-tests.patch
@@ -0,0 +1,28 @@
+From 3bd65679f7db2ec95abb22fef7a30a15dcc1c297 Mon Sep 17 00:00:00 2001
+From: Bernd Waibel <waebbl-gentoo@posteo.net>
+Date: Mon, 23 Jan 2023 19:54:23 +0100
+Subject: [PATCH] disable collada tests
+
+Signed-off-by: Bernd Waibel <waebbl-gentoo@posteo.net>
+--- a/test/CMakeLists.txt
++++ b/test/CMakeLists.txt
+@@ -63,7 +63,6 @@ SET( COMMON
+   unit/utSimd.cpp
+   unit/utIOSystem.cpp
+   unit/utIOStreamBuffer.cpp
+-  unit/utIssues.cpp
+   unit/utAnim.cpp
+   unit/AssimpAPITest.cpp
+   unit/AssimpAPITest_aiMatrix3x3.cpp
+@@ -137,8 +136,6 @@ SET( IMPORTERS
+   unit/utBlendImportMaterials.cpp
+   unit/utBlenderWork.cpp
+   unit/utBVHImportExport.cpp
+-  unit/utColladaExport.cpp
+-  unit/utColladaImportExport.cpp
+   unit/utCSMImportExport.cpp
+   unit/utB3DImportExport.cpp
+   #unit/utM3DImportExport.cpp
+-- 
+2.39.1
+


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

* [gentoo-commits] repo/gentoo:master commit in: media-libs/assimp/files/, media-libs/assimp/
@ 2024-01-20 12:27 Sam James
  0 siblings, 0 replies; 11+ messages in thread
From: Sam James @ 2024-01-20 12:27 UTC (permalink / raw
  To: gentoo-commits

commit:     054f5ce87ab5e96a7224e2e396f897472d0d8f62
Author:     Paul Zander <negril.nx+gentoo <AT> gmail <DOT> com>
AuthorDate: Fri Dec 15 16:50:01 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sat Jan 20 12:26:30 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=054f5ce8

media-libs/assimp: add 5.2.5-r2, add 5.3.1

Rework tests to make use of gtest via ctest.
Some tests generate random input data which might fail on fma-enabled CPUs due to smaller rounding errors on fused operations, so we repeat those
tests until they succeed.

Closes: https://bugs.gentoo.org/908403
Closes: https://bugs.gentoo.org/910362
Signed-off-by: Paul Zander <negril.nx+gentoo <AT> gmail.com>
Closes: https://github.com/gentoo/gentoo/pull/34346
Signed-off-by: Sam James <sam <AT> gentoo.org>

 media-libs/assimp/Manifest                         |   1 +
 media-libs/assimp/assimp-5.2.5-r2.ebuild           |  94 ++++++++++++++++
 media-libs/assimp/assimp-5.3.1.ebuild              | 125 +++++++++++++++++++++
 .../files/assimp-5.2.5-float-comparison.patch      |  84 ++++++++++++++
 media-libs/assimp/files/assimp-5.2.5-gtest.patch   |  30 +++++
 5 files changed, 334 insertions(+)

diff --git a/media-libs/assimp/Manifest b/media-libs/assimp/Manifest
index 34611184f6fc..cef7c0a6b33c 100644
--- a/media-libs/assimp/Manifest
+++ b/media-libs/assimp/Manifest
@@ -1 +1,2 @@
 DIST assimp-5.2.5.tar.gz 49543936 BLAKE2B 77e0eecd1307646211a86244a371e24401dffd03dceb569acdd63751cdb38bd169c8b12c942efd2e77b5f541653f2775739150b9fe352b8c903dcc4fe7bccca8 SHA512 ac0dc4243f9d1ff077966f0037187b4374075ac97e75e1a3cd6bdc1caf5f8e4d40953d9a8a316480969c09524d87daa9d3ed75e6ac6f037dd5b1c5f25fce3afb
+DIST assimp-5.3.1.tar.gz 52826870 BLAKE2B 1f3eac17deb6d19777f2a7cdf74e5be9d6df12a70e9b0449a90f3cc6f85b6d4170de2b870c028e2ad9c7f6ac7269daa0cbb3971dd1feb83a5b12a683ff8bb72f SHA512 49963f84ed0a8145f3af249890a533f0b12f5553ae09581289cb1f20cb49cb1a3ed3f3c4c966ceb43aa897b90deca268aa6554066b2bd34f2ac9c15041420ddb

diff --git a/media-libs/assimp/assimp-5.2.5-r2.ebuild b/media-libs/assimp/assimp-5.2.5-r2.ebuild
new file mode 100644
index 000000000000..d8f7abc1a02b
--- /dev/null
+++ b/media-libs/assimp/assimp-5.2.5-r2.ebuild
@@ -0,0 +1,94 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake
+
+DESCRIPTION="Importer library to import assets from 3D files"
+HOMEPAGE="https://github.com/assimp/assimp"
+SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0/${PV}"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~riscv ~x86"
+IUSE="samples test"
+
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+	sys-libs/zlib[minizip]
+	samples? (
+		media-libs/freeglut
+		media-libs/libglvnd
+	)
+	test? (
+		dev-cpp/gtest
+	)
+"
+DEPEND="${RDEPEND}"
+
+PATCHES=(
+	"${FILESDIR}/${PN}-5.2.5-gtest.patch"
+	"${FILESDIR}/${PN}-5.2.5-float-comparison.patch"
+)
+
+DOCS=( CodeConventions.md Readme.md )
+
+src_prepare() {
+	sed -r \
+		-e "s#PROJECT\(Assimp VERSION [0-9]+\.[0-9]+\.[0-9]+\)#PROJECT(Assimp VERSION ${PV})#g" \
+		-i CMakeLists.txt || die
+	sed -r \
+		-e "s#EXPECT_EQ\(aiGetVersionPatch\(\), [0-9]+U \);#EXPECT_EQ(aiGetVersionPatch(), $(ver_cut 3)U );#g" \
+		-e "s#EXPECT_NE\( aiGetVersionRevision#EXPECT_EQ\( aiGetVersionRevision#g" \
+		-i test/unit/utVersion.cpp || die
+	sed \
+		-e "s# -O0 -g # #g" \
+		-i \
+			cmake-modules/Coveralls.cmake \
+			contrib/android-cmake/android.toolchain.cmake \
+			contrib/openddlparser/CMakeLists.txt \
+			CMakeLists.txt \
+		|| die
+
+	cmake_src_prepare
+}
+
+src_configure() {
+	local mycmakeargs=(
+		-DASSIMP_ASAN=OFF
+		-DASSIMP_BUILD_ASSIMP_TOOLS=ON
+		-DASSIMP_BUILD_DOCS=OFF
+		-DASSIMP_BUILD_SAMPLES=$(usex samples)
+		-DASSIMP_BUILD_TESTS=$(usex test)
+		-DASSIMP_BUILD_ZLIB=OFF
+		-DASSIMP_DOUBLE_PRECISION=OFF
+		-DASSIMP_INJECT_DEBUG_POSTFIX=OFF
+		-DASSIMP_IGNORE_GIT_HASH=ON
+		-DASSIMP_UBSAN=OFF
+		-DASSIMP_WARNINGS_AS_ERRORS=OFF
+		# bug #891787 (CVE-2022-45748), intentionally not in alphabetic ordering
+		-DASSIMP_BUILD_COLLADA_IMPORTER=OFF
+		-DASSIMP_BUILD_COLLADA_EXPORTER=OFF
+	)
+
+	if use samples; then
+		mycmakeargs+=( -DOpenGL_GL_PREFERENCE="GLVND" )
+	fi
+
+	cmake_src_configure
+}
+
+src_test() {
+	local CMAKE_SKIP_TESTS=(
+		# ( Failed )
+		"^utCollada.*"
+		"^utIssues.OpacityBugWhenExporting_727$"
+	)
+	myctestargs+=(
+		--repeat until-pass:100
+	)
+
+	cmake_src_test
+}

diff --git a/media-libs/assimp/assimp-5.3.1.ebuild b/media-libs/assimp/assimp-5.3.1.ebuild
new file mode 100644
index 000000000000..1fd76e9b1701
--- /dev/null
+++ b/media-libs/assimp/assimp-5.3.1.ebuild
@@ -0,0 +1,125 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake
+
+DESCRIPTION="Importer library to import assets from 3D files"
+HOMEPAGE="https://github.com/assimp/assimp"
+SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0/${PV}"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~riscv ~x86"
+IUSE="doc samples test"
+
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+	sys-libs/zlib[minizip]
+	doc? ( app-doc/doxygen )
+	samples? (
+		media-libs/freeglut
+		media-libs/libglvnd
+	)
+	test? (
+		dev-cpp/gtest
+	)
+"
+DEPEND="${RDEPEND}"
+
+PATCHES=(
+	"${FILESDIR}/${PN}-5.2.5-gtest.patch"
+	"${FILESDIR}/${PN}-5.2.5-float-comparison.patch"
+)
+
+DOCS=( CodeConventions.md Readme.md )
+
+src_prepare() {
+	sed -r \
+		-e "s#PROJECT\(Assimp VERSION [0-9]+\.[0-9]+\.[0-9]+\)#PROJECT(Assimp VERSION ${PV})#g" \
+		-i CMakeLists.txt || die
+	sed -r \
+		-e "s#EXPECT_EQ\(aiGetVersionPatch\(\), [0-9]+U \);#EXPECT_EQ(aiGetVersionPatch(), $(ver_cut 3)U );#g" \
+		-e "s#EXPECT_NE\( aiGetVersionRevision#EXPECT_EQ\( aiGetVersionRevision#g" \
+		-i test/unit/utVersion.cpp || die
+	sed \
+		-e "s# -g -O0 # #g" \
+		-i \
+			cmake-modules/Coveralls.cmake \
+			contrib/android-cmake/android.toolchain.cmake \
+			contrib/openddlparser/CMakeLists.txt \
+			CMakeLists.txt \
+		|| die
+	sed -r \
+		-e "s#(PROJECT_NUMBER *= \").*\"#\1v${PV}\"#g" \
+		-e "s#(GENERATE_XML *= )(YES|NO)#\1NO#g" \
+		-e "s#(GENERATE_HTML *= )(YES|NO)#\1YES#g" \
+		-i doc/Doxyfile.in || die
+	sed -r \
+		-e "s#AssimpDoc_Html(/AnimationOverview)#architecture\1#g" \
+		-e "s#AssimpDoc_Html(/dragonsplash)#images\1#g" \
+		-i doc/CMakeLists.txt || die
+
+	cmake_src_prepare
+}
+
+src_configure() {
+	local mycmakeargs=(
+		# -DASSIMP_ASAN=yes # Enable AddressSanitizer.
+		-DASSIMP_BUILD_ASSIMP_TOOLS=yes # If the supplementary tools for Assimp are built in addition to the library.
+		-DASSIMP_BUILD_DOCS=$(usex doc) # Build documentation using Doxygen.
+		# -DASSIMP_BUILD_DRACO=no # If the Draco libraries are to be built. Primarily for glTF
+		# -DASSIMP_BUILD_NONFREE_C4D_IMPORTER=no # Build the C4D importer, which relies on the non-free Cineware SDK.
+		-DASSIMP_BUILD_SAMPLES=$(usex samples) # If the official samples are built as well (needs Glut).
+		-DASSIMP_BUILD_TESTS=$(usex test) # If the test suite for Assimp is built in addition to the library.
+		-DASSIMP_BUILD_ZLIB=no # Build your own zlib
+		-DASSIMP_COVERALLS=$(usex test) # Enable this to measure test coverage.
+		# breaks tests
+		# -DASSIMP_DOUBLE_PRECISION=no # Set to yes to enable double precision processing
+		# -DASSIMP_HUNTER_ENABLED=no # Enable Hunter package manager support
+		-DASSIMP_IGNORE_GIT_HASH=yes # Don't call git to get the hash.
+		-DASSIMP_INJECT_DEBUG_POSTFIX=no # Inject debug postfix in .a/.so/.dll lib names
+		# -DASSIMP_INSTALL=yes # Disable this if you want to use assimp as a submodule.
+		# -DASSIMP_LIBRARY_SUFFIX= # Suffix to append to library names
+		# -DASSIMP_NO_EXPORT=no # Disable Assimp's export functionality.
+		# -DASSIMP_OPT_BUILD_PACKAGES=no # Set to yes to generate CPack configuration files and packaging targets
+		-DASSIMP_RAPIDJSON_NO_MEMBER_ITERATOR=no # Suppress rapidjson warning on MSVC (NOTE: breaks android build)
+		# -DASSIMP_UBSAN=yes # Enable Undefined Behavior sanitizer.
+		-DASSIMP_WARNINGS_AS_ERRORS=no # Treat all warnings as errors.
+		# -DBUILD_SHARED_LIBS=yes # Build package with shared libraries.
+		# bug #891787 (CVE-2022-45748), intentionally not in alphabetic ordering
+		-DASSIMP_BUILD_COLLADA_IMPORTER=OFF
+		-DASSIMP_BUILD_COLLADA_EXPORTER=OFF
+	)
+
+	if use doc; then
+		mycmakeargs+=(
+			-DHTML_OUTPUT="html"
+		)
+	fi
+	if use samples; then
+		mycmakeargs+=(
+			-DOpenGL_GL_PREFERENCE="GLVND"
+		)
+	fi
+	if use test; then
+		# adds the target headercheck which compiles every header file, default disabled because it adds many targets
+		-DASSIMP_HEADERCHECK=$(usex test)
+	fi
+
+	cmake_src_configure
+}
+
+src_test() {
+	local CMAKE_SKIP_TESTS=(
+		# ( Failed )
+		"^utCollada.*"
+		"^utIssues.OpacityBugWhenExporting_727$"
+	)
+	myctestargs+=(
+		--repeat until-pass:100
+	)
+	cmake_src_test
+}

diff --git a/media-libs/assimp/files/assimp-5.2.5-float-comparison.patch b/media-libs/assimp/files/assimp-5.2.5-float-comparison.patch
new file mode 100644
index 000000000000..ccbcffe2c167
--- /dev/null
+++ b/media-libs/assimp/files/assimp-5.2.5-float-comparison.patch
@@ -0,0 +1,84 @@
+diff --git a/include/assimp/matrix3x3.inl b/include/assimp/matrix3x3.inl
+index 99d9197..0ffa433 100644
+--- a/include/assimp/matrix3x3.inl
++++ b/include/assimp/matrix3x3.inl
+@@ -140,9 +140,7 @@ const TReal* aiMatrix3x3t<TReal>::operator[] (unsigned int p_iIndex) const {
+ template <typename TReal>
+ AI_FORCE_INLINE
+ bool aiMatrix3x3t<TReal>::operator== (const aiMatrix3x3t<TReal>& m) const {
+-    return a1 == m.a1 && a2 == m.a2 && a3 == m.a3 &&
+-           b1 == m.b1 && b2 == m.b2 && b3 == m.b3 &&
+-           c1 == m.c1 && c2 == m.c2 && c3 == m.c3;
++    return this->Equal(m);
+ }
+ 
+ // ------------------------------------------------------------------------------------------------
+diff --git a/include/assimp/matrix4x4.inl b/include/assimp/matrix4x4.inl
+index 54d176d..0d9da5d 100644
+--- a/include/assimp/matrix4x4.inl
++++ b/include/assimp/matrix4x4.inl
+@@ -328,10 +328,7 @@ const TReal* aiMatrix4x4t<TReal>::operator[](unsigned int p_iIndex) const {
+ template <typename TReal>
+ AI_FORCE_INLINE
+ bool aiMatrix4x4t<TReal>::operator== (const aiMatrix4x4t<TReal>& m) const {
+-    return (a1 == m.a1 && a2 == m.a2 && a3 == m.a3 && a4 == m.a4 &&
+-            b1 == m.b1 && b2 == m.b2 && b3 == m.b3 && b4 == m.b4 &&
+-            c1 == m.c1 && c2 == m.c2 && c3 == m.c3 && c4 == m.c4 &&
+-            d1 == m.d1 && d2 == m.d2 && d3 == m.d3 && d4 == m.d4);
++    return this->Equal(m);
+ }
+ 
+ // ----------------------------------------------------------------------------------------
+diff --git a/include/assimp/quaternion.inl b/include/assimp/quaternion.inl
+index 960e91a..d6bcbe7 100644
+--- a/include/assimp/quaternion.inl
++++ b/include/assimp/quaternion.inl
+@@ -73,7 +73,7 @@ aiQuaterniont<TReal> operator * (const aiMatrix4x4t<TReal>& pMatrix, const aiQua
+ template<typename TReal>
+ bool aiQuaterniont<TReal>::operator== (const aiQuaterniont& o) const
+ {
+-    return x == o.x && y == o.y && z == o.z && w == o.w;
++    return this->Equal(o);
+ }
+ 
+ // ---------------------------------------------------------------------------
+diff --git a/include/assimp/vector2.inl b/include/assimp/vector2.inl
+index 245eb31..cd057fe 100644
+--- a/include/assimp/vector2.inl
++++ b/include/assimp/vector2.inl
+@@ -144,14 +144,14 @@ TReal aiVector2t<TReal>::operator[](unsigned int i) const {
+ template <typename TReal>
+ inline
+ bool aiVector2t<TReal>::operator== (const aiVector2t& other) const {
+-    return x == other.x && y == other.y;
++    return this->Equal(other);
+ }
+ 
+ // ------------------------------------------------------------------------------------------------
+ template <typename TReal>
+ inline
+ bool aiVector2t<TReal>::operator!= (const aiVector2t& other) const {
+-    return x != other.x || y != other.y;
++    return !(*this == other);
+ }
+ 
+ // ---------------------------------------------------------------------------
+diff --git a/include/assimp/vector3.inl b/include/assimp/vector3.inl
+index 28ca2be..daa63e8 100644
+--- a/include/assimp/vector3.inl
++++ b/include/assimp/vector3.inl
+@@ -198,12 +198,12 @@ AI_FORCE_INLINE TReal& aiVector3t<TReal>::operator[](unsigned int i) {
+ // ------------------------------------------------------------------------------------------------
+ template <typename TReal>
+ AI_FORCE_INLINE bool aiVector3t<TReal>::operator== (const aiVector3t<TReal>& other) const {
+-    return x == other.x && y == other.y && z == other.z;
++    return this->Equal(other);
+ }
+ // ------------------------------------------------------------------------------------------------
+ template <typename TReal>
+ AI_FORCE_INLINE bool aiVector3t<TReal>::operator!= (const aiVector3t<TReal>& other) const {
+-    return x != other.x || y != other.y || z != other.z;
++    return !(*this == other);
+ }
+ // ---------------------------------------------------------------------------
+ template<typename TReal>

diff --git a/media-libs/assimp/files/assimp-5.2.5-gtest.patch b/media-libs/assimp/files/assimp-5.2.5-gtest.patch
new file mode 100644
index 000000000000..9441141337ac
--- /dev/null
+++ b/media-libs/assimp/files/assimp-5.2.5-gtest.patch
@@ -0,0 +1,30 @@
+diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
+index afe4874..5a87cc2 100644
+--- a/test/CMakeLists.txt
++++ b/test/CMakeLists.txt
+@@ -191,7 +191,6 @@ SET( POST_PROCESSES
+   unit/utRemoveComments.cpp
+   unit/utRemoveComponent.cpp
+   unit/utVertexTriangleAdjacency.cpp
+-  unit/utJoinVertices.cpp
+   unit/utSplitLargeMeshes.cpp
+   unit/utFindDegenerates.cpp
+   unit/utFindInvalidData.cpp
+@@ -281,4 +281,6 @@ target_link_libraries( unit assimp ${platform_libs} )
+ 
+ add_subdirectory(headercheck)
+ 
+-add_test( unittests unit )
++get_target_property(unit_SOURCES unit SOURCES)
++find_package(GTest REQUIRED)
++gtest_add_tests(TARGET unit ${unit_SOURCES})
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -725,6 +725,7 @@ IF ( ASSIMP_BUILD_SAMPLES )
+ ENDIF ()
+ 
+ IF ( ASSIMP_BUILD_TESTS )
++  enable_testing()
+   ADD_SUBDIRECTORY( test/ )
+ ENDIF ()
+ 


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

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

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-11-18 10:50 [gentoo-commits] repo/gentoo:master commit in: media-libs/assimp/files/, media-libs/assimp/ Slawek Lis
  -- strict thread matches above, loose matches on Subject: below --
2024-01-20 12:27 Sam James
2023-02-05  9:13 Joonas Niilola
2023-01-09  7:02 Viorel Munteanu
2022-08-23  5:11 Sam James
2022-04-29  2:22 Sam James
2020-06-05 12:48 Andreas Sturmlechner
2019-10-09  5:43 Slawek Lis
2018-09-15  2:31 Andreas Sturmlechner
2018-08-26  0:00 Andreas Sturmlechner
2018-05-16 12:09 Andreas Sturmlechner

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