mathomatic: fix path in TMP_FILE
authorLeonid Plyushch <leonid.plyushch@gmail.com>
Thu, 14 Sep 2017 11:37:35 +0000 (14:37 +0300)
committerFredrik Fornwall <fredrik@fornwall.net>
Thu, 14 Sep 2017 14:21:22 +0000 (16:21 +0200)
packages/mathomatic/build.sh
packages/mathomatic/fix-tmp_file.patch [new file with mode: 0644]

index c46b7f6..af25eff 100644 (file)
@@ -1,7 +1,7 @@
 TERMUX_PKG_HOMEPAGE=http://www.mathomatic.org/
 TERMUX_PKG_DESCRIPTION="Simple CAS and symbolic calculator"
 TERMUX_PKG_VERSION=16.0.5
-TERMUX_PKG_REVISION=2
+TERMUX_PKG_REVISION=3
 TERMUX_PKG_SRCURL="https://fossies.org/linux/misc/old/mathomatic-${TERMUX_PKG_VERSION}.tar.xz"
 TERMUX_PKG_SHA256=7f525bdb2e13006549dd8f17906c26f926f5ac51174f02f074107c612491e05c
 TERMUX_PKG_BUILD_IN_SRC=yes
diff --git a/packages/mathomatic/fix-tmp_file.patch b/packages/mathomatic/fix-tmp_file.patch
new file mode 100644 (file)
index 0000000..f27d1a1
--- /dev/null
@@ -0,0 +1,12 @@
+diff -uNr mathomatic-16.0.5/am.h mathomatic-16.0.5.mod/am.h
+--- mathomatic-16.0.5/am.h     2012-08-19 17:42:52.000000000 +0300
++++ mathomatic-16.0.5.mod/am.h 2017-09-14 14:36:31.112860259 +0300
+@@ -57,7 +57,7 @@
+ #define       TEXT_ROWS       STANDARD_SCREEN_ROWS            /* number of lines per page in the symbolic math library */
+ #define       TEXT_COLUMNS    STANDARD_SCREEN_COLUMNS         /* default number of columns per page in the symbolic math library */
+-#define       TMP_FILE        "/tmp/mathomatic.XXXXXX"        /* temporary file template for mkstemp(3) */
++#define       TMP_FILE        "@TERMUX_PREFIX@/tmp/mathomatic.XXXXXX" /* temporary file template for mkstemp(3) */
+ #define       PROMPT_STR      "-> "                           /* user interface main prompt strings, preceded by the current equation number */
+ #define       HTML_PROMPT_STR "&minus;&gt; "                  /* main prompt in HTML output mode, should be same number of columns as above */