aboutsummaryrefslogtreecommitdiff
path: root/perl/perl-Config-Find
diff options
context:
space:
mode:
authorB. Watson <yalhcru@gmail.com>2022-03-01 01:40:37 -0500
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2022-03-01 19:35:42 +0700
commit5f7399eb32c041939beff0ef7768d99155bfe9f8 (patch)
tree041df348437674d3aaeb6377e31615b78083a53f /perl/perl-Config-Find
parent2db5975cde93256df94d8d371fa0ed1a34e7bbef (diff)
perl/perl-Config-Find: Fix build if perl-Test-Pod is installed.
Signed-off-by: B. Watson <yalhcru@gmail.com> Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'perl/perl-Config-Find')
-rw-r--r--perl/perl-Config-Find/perl-Config-Find.SlackBuild38
1 files changed, 18 insertions, 20 deletions
diff --git a/perl/perl-Config-Find/perl-Config-Find.SlackBuild b/perl/perl-Config-Find/perl-Config-Find.SlackBuild
index 2c32f28f00e2..cc99307e15f8 100644
--- a/perl/perl-Config-Find/perl-Config-Find.SlackBuild
+++ b/perl/perl-Config-Find/perl-Config-Find.SlackBuild
@@ -22,27 +22,21 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+# 20220222 bkw: Modified by SlackBuilds.org, BUILD=2:
+# - make this noarch, since there's no compiled code.
+# - fix build if perl-Test-Pod is installed.
+
cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=perl-Config-Find
VERSION=${VERSION:-0.26}
-BUILD=${BUILD:-1}
+BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
+ARCH=noarch
SRCNAM="$( echo $PRGNAM | cut -d- -f2- )"
-if [ -z "$ARCH" ]; then
- case "$( uname -m )" in
- i?86) ARCH=i486 ;;
- arm*) ARCH=arm ;;
- *) ARCH=$( uname -m ) ;;
- esac
-fi
-
-# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
-# the name of the created package would be, and then exit. This information
-# could be useful to other scripts.
if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
exit 0
@@ -61,11 +55,17 @@ rm -rf $SRCNAM-$VERSION
tar xvf $CWD/$SRCNAM-$VERSION.tar.gz
cd $SRCNAM-$VERSION
chown -R root:root .
-find -L . \
- \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 -o -perm 511 \) \
- -exec chmod 755 {} \; -o \
- \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
- -exec chmod 644 {} \;
+# 20220301 bkw: permissions are most bletcherous, don't revert to template.
+find . -type f -exec chmod 644 {} \+
+find . -type d -exec chmod 755 {} \+
+
+# 20220301 bkw: if perl-Test-POD was installed, the test "t/3_pods.t" was
+# failing, because the .pm files didn't specify an encoding for the
+# embedded POD docs, and there's a non-ASCII character in the author's
+# name in every file. The easy way to fix it would have been:
+# rm -f t/3_pods.t
+# but the *correct* fix is to do this:
+sed -i '2i\\n=encoding latin1\n\n=cut\n\n' lib/Config/Find{/*,.pm}
perl Makefile.PL \
PREFIX=/usr \
@@ -74,9 +74,7 @@ perl Makefile.PL \
make
make test
make install DESTDIR=$PKG
-
-find $PKG/usr/man -type f -exec gzip -9 {} \;
-for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
+gzip $PKG/usr/man/man*/*
find $PKG -name perllocal.pod -o -name ".packlist" -o -name "*.bs" | xargs rm -f || true