summaryrefslogtreecommitdiffstats
path: root/development/ragel/ragel.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'development/ragel/ragel.SlackBuild')
-rw-r--r--development/ragel/ragel.SlackBuild36
1 files changed, 21 insertions, 15 deletions
diff --git a/development/ragel/ragel.SlackBuild b/development/ragel/ragel.SlackBuild
index 46877dadca..083354d312 100644
--- a/development/ragel/ragel.SlackBuild
+++ b/development/ragel/ragel.SlackBuild
@@ -22,10 +22,15 @@
# 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
-VERSION=${VERSION:-7.0.0.12}
+VERSION=${VERSION:-7.0.4}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
@@ -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
@@ -64,7 +66,7 @@ else
LIBDIRSUFFIX=""
fi
-DOCS="AUTHORS COPYING README TODO"
+DOCS="COPYING README"
set -e
@@ -73,14 +75,19 @@ mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
-tar xvf $CWD/$PRGNAM-$VERSION.tar.?z*
+tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
cd $PRGNAM-$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 \
+ -o -perm 511 \) -exec chmod 755 {} \+ -o \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
- -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
+ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \+
+
+if [ "$LIBDIRSUFFIX" = "64" ]; then
+ patch --verbose -p1 -i $CWD/lib64.patch
+fi
+patch --verbose -p1 -i $CWD/shared-colm.patch
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
@@ -92,21 +99,20 @@ CXXFLAGS="$SLKCFLAGS" \
--mandir=/usr/man \
--docdir=/usr/doc/$PRGNAM-$VERSION \
--disable-static \
+ --with-colm=/usr \
+ --disable-manual \
--build=$ARCH-slackware-linux
make
-make install DESTDIR=$PKG
-
-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
+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
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