From d7b118b294f6eb27ba2e4689506cb26cc2230d7c Mon Sep 17 00:00:00 2001 From: "B. Watson" Date: Tue, 8 Mar 2022 04:58:13 -0500 Subject: development/ragel: Check for installed copy first. Signed-off-by: B. Watson Signed-off-by: Willy Sudiarto Raharjo --- development/ragel/ragel.SlackBuild | 35 ++++++++++++++++++++++------------- 1 file changed, 22 insertions(+), 13 deletions(-) diff --git a/development/ragel/ragel.SlackBuild b/development/ragel/ragel.SlackBuild index 4ee92d93e6a21..b3eb898ea1ec1 100644 --- a/development/ragel/ragel.SlackBuild +++ b/development/ragel/ragel.SlackBuild @@ -22,6 +22,11 @@ # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +# 20220308 bkw: Modified by SlackBuilds.org: +# This build always fails if ragel is already installed. Add a check +# to make it fail quickly, with a useful error message (instead of a +# confusing link error, after compiling for several minutes). + cd $(dirname $0) ; CWD=$(pwd) PRGNAM=ragel @@ -38,9 +43,6 @@ if [ -z "$ARCH" ]; then 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 @@ -68,19 +70,31 @@ DOCS="AUTHORS COPYING README TODO" set -e +if [ -x /usr/bin/ragel ]; then + cat < /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 +make install-strip DESTDIR=$PKG +gzip -9 $PKG/usr/man/man*/* mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION cp -a $DOCS $PKG/usr/doc/$PRGNAM-$VERSION -- cgit v1.2.3