mirror of
https://git.freebsd.org/ports.git
synced 2025-07-17 17:29:23 -04:00
Update to 3.2
- Build and install static libraries - Update BROKEN: use lowercase for leading character - Remove PLIST_SUB - Convert to options target helper - Cosmetic change - Update pkg-descr - Update WWW - Take maintainership Changes: https://github.com/mozilla/mozjpeg/releases
This commit is contained in:
parent
9397d765c7
commit
e1b82c4f16
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=440370
5 changed files with 56 additions and 99 deletions
|
@ -2,57 +2,51 @@
|
|||
# $FreeBSD$
|
||||
|
||||
PORTNAME= mozjpeg
|
||||
PORTVERSION= 3.1
|
||||
PORTVERSION= 3.2
|
||||
DISTVERSIONPREFIX= v
|
||||
PORTREVISION= 1
|
||||
CATEGORIES= graphics
|
||||
|
||||
MAINTAINER= ports@FreeBSD.org
|
||||
COMMENT= Advanced JPEG encoder for the Web
|
||||
MAINTAINER= sunpoet@FreeBSD.org
|
||||
COMMENT= Improved JPEG encoder by Mozilla
|
||||
|
||||
LICENSE= BSD3CLAUSE
|
||||
LICENSE_FILE= ${WRKSRC}/LICENSE.txt
|
||||
|
||||
USE_GITHUB= yes
|
||||
GH_ACCOUNT= mozilla
|
||||
LIB_DEPENDS= libpng.so:graphics/png
|
||||
|
||||
USES= autoreconf libtool pkgconfig
|
||||
USE_LDCONFIG= ${PREFIX}/lib/${PORTNAME}
|
||||
GNU_CONFIGURE= yes
|
||||
CONFIGURE_ARGS= --docdir=${PREFIX}/share/doc/${PORTNAME} \
|
||||
--includedir=${PREFIX}/include/${PORTNAME} \
|
||||
--libdir=${PREFIX}/lib/${PORTNAME} \
|
||||
--with-jpeg8 \
|
||||
--disable-static
|
||||
INSTALL_TARGET= install-strip
|
||||
|
||||
PLIST_SUB= PORTNAME=${PORTNAME}
|
||||
|
||||
PORTDOCS= *
|
||||
PORTEXAMPLES= *
|
||||
BROKEN_aarch64= does not configure: error: SIMD support cannot be enabled
|
||||
BROKEN_mips64= does not configure: error: SIMD support cannot be enabled
|
||||
BROKEN_powerpc64= does not build: undefined reference to htole32
|
||||
BROKEN_sparc64= does not configure: error: SIMD support cannot be enabled
|
||||
|
||||
OPTIONS_DEFINE= DOCS EXAMPLES SIMD TURBOJPEG
|
||||
OPTIONS_DEFAULT=SIMD TURBOJPEG
|
||||
OPTIONS_SUB= yes
|
||||
|
||||
SIMD_DESC= Include SIMD extensions
|
||||
TURBOJPEG_DESC= Include the TurboJPEG wrapper library and associated tests
|
||||
|
||||
SIMD_CONFIGURE_WITH= simd
|
||||
SIMD_BUILD_DEPENDS= yasm:devel/yasm
|
||||
CONFIGURE_ARGS= --docdir=${DOCSDIR} \
|
||||
--includedir=${PREFIX}/include/${PORTNAME} \
|
||||
--libdir=${PREFIX}/lib/${PORTNAME} \
|
||||
--with-jpeg8
|
||||
GNU_CONFIGURE= yes
|
||||
INSTALL_TARGET= install-strip
|
||||
USE_LDCONFIG= ${PREFIX}/lib/${PORTNAME}
|
||||
USES= autoreconf libtool pkgconfig
|
||||
|
||||
PORTDOCS= *
|
||||
PORTEXAMPLES= *
|
||||
|
||||
GH_ACCOUNT= mozilla
|
||||
USE_GITHUB= yes
|
||||
|
||||
SIMD_BUILD_DEPENDS= yasm:devel/yasm
|
||||
SIMD_CONFIGURE_WITH= simd
|
||||
TURBOJPEG_CONFIGURE_WITH= turbojpeg
|
||||
|
||||
BROKEN_aarch64= Does not configure: error: SIMD support cannot be enabled
|
||||
BROKEN_mips64= Does not configure: error: SIMD support cannot be enabled
|
||||
BROKEN_powerpc64= Does not build: undefined reference to htole32
|
||||
BROKEN_sparc64= Does not configure: error: SIMD support cannot be enabled
|
||||
|
||||
post-patch:
|
||||
@${REINPLACE_CMD} -e '/^docdir/s|=.*|= ${DOCSDIR}|; \
|
||||
/^exampledir/s|=.*|= ${EXAMPLESDIR}|' \
|
||||
${WRKSRC}/Makefile.am
|
||||
@${REINPLACE_CMD} -e '/pkgconfig/d; /^exampledir = / s| =.*| = ${EXAMPLESDIR}|' ${WRKSRC}/Makefile.am
|
||||
|
||||
post-install:
|
||||
(cd ${WRKSRC}/doc && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR})
|
||||
post-install-DOCS-on:
|
||||
cd ${WRKSRC}/doc/ && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR}/
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
|
|
@ -1,2 +1,3 @@
|
|||
SHA256 (mozilla-mozjpeg-v3.1_GH0.tar.gz) = 11823198f3c677b1832fa2dcf702e458f70c959661c4bec9c8922b7c36e94739
|
||||
SIZE (mozilla-mozjpeg-v3.1_GH0.tar.gz) = 1180063
|
||||
TIMESTAMP = 1494045680
|
||||
SHA256 (mozilla-mozjpeg-v3.2_GH0.tar.gz) = 21fa401adfb9052bc65563bc51ce8a1f18f4adc2dc68e5611f042bb3b24e48be
|
||||
SIZE (mozilla-mozjpeg-v3.2_GH0.tar.gz) = 1243935
|
||||
|
|
|
@ -1,41 +0,0 @@
|
|||
--- jcdctmgr.c.orig 2015-05-18 14:28:09 UTC
|
||||
+++ jcdctmgr.c
|
||||
@@ -6,7 +6,7 @@
|
||||
* libjpeg-turbo Modifications:
|
||||
* Copyright (C) 1999-2006, MIYASAKA Masaru.
|
||||
* Copyright 2009 Pierre Ossman <ossman@cendio.se> for Cendio AB
|
||||
- * Copyright (C) 2011, 2014 D. R. Commander
|
||||
+ * Copyright (C) 2011, 2014-2015 D. R. Commander
|
||||
* mozjpeg Modifications:
|
||||
* Copyright (C) 2014, Mozilla Corporation.
|
||||
* For conditions of distribution and use, see the accompanying README file.
|
||||
@@ -185,6 +185,19 @@ compute_reciprocal (UINT16 divisor, DCTE
|
||||
UDCTELEM c;
|
||||
int b, r;
|
||||
|
||||
+ if (divisor == 1) {
|
||||
+ /* divisor == 1 means unquantized, so these reciprocal/correction/shift
|
||||
+ * values will cause the C quantization algorithm to act like the
|
||||
+ * identity function. Since only the C quantization algorithm is used in
|
||||
+ * these cases, the scale value is irrelevant.
|
||||
+ */
|
||||
+ dtbl[DCTSIZE2 * 0] = (DCTELEM) 1; /* reciprocal */
|
||||
+ dtbl[DCTSIZE2 * 1] = (DCTELEM) 0; /* correction */
|
||||
+ dtbl[DCTSIZE2 * 2] = (DCTELEM) 1; /* scale */
|
||||
+ dtbl[DCTSIZE2 * 3] = (DCTELEM) (-sizeof(DCTELEM) * 8); /* shift */
|
||||
+ return 0;
|
||||
+ }
|
||||
+
|
||||
b = flss(divisor) - 1;
|
||||
r = sizeof(DCTELEM) * 8 + b;
|
||||
|
||||
@@ -589,7 +602,8 @@ quantize (JCOEFPTR coef_block, DCTELEM *
|
||||
|
||||
#if BITS_IN_JSAMPLE == 8
|
||||
|
||||
- UDCTELEM recip, corr, shift;
|
||||
+ UDCTELEM recip, corr;
|
||||
+ int shift;
|
||||
UDCTELEM2 product;
|
||||
|
||||
for (i = 0; i < DCTSIZE2; i++) {
|
|
@ -1,15 +1,16 @@
|
|||
MozJPEG is a fork of libjpeg-turbo with 'jpgcrush' functionality built in.
|
||||
Mozilla JPEG Encoder Project
|
||||
|
||||
This project's goal is to reduce the size of JPEG files without reducing quality
|
||||
or compatibility with the vast majority of the world's deployed decoders.
|
||||
MozJPEG reduces file sizes of JPEG images while retaining quality and
|
||||
compatibility with the vast majority of the world's deployed decoders.
|
||||
|
||||
The idea is to reduce transfer times for JPEGs on the Web, thus reducing page
|
||||
load times.
|
||||
MozJPEG is based on libjpeg-turbo. It's compatible with libjpeg API and ABI, and
|
||||
can be used as a drop-in replacement for libjpeg. MozJPEG makes tradeoffs that
|
||||
are intended to benefit Web use cases and focuses solely on improving encoding,
|
||||
so it's best used as part of a Web encoding workflow.
|
||||
|
||||
'mozjpeg' is not intended to be a general JPEG library replacement. It makes
|
||||
tradeoffs that are intended to benefit Web use cases and focuses solely on
|
||||
improving encoding. It is best used as part of a Web encoding workflow. For a
|
||||
general JPEG library (e.g. your system libjpeg), especially if you care about
|
||||
decoding, we recommend graphics/libjpeg-turbo port.
|
||||
MozJPEG is meant to be used as a library in graphics programs and image
|
||||
processing tools. We include a demo cjpeg tool, but it's not intended for
|
||||
serious use. We encourage authors of graphics programs to use MozJPEG's C API
|
||||
instead.
|
||||
|
||||
WWW: https://github.com/mozilla/mozjpeg/
|
||||
WWW: https://github.com/mozilla/mozjpeg
|
||||
|
|
|
@ -4,17 +4,19 @@ bin/jpegtran
|
|||
bin/rdjpgcom
|
||||
%%TURBOJPEG%%bin/tjbench
|
||||
bin/wrjpgcom
|
||||
include/%%PORTNAME%%/jconfig.h
|
||||
include/%%PORTNAME%%/jerror.h
|
||||
include/%%PORTNAME%%/jmorecfg.h
|
||||
include/%%PORTNAME%%/jpeglib.h
|
||||
%%TURBOJPEG%%include/%%PORTNAME%%/turbojpeg.h
|
||||
lib/%%PORTNAME%%/libjpeg.so
|
||||
lib/%%PORTNAME%%/libjpeg.so.8
|
||||
lib/%%PORTNAME%%/libjpeg.so.8.1.2
|
||||
%%TURBOJPEG%%lib/%%PORTNAME%%/libturbojpeg.so
|
||||
%%TURBOJPEG%%lib/%%PORTNAME%%/libturbojpeg.so.0
|
||||
%%TURBOJPEG%%lib/%%PORTNAME%%/libturbojpeg.so.0.1.0
|
||||
include/mozjpeg/jconfig.h
|
||||
include/mozjpeg/jerror.h
|
||||
include/mozjpeg/jmorecfg.h
|
||||
include/mozjpeg/jpeglib.h
|
||||
%%TURBOJPEG%%include/mozjpeg/turbojpeg.h
|
||||
lib/mozjpeg/libjpeg.a
|
||||
lib/mozjpeg/libjpeg.so
|
||||
lib/mozjpeg/libjpeg.so.8
|
||||
lib/mozjpeg/libjpeg.so.8.1.2
|
||||
%%TURBOJPEG%%lib/mozjpeg/libturbojpeg.a
|
||||
%%TURBOJPEG%%lib/mozjpeg/libturbojpeg.so
|
||||
%%TURBOJPEG%%lib/mozjpeg/libturbojpeg.so.0
|
||||
%%TURBOJPEG%%lib/mozjpeg/libturbojpeg.so.0.1.0
|
||||
man/man1/cjpeg.1.gz
|
||||
man/man1/djpeg.1.gz
|
||||
man/man1/jpegtran.1.gz
|
||||
|
|
Loading…
Add table
Reference in a new issue