academic/aris: New maintainer. Update patch.

Signed-off-by: Dave Woodfall <dave@slackbuilds.org>

Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
This commit is contained in:
Juan M. Lasca 2022-08-12 12:54:18 +01:00 committed by Willy Sudiarto Raharjo
parent e4bc3d8653
commit ad694a3d5c
No known key found for this signature in database
GPG key ID: 3F617144D7238786
4 changed files with 77 additions and 25 deletions

View file

@ -2,9 +2,11 @@
# Slackware build script for GNU aris
# Originally written by Juan M. Lasca <juanmlasca at gmail dot com>
# Currently maintained by Philip Lacroix <slackph at posteo dot de>
# Copyright 2013-2020 Juan M. Lasca <juanmlasca@gmail.com>
# Copyright 2020-2022 Philip Lacroix <slackph at posteo dot de>
# Copyright 2022 Juan M. Lasca <juanmlasca@gmail.com>
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
# permitted provided that the following conditions are met:
#
@ -26,7 +28,7 @@ cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=aris
VERSION=${VERSION:-2.2}
BUILD=${BUILD:-1}
BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
@ -38,9 +40,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
@ -75,15 +74,14 @@ 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 {} \;
CFLAGS="$SLKCFLAGS -w -Wl,--allow-multiple-definition" \
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
./configure \
--prefix=/usr \
--disable-static \
--build=$ARCH-slackware-linux
# Fix path for local manual
patch src/aris.c < $CWD/help_path.diff
# Fix path for local manual and multiple symbol definitions
cat $CWD/docs_and_build.patch | patch -p1 || exit
make
make install DESTDIR=$PKG
@ -91,7 +89,6 @@ make install 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
# Install documentation
mkdir -p $PKG/usr/info $PKG/usr/doc/$PRGNAM-$VERSION
cp -a doc/$PRGNAM.info $PKG/usr/info/
gzip -9 $PKG/usr/info/$PRGNAM.info

View file

@ -6,5 +6,5 @@ MD5SUM="523e2c40f17e6e857b533c22a26ff4e1"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES=""
MAINTAINER="Philip Lacroix"
EMAIL="slackph at posteo dot de"
MAINTAINER="Juan M. Lasca"
EMAIL="juanmlasca@gmail.com"

View file

@ -0,0 +1,66 @@
# * Change documentation location
# * Instead of allowing multiple definitions (allocations in header files),
# declare global variables in headers, and allocate them in their
# corresponding .c files, with a reasonable initial value.
diff -u3 aris-2.2/src/app.c aris-2.2-patched/src/app.c
--- aris-2.2/src/app.c 2014-02-28 10:17:24.000000000 -0300
+++ aris-2.2-patched/src/app.c 2022-08-11 15:28:59.318566050 -0300
@@ -46,6 +46,9 @@
#include "elm-conn.xpm"
#include "nil-conn.xpm"
+
+aris_app * the_app = 0;
+
// Macro to get the length of a file.
#ifndef WIN32
diff -u3 aris-2.2/src/app.h aris-2.2-patched/src/app.h
--- aris-2.2/src/app.h 2014-02-27 22:32:07.000000000 -0300
+++ aris-2.2-patched/src/app.h 2022-08-11 13:01:06.315136621 -0300
@@ -106,6 +106,6 @@
int app_set_color (aris_app * app, int index, int red, int green, int blue);
/* The main application */
-aris_app * the_app;
+extern aris_app * the_app;
#endif /* ARIS_APP_H */
diff -u3 aris-2.2/src/aris.c aris-2.2-patched/src/aris.c
--- aris-2.2/src/aris.c 2014-02-28 10:29:10.000000000 -0300
+++ aris-2.2-patched/src/aris.c 2022-08-11 15:38:22.990593330 -0300
@@ -844,8 +844,7 @@
if (the_app->working_dir)
{
- parent = g_file_get_parent (parent);
- sprintf (the_app->help_file, "file://%s/doc/aris/index.html", g_file_get_path (parent));
+ sprintf (the_app->help_file, "file:///usr/doc/aris-" PACKAGE_VERSION "/html/index.html");
}
int ret;
diff -u3 aris-2.2/src/process.c aris-2.2-patched/src/process.c
--- aris-2.2/src/process.c 2014-03-06 17:53:32.000000000 -0300
+++ aris-2.2-patched/src/process.c 2022-08-11 15:27:56.582563013 -0300
@@ -26,6 +26,8 @@
#include <ctype.h>
#include <math.h>
+struct connectives_list main_conns = { 0 };
+
/* Eliminates a negation from a string.
* input:
* not_str - the string from which to eliminate the negation.
diff -u3 aris-2.2/src/process.h aris-2.2-patched/src/process.h
--- aris-2.2/src/process.h 2014-03-02 16:30:39.000000000 -0300
+++ aris-2.2-patched/src/process.h 2022-08-11 13:04:45.004147205 -0300
@@ -170,7 +170,7 @@
// The main connectives.
-struct connectives_list main_conns;
+extern struct connectives_list main_conns;
// Definitions.

View file

@ -1,11 +0,0 @@
--- a/aris.c 2021-02-10 17:51:33.532759576 +0400
+++ b/aris.c 2021-02-10 17:52:15.210759108 +0400
@@ -845,7 +845,7 @@
if (the_app->working_dir)
{
parent = g_file_get_parent (parent);
- sprintf (the_app->help_file, "file://%s/doc/aris/index.html", g_file_get_path (parent));
+ sprintf (the_app->help_file, "file:///usr/doc/aris-2.2/html/index.html", g_file_get_path (parent));
}
int ret;