summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorZach Callear2018-04-16 09:07:42 -0600
committerZach Callear2018-04-16 09:07:42 -0600
commit8e2f0f41a269931e954671493afa32ee950dbd7c (patch)
tree500779f287326e07b23a899bcff6501ac3813479
downloadaur-adept-git.tar.gz
Add adept-git package
-rw-r--r--.SRCINFO22
-rw-r--r--LICENSE.md16
-rw-r--r--PKGBUILD33
3 files changed, 71 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..74758ff3ef3a
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,22 @@
+pkgbase = adept-git
+ pkgdesc = A JPEG compressor which varies compression within an image based on detection of salient regions of interest
+ pkgver = r69.c5d3cf9
+ pkgrel = 1
+ url = https://github.com/technopagan/adept-jpg-compressor
+ arch = any
+ license = BSD
+ makedepends = git
+ depends = bc
+ depends = imagemagick
+ depends = jpegrescan-git
+ depends = mozjpeg
+ depends = mss-saliency-git
+ provides = adept
+ conflicts = adept
+ source = adept::git+https://github.com/technopagan/adept-jpg-compressor.git
+ source = LICENSE.md
+ md5sums = SKIP
+ md5sums = SKIP
+
+pkgname = adept-git
+
diff --git a/LICENSE.md b/LICENSE.md
new file mode 100644
index 000000000000..ead3e210c721
--- /dev/null
+++ b/LICENSE.md
@@ -0,0 +1,16 @@
+This software is published under the BSD licence 3.0
+
+Copyright (c) 2015, Tobias Baldauf
+All rights reserved.
+
+Mail: [kontakt@tobias-baldauf.de](mailto:kontakt@tobias-baldauf.de)
+Web: [who.tobias.is](http://who.tobias.is/)
+Twitter: [@tbaldauf](http://twitter.com/tbaldauf)
+
+Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
+
+ * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
+ * Neither the name of the author nor the names of contributors may be used to endorse or promote products derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..a0c194c89f81
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,33 @@
+# Maintainer: Zach Callear <zach@callear.org>
+_pkgname=adept
+pkgname="$_pkgname-git"
+pkgver=r69.c5d3cf9
+pkgrel=1
+pkgdesc="A JPEG compressor which varies compression within an image based on detection of salient regions of interest"
+arch=('any')
+url="https://github.com/technopagan/adept-jpg-compressor"
+license=('BSD')
+depends=('bc' 'imagemagick' 'jpegrescan-git' 'mozjpeg' 'mss-saliency-git')
+makedepends=('git')
+provides=("$_pkgname")
+conflicts=("$_pkgname")
+source=("$_pkgname::git+$url.git" 'LICENSE.md')
+md5sums=('SKIP' 'SKIP')
+
+pkgver() {
+ cd "$srcdir/$_pkgname"
+ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+}
+
+prepare() {
+ cd "$srcdir/$_pkgname"
+
+ # Make adept use MozJPEG's cjpeg binary directly rather requiring "mozjpeg" be symlinked to it.
+ sed -i 's~\(JPEGCOMPRESSION_COMMAND\) mozjpeg~\1 cjpeg~' adept.sh
+}
+
+package() {
+ cd "$srcdir/$_pkgname"
+ install -Dm755 adept.sh "$pkgdir/usr/bin/adept"
+ install -Dm644 "$srcdir/LICENSE.md" "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
+}