aboutsummaryrefslogtreecommitdiff
path: root/graphics/py-lerc
diff options
context:
space:
mode:
authorPo-Chuan Hsieh <sunpoet@FreeBSD.org>2022-08-27 10:10:30 +0000
committerPo-Chuan Hsieh <sunpoet@FreeBSD.org>2022-08-27 10:10:30 +0000
commit2b8486a5c333215ecb74f745851d80f1ed1df884 (patch)
tree2356fd9ab57843e14b1c90227fd319ec8d1c49d7 /graphics/py-lerc
parent39eb9db143e8415db6bbeb403ebc71b6a779362a (diff)
downloadports-2b8486a5c333215ecb74f745851d80f1ed1df884.tar.gz
ports-2b8486a5c333215ecb74f745851d80f1ed1df884.zip
graphics/py-lerc: Add py-lerc 4.0.0
LERC is an open-source image or raster format which supports rapid encoding and decoding for any pixel type (not just RGB or Byte). Users set the maximum compression error per pixel while encoding, so the precision of the original input image is preserved (within user defined error bounds). This port is the Python binding for LERC (Limited Error Raster Compression). WWW: https://esri.github.io/lerc/ WWW: https://github.com/Esri/lerc/tree/master/OtherLanguages/Python
Diffstat (limited to 'graphics/py-lerc')
-rw-r--r--graphics/py-lerc/Makefile28
-rw-r--r--graphics/py-lerc/distinfo3
-rw-r--r--graphics/py-lerc/files/patch-setup.py13
-rw-r--r--graphics/py-lerc/pkg-descr9
4 files changed, 53 insertions, 0 deletions
diff --git a/graphics/py-lerc/Makefile b/graphics/py-lerc/Makefile
new file mode 100644
index 000000000000..68b9844fb275
--- /dev/null
+++ b/graphics/py-lerc/Makefile
@@ -0,0 +1,28 @@
+PORTNAME= lerc
+PORTVERSION= 4.0.0
+DISTVERSIONPREFIX= v
+CATEGORIES= graphics python
+PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
+
+MAINTAINER= sunpoet@FreeBSD.org
+COMMENT= Python binding for LERC (Limited Error Raster Compression)
+
+LICENSE= APACHE20
+LICENSE_FILE= ${WRKSRC}/../../LICENSE
+
+LIB_DEPENDS= libLerc.so:graphics/lerc
+
+USES= python:3.6+
+USE_PYTHON= autoplist concurrent distutils
+
+WRKSRC_SUBDIR= OtherLanguages/Python
+
+GH_ACCOUNT= Esri
+USE_GITHUB= yes
+
+# lib/libLerc.* are not available until configure phase
+post-configure:
+ @${MKDIR} ${WRKSRC}/../../bin/FreeBSD/
+ @${CP} ${LOCALBASE}/lib/libLerc.so.* ${WRKSRC}/../../bin/FreeBSD/
+
+.include <bsd.port.mk>
diff --git a/graphics/py-lerc/distinfo b/graphics/py-lerc/distinfo
new file mode 100644
index 000000000000..dccfa1bda1e1
--- /dev/null
+++ b/graphics/py-lerc/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1660576692
+SHA256 (Esri-lerc-v4.0.0_GH0.tar.gz) = 91431c2b16d0e3de6cbaea188603359f87caed08259a645fd5a3805784ee30a0
+SIZE (Esri-lerc-v4.0.0_GH0.tar.gz) = 4710408
diff --git a/graphics/py-lerc/files/patch-setup.py b/graphics/py-lerc/files/patch-setup.py
new file mode 100644
index 000000000000..3f9a1926b396
--- /dev/null
+++ b/graphics/py-lerc/files/patch-setup.py
@@ -0,0 +1,13 @@
+--- setup.py.orig 2022-07-15 18:25:29 UTC
++++ setup.py
+@@ -16,8 +16,8 @@ except Exception:
+
+ # Using MANIFEST.in doesn't respect relative paths above the package root.
+ # Instead, inspect the location and copy in the binaries if newer.
+-BINARY_TYPES = ["*.dll", "*.lib", "*.so*", "*.dylib"]
+-PLATFORMS = ["Linux", "MacOS", "windows"]
++BINARY_TYPES = ["*.so*"]
++PLATFORMS = ["FreeBSD"]
+ for platform in PLATFORMS:
+ platform_dir = join("..", "..", "bin", platform)
+ for ext in BINARY_TYPES:
diff --git a/graphics/py-lerc/pkg-descr b/graphics/py-lerc/pkg-descr
new file mode 100644
index 000000000000..f308b5cd40d6
--- /dev/null
+++ b/graphics/py-lerc/pkg-descr
@@ -0,0 +1,9 @@
+LERC is an open-source image or raster format which supports rapid encoding and
+decoding for any pixel type (not just RGB or Byte). Users set the maximum
+compression error per pixel while encoding, so the precision of the original
+input image is preserved (within user defined error bounds).
+
+This port is the Python binding for LERC (Limited Error Raster Compression).
+
+WWW: https://esri.github.io/lerc/
+WWW: https://github.com/Esri/lerc/tree/master/OtherLanguages/Python