summaryrefslogtreecommitdiffstats
path: root/audio/sbagen/sbagen.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'audio/sbagen/sbagen.SlackBuild')
-rw-r--r--audio/sbagen/sbagen.SlackBuild25
1 files changed, 15 insertions, 10 deletions
diff --git a/audio/sbagen/sbagen.SlackBuild b/audio/sbagen/sbagen.SlackBuild
index 69c169357d..34602fbd21 100644
--- a/audio/sbagen/sbagen.SlackBuild
+++ b/audio/sbagen/sbagen.SlackBuild
@@ -22,6 +22,8 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+# 20220322 bkw: Modified by SlackBuilds.org: fix 32-bit build.
+
cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=sbagen
@@ -39,7 +41,7 @@ RIVERSOUNDS="sbagen-river-1.4.1.tgz"
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
- i?86) ARCH=i486
+ i?86) ARCH=i586
;;
x86_64) ARCH=x86_64
;;
@@ -48,9 +50,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
@@ -60,8 +59,8 @@ TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
-if [ "$ARCH" = "i486" ]; then
- SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+if [ "$ARCH" = "i586" ]; then
+ SLKCFLAGS="-O2 -march=i586 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
@@ -82,9 +81,13 @@ 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 {} \+
+
+# 20220323 bkw: for some reason, inlining the calcNow() function
+# causes the build to fail on 32-bit.
+patch -p1 < $CWD/no_inline_calcnow.diff
if [ "$NONFREE" = "yes" ]; then
LIBS="/usr/lib${LIBDIRSUFFIX}/libvorbisidec.so.1 /usr/lib${LIBDIRSUFFIX}/libmad.so"
@@ -105,11 +108,13 @@ cp -ar $DOCS examples \
$PKG/usr/doc/$PRGNAM-$VERSION
cp -ar scripts river{1,2}.ogg \
$PKG/usr/share/$PRGNAM
+
+# 20220323 bkw: why are we installing the source?
cp -ar *.c mk-* libs \
$PKG/usr/share/$PRGNAM/src
-install -m0755 -o 0:0 $CWD/$PRGNAM $PKG/usr/bin
-install -m0755 -o 0:0 $BINNAME $PKG/usr/bin/$BINNAME
+install -m0755 -oroot -groot $CWD/$PRGNAM $PKG/usr/bin
+install -m0755 -oroot -groot $BINNAME $PKG/usr/bin/$BINNAME
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild