diff options
author | Andreas Sturmlechner <asturm@gentoo.org> | 2017-02-11 16:31:24 +0100 |
---|---|---|
committer | Andreas Sturmlechner <asturm@gentoo.org> | 2017-02-12 14:19:14 +0100 |
commit | 480753efd49061c8ea1fff89a9f0a7c16678c175 (patch) | |
tree | d0b82f34a2a639aba076c2390c56f4a894654b35 /media-gfx/enblend | |
parent | dev-ml/ocaml-containers: Add 1.0 without keywords since it breaks its sole re... (diff) | |
download | gentoo-480753efd49061c8ea1fff89a9f0a7c16678c175.tar.gz gentoo-480753efd49061c8ea1fff89a9f0a7c16678c175.tar.bz2 gentoo-480753efd49061c8ea1fff89a9f0a7c16678c175.zip |
media-gfx/enblend: Fix Find{LCMS2,OpenGL}.cmake hardcoded lib32 paths
Fixes build on amd64 without ABI_X86_32 enabled deps.
- enblend-4.1.3-r2: EAPI 6, cleanup deps, add missing virtual/glu dep
- enblend-4.2.0_p20161007-r1: Cleanup, fix, sort, drop unused deps
- push back media-libs/libpng, virtual/jpeg to DEPEND (only headers)
- media-gfx/imagemagick -> virtual/imagemagick-tools, only if USE=doc
Package-Manager: portage-2.3.3
Closes: https://github.com/gentoo/gentoo/pull/3923
Diffstat (limited to 'media-gfx/enblend')
5 files changed, 201 insertions, 2 deletions
diff --git a/media-gfx/enblend/enblend-4.1.3-r2.ebuild b/media-gfx/enblend/enblend-4.1.3-r2.ebuild new file mode 100644 index 000000000000..4405286b0477 --- /dev/null +++ b/media-gfx/enblend/enblend-4.1.3-r2.ebuild @@ -0,0 +1,87 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=6 + +inherit cmake-utils + +MY_P="${PN}-enfuse-${PV}" + +DESCRIPTION="Image Blending with Multiresolution Splines" +HOMEPAGE="http://enblend.sourceforge.net/" +SRC_URI="mirror://sourceforge/enblend/${MY_P}.tar.gz" + +LICENSE="GPL-2 VIGRA" +SLOT="0" +KEYWORDS="~amd64 ~ppc ~x86" +IUSE="debug doc gpu openmp" + +RDEPEND=" + dev-libs/boost:= + media-libs/lcms:2 + media-libs/openexr:= + media-libs/tiff:= + media-libs/vigra[openexr] + sci-libs/gsl:= + debug? ( dev-libs/dmalloc ) + gpu? ( + media-libs/freeglut + media-libs/glew:* + virtual/glu + virtual/opengl + )" +DEPEND="${RDEPEND} + media-libs/libpng:0 + sys-apps/help2man + virtual/jpeg:0 + virtual/pkgconfig + doc? ( + media-gfx/transfig + sci-visualization/gnuplot[gd] + virtual/imagemagick-tools + virtual/latex-base + )" + +S="${WORKDIR}/${MY_P}" + +DOCS=( AUTHORS NEWS README ) + +PATCHES=( + "${FILESDIR}"/${P}-vigra_check.patch + "${FILESDIR}"/${P}-texinfo-5-upstream.patch + "${FILESDIR}"/${P}-texinfo-5-more.patch + "${FILESDIR}"/${P}-cmake.patch +) + +src_prepare() { + cmake-utils_src_prepare + + # CRLF in files, don't bother with patch + sed -i -e "/FIND_LIBRARY(LCMS2_LIBRARIES/s/lib32/lib/" \ + CMakeModules/FindLCMS2.cmake || die + sed -e "/FIND_LIBRARY(OPENGL_gl_LIBRARY/s/lib32/lib/" \ + -e "/NAMES.*MesaGLU/s/lib32/lib/" \ + -i CMakeModules/FindOpenGL.cmake || die + + sed -i -e "/CXX_FLAGS/s:-O3::g" CMakeLists.txt || die + sed -i -e "s:doc/enblend:share/doc/${PF}:" doc/CMakeLists.txt || die +} + +src_configure() { + local mycmakeargs=( + -DCMAKE_CXX_FLAGS_RELEASE="" + -DENABLE_DMALLOC=$(usex debug) + -DDOC=$(usex doc) + -DENABLE_GPU=$(usex gpu) + -DENABLE_IMAGECACHE=$(usex !openmp) + -DENABLE_OPENMP=$(usex openmp) + ) + CMAKE_BUILD_TYPE="Release" + cmake-utils_src_configure +} + +src_compile() { + # forcing -j1 as every parallel compilation process needs about 1 GB RAM. + cmake-utils_src_compile -j1 +} diff --git a/media-gfx/enblend/enblend-4.2.0_p20161007-r1.ebuild b/media-gfx/enblend/enblend-4.2.0_p20161007-r1.ebuild new file mode 100644 index 000000000000..3480db31938f --- /dev/null +++ b/media-gfx/enblend/enblend-4.2.0_p20161007-r1.ebuild @@ -0,0 +1,79 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=6 + +inherit cmake-utils + +DESCRIPTION="Image Blending with Multiresolution Splines" +HOMEPAGE="http://enblend.sourceforge.net/" +SRC_URI="https://dev.gentoo.org/~soap/distfiles/${P}.tar.xz" + +LICENSE="GPL-2 VIGRA" +SLOT="0" +KEYWORDS="~amd64 ~ppc ~x86" +IUSE="debug doc openmp tcmalloc cpu_flags_x86_sse2" + +REQUIRED_USE="tcmalloc? ( !debug )" + +RDEPEND=" + media-libs/lcms:2 + media-libs/openexr:= + media-libs/tiff:0 + media-libs/vigra[openexr] + sci-libs/gsl:= + debug? ( dev-libs/dmalloc ) + tcmalloc? ( dev-util/google-perftools )" +DEPEND="${RDEPEND} + >=dev-libs/boost-1.62.0 + media-libs/libpng:0 + sys-apps/help2man + virtual/jpeg:0 + virtual/pkgconfig + doc? ( + dev-lang/perl + dev-perl/Readonly + dev-tex/hevea + gnome-base/librsvg + media-gfx/graphviz + media-gfx/transfig + sci-visualization/gnuplot[gd] + virtual/imagemagick-tools + virtual/latex-base + )" + +PATCHES=( + "${FILESDIR}"/${PN}-4.2-doc-install-dir-fix.patch + "${FILESDIR}"/${P}-cmake.patch +) + +src_prepare() { + cmake-utils_src_prepare + + sed -i -e "s:share/doc/enblend:share/doc/${PF}:" doc/CMakeLists.txt || die +} + +src_configure() { + local mycmakeargs=( + -DENABLE_DMALLOC=$(usex debug) + -DENABLE_TCMALLOC=$(usex tcmalloc) + -DDOC=$(usex doc) + -DINSTALL_HTML_DOC=$(usex doc) + -DINSTALL_PDF_DOC=$(usex doc) + -DENABLE_OPENMP=$(usex openmp) + -DENABLE_SSE2=$(usex cpu_flags_x86_sse2) + ) + cmake-utils_src_configure +} + +src_compile() { + # To allow icon resizing with renderers (no way to disable) + addpredict /dev/dri + + # To compile fonts in the temp directory + export VARTEXFONTS="${T}/fonts" + + # forcing -j1 as every parallel compilation process needs about 1 GB RAM. + cmake-utils_src_compile -j1 +} diff --git a/media-gfx/enblend/files/enblend-4.1.3-cmake.patch b/media-gfx/enblend/files/enblend-4.1.3-cmake.patch new file mode 100644 index 000000000000..e9fef85278d5 --- /dev/null +++ b/media-gfx/enblend/files/enblend-4.1.3-cmake.patch @@ -0,0 +1,22 @@ +--- a/CMakeLists.txt 2017-02-12 13:43:46.862787952 +0100 ++++ b/CMakeLists.txt 2017-02-12 13:50:03.461229021 +0100 +@@ -185,7 +185,6 @@ + FIND_PACKAGE(TIFF REQUIRED) + FIND_PACKAGE(Perl REQUIRED) + # this one is needed in doc. (Especially the program "convert") +-FIND_PACKAGE(ImageMagick REQUIRED) + FIND_PACKAGE(GSL REQUIRED) + include_directories(${GSL_INCLUDE_DIR}) + LIST(APPEND common_libs ${LCMS2_LIBRARIES} ${TIFF_LIBRARIES} ${GSL_LIBRARIES}) +@@ -394,8 +393,9 @@ + add_subdirectory(src) + + # you really should have perl installed, when creating doc's +-if (PERL_FOUND AND IMAGEMAGICK_FOUND AND DOC) +- # this should be set from comman line ++if (PERL_FOUND AND DOC) ++ FIND_PACKAGE(ImageMagick REQUIRED) ++ # this should be set from command line + # Possible values like described in README: @smallbook @afivepaper @afourpaper @afourwide @afourlatex + # @letter is default + set(EXTRATEXI2DVIFLAGS "@afourpaper" CACHE STRING "Papersize: @letter @smallbook @afivepaper @afourpaper @afourwide @afourlatex") diff --git a/media-gfx/enblend/files/enblend-4.1.3-vigra_check.patch b/media-gfx/enblend/files/enblend-4.1.3-vigra_check.patch index 982293e47713..d067df3c57ae 100644 --- a/media-gfx/enblend/files/enblend-4.1.3-vigra_check.patch +++ b/media-gfx/enblend/files/enblend-4.1.3-vigra_check.patch @@ -1,5 +1,5 @@ ---- ConfigureChecks.cmake.orig 2013-10-07 10:50:00.000000000 +0400 -+++ ConfigureChecks.cmake 2015-03-31 13:42:40.179527224 +0300 +--- a/ConfigureChecks.cmake 2013-10-07 10:50:00.000000000 +0400 ++++ b/ConfigureChecks.cmake 2015-03-31 13:42:40.179527224 +0300 @@ -53,7 +53,7 @@ if(VIGRA_FOUND AND NOT VIGRA_VERSION_CHECK) unset(VIGRA_SETIMAGEINDEX CACHE) diff --git a/media-gfx/enblend/files/enblend-4.2.0_p20161007-cmake.patch b/media-gfx/enblend/files/enblend-4.2.0_p20161007-cmake.patch new file mode 100644 index 000000000000..fcbeb64232d1 --- /dev/null +++ b/media-gfx/enblend/files/enblend-4.2.0_p20161007-cmake.patch @@ -0,0 +1,11 @@ +--- a/CMakeModules/FindLCMS2.cmake 2016-09-24 11:28:47.000000000 +0200 ++++ b/CMakeModules/FindLCMS2.cmake 2017-02-11 16:15:33.492507341 +0100 +@@ -5,7 +5,7 @@ + /usr/local/include + /usr/include + ) +- FIND_LIBRARY(LCMS2_LIBRARIES lcms2 HINTS /usr/local/lib /usr/lib/x86_64-linux-gnu /usr/lib32) ++ FIND_LIBRARY(LCMS2_LIBRARIES lcms2 HINTS /usr/local/lib /usr/lib/x86_64-linux-gnu /usr/lib) + ELSE(NOT WIN32) + FIND_PATH(LCMS2_ROOT_DIR + NAMES include/lcms2.h |