diff options
Diffstat (limited to 'source/x/m17n-lib')
-rwxr-xr-x | source/x/m17n-lib/m17n-lib.SlackBuild | 88 | ||||
-rw-r--r-- | source/x/m17n-lib/slack-desc | 14 |
2 files changed, 46 insertions, 56 deletions
diff --git a/source/x/m17n-lib/m17n-lib.SlackBuild b/source/x/m17n-lib/m17n-lib.SlackBuild index 82cc38ad..67d803b3 100755 --- a/source/x/m17n-lib/m17n-lib.SlackBuild +++ b/source/x/m17n-lib/m17n-lib.SlackBuild @@ -1,7 +1,7 @@ -#!/bin/sh +#!/bin/bash # Copyright 2008, 2009 Eric Hameleers, Eindhoven, NL -# Copyright 2008, 2009, 2010 Patrick J. Volkerding, Sebeka, MN USA +# Copyright 2008, 2009, 2010, 2018 Patrick J. Volkerding, Sebeka, MN USA # All rights reserved. # # Permission to use, copy, modify, and distribute this software for @@ -32,41 +32,45 @@ # # ----------------------------------------------------------------------------- +cd $(dirname $0) ; CWD=$(pwd) PKGNAM=m17n-lib SHORTNAM=m17n -VERSION=${VERSION:-1.6.1} -DBVERSION=${DBVERSION:-1.6.1} -# Won't build && are not maintained for current version -#DOCVERSION=${DOCVERSION:-1.5.5} -BUILD=${BUILD:-1} +VERSION=${VERSION:-1.8.0} +DBVERSION=${DBVERSION:-1.8.0} +BUILD=${BUILD:-2} # Automatically determine the architecture we're building on: if [ -z "$ARCH" ]; then case "$( uname -m )" in - i?86) export ARCH=i486 ;; + i?86) export ARCH=i586 ;; arm*) export ARCH=arm ;; # Unless $ARCH is already set, use uname -m for all other archs: *) export 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 "$PKGNAM-$VERSION-$ARCH-$BUILD.txz" + exit 0 +fi + NUMJOBS=${NUMJOBS:-" -j7 "} -DOCS="ABOUT-NLS AUTHORS COPYING ChangeLog INSTALL NEWS README TODO" +DOCS="AUTHORS COPYING ChangeLog NEWS README TODO" DOCS_DB="ABOUT-NLS AUTHORS COPYING ChangeLog NEWS README" -DOCS_DOC="AUTHORS COPYING ChangeLog INSTALL NEWS README" -CWD=$(pwd) TMP=${TMP:-/tmp} PKG=$TMP/package-$PKGNAM -SOURCE[0]="$CWD/${PKGNAM}-${VERSION}.tar.xz" -SOURCE[1]="$CWD/${SHORTNAM}-db-${DBVERSION}.tar.xz" -#SOURCE[2]="$CWD/${SHORTNAM}-docs-${DOCVERSION}.tar.xz" +SOURCE[0]="$CWD/${PKGNAM}-${VERSION}.tar.lz" +SOURCE[1]="$CWD/${SHORTNAM}-db-${DBVERSION}.tar.lz" -if [ "$ARCH" = "i486" ]; then - SLKCFLAGS="-O2 -march=i486 -mtune=i686" +if [ "$ARCH" = "i586" ]; then + SLKCFLAGS="-O2 -march=i586 -mtune=i686" LIBDIRSUFFIX="" elif [ "$ARCH" = "s390" ]; then SLKCFLAGS="-O2" @@ -74,11 +78,11 @@ elif [ "$ARCH" = "s390" ]; then elif [ "$ARCH" = "x86_64" ]; then SLKCFLAGS="-O2 -fPIC" LIBDIRSUFFIX="64" -elif [ "$ARCH" = "arm" ]; then - SLKCFLAGS="-O2 -march=armv4 -mtune=xscale" +elif [ "$ARCH" = "armv7hl" ]; then + SLKCFLAGS="-O2 -march=armv7-a -mfpu=vfpv3-d16" LIBDIRSUFFIX="" -elif [ "$ARCH" = "armel" ]; then - SLKCFLAGS="-O2 -march=armv4t" +else + SLKCFLAGS="-O2" LIBDIRSUFFIX="" fi @@ -92,9 +96,7 @@ done chown -R root:root * chmod -R u+w,go+r-w,a-s * -cd ${PKGNAM}-${VERSION} -# Add the missing internal-flt.h file: -[ ! -r src/internal-flt.h ] && cp $CWD/internal-flt.h src/ +cd ${PKGNAM}-${VERSION} || exit 1 echo Building ... CXXFLAGS="$SLKCFLAGS" \ @@ -105,11 +107,11 @@ CFLAGS="$SLKCFLAGS" \ --localstatedir=/var \ --sysconfdir=/etc \ --mandir=/usr/man \ - --without-gui \ + --disable-gui \ --disable-static \ --program-prefix= \ --program-suffix= \ - --build=$ARCH-slackware-linux + --build=$ARCH-slackware-linux || exit 1 # If you get errors here, uninstall the present m17n-lib package first: make $NUMJOBS || make || exit 1 make DESTDIR=$PKG install || exit 1 @@ -127,37 +129,28 @@ CFLAGS="$SLKCFLAGS" \ --sysconfdir=/etc \ --program-prefix= \ --program-suffix= \ - --build=$ARCH-slackware-linux + --build=$ARCH-slackware-linux || exit 1 make $NUMJOBS || make || exit 1 make DESTDIR=$PKG install || exit 1 cd .. -## Compile and install the m17n user documentation: -#echo "Building the m17n user docs..." -#cd ${SHORTNAM}-docs-${DOCVERSION} -#CXXFLAGS="$SLKCFLAGS" \ -#CFLAGS="$SLKCFLAGS" \ -#./configure \ -# --prefix=/usr \ -# --libdir=/usr/lib${LIBDIRSUFFIX} \ -# --localstatedir=/var \ -# --sysconfdir=/etc \ -# --mandir=/usr/man \ -# --program-prefix= \ -# --program-suffix= \ -# --build=$ARCH-slackware-linux -#make $NUMJOBS || make || exit 1 -#make DESTDIR=$PKG install || exit 1 -#cd .. +# Don't ship .la files: +rm -f $PKG/{,usr/}lib${LIBDIRSUFFIX}/*.la # Add package documentation: -mkdir -p $PKG/usr/doc/$PKGNAM-$VERSION/{db,docs} +mkdir -p $PKG/usr/doc/$PKGNAM-$VERSION/db cd ${PKGNAM}-${VERSION} cp -a $DOCS $PKG/usr/doc/$PKGNAM-$VERSION +# If there's a ChangeLog, installing at least part of the recent history +# is useful, but don't let it get totally out of control: +cat ChangeLog | head -n 1000 > $PKG/usr/doc/$PKGNAM-$VERSION/ChangeLog +touch -r ChangeLog $PKG/usr/doc/$PKGNAM-$VERSION/ChangeLog cd ../${SHORTNAM}-db-${DBVERSION} cp -a $DOCS_DB $PKG/usr/doc/$PKGNAM-$VERSION/db -cd ../${SHORTNAM}-docs-${DOCVERSION} -cp -a $DOCS_DOC $PKG/usr/doc/$PKGNAM-$VERSION/docs +# If there's a ChangeLog, installing at least part of the recent history +# is useful, but don't let it get totally out of control: +cat ChangeLog | head -n 1000 > $PKG/usr/doc/$PKGNAM-$VERSION/db/ChangeLog +touch -r ChangeLog $PKG/usr/doc/$PKGNAM-$VERSION/db/ChangeLog cd .. find $PKG/usr/doc -type f -exec chmod 644 {} \; @@ -179,9 +172,6 @@ find $PKG | xargs file | grep -e "executable" -e "shared object" \ # Add a package description: mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc -if [ -f $CWD/doinst.sh ]; then - cat $CWD/doinst.sh >> $PKG/install/doinst.sh -fi # Build the package: cd $PKG diff --git a/source/x/m17n-lib/slack-desc b/source/x/m17n-lib/slack-desc index 78164bc0..67a33292 100644 --- a/source/x/m17n-lib/slack-desc +++ b/source/x/m17n-lib/slack-desc @@ -1,19 +1,19 @@ # HOW TO EDIT THIS FILE: -# The "handy ruler" below makes it easier to edit a package description. Line +# 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 +# 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------------------------------------------------------| m17n-lib: m17n-lib (application multilingualization library) m17n-lib: -m17n-lib: M17n is an abbreviation of Multilingualization. The m17n library -m17n-lib: implements multilingualization for many applications. The m17n -m17n-lib: library supports functions to handle M-texts. This package also +m17n-lib: M17n is an abbreviation of Multilingualization. The m17n library +m17n-lib: implements multilingualization for many applications. The m17n +m17n-lib: library supports functions to handle M-texts. This package also m17n-lib: contains the m17n database. m17n-lib: -m17n-lib: m17n-lib home: http://m17n.org/ +m17n-lib: Homepage: http://m17n.nongnu.org m17n-lib: m17n-lib: m17n-lib: |