development/as31: Minor build fix.

Signed-off-by: B. Watson <yalhcru@gmail.com>
This commit is contained in:
B. Watson 2019-12-28 11:51:50 -05:00 committed by Willy Sudiarto Raharjo
parent 0030076b42
commit 5b5f2d950d
No known key found for this signature in database
GPG Key ID: 887B8374D7333381
2 changed files with 17 additions and 13 deletions

View File

@ -3,3 +3,7 @@ as31 (8031/8051 cross assembler)
as31 is an assembler for the 8031 and 8051 microcontrollers. It
produces output in several different formats, including Intel hex
format and Motorola s-records.
Note: the download filename gets mangled by certain browsers and other
web clients. If the SlackBuild complains that it can't find the source,
you can force the source filename with the SRC environment variable.

View File

@ -40,23 +40,25 @@ fi
set -e
# for some reason, upstream uses colons for separators in its URL
if [ -e "wiki:projects:linux:as31:$PRGNAM-$VERSION.tar.gz" ]; then
mv "wiki:projects:linux:as31:$PRGNAM-$VERSION.tar.gz" $PRGNAM-$VERSION.tar.gz
fi
# For some reason, upstream uses colons for separators in its URL.
# Some clients might save the file with hex escapes in the name...
# If all else fails, accept SRC from the environment.
for i in "${SRC:-$PRGNAM-$VERSION.tar.gz}" \
"wiki:projects:linux:as31:$PRGNAM-$VERSION.tar.gz" \
"wiki%3Aprojects%3Alinux%3Aas31%3A$PRGNAM-$VERSION.tar.gz";
do
[ -e "$CWD/$i" ] && SRC="$CWD/$i"
done
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
tar xvf $SRC
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 \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} \+ -o \
\! -perm /111 -a \! -perm 644 -a -exec chmod 644 {} \+
# Patch from Debian, check return value from getline(), seems like
# a good idea.
@ -78,9 +80,7 @@ sh ./configure \
make
make install-strip DESTDIR=$PKG
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
gzip -9 $PKG/usr/man/man1/$PRGNAM.1
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION/examples
cp -a COPYING AUTHORS ChangeLog NEWS README $PKG/usr/doc/$PRGNAM-$VERSION