From 7c0504f304c22ae1e4bdd7a5caaba509cfb6c43a Mon Sep 17 00:00:00 2001 From: "A. Tomasini" Date: Tue, 10 Dec 2024 15:08:52 +0700 Subject: [PATCH] academic/xschem: Update script. --- academic/xschem/doinst.sh | 1 + academic/xschem/xschem.SlackBuild | 37 ++++++++++++++++++------------- academic/xschem/xschem.desktop | 4 ++-- 3 files changed, 25 insertions(+), 17 deletions(-) mode change 100644 => 100755 academic/xschem/doinst.sh diff --git a/academic/xschem/doinst.sh b/academic/xschem/doinst.sh old mode 100644 new mode 100755 index 5fb28930db0..4e8ba7071de --- a/academic/xschem/doinst.sh +++ b/academic/xschem/doinst.sh @@ -1,3 +1,4 @@ if [ -x /usr/bin/update-desktop-database ]; then /usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1 fi + diff --git a/academic/xschem/xschem.SlackBuild b/academic/xschem/xschem.SlackBuild index 1c513ac5c2a..ad45bfc6ba8 100644 --- a/academic/xschem/xschem.SlackBuild +++ b/academic/xschem/xschem.SlackBuild @@ -25,7 +25,7 @@ cd $(dirname $0) ; CWD=$(pwd) PRGNAM=xschem -VERSION=${VERSION:-3.4.4} +VERSION=${VERSION:-3.4.5} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} PKGTYPE=${PKGTYPE:-tgz} @@ -89,25 +89,32 @@ make install PREFIX=/usr 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 -mv $PKG/usr/share/man $PKG/usr/ - -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 +PKGDOC=$PKG/usr/doc +mkdir -p $PKGDOC -mkdir -p $PKG/usr/share/applications -mkdir -p $PKG/usr/share/pixmaps/$PRGNAM/ -cp $CWD/$PRGNAM.desktop $PKG/usr/share/applications/ -cp $CWD/$PRGNAM.png $PKG/usr/share/pixmaps/$PRGNAM/ +PKGDOC=$PKG/usr/share/doc/$PRGNAM -mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION -mv $PKG/usr/share/doc/$PRGNAM/* $PKG/usr/doc/$PRGNAM-$VERSION/ -rmdir $PKG/usr/share/doc/$PRGNAM/ -rmdir $PKG/usr/share/doc/ -cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild +cat $CWD/$PRGNAM.SlackBuild > $PKGDOC/$PRGNAM.SlackBuild mkdir -p $PKG/install -cat $CWD/slack-desc > $PKG/install/slack-desc cat $CWD/doinst.sh > $PKG/install/doinst.sh +cat $CWD/slack-desc > $PKG/install/slack-desc cd $PKG +#printf "\033[32m remane usr/share/doc/${PRGNAM} usr/share/doc/$PRGNAM-$VERSION\033[0m\n" +#mv usr/share/doc/${PRGNAM} usr/doc/$PRGNAM-$VERSION +#rm -rf $PKG/usr/share/doc + +printf "\033[32m create desktop and icons\033[0m\n" +mkdir -p usr/share/applications +mkdir -p usr/share/pixmaps/xschem/ +cp $CWD/${PRGNAM}.desktop usr/share/applications/ +cp $CWD/${PRGNAM}.png usr/share/pixmaps/xschem/ + +# compress the manual + +printf "\033[32mcompress manual in ${PKG}/usr/share/doc/share/man\033[0m\n" +find usr/share/man -name "*.[12345678n]" -exec gzip {} \; +mv $PKG/usr/share/man $PKG/usr/ + /sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE diff --git a/academic/xschem/xschem.desktop b/academic/xschem/xschem.desktop index 8706de83a27..2f98ea25b87 100644 --- a/academic/xschem/xschem.desktop +++ b/academic/xschem/xschem.desktop @@ -1,8 +1,8 @@ [Desktop Entry] Exec=/usr/bin/xschem InitialPreference=2 -MimeType=application/xscheme; -Name=xscheme +MimeType=application/xschem; +Name=xschem Comment=Schematic capture Icon=/usr/share/pixmaps/xschem/xschem.png Terminal=false