summaryrefslogtreecommitdiffstats
path: root/media-libs
diff options
context:
space:
mode:
authorormorph <roma251078@mail.ru>2021-02-27 09:51:12 +0300
committerTDE Gitea <gitea@mirror.git.trinitydesktop.org>2021-05-19 18:34:53 +0000
commit9246a89638ec78794615f713b04e01ca66778978 (patch)
treeab17fe3b6116cd366227e9e645641f31b2f7c82f /media-libs
parent80f7847b40a3f56df35ad5e7d26907c7bf45c665 (diff)
downloadtde-packaging-gentoo-9246a89638ec78794615f713b04e01ca66778978.tar.gz
tde-packaging-gentoo-9246a89638ec78794615f713b04e01ca66778978.zip
Aded media-libs/lcms
Signed-off-by: ormorph <roma251078@mail.ru>
Diffstat (limited to 'media-libs')
-rw-r--r--media-libs/lcms/Manifest1
-rw-r--r--media-libs/lcms/files/lcms-1.19-disable_static_modules.patch20
-rw-r--r--media-libs/lcms/files/lcms-1.19-implicit.patch49
-rw-r--r--media-libs/lcms/lcms-1.19-r1.ebuild59
-rw-r--r--media-libs/lcms/metadata.xml16
5 files changed, 145 insertions, 0 deletions
diff --git a/media-libs/lcms/Manifest b/media-libs/lcms/Manifest
new file mode 100644
index 00000000..3aefd93f
--- /dev/null
+++ b/media-libs/lcms/Manifest
@@ -0,0 +1 @@
+DIST lcms-1.19.tar.gz 927752 BLAKE2B b8850f47652270082e11729119c35dfb90e112a40a80c531298b9585d89b3fba6e3ff1e0abd284ec2c6654a64fd44870f79d0a437917b8414e94d38afb66be93 SHA512 85a55ad0673f0df2aaa80d18caa50314319f8da5ee4d84eed919059d0dad9861d684ef6353ce0ec6f9892a4603ce8e8e12f84d46858e23f52846b8aefd3cf449
diff --git a/media-libs/lcms/files/lcms-1.19-disable_static_modules.patch b/media-libs/lcms/files/lcms-1.19-disable_static_modules.patch
new file mode 100644
index 00000000..15e19eeb
--- /dev/null
+++ b/media-libs/lcms/files/lcms-1.19-disable_static_modules.patch
@@ -0,0 +1,20 @@
+--- a/python/Makefile.am
++++ b/python/Makefile.am
+@@ -22,7 +22,7 @@
+
+ endif
+
+-_lcms_la_LDFLAGS = -no-undefined -module -avoid-version \
++_lcms_la_LDFLAGS = -no-undefined -module -avoid-version -shared \
+ -L$(LCMS_PYLIB)/config
+
+ _lcms_la_LIBADD = $(top_builddir)/src/liblcms.la -lpython$(PYTHON_VERSION)
+@@ -31,7 +31,7 @@
+
+ _lcms_la_CPPFLAGS = -I$(PYTHON_PREFIX)/include/python$(PYTHON_VERSION) \
+ -I$(LCMS_PYINCLUDE) \
+- $(AM_CPPFLAGS)
++ $(AM_CPPFLAGS) -shared
+
+
+ EXTRA_DIST = lcms.py lcms.i testbed swig_lcms
diff --git a/media-libs/lcms/files/lcms-1.19-implicit.patch b/media-libs/lcms/files/lcms-1.19-implicit.patch
new file mode 100644
index 00000000..d8047227
--- /dev/null
+++ b/media-libs/lcms/files/lcms-1.19-implicit.patch
@@ -0,0 +1,49 @@
+cmsio1.c: In function 'AdjustEndianessArray16':
+cmsio1.c:118: warning: implicit declaration of function 'swab'
+testcms.c: In function 'CheckSwab':
+testcms.c:113: warning: implicit declaration of function 'swab'
+================================================================================
+--- a/src/Makefile.am
++++ b/src/Makefile.am
+@@ -6,6 +6,9 @@
+ # Don't require all the GNU mandated files
+ AUTOMAKE_OPTIONS = 1.7 foreign
+
++# _XOPEN_SOURCE is required for swab() but undefines strcasecmp(), so add _GNU_SOURCE as well:
++AM_CPPFLAGS = -D_XOPEN_SOURCE -D_GNU_SOURCE
++
+ includedir = ${prefix}/include
+
+ # Shared libraries built in this directory
+--- a/src/cmsio1.c
++++ b/src/cmsio1.c
+@@ -24,6 +24,7 @@
+
+
+ #include "lcms.h"
++#include <unistd.h>
+
+ // ----------------------------------------------------------------- Tag Serialization
+
+--- a/testbed/Makefile.am
++++ b/testbed/Makefile.am
+@@ -6,6 +6,9 @@
+ # Don't require all the GNU mandated files
+ AUTOMAKE_OPTIONS = 1.7 foreign
+
++# Required for swab()
++AM_CPPFLAGS = -D_XOPEN_SOURCE
++
+ INCLUDES = -I$(top_builddir)/include -I$(top_srcdir)/include
+
+ check_PROGRAMS = testcms
+--- a/testbed/testcms.c
++++ b/testbed/testcms.c
+@@ -36,6 +36,7 @@
+ #include <time.h>
+ #include <stdio.h>
+ #include <stdlib.h>
++#include <unistd.h>
+
+ #ifndef NON_WINDOWS
+ #include <icm.h>
diff --git a/media-libs/lcms/lcms-1.19-r1.ebuild b/media-libs/lcms/lcms-1.19-r1.ebuild
new file mode 100644
index 00000000..e4bcf3dc
--- /dev/null
+++ b/media-libs/lcms/lcms-1.19-r1.ebuild
@@ -0,0 +1,59 @@
+# Copyright 1999-2021 Gentoo Authors
+# Copyright 2021 The Trinity Desktop Project
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="7"
+
+inherit autotools eutils
+
+DESCRIPTION="Lightweight, speed optimized color management engine"
+HOMEPAGE="https://www.littlecms.com/"
+SRC_URI="mirror://sourceforge/lcms/${PV}/${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 m68k ~mips ppc ppc64 s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
+IUSE="jpeg static-libs tiff zlib"
+
+# Don't use Gentoo mirrors
+RESTRICT="mirror"
+
+RDEPEND="
+ jpeg? ( virtual/jpeg:0 )
+ tiff? ( media-libs/tiff:0 )
+ zlib? ( sys-libs/zlib )"
+DEPEND="${RDEPEND}"
+
+PATCHES=(
+ "${FILESDIR}/${P}-disable_static_modules.patch"
+ "${FILESDIR}/${P}-implicit.patch"
+)
+
+src_prepare() {
+
+ default
+
+ eautoreconf
+}
+
+src_configure() {
+ econf \
+ --libdir="${EPREFIX}"/usr/$(get_libdir) \
+ --bindir="${EPREFIX}"/usr/bin \
+ --disable-dependency-tracking \
+ $(use_enable static-libs static) \
+ $(use_with jpeg) \
+ $(use_with tiff) \
+ $(use_with zlib)
+}
+
+src_install() {
+ DOCS=(AUTHORS README* INSTALL NEWS doc/*)
+
+ default
+
+ insinto /usr/share/lcms/profiles
+ doins testbed/*.icm
+
+ find "${ED}" -name '*.la' -delete || die
+}
diff --git a/media-libs/lcms/metadata.xml b/media-libs/lcms/metadata.xml
new file mode 100644
index 00000000..8a119fbe
--- /dev/null
+++ b/media-libs/lcms/metadata.xml
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>fatzer2@gmail.com</email>
+ <name>Alexander Golubev</name>
+ <description>The maintainer of the package in the overlay</description>
+ </maintainer>
+ <maintainer type="project">
+ <email>printing@gentoo.org</email>
+ <name>Gentoo Printing Project</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="sourceforge">lcms</remote-id>
+ </upstream>
+</pkgmetadata>