diff options
author | LukenShiro <lukenshiro@ngi.it> | 2010-05-11 22:53:52 +0200 |
---|---|---|
committer | Robby Workman <rworkman@slackbuilds.org> | 2010-05-11 22:53:52 +0200 |
commit | 4a60a8c00a040f50c5b366c29ca1a25a511fc00d (patch) | |
tree | 2840d3918a00398245eba210a4eb4f36e6983f4e /graphics/unpaper | |
parent | 0a5d1c12a9b7d656e92fc26293e39847226b448e (diff) | |
download | slackbuilds-4a60a8c00a040f50c5b366c29ca1a25a511fc00d.tar.gz |
graphics/unpaper: Added to 12.1 repository
Diffstat (limited to 'graphics/unpaper')
-rw-r--r-- | graphics/unpaper/README | 19 | ||||
-rw-r--r-- | graphics/unpaper/slack-desc | 19 | ||||
-rw-r--r-- | graphics/unpaper/unpaper.SlackBuild | 76 | ||||
-rw-r--r-- | graphics/unpaper/unpaper.info | 8 |
4 files changed, 122 insertions, 0 deletions
diff --git a/graphics/unpaper/README b/graphics/unpaper/README new file mode 100644 index 0000000000..3a19caed4d --- /dev/null +++ b/graphics/unpaper/README @@ -0,0 +1,19 @@ +unpaper is a post-processing tool for scanned sheets of paper, especially +for book pages that have been scanned from previously created photocopies. +The main purpose is to make scanned book pages better readable on screen +after conversion to PDF. Additionally, unpaper might be useful to enhance +the quality of scanned pages before performing optical character +recognition (OCR). unpaper tries to clean scanned images by removing dark +edges that appeared through scanning or copying on areas outside the actual +page content (e.g. dark areas between the left-hand-side and the +right-hand-side of a double- sided book-page scan). The program also tries +to detect disaligned centering and rotation of pages and will automatically +straighten each page by rotating it to the correct angle. This process is +called "deskewing". Note that the automatic processing will sometimes fail. +It is always a good idea to manually control the results of unpaper and adjust +the parameter settings according to the requirements of the input. Each +processing step can also be disabled individually for each sheet. Input and +output files can be in either .pbm , .pgm or .ppm format, thus generally in +.pnm format, as also used by the Linux scanning tools scanimage and scanadf. +Conversion to PDF can e.g. be achieved with the Linux tools pgm2tiff, tiffcp +and tiff2pdf. diff --git a/graphics/unpaper/slack-desc b/graphics/unpaper/slack-desc new file mode 100644 index 0000000000..8df8fa6a57 --- /dev/null +++ b/graphics/unpaper/slack-desc @@ -0,0 +1,19 @@ +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. Line +# up the first '|' above the ':' following the base package name, and the '|' +# on the right side marks the last column you can put a character in. You must +# make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':'. + + |-----handy-ruler-----------------------------------------------------| +unpaper: unpaper (for post-processing scanned and photocopied book pages) +unpaper: +unpaper: It is a post-processing tool for scanned sheets of paper, especially +unpaper: for book pages that have been scanned from previously created +unpaper: photocopies. Main purpose is to make scanned book pages better +unpaper: readable on screen after conversion to PDF. Additionally, it might +unpaper: be useful to enhance the quality of scanned pages before performing +unpaper: optical character recognition (OCR). +unpaper: +unpaper: Homepage: http://unpaper.berlios.de +unpaper: diff --git a/graphics/unpaper/unpaper.SlackBuild b/graphics/unpaper/unpaper.SlackBuild new file mode 100644 index 0000000000..d02016d948 --- /dev/null +++ b/graphics/unpaper/unpaper.SlackBuild @@ -0,0 +1,76 @@ +#!/bin/sh + +# Slackware build script for unpaper + +# Copyright 2008 LukenShiro <lukenshiro@ngi.it> +# All rights reserved. +# +# Redistribution and use of this script, with or without modification, is +# permitted provided that the following conditions are met: +# +# 1. Redistributions of this script must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ''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 AUTHOR 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. +# Slackware build script for scrot + +PRGNAM=unpaper +VERSION=0.3 +ARCH=${ARCH:-i486} +BUILD=${BUILD:-1} +TAG=${TAG:-_SBo} + +CWD=$(pwd) +TMP=${TMP:-/tmp/SBo} +PKG=$TMP/package-$PRGNAM +OUTPUT=${OUTPUT:-/tmp} + +if [ "$ARCH" = "i486" ]; then + SLKCFLAGS="-O2 -march=i486 -mtune=i686" +elif [ "$ARCH" = "i686" ]; then + SLKCFLAGS="-O2 -march=i686 -mtune=i686" +elif [ "$ARCH" = "x86_64" ]; then + SLKCFLAGS="-O2 -fPIC" +fi + +set -e + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT +cd $TMP +rm -rf $PRGNAM-$VERSION +tar xvf $CWD/$PRGNAM-$VERSION.tar.gz +cd $PRGNAM-$VERSION +chown -R root:root . +chmod -R u+w,go+r-w,a-s . + +# There is a building shell script (make.sh), +# but I prefer a direct and minimalistic approach +CFLAGS="$SLKCFLAGS" \ +CXXFLAGS="$SLKCFLAGS" \ +gcc -lm -o unpaper src/unpaper.c +strip --strip-unneeded unpaper 2>/dev/null || true + +mkdir -p $PKG/usr/bin +install -m 0755 unpaper $PKG/usr/bin/ + +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION/img +install -m 0644 doc/*.html $PKG/usr/doc/$PRGNAM-$VERSION/ +install -m 0644 doc/img/* $PKG/usr/doc/$PRGNAM-$VERSION/img/ +cp -a CHANGELOG README LICENSE $PKG/usr/doc/$PRGNAM-$VERSION +cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild + +mkdir -p $PKG/install +cat $CWD/slack-desc > $PKG/install/slack-desc + +cd $PKG +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz diff --git a/graphics/unpaper/unpaper.info b/graphics/unpaper/unpaper.info new file mode 100644 index 0000000000..8013585375 --- /dev/null +++ b/graphics/unpaper/unpaper.info @@ -0,0 +1,8 @@ +PRGNAM="unpaper" +VERSION="0.3" +HOMEPAGE="http://unpaper.berlios.de" +DOWNLOAD="http://download.berlios.de/unpaper/unpaper-0.3.tar.gz" +MD5SUM="be41eaf8556e7df39ab53939c99c4f7b" +MAINTAINER="LukenShiro" +EMAIL="lukenshiro@ngi.it" +APPROVED="rworkman" |