From 7ce539c311a8531c6daf4ee5c3a49d7a25cc163c Mon Sep 17 00:00:00 2001 From: Jeremy Hansen Date: Mon, 11 Sep 2023 18:22:26 -0700 Subject: misc/recode: Updated for version 3.7.13. Switched to maintained upstream. Signed-off-by: Andrew Clemons Signed-off-by: Willy Sudiarto Raharjo --- misc/recode/README | 9 ++++++--- misc/recode/recode.SlackBuild | 38 ++++++++++++++++++++++---------------- misc/recode/recode.info | 12 ++++++++---- misc/recode/slack-desc | 2 +- 4 files changed, 37 insertions(+), 24 deletions(-) (limited to 'misc') diff --git a/misc/recode/README b/misc/recode/README index bc7ab94359..7e971d8048 100644 --- a/misc/recode/README +++ b/misc/recode/README @@ -4,6 +4,9 @@ When exact translations are not possible, the program may get rid of offending characters or use approximations. Particular attention has been paid to the proper representation of French language diacritics. -Although we normally wouldn't put anything beta on SlackBuilds, -this release fixes some long-standing bugs that everyone else has -been patching for years. +The original recode by pinard hasn't been updated in almost 10 years. +It seems most distros have moved to a well-maintained fork by +rrthomas and it's probably time we did too. + +NOTE: We are unable to update past 3.7.13 due to Slackware 15.0's +autoconf being too old (2.69). recode-3.7.14+ requires autoconf 2.71+. diff --git a/misc/recode/recode.SlackBuild b/misc/recode/recode.SlackBuild index 136769239c..983cc10c81 100644 --- a/misc/recode/recode.SlackBuild +++ b/misc/recode/recode.SlackBuild @@ -2,6 +2,7 @@ # Copyright (c) 2007 Niki Kovacs # Copyright 2014 Ryan P.C. McQuen, WA, +# Copyright 2023 Jeremy Hansen # # Slackware build script for recode @@ -38,10 +39,10 @@ cd $(dirname $0) ; CWD=$(pwd) PRGNAM=recode -SRCNAM=Recode -VERSION=${VERSION:-3.7_beta2} -SRCVER=$(echo $VERSION | tr _ -) -BUILD=${BUILD:-4} +VERSION=${VERSION:-3.7.13} +GNULIBVER=${GNULIBVER:-2752f1cb315fc461e3df263ab5bb03a354cf4308} +BOOTSTRAPVER=${BOOTSTRAPVER:-037f83765b6e8f90dfabdfac4889be22a5a3f4a4} +BUILD=${BUILD:-1} TAG=${TAG:-_SBo} PKGTYPE=${PKGTYPE:-tgz} @@ -84,9 +85,12 @@ set -e rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT cd $TMP -rm -rf $SRCNAM-$SRCVER -tar xvf $CWD/$SRCNAM-$SRCVER.tar.gz || tar xvf $CWD/v$SRCVER.tar.gz -cd $SRCNAM-$SRCVER +rm -rf $PRGNAM-$VERSION +tar xvf $CWD/$PRGNAM-$VERSION.tar.gz +cd $PRGNAM-$VERSION +# Extract git submodule archives to correct location +tar xvf $CWD/gnulib-$GNULIBVER.tar.gz --strip-components=1 -C gnulib/ +tar xvf $CWD/bootstrap-$BOOTSTRAPVER.tar.gz --strip-components=1 -C gl-mod/bootstrap/ chown -R root:root . find -L . \ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ @@ -94,25 +98,29 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \+ -# allow recode to be built on a gcc that is not ancient -ryan -sed -i "s/bool ignore : 2;/bool ignore : 1;/g" ./src/recodext.h - -# libdir and target are critical for x86_64 +./bootstrap --skip-po CFLAGS="$SLKCFLAGS" \ CXXFLAGS="$SLKCFLAGS" \ ./configure \ --prefix=/usr \ - --enable-static=no \ + --libdir=/usr/lib${LIBDIRSUFFIX} \ --infodir=/usr/info \ --mandir=/usr/man \ - --libdir=/usr/lib${LIBDIRSUFFIX} \ + --enable-static=no \ --build=$ARCH-slackware-linux \ --host=$ARCH-slackware-linux \ --target=$ARCH-slackware-linux make make install-strip DESTDIR=$PKG -gzip -9 $PKG/usr/man/man*/* + +rm -f $PKG/{,usr/}lib${LIBDIRSUFFIX}/*.la + +find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \ + | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true + +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 rm -f $PKG/usr/info/dir gzip -9 $PKG/usr/info/*.info* @@ -122,8 +130,6 @@ cp -a AUTHORS COPYING* NEWS README THANKS TODO \ $PKG/usr/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild -rm -f $PKG/usr/lib*/*.la - mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc diff --git a/misc/recode/recode.info b/misc/recode/recode.info index 3b28a6495f..16e488d881 100644 --- a/misc/recode/recode.info +++ b/misc/recode/recode.info @@ -1,8 +1,12 @@ PRGNAM="recode" -VERSION="3.7_beta2" -HOMEPAGE="https://github.com/pinard/Recode" -DOWNLOAD="https://github.com/pinard/Recode/archive/v3.7-beta2/Recode-3.7-beta2.tar.gz" -MD5SUM="fd0e609d54fad968fcb52a8eca2d6bf0" +VERSION="3.7.13" +HOMEPAGE="https://github.com/rrthomas/recode" +DOWNLOAD="https://github.com/rrthomas/recode/archive/refs/tags/v3.7.13/recode-3.7.13.tar.gz \ + https://github.com/coreutils/gnulib/archive/2752f1c/gnulib-2752f1cb315fc461e3df263ab5bb03a354cf4308.tar.gz \ + https://github.com/gnulib-modules/bootstrap/archive/037f837/bootstrap-037f83765b6e8f90dfabdfac4889be22a5a3f4a4.tar.gz" +MD5SUM="3348e4f4328e828d75178af9ace44352 \ + 042bd31255f32188cf1f0f599b6818a3 \ + ed24221935b5a2aeb635e5541c1f2fa3" DOWNLOAD_x86_64="" MD5SUM_x86_64="" REQUIRES="" diff --git a/misc/recode/slack-desc b/misc/recode/slack-desc index 30b08a8b40..afd1de0357 100644 --- a/misc/recode/slack-desc +++ b/misc/recode/slack-desc @@ -14,6 +14,6 @@ recode: When exact translations are not possible, the program may get rid of recode: offending characters or use approximations. Particular attention has recode: been paid to the proper representation of French language diacritics. recode: -recode: Homepage: https://github.com/pinard/Recode +recode: Homepage: https://github.com/rrthomas/recode recode: recode: -- cgit v1.2.3