summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Deutschmann <whissi@gentoo.org>2021-04-24 22:07:52 +0200
committerThomas Deutschmann <whissi@gentoo.org>2021-04-24 22:07:52 +0200
commite8a9f58b5f29fbf5beb1c6b0fe4aaccfce837b2e (patch)
treec9b6d241c422d2f6ff854999c60d9a9a87f53426 /media-libs
parentmedia-libs/libjpeg-turbo: allow ekeyword usage (diff)
downloadgentoo-e8a9f58b5f29fbf5beb1c6b0fe4aaccfce837b2e.tar.gz
gentoo-e8a9f58b5f29fbf5beb1c6b0fe4aaccfce837b2e.tar.bz2
gentoo-e8a9f58b5f29fbf5beb1c6b0fe4aaccfce837b2e.zip
media-libs/libjpeg-turbo: bump to v2.1.0
Package-Manager: Portage-3.0.18, Repoman-3.0.3 Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>
Diffstat (limited to 'media-libs')
-rw-r--r--media-libs/libjpeg-turbo/Manifest1
-rw-r--r--media-libs/libjpeg-turbo/libjpeg-turbo-2.1.0.ebuild123
2 files changed, 124 insertions, 0 deletions
diff --git a/media-libs/libjpeg-turbo/Manifest b/media-libs/libjpeg-turbo/Manifest
index 8bc60edd6335..d27df442fc00 100644
--- a/media-libs/libjpeg-turbo/Manifest
+++ b/media-libs/libjpeg-turbo/Manifest
@@ -1,3 +1,4 @@
DIST libjpeg-turbo-1.5.3.tar.gz 1658672 BLAKE2B 4d2182802aa9963fa57ec2c4fb5cf0a586847d43803e4c2d2e12cf1144c4da0ede7fdbace5965c77cd6df4547090165615960ebb65c964fd2fac823c021f50b7 SHA512 b611b1cc3d1ddedddad871854b42449d053a5f910ed1bdfa45c98e0270f4ecc110fde3a10111d2b876d847a826fa634f09c0bb8c357056c9c3a91c9065eb5202
DIST libjpeg-turbo-2.0.6.tar.gz 2192315 BLAKE2B 1e003b147bf5bc1fed59df1eb42c8bd83f6548f267033969a6a26830afb24ae96c8ebba8407e4d2ded76da66a535ed59e249f64ed61218055771e5db9491514f SHA512 504062778224f2ed2ddb64c988fbf466a14247952aab0cf1d35d281942b6f0874eafd34b45914d2208e087f05ddd896c5ba87a67c944e8bb80323e187413038c
+DIST libjpeg-turbo-2.1.0.tar.gz 2255497 BLAKE2B 693eccd00e8e1574e60ceb7464552ce9c4fd370c5ec4fc0dc3696ead7b4cd031228aaaf0eef3ceba194bb96bac6134b9c951162c0b81e88637edd6e71f4577f7 SHA512 6632a2a71cb3a350fe4f850fe84e51e361755c373babf2b47fb164c3a9fc3fd66705639bebedd8c1b40cf6c15fd702e814425b0be5919048987bbec357828605
DIST libjpeg8_8d-2.debian.tar.gz 14764 BLAKE2B e93d12afa062da28b717b540492221f70e8d9ccf3885371647cf85a2937f938ca723d4a27d5e1c5d79c26aa25dddf69b38754558851a1704172e8b52baf8e17c SHA512 8c5959fb7583a2d61e9442187f67b91b45e72d9dd30db3360d583a3b5d8e1a908db5659f760bdd455b3056e6ae3535b2fd3b847df3d58b140a1816b754003675
diff --git a/media-libs/libjpeg-turbo/libjpeg-turbo-2.1.0.ebuild b/media-libs/libjpeg-turbo/libjpeg-turbo-2.1.0.ebuild
new file mode 100644
index 000000000000..2df2093af167
--- /dev/null
+++ b/media-libs/libjpeg-turbo/libjpeg-turbo-2.1.0.ebuild
@@ -0,0 +1,123 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+CMAKE_ECLASS=cmake
+inherit cmake-multilib java-pkg-opt-2 libtool toolchain-funcs
+
+DESCRIPTION="MMX, SSE, and SSE2 SIMD accelerated JPEG library"
+HOMEPAGE="https://libjpeg-turbo.org/ https://sourceforge.net/projects/libjpeg-turbo/"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz
+ mirror://gentoo/libjpeg8_8d-2.debian.tar.gz"
+
+LICENSE="BSD IJG ZLIB"
+SLOT="0/0.2"
+if [[ "$(ver_cut 3)" -lt 90 ]] ; then
+ KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-macos ~x64-solaris ~x86-solaris"
+fi
+IUSE="java static-libs"
+
+ASM_DEPEND="|| ( dev-lang/nasm dev-lang/yasm )"
+
+COMMON_DEPEND="!media-libs/jpeg:0
+ !media-libs/jpeg:62"
+
+BDEPEND=">=dev-util/cmake-3.16.5
+ amd64? ( ${ASM_DEPEND} )
+ x86? ( ${ASM_DEPEND} )
+ amd64-fbsd? ( ${ASM_DEPEND} )
+ x86-fbsd? ( ${ASM_DEPEND} )
+ amd64-linux? ( ${ASM_DEPEND} )
+ x86-linux? ( ${ASM_DEPEND} )
+ x64-macos? ( ${ASM_DEPEND} )
+ x64-cygwin? ( ${ASM_DEPEND} )"
+
+DEPEND="${COMMON_DEPEND}
+ java? ( >=virtual/jdk-1.5 )"
+
+RDEPEND="${COMMON_DEPEND}
+ java? ( >=virtual/jre-1.5 )"
+
+MULTILIB_WRAPPED_HEADERS=( /usr/include/jconfig.h )
+
+src_prepare() {
+ local FILE
+ ln -snf ../debian/extra/*.c . || die
+
+ for FILE in ../debian/extra/*.c; do
+ FILE=${FILE##*/}
+ cat >> CMakeLists.txt <<EOF || die
+add_executable(${FILE%.c} ${FILE})
+install(TARGETS ${FILE%.c})
+EOF
+ done
+
+ for FILE in ../debian/extra/exifautotran; do
+ cat >> CMakeLists.txt <<EOF || die
+install(FILES \${CMAKE_CURRENT_SOURCE_DIR}/${FILE} DESTINATION \${CMAKE_INSTALL_BINDIR})
+EOF
+ done
+
+ for FILE in ../debian/extra/*.[0-9]*; do
+ cat >> CMakeLists.txt <<EOF || die
+install(FILES \${CMAKE_CURRENT_SOURCE_DIR}/${FILE} DESTINATION \${CMAKE_INSTALL_MANDIR}/man${FILE##*.})
+EOF
+ done
+
+ #default
+
+ cmake_src_prepare
+ java-pkg-opt-2_src_prepare
+}
+
+multilib_src_configure() {
+ if multilib_is_native_abi && use java ; then
+ export JAVACFLAGS="$(java-pkg_javac-args)"
+ export JNI_CFLAGS="$(java-pkg_get-jni-cflags)"
+ fi
+
+ local mycmakeargs=(
+ -DCMAKE_INSTALL_DEFAULT_DOCDIR="${EPREFIX}/usr/share/doc/${PF}"
+ -DENABLE_STATIC="$(usex static-libs)"
+ -DWITH_JAVA="$(multilib_native_usex java)"
+ -DWITH_MEM_SRCDST=ON
+ )
+
+ # bug #420239, bug #723800
+ [[ ${ABI} == "x32" ]] && mycmakeargs+=( -DWITH_SIMD=OFF ) #420239
+
+ # mostly for Prefix, ensure that we use our yasm if installed and
+ # not pick up host-provided nasm
+ has_version dev-lang/yasm && ! has_version dev-lang/nasm && \
+ mycmakeargs+=( -DCMAKE_ASM_NASM_COMPILER=$(type -P yasm) )
+
+ cmake_src_configure
+}
+
+multilib_src_install() {
+ cmake_src_install
+
+ if multilib_is_native_abi && use java ; then
+ rm -rf "${ED}"/usr/classes || die
+ java-pkg_dojar java/turbojpeg.jar
+ fi
+}
+
+multilib_src_install_all() {
+ find "${ED}" -type f -name '*.la' -delete || die
+
+ local -a DOCS=( README.md ChangeLog.md )
+ einstalldocs
+
+ newdoc "${WORKDIR}"/debian/changelog changelog.debian
+
+ docinto html
+ dodoc -r "${S}"/doc/html/*
+
+ if use java; then
+ docinto html/java
+ dodoc -r "${S}"/java/doc/*
+ newdoc "${S}"/java/README README.java
+ fi
+}