diff options
Diffstat (limited to 'academic/wxMaxima/wxMaxima.SlackBuild')
-rw-r--r-- | academic/wxMaxima/wxMaxima.SlackBuild | 65 |
1 files changed, 28 insertions, 37 deletions
diff --git a/academic/wxMaxima/wxMaxima.SlackBuild b/academic/wxMaxima/wxMaxima.SlackBuild index fb42b15df6a5..80b7aa18e0da 100644 --- a/academic/wxMaxima/wxMaxima.SlackBuild +++ b/academic/wxMaxima/wxMaxima.SlackBuild @@ -22,15 +22,17 @@ # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +# Mar 2021 - updated for v. 21.01, Judah Milgram, milgram at cgpp com + PRGNAM=wxMaxima SRCNAM=wxmaxima -VERSION=${VERSION:-16.04.2} +VERSION=${VERSION:-21.01.0} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} if [ -z "$ARCH" ]; then case "$( uname -m )" in - i?86) ARCH=i486 ;; + i?86) ARCH=i586 ;; arm*) ARCH=arm ;; *) ARCH=$( uname -m ) ;; esac @@ -41,8 +43,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" @@ -60,9 +62,9 @@ set -e rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT cd $TMP -rm -rf $SRCNAM-$VERSION -tar xvf $CWD/$SRCNAM-$VERSION.tar.gz -cd $SRCNAM-$VERSION +rm -rf $SRCNAM-Version-$VERSION +tar xvf $CWD/Version-$VERSION.tar.gz +cd $SRCNAM-Version-$VERSION chown -R root:root . find -L . \ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ @@ -70,44 +72,33 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; -# Fix man directory. -sed -i '/^mandatadir/s|=.*|= \$(mandir)|' data/Makefile* -#Fix end-of-line encoding. -for i in art/*.txt; do - sed -e 's/\r//' $i > ${i}.new - touch -r $i ${i}.new - mv ${i}.new $i -done - -CFLAGS="$SLKCFLAGS" \ -CXXFLAGS="$SLKCFLAGS" \ -./configure \ - --prefix=/usr \ - --mandir=/usr/man \ - --infodir=/usr/info \ - --docdir=/usr/doc/$PRGNAM-$VERSION \ - --disable-dependency-tracking \ - --disable-silent-rules \ - --enable-printing \ - --build=$ARCH-slackware-linux - -make -make allmo -make install DESTDIR=$PKG +BUILDDIR=build +mkdir -p $BUILDDIR + +export PATH="/opt/cmake-202x/bin:$PATH" +cmake \ + -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \ + -DCMAKE_INSTALL_PREFIX=$PKG/usr \ + -DCMAKE_BUILD_TYPE=Release \ + -G Ninja -S . -B $BUILDDIR +cmake --build $BUILDDIR +cmake --install $BUILDDIR 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 -rm -f $PKG/usr/info/dir -gzip -9 $PKG/usr/info/*.info* - -mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION -cp -a AUTHORS ChangeLog COPYING README.md art/*.txt $PKG/usr/doc/$PRGNAM-$VERSION -rm -f $PKG/usr/share/$PRGNAM/{COPYING,README} +mkdir $PKG/usr/doc +mv $PKG/usr/share/doc/$SRCNAM $PKG/usr/doc/$PRGNAM-$VERSION +rmdir $PKG/usr/share/doc cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION/examples +cp -a examples/*.wxm $PKG/usr/doc/$PRGNAM-$VERSION/examples + mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc cat $CWD/doinst.sh > $PKG/install/doinst.sh |