From owner-svn-ports-head@freebsd.org Tue Jul 2 07:19:57 2019 Return-Path: Delivered-To: svn-ports-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C1B1315CA1AF; Tue, 2 Jul 2019 07:19:57 +0000 (UTC) (envelope-from kai@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 5875171634; Tue, 2 Jul 2019 07:19:57 +0000 (UTC) (envelope-from kai@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 322D020F20; Tue, 2 Jul 2019 07:19:57 +0000 (UTC) (envelope-from kai@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id x627Jvbl018706; Tue, 2 Jul 2019 07:19:57 GMT (envelope-from kai@FreeBSD.org) Received: (from kai@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id x627JuI6018702; Tue, 2 Jul 2019 07:19:56 GMT (envelope-from kai@FreeBSD.org) Message-Id: <201907020719.x627JuI6018702@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kai set sender to kai@FreeBSD.org using -f From: Kai Knoblich Date: Tue, 2 Jul 2019 07:19:56 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r505661 - in head/graphics: . py-img2pdf X-SVN-Group: ports-head X-SVN-Commit-Author: kai X-SVN-Commit-Paths: in head/graphics: . py-img2pdf X-SVN-Commit-Revision: 505661 X-SVN-Commit-Repository: ports MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 5875171634 X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-2.96 / 15.00]; local_wl_from(0.00)[FreeBSD.org]; NEURAL_HAM_SHORT(-0.97)[-0.966,0]; ASN(0.00)[asn:11403, ipnet:2610:1c1:1::/48, country:US]; NEURAL_HAM_MEDIUM(-1.00)[-0.998,0]; NEURAL_HAM_LONG(-1.00)[-1.000,0] X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 02 Jul 2019 07:19:58 -0000 Author: kai Date: Tue Jul 2 07:19:56 2019 New Revision: 505661 URL: https://svnweb.freebsd.org/changeset/ports/505661 Log: New port: graphics/py-img2pdf This Python package provides lossless conversion of raster images to PDF. You should use img2pdf if your priorities are (in this order): 1. "always lossless": The image embedded in the PDF will always have the exact same color information for every pixel as the input. 2. "small": If possible, the difference in filesize between the input image and the output PDF will only be the overhead of the PDF container itself. 3. "fast": If possible, the input image is just pasted into the PDF document as-is without any CPU hungry re-encoding of the pixel data. Conventional conversion software (like ImageMagick) would either: 1. Not be lossless because lossy re-encoding to JPEG. 2. Not be small because using wasteful flate encoding of raw pixel data. 3. Not be fast because input data gets re-encoded. Another advantage of not having to re-encode the input (in most common situations) is, that img2pdf is able to handle much larger input than other software, because the raw pixel data never has to be loaded into memory. WWW: https://gitlab.mister-muffin.de/josch/img2pdf Added: head/graphics/py-img2pdf/ head/graphics/py-img2pdf/Makefile (contents, props changed) head/graphics/py-img2pdf/distinfo (contents, props changed) head/graphics/py-img2pdf/pkg-descr (contents, props changed) Modified: head/graphics/Makefile Modified: head/graphics/Makefile ============================================================================== --- head/graphics/Makefile Tue Jul 2 05:43:56 2019 (r505660) +++ head/graphics/Makefile Tue Jul 2 07:19:56 2019 (r505661) @@ -842,6 +842,7 @@ SUBDIR += py-imageio-ffmpeg SUBDIR += py-imageio24 SUBDIR += py-imagesize + SUBDIR += py-img2pdf SUBDIR += py-imgurpython SUBDIR += py-leather SUBDIR += py-mapclassify Added: head/graphics/py-img2pdf/Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/graphics/py-img2pdf/Makefile Tue Jul 2 07:19:56 2019 (r505661) @@ -0,0 +1,29 @@ +# $FreeBSD$ + +PORTNAME= img2pdf +DISTVERSION= 0.3.3 +CATEGORIES= graphics python +MASTER_SITES= CHEESESHOP +PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} + +MAINTAINER= kai@FreeBSD.org +COMMENT= Convert images to PDF via direct JPEG inclusion + +LICENSE= LGPL3+ +LICENSE_FILE= ${WRKSRC}/LICENSE + +RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pillow>0:graphics/py-pillow@${PY_FLAVOR} \ + ${PY_ENUM34} +TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pdfrw>0:textproc/py-pdfrw@${PY_FLAVOR} + +USES= python +USE_PYTHON= autoplist concurrent distutils + +NO_ARCH= yes + +# Note: The tests only work with Python 3, see also: +# https://gitlab.mister-muffin.de/josch/img2pdf/issues/60 +do-test: + @(cd ${WRKSRC} && ${PYTHON_CMD} ${PYDISTUTILS_SETUP} test) + +.include Added: head/graphics/py-img2pdf/distinfo ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/graphics/py-img2pdf/distinfo Tue Jul 2 07:19:56 2019 (r505661) @@ -0,0 +1,3 @@ +TIMESTAMP = 1558438909 +SHA256 (img2pdf-0.3.3.tar.gz) = 9d77c17ee65a736abe92ef8cba9cca009c064ea4ed74492c01aea596e41856cf +SIZE (img2pdf-0.3.3.tar.gz) = 80523 Added: head/graphics/py-img2pdf/pkg-descr ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/graphics/py-img2pdf/pkg-descr Tue Jul 2 07:19:56 2019 (r505661) @@ -0,0 +1,23 @@ +This Python package provides lossless conversion of raster images to PDF. You +should use img2pdf if your priorities are (in this order): + +1. "always lossless": The image embedded in the PDF will always have the exact + same color information for every pixel as the input. + +2. "small": If possible, the difference in filesize between the input image and + the output PDF will only be the overhead of the PDF container itself. + +3. "fast": If possible, the input image is just pasted into the PDF document + as-is without any CPU hungry re-encoding of the pixel data. + +Conventional conversion software (like ImageMagick) would either: + +1. Not be lossless because lossy re-encoding to JPEG. +2. Not be small because using wasteful flate encoding of raw pixel data. +3. Not be fast because input data gets re-encoded. + +Another advantage of not having to re-encode the input (in most common +situations) is, that img2pdf is able to handle much larger input than other +software, because the raw pixel data never has to be loaded into memory. + +WWW: https://gitlab.mister-muffin.de/josch/img2pdf