Skip to content

Commit

Permalink
octave{,-x}: bump to 9.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
licy183 committed Oct 26, 2024
1 parent 5970d2d commit 0b7940e
Show file tree
Hide file tree
Showing 4 changed files with 47 additions and 26 deletions.
23 changes: 19 additions & 4 deletions tur/octave-x/0003-undefine-the-macro-in-pwd.h.patch
Original file line number Diff line number Diff line change
@@ -1,6 +1,21 @@
--- a/liboctave/system/oct-password.cc
+++ b/liboctave/system/oct-password.cc
@@ -31,6 +31,15 @@
--- a/liboctave/wrappers/pwd-wrappers.h
+++ b/liboctave/wrappers/pwd-wrappers.h
@@ -43,7 +43,12 @@
char *pw_passwd;
uid_t pw_uid;
gid_t pw_gid;
+#if defined(__ANDROID__) && !defined(__LP64__) && !defined(pw_gecos)
+ /* Note: On LP32, we define pw_gecos to pw_passwd since they're both NULL. */
+# define pw_gecos pw_passwd
+#else
char *pw_gecos;
+#endif
char *pw_dir;
char *pw_shell;
};
--- a/liboctave/wrappers/pwd-wrappers.c
+++ b/liboctave/wrappers/pwd-wrappers.c
@@ -32,6 +32,15 @@

#if defined (HAVE_PWD_H)
# include <pwd.h>
Expand All @@ -15,4 +30,4 @@
+# endif
#endif

#include "lo-error.h"
#include "pwd-wrappers.h"
20 changes: 6 additions & 14 deletions tur/octave-x/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,17 @@ TERMUX_PKG_HOMEPAGE=https://octave.org
TERMUX_PKG_DESCRIPTION="GNU Octave is a high-level language, primarily intended for numerical computations. (with X11 support)"
TERMUX_PKG_LICENSE="GPL-3.0"
TERMUX_PKG_MAINTAINER="@termux-user-repository"
TERMUX_PKG_VERSION=1:8.4.0
TERMUX_PKG_REVISION=5
TERMUX_PKG_VERSION=1:9.2.0
TERMUX_PKG_SRCURL=https://ftpmirror.gnu.org/octave/octave-${TERMUX_PKG_VERSION#*:}.tar.xz
TERMUX_PKG_SHA256=6f9ad73a3ee4291b6341d6c0f5e5c85d6e0310376e4991b959a6d340b3ffa8a8
TERMUX_PKG_DEPENDS="arpack-ng, bzip2, fftw, fltk, fontconfig, freetype, glpk, glu, graphicsmagick, libcurl, libhdf5, libiconv, libopenblas, libsndfile, opengl, openssl, pcre2, portaudio, qhull, qrupdate-ng, rapidjson, readline, suitesparse, sundials, zlib"
TERMUX_PKG_BUILD_DEPENDS="gnuplot, less"

# Qt-GUI cannot be enabled, because `qcollectiongenerator` and
# `qhelpgenerator` is not exist at host.
#TERMUX_PKG_DEPENDS="zlib, bzip2, openssl, libiconv, pcre, readline, libcurl, libhdf5, qhull, rapidjson, fftw, glpk, libopenblas, arpack-ng, qrupdate-ng, suitesparse, sundials, fontconfig, freetype, graphicsmagick, libsndfile, portaudio, fltk, mesa, glu, qt5-qtbase, qt5-qttools, qscintilla""
#TERMUX_PKG_BUILD_DEPENDS="gnuplot, less, qt5-qtbase-cross-tools, qt5-qttools-cross-tools"

TERMUX_PKG_SHA256=21417afb579105b035cac0bea09201522e384893ae90a781b8727efa32765807
TERMUX_PKG_DEPENDS="arpack-ng, bzip2, fftw, fltk, fontconfig, freetype, glpk, glu, graphicsmagick, libcurl, libhdf5, libiconv, libopenblas, libsndfile, opengl, openssl, pcre2, portaudio, qhull, qrupdate-ng, qt6-qtbase, qt6-qttools, qt6-qt5compat, rapidjson, readline, suitesparse, sundials, zlib"
TERMUX_PKG_BUILD_DEPENDS="gnuplot, less, qt6-qtbase-cross-tools, qt6-qttools-cross-tools"
TERMUX_PKG_RECOMMENDS="gnuplot, less"
TERMUX_PKG_CONFLICTS="octave"
TERMUX_PKG_BUILD_IN_SRC=true
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
--with-x
--with-qt=6
--enable-link-all-dependencies
--disable-openmp
--with-blas=openblas
Expand Down Expand Up @@ -78,7 +72,5 @@ termux_step_pre_configure() {
done
export PATH="$TERMUX_PKG_TMPDIR/_fake_bin:$PATH"

## This is to allow the build script find the `moc` on cross-build host
# for Qt-GUI
#export PATH+=":${TERMUX_PREFIX}/opt/qt/cross/bin"
export PATH="$TERMUX_PREFIX/opt/qt6/cross/bin:$PATH"
}
23 changes: 19 additions & 4 deletions tur/octave/0003-undefine-the-macro-in-pwd.h.patch
Original file line number Diff line number Diff line change
@@ -1,6 +1,21 @@
--- a/liboctave/system/oct-password.cc
+++ b/liboctave/system/oct-password.cc
@@ -31,6 +31,15 @@
--- a/liboctave/wrappers/pwd-wrappers.h
+++ b/liboctave/wrappers/pwd-wrappers.h
@@ -43,7 +43,12 @@
char *pw_passwd;
uid_t pw_uid;
gid_t pw_gid;
+#if defined(__ANDROID__) && !defined(__LP64__) && !defined(pw_gecos)
+ /* Note: On LP32, we define pw_gecos to pw_passwd since they're both NULL. */
+# define pw_gecos pw_passwd
+#else
char *pw_gecos;
+#endif
char *pw_dir;
char *pw_shell;
};
--- a/liboctave/wrappers/pwd-wrappers.c
+++ b/liboctave/wrappers/pwd-wrappers.c
@@ -32,6 +32,15 @@

#if defined (HAVE_PWD_H)
# include <pwd.h>
Expand All @@ -15,4 +30,4 @@
+# endif
#endif

#include "lo-error.h"
#include "pwd-wrappers.h"
7 changes: 3 additions & 4 deletions tur/octave/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,10 @@ TERMUX_PKG_HOMEPAGE=https://octave.org
TERMUX_PKG_DESCRIPTION="GNU Octave is a high-level language, primarily intended for numerical computations. (only CLI)"
TERMUX_PKG_LICENSE="GPL-3.0"
TERMUX_PKG_MAINTAINER="@termux-user-repository"
TERMUX_PKG_VERSION=1:8.4.0
TERMUX_PKG_REVISION=5
TERMUX_PKG_VERSION=1:9.2.0
TERMUX_PKG_SRCURL=https://ftpmirror.gnu.org/octave/octave-${TERMUX_PKG_VERSION#*:}.tar.xz
TERMUX_PKG_SHA256=6f9ad73a3ee4291b6341d6c0f5e5c85d6e0310376e4991b959a6d340b3ffa8a8
TERMUX_PKG_DEPENDS="arpack-ng, bzip2, fftw, fontconfig, freetype, glpk, graphicsmagick, libcurl, libhdf5, libiconv, libopenblas, libsndfile, openssl, pcre2, portaudio, qhull, qrupdate-ng, rapidjson, readline, suitesparse, sundials, zlib"
TERMUX_PKG_SHA256=21417afb579105b035cac0bea09201522e384893ae90a781b8727efa32765807
TERMUX_PKG_DEPENDS="arpack-ng, bzip2, fftw, fontconfig, freetype, glpk, graphicsmagick, libcurl, libhdf5, libiconv, libopenblas, libsndfile, openssl, pcre2, portaudio, qhull, qrupdate-ng, qt6-qtbase, qt6-qttools, qt6-qt5compat, rapidjson, readline, suitesparse, sundials, zlib"
TERMUX_PKG_BUILD_DEPENDS="gnuplot, less"
TERMUX_PKG_RECOMMENDS="gnuplot, less"
TERMUX_PKG_CONFLICTS="octave-x"
Expand Down

0 comments on commit 0b7940e

Please sign in to comment.