export CXX=$TERMUX_HOST_PLATFORM-g++
_SPECSFLAG="-specs=$TERMUX_SCRIPTDIR/termux.spec"
else
- export AS=${TERMUX_HOST_PLATFORM}-clang
+ export AS=${TERMUX_HOST_PLATFORM}-gcc
export CC=$TERMUX_HOST_PLATFORM-clang
export CXX=$TERMUX_HOST_PLATFORM-clang++
# TODO: clang does not have specs file, how to ensure pie
export LDFLAGS="$_SPECSFLAG -L${TERMUX_PREFIX}/lib"
if [ "$TERMUX_ARCH" = "arm" ]; then
- # For hard support: http://blog.alexrp.com/2014/02/18/android-hard-float-support/
- # "First, to utilize the hard float ABI, you must either compile every last component of your application
- # as hard float (the -mhard-float GCC/Clang switch), or mark individual functions with the appropriate
- # __attribute__ to indicate the desired ABI. For example, to mark a function so that it’s called with the
- # soft float ABI, stick __attribute__((pcs("aapcs"))) on it.
- # Note that the NDK will link to a libm which uses the aforementioned attribute on all of its functions.
- # This means that if you use libm functions a lot, you’re not likely to get much of a boost in those places.
- # The way to fix this is to add -mhard-float -D_NDK_MATH_NO_SOFTFP=1 to your GCC/Clang command line. Then
- # add -lm_hard to your linker command line (or -Wl,-lm_hard if you just invoke GCC/Clang to link). This will
- # make your application link statically to a libm compiled for the hard float ABI. The only downside of this
- # is that your application will increase somewhat in size."
- CFLAGS+=" -march=armv7-a -mfpu=neon -mhard-float -Wl,--no-warn-mismatch"
- LDFLAGS+=" -march=armv7-a -Wl,--no-warn-mismatch"
+ CFLAGS+=" -march=armv7-a -mfpu=neon -mfloat-abi=softfp"
+ # "first flag instructs the linker to pick libgcc.a, libgcov.a, and
+ # crt*.o, which are tailored for armv7-a"
+ # - https://developer.android.com/ndk/guides/standalone_toolchain.html
+ LDFLAGS+=" -march=armv7-a -Wl,--fix-cortex-a8"
elif [ $TERMUX_ARCH = "i686" ]; then
# From $NDK/docs/CPU-ARCH-ABIS.html:
CFLAGS+=" -march=i686 -msse3 -mstackrealign -mfpmath=sse"
#include <stddef.h>
+#include <string.h> /* For strcpy(3) used by ctermid() */
-+#include <asm-generic/fcntl.h> /* For O_RDWR and other O_* constants */
++#include <asm/fcntl.h> /* For O_RDWR and other O_* constants */
+#include <stdlib.h> /* For arc4random() */
+
#define __need_NULL
TERMUX_PKG_HOMEPAGE=http://aria2.sourceforge.net/
TERMUX_PKG_DESCRIPTION="Multi-protocol & multi-source command-line download utility supporting HTTP/HTTPS, FTP, BitTorrent and Metalink"
-TERMUX_PKG_VERSION=1.22.0
+TERMUX_PKG_VERSION=1.23.0
TERMUX_PKG_SRCURL=https://github.com/tatsuhiro-t/aria2/releases/download/release-$TERMUX_PKG_VERSION/aria2-${TERMUX_PKG_VERSION}.tar.xz
TERMUX_PKG_DEPENDS="c-ares, openssl, libxml2, libgnustl"
# sqlite3 is only used for loading cookies from firefox or chrome:
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="--with-openssl --without-gnutls --without-libuv --without-sqlite3 ac_cv_search_getaddrinfo=no ac_cv_func_getaddrinfo=yes ac_cv_func_gettimeofday=yes ac_cv_func_sleep=yes ac_cv_func_usleep=yes ac_cv_func_basename=yes"
termux_step_pre_configure () {
- export CXXFLAGS="$CXXFLAGS -lgnustl_shared"
# Run autoreconf since we have patched Makefile.am:
cd $TERMUX_PKG_SRCDIR
autoreconf
+++ /dev/null
-diff -u -r ../binutils-2.24/ld/ldmain.c ./ld/ldmain.c
---- ../binutils-2.24/ld/ldmain.c 2013-11-08 11:13:48.000000000 +0100
-+++ ./ld/ldmain.c 2014-06-18 08:16:53.945378483 +0200
-@@ -263,7 +263,13 @@
- config.text_read_only = TRUE;
- link_info.disable_target_specific_optimizations = -1;
-
-- command_line.warn_mismatch = TRUE;
-+ command_line.warn_mismatch =
-+#if defined(__ANDROID__) && defined(__arm__)
-+ /* --no-warn-mismatch is needed to suppress linker errors about not all functions using VFP register to pass arguments: */
-+ FALSE;
-+# else
-+ TRUE;
-+#endif
- command_line.warn_search_mismatch = TRUE;
- command_line.check_section_addresses = -1;
-
TERMUX_PKG_DESCRIPTION="C and C++ frontend for the LLVM compiler"
_PKG_MAJOR_VERSION=3.8
TERMUX_PKG_VERSION=${_PKG_MAJOR_VERSION}.0
-TERMUX_PKG_BUILD_REVISION=2
+TERMUX_PKG_BUILD_REVISION=3
TERMUX_PKG_SRCURL=http://llvm.org/releases/${TERMUX_PKG_VERSION}/llvm-${TERMUX_PKG_VERSION}.src.tar.xz
TERMUX_PKG_HOSTBUILD=true
TERMUX_PKG_RM_AFTER_INSTALL="bin/macho-dump bin/bugpoint bin/llvm-tblgen lib/BugpointPasses.so lib/LLVMHello.so"
break;
case llvm::Triple::Android:
- ABI = (SubArch == 7) ? FloatABI::SoftFP : FloatABI::Soft;
-+ ABI = FloatABI::Hard;
++ ABI = FloatABI::SoftFP;
break;
default:
// Assume "soft", but warn the user we are guessing.
- ABI = FloatABI::Soft;
-+ ABI = FloatABI::Hard;
++ ABI = FloatABI::SoftFP;
if (Triple.getOS() != llvm::Triple::UnknownOS ||
!Triple.isOSBinFormatMachO())
D.Diag(diag::warn_drv_assuming_mfloat_abi_is) << "soft";
cd $TERMUX_PKG_TMPDIR
tar xf $ARGP_FILE
cd argp-standalone-1.3
+ ORIG_CFLAGS="$CFLAGS"
+ CFLAGS+=" -std=gnu89"
./configure --host=$TERMUX_HOST_PLATFORM
make
+ CFLAGS="$ORIG_CFLAGS"
cp $TERMUX_PKG_BUILDER_DIR/error.h .
cp $TERMUX_PKG_BUILDER_DIR/stdio_ext.h .
TERMUX_PKG_DESCRIPTION="GNU C compiler"
TERMUX_PKG_DEPENDS="binutils, libgmp, libmpfr, libmpc, ndk-sysroot, libgcc, libisl, libgnustl"
TERMUX_PKG_VERSION=6.1.0
-TERMUX_PKG_BUILD_REVISION=1
+TERMUX_PKG_BUILD_REVISION=2
TERMUX_PKG_SRCURL=ftp://ftp.fu-berlin.de/unix/languages/gcc/releases/gcc-${TERMUX_PKG_VERSION}/gcc-${TERMUX_PKG_VERSION}.tar.bz2
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="--enable-languages=c,c++ --with-system-zlib --disable-multilib --disable-lto"
TERMUX_PKG_EXTRA_CONFIGURE_ARGS+=" --target=$TERMUX_HOST_PLATFORM"
TERMUX_PKG_EXTRA_CONFIGURE_ARGS+=" --enable-default-pie"
if [ "$TERMUX_ARCH" = "arm" ]; then
- TERMUX_PKG_EXTRA_CONFIGURE_ARGS+=" --with-arch=armv7-a --with-fpu=neon --with-float=hard"
+ TERMUX_PKG_EXTRA_CONFIGURE_ARGS+=" --with-arch=armv7-a --with-fpu=neon --with-float=softfp"
elif [ "$TERMUX_ARCH" = "aarch64" ]; then
TERMUX_PKG_EXTRA_CONFIGURE_ARGS+=" --with-arch=armv8-a"
elif [ "$TERMUX_ARCH" = "i686" ]; then
TERMUX_PKG_HOMEPAGE=http://www.gnu.org.ua/software/gdbm/
TERMUX_PKG_DESCRIPTION="Library of database functions that use extensible hashing"
-TERMUX_PKG_VERSION=1.11
+TERMUX_PKG_VERSION=1.12
TERMUX_PKG_SRCURL=ftp://ftp.gnu.org/gnu/gdbm/gdbm-${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_HOMEPAGE=http://lftp.yar.ru/
TERMUX_PKG_DESCRIPTION="FTP/HTTP client and file transfer program"
TERMUX_PKG_VERSION=4.7.1
+TERMUX_PKG_BUILD_REVISION=1
TERMUX_PKG_SRCURL=http://lftp.yar.ru/ftp/lftp-${TERMUX_PKG_VERSION}.tar.xz
# (1) Android has dn_expand, but lftp assumes that dn_skipname then exists, which it does not on android.
# (2) Use --with-openssl to use openssl instead of gnutls.
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="ac_cv_func_dn_expand=no --with-openssl --with-zlib=$TERMUX_STANDALONE_TOOLCHAIN/sysroot/usr --with-expat=$TERMUX_PREFIX"
-TERMUX_PKG_DEPENDS="libexpat, openssl, readline, libutil, libidn"
+TERMUX_PKG_DEPENDS="libexpat, openssl, readline, libutil, libidn, libgnustl"
termux_step_pre_configure () {
# We have patched an m4 file.
TERMUX_PKG_HOMEPAGE=https://developer.android.com/tools/sdk/ndk/index.html
TERMUX_PKG_DESCRIPTION="Library extending the Android C library (Bionic) for additional multibyte, locale and math support"
# Increase last digit each time a patch changes.
-TERMUX_PKG_VERSION=${TERMUX_NDK_VERSION}.8
+TERMUX_PKG_VERSION=${TERMUX_NDK_VERSION}.9
TERMUX_PKG_BUILD_IN_SRC=yes
TERMUX_PKG_ESSENTIAL=yes
TERMUX_PKG_HOMEPAGE=http://gcc.gnu.org/onlinedocs/libstdc++/
TERMUX_PKG_DESCRIPTION="The GNU Standard C++ Library (a.k.a. libstdc++-v3), necessary on android since the system libstdc++.so is stripped down"
TERMUX_PKG_VERSION=$TERMUX_NDK_VERSION
-TERMUX_PKG_BUILD_REVISION=3
+TERMUX_PKG_BUILD_REVISION=4
termux_step_make_install () {
- LIBFILE=$TERMUX_STANDALONE_TOOLCHAIN/${TERMUX_HOST_PLATFORM}/lib/libgnustl_shared.so
+ local LIBFILE=$TERMUX_STANDALONE_TOOLCHAIN/${TERMUX_HOST_PLATFORM}/lib/libgnustl_shared.so
if [ $TERMUX_ARCH = arm ]; then
- LIBFILE=$TERMUX_STANDALONE_TOOLCHAIN/${TERMUX_HOST_PLATFORM}/lib/armv7-a/hard/libgnustl_shared.so
+ LIBFILE=$TERMUX_STANDALONE_TOOLCHAIN/${TERMUX_HOST_PLATFORM}/lib/armv7-a/libgnustl_shared.so
fi
cp $LIBFILE $TERMUX_PREFIX/lib/
}
+
+termux_step_post_massage () {
+ # Setup a libgnustl_shared.so in $PREFIX/lib, so that other C++ using packages
+ # links to it. We do however want to avoid installing this, to avoid problems
+ # where e.g. libm.so on some i686 devices links against libstdc++.so, so do
+ # this here in termux_step_post_massage.
+ cd $TERMUX_PREFIX/lib
+ ln -f -s libgnustl_shared.so libstdc++.so
+}
TERMUX_PKG_HOMEPAGE=http://www.sqlite.org/
TERMUX_PKG_DESCRIPTION="Software library that implements a self-contained, serverless, zero-configuration, transactional SQL database engine"
-TERMUX_PKG_VERSION=3.12.2
-TERMUX_PKG_SRCURL=https://www.sqlite.org/2016/sqlite-autoconf-3120200.tar.gz
+TERMUX_PKG_VERSION=3.13.0
+TERMUX_PKG_SRCURL=https://www.sqlite.org/2016/sqlite-autoconf-3130000.tar.gz
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="--enable-readline"
TERMUX_PKG_HOMEPAGE=http://libuv.org
TERMUX_PKG_DESCRIPTION="Support library with a focus on asynchronous I/O"
-TERMUX_PKG_VERSION=1.9.0
+TERMUX_PKG_VERSION=1.9.1
TERMUX_PKG_SRCURL=http://dist.libuv.org/dist/v${TERMUX_PKG_VERSION}/libuv-v${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="--disable-dtrace" # needed for building on mac
cd $TERMUX_PKG_SRCDIR
sh autogen.sh
}
-
-termux_step_post_make_install () {
- # The installed include/uv-unix includes pthread-fixes.h inside ifdef __ANDROID__
- cp $TERMUX_PKG_SRCDIR/include/pthread-fixes.h $TERMUX_PREFIX/include
-}
-Remove no longer needed workaround which breaks node.js build.
-
-diff -u -r ../libuv-v1.7.3/include/pthread-fixes.h ./include/pthread-fixes.h
---- ../libuv-v1.7.3/include/pthread-fixes.h 2015-08-27 17:42:36.000000000 -0400
-+++ ./include/pthread-fixes.h 2015-09-08 17:31:47.658023853 -0400
-@@ -57,16 +57,4 @@
+diff -u -r ../libuv-v1.9.1/src/unix/internal.h ./src/unix/internal.h
+--- ../libuv-v1.9.1/src/unix/internal.h 2016-05-16 17:22:19.000000000 -0400
++++ ./src/unix/internal.h 2016-05-18 10:48:45.456553752 -0400
+@@ -55,14 +55,6 @@
+ # include <CoreServices/CoreServices.h>
+ #endif
- int pthread_yield(void);
-
--/* Workaround pthread_sigmask() returning EINVAL on versions < 4.1 by
-- * replacing all calls to pthread_sigmask with sigprocmask. See:
-- * https://android.googlesource.com/platform/bionic/+/9bf330b5
-- * https://code.google.com/p/android/issues/detail?id=15337
-- */
+-#if defined(__ANDROID__)
-int uv__pthread_sigmask(int how, const sigset_t* set, sigset_t* oset);
--
--#ifdef pthread_sigmask
--#undef pthread_sigmask
+-# ifdef pthread_sigmask
+-# undef pthread_sigmask
+-# endif
+-# define pthread_sigmask(how, set, oldset) uv__pthread_sigmask(how, set, oldset)
-#endif
--#define pthread_sigmask(how, set, oldset) uv__pthread_sigmask(how, set, oldset)
-
- #endif /* GOOGLE_BREAKPAD_COMMON_ANDROID_TESTING_PTHREAD_FIXES_H */
-diff -u -r ../libuv-v1.7.3/src/unix/pthread-fixes.c ./src/unix/pthread-fixes.c
---- ../libuv-v1.7.3/src/unix/pthread-fixes.c 2015-08-27 17:42:36.000000000 -0400
-+++ ./src/unix/pthread-fixes.c 2015-09-08 17:31:31.562244293 -0400
-@@ -29,31 +29,6 @@
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
+ #define ACCESS_ONCE(type, var) \
+ (*(volatile type*) &(var))
--/* Android versions < 4.1 have a broken pthread_sigmask.
-- * Note that this block of code must come before any inclusion of
-- * pthread-fixes.h so that the real pthread_sigmask can be referenced.
-- * */
--#include <errno.h>
--#include <pthread.h>
--#include <signal.h>
+diff -u -r ../libuv-v1.9.1/src/unix/pthread-fixes.c ./src/unix/pthread-fixes.c
+--- ../libuv-v1.9.1/src/unix/pthread-fixes.c 2016-05-16 17:22:19.000000000 -0400
++++ ./src/unix/pthread-fixes.c 2016-05-18 10:47:54.209328719 -0400
+@@ -33,24 +33,3 @@
+ #include <errno.h>
+ #include <pthread.h>
+ #include <signal.h>
-
-int uv__pthread_sigmask(int how, const sigset_t* set, sigset_t* oset) {
- static int workaround;
+- int err;
-
- if (workaround) {
- return sigprocmask(how, set, oset);
-- } else if (pthread_sigmask(how, set, oset)) {
-- if (errno == EINVAL && sigprocmask(how, set, oset) == 0) {
-- workaround = 1;
-- return 0;
-- } else {
-- return -1;
-- }
- } else {
-- return 0;
+- err = pthread_sigmask(how, set, oset);
+- if (err) {
+- if (err == EINVAL && sigprocmask(how, set, oset) == 0) {
+- workaround = 1;
+- return 0;
+- } else {
+- return -1;
+- }
+- }
- }
--}
-
- /*Android doesn't provide pthread_barrier_t for now.*/
- #ifndef PTHREAD_BARRIER_SERIAL_THREAD
-
+- return 0;
+-}
TERMUX_PKG_HOMEPAGE=http://www.ltrace.org/
TERMUX_PKG_DESCRIPTION="Tracks runtime library calls in dynamically linked programs"
TERMUX_PKG_VERSION=0.7.3.20160411
-TERMUX_PKG_DEPENDS="elfutils"
+TERMUX_PKG_DEPENDS="elfutils, libgnustl"
# TERMUX_PKG_SRCURL=http://www.ltrace.org/ltrace_${TERMUX_PKG_VERSION}.orig.tar.bz2
# TERMUX_PKG_FOLDERNAME=ltrace-${TERMUX_PKG_VERSION}
--- /dev/null
+Disabled for now - enable if we want c++ as the default C++ compiler.
+diff -u -r ../make-4.1/default.c ./default.c
+--- ../make-4.1/default.c 2014-10-05 12:24:51.000000000 -0400
++++ ./default.c 2016-05-02 17:35:39.128123074 -0400
+@@ -447,7 +447,7 @@
+ "OBJC", "gcc",
+ #else
+ "CC", "cc",
+- "CXX", "g++",
++ "CXX", "c++",
+ "OBJC", "cc",
+ #endif
+
TERMUX_PKG_NO_DEVELSPLIT=yes
termux_step_extract_into_massagedir () {
- #mkdir -p $TERMUX_PKG_MASSAGEDIR/$TERMUX_PREFIX/lib/gcc/arm-linux-androideabi/4.9.0/include/
- #cp -Rf $TERMUX_STANDALONE_TOOLCHAIN/include/c++/4.8/* $TERMUX_PKG_MASSAGEDIR/$TERMUX_PREFIX/lib/gcc/arm-linux-androideabi/4.9.0/include/
- # Needed:
- #cp $TERMUX_PKG_MASSAGEDIR/$TERMUX_PREFIX/lib/gcc/arm-linux-androideabi/4.9.0/include/arm-linux-androideabi/bits/* $TERMUX_PKG_MASSAGEDIR/$TERMUX_PREFIX/lib/gcc/arm-linux-androideabi/4.9.0/include/bits/
-
mkdir -p $TERMUX_PKG_MASSAGEDIR/$TERMUX_PREFIX/include/
- cp -Rf $TERMUX_STANDALONE_TOOLCHAIN/include/c++/4.9/* $TERMUX_PKG_MASSAGEDIR/$TERMUX_PREFIX/include/
+ cp -Rf $TERMUX_STANDALONE_TOOLCHAIN/include/c++/4.9/* $TERMUX_PKG_MASSAGEDIR/$TERMUX_PREFIX/include/
+
if [ $TERMUX_ARCH = arm ]; then
cp $TERMUX_PKG_MASSAGEDIR/$TERMUX_PREFIX/include/arm-linux-androideabi/armv7-a/bits/* \
$TERMUX_PKG_MASSAGEDIR/$TERMUX_PREFIX/include/bits
TERMUX_PKG_HOMEPAGE=http://nodejs.org/
TERMUX_PKG_DESCRIPTION="Platform built on Chrome's JavaScript runtime for easily building fast, scalable network applications"
-TERMUX_PKG_VERSION=6.1.0
+TERMUX_PKG_VERSION=6.2.0
TERMUX_PKG_SRCURL=https://nodejs.org/dist/v${TERMUX_PKG_VERSION}/node-v${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_DEPENDS="openssl, libuv, libgnustl, c-ares"
TERMUX_PKG_RM_AFTER_INSTALL="lib/node_modules/npm/html lib/node_modules/npm/make.bat share/systemtap lib/dtrace"
--dest-os=android \
--shared-openssl --shared-zlib --shared-libuv --shared-cares \
--without-snapshot \
+ --without-intl \
$_EXTRA_CONFIGURE_ARGS
}
--- /dev/null
+diff -u -r ../node-v6.2.0/lib/child_process.js ./lib/child_process.js
+--- ../node-v6.2.0/lib/child_process.js 2016-05-17 15:53:06.000000000 -0400
++++ ./lib/child_process.js 2016-05-18 16:31:45.574685443 -0400
+@@ -335,7 +335,7 @@
+ if (typeof options.shell === 'string')
+ file = options.shell;
+ else if (process.platform === 'android')
+- file = '/system/bin/sh';
++ file = '@TERMUX_PREFIX@/bin/sh';
+ else
+ file = '/bin/sh';
+ args = ['-c', command];
--- /dev/null
+Backport of https://github.com/nodejs/node/pull/6820
+
+diff -u -r ../node-v6.2.0/src/node_config.cc ./src/node_config.cc
+--- ../node-v6.2.0/src/node_config.cc 2016-05-17 15:53:07.000000000 -0400
++++ ./src/node_config.cc 2016-05-18 16:45:34.588991777 -0400
+@@ -29,8 +29,8 @@
+ void InitConfig(Local<Object> target,
+ Local<Value> unused,
+ Local<Context> context) {
+-#ifdef NODE_HAVE_I18N_SUPPORT
+ Environment* env = Environment::GetCurrent(context);
++#ifdef NODE_HAVE_I18N_SUPPORT
+
+ READONLY_BOOLEAN_PROPERTY("hasIntl");
+
TERMUX_PKG_DESCRIPTION="Library implementing the SSL and TLS protocols as well as general purpose cryptography functions"
TERMUX_PKG_DEPENDS="ca-certificates"
TERMUX_PKG_VERSION=1.0.2h
+TERMUX_PKG_BUILD_REVISION=1
TERMUX_PKG_SRCURL="http://www.openssl.org/source/openssl-${TERMUX_PKG_VERSION}.tar.gz"
TERMUX_PKG_RM_AFTER_INSTALL="bin/c_rehash etc/ssl/misc"
TERMUX_PKG_BUILD_IN_SRC=yes
TERMUX_PKG_DEPENDS="libcrypt, openssl"
_PICOLISP_YEAR=16
_PICOLISP_MONTH=5
-_PICOLISP_DAY=8
+_PICOLISP_DAY=13
TERMUX_PKG_VERSION=${_PICOLISP_YEAR}.${_PICOLISP_MONTH}.${_PICOLISP_DAY}
TERMUX_PKG_SRCURL=http://software-lab.de/picoLisp.tgz
TERMUX_PKG_FOLDERNAME=picoLisp
cd $TERMUX_PKG_SRCDIR/
if [ $TERMUX_ARCH_BITS = "64" ]; then
- $CC -pie -o ../bin/picolisp -rdynamic ${TERMUX_PKG_EXTRA_MAKE_ARGS}.base.s -lc -lm -ldl
+ $AS -pie -o ../bin/picolisp -rdynamic ${TERMUX_PKG_EXTRA_MAKE_ARGS}.base.s -lc -lm -ldl
chmod +x ../bin/picolisp
- $CC -pie -o ../lib/ext -shared -export-dynamic ${TERMUX_PKG_EXTRA_MAKE_ARGS}.ext.s
- $CC --pie -o ../lib/ht -shared -export-dynamic ${TERMUX_PKG_EXTRA_MAKE_ARGS}.ht.s
+ $AS -pie -o ../lib/ext -shared -export-dynamic ${TERMUX_PKG_EXTRA_MAKE_ARGS}.ext.s
+ $AS --pie -o ../lib/ht -shared -export-dynamic ${TERMUX_PKG_EXTRA_MAKE_ARGS}.ht.s
fi
mkdir -p $TERMUX_PREFIX/share/man/man1
_MAJOR_VERSION=3.5
TERMUX_PKG_VERSION=${_MAJOR_VERSION}.1
-TERMUX_PKG_BUILD_REVISION=4
+TERMUX_PKG_BUILD_REVISION=5
TERMUX_PKG_SRCURL=http://www.python.org/ftp/python/${TERMUX_PKG_VERSION}/Python-${TERMUX_PKG_VERSION}.tar.xz
# The flag --with(out)-pymalloc (disable/enable specialized mallocs) is enabled by default and causes m suffix versions of python.
+++ /dev/null
-The math module uses function pointers to math functions, which breaks
-using the system libm on ARM since we compile with -mhard-float.
-
-diff -u -r ../Python-3.4.3/Modules/mathmodule.c ./Modules/mathmodule.c
---- ../Python-3.4.3/Modules/mathmodule.c 2015-02-25 06:27:46.000000000 -0500
-+++ ./Modules/mathmodule.c 2015-04-29 16:50:52.895371496 -0400
-@@ -727,7 +727,7 @@
- */
-
- static PyObject *
--math_1_to_whatever(PyObject *arg, double (*func) (double),
-+math_1_to_whatever(PyObject *arg, __NDK_FPABI_MATH__ double (*func) (double),
- PyObject *(*from_double_func) (double),
- int can_overflow)
- {
-@@ -765,7 +765,7 @@
- errno = ERANGE for overflow). */
-
- static PyObject *
--math_1a(PyObject *arg, double (*func) (double))
-+math_1a(PyObject *arg, __NDK_FPABI_MATH__ double (*func) (double))
- {
- double x, r;
- x = PyFloat_AsDouble(arg);
-@@ -808,19 +808,19 @@
- */
-
- static PyObject *
--math_1(PyObject *arg, double (*func) (double), int can_overflow)
-+math_1(PyObject *arg, __NDK_FPABI_MATH__ double (*func) (double), int can_overflow)
- {
- return math_1_to_whatever(arg, func, PyFloat_FromDouble, can_overflow);
- }
-
- static PyObject *
--math_1_to_int(PyObject *arg, double (*func) (double), int can_overflow)
-+math_1_to_int(PyObject *arg, __NDK_FPABI_MATH__ double (*func) (double), int can_overflow)
- {
- return math_1_to_whatever(arg, func, PyLong_FromDouble, can_overflow);
- }
-
- static PyObject *
--math_2(PyObject *args, double (*func) (double, double), char *funcname)
-+math_2(PyObject *args, __NDK_FPABI_MATH__ double (*func) (double, double), char *funcname)
- {
- PyObject *ox, *oy;
- double x, y, r;
--- /dev/null
+Fix issues when compiling with clang (where cpp is provided by gcc
+in the standalone toolchain).
+
+diff -u -r ../ruby-2.3.1/configure.in ./configure.in
+--- ../ruby-2.3.1/configure.in 2016-04-24 13:44:40.000000000 -0400
++++ ./configure.in 2016-05-18 01:10:09.523385169 -0400
+@@ -799,7 +799,7 @@
+ rb_cv_warnflags="$warnflags"
+ if test "$GCC:${warnflags+set}:no" = yes::no; then
+ if test $gcc_major -ge 4; then
+- extra_warning=-Werror=extra-tokens
++ extra_warning=
+ else
+ extra_warning=
+ fi
+@@ -813,9 +813,7 @@
+ -Werror=pointer-arith \
+ -Werror=write-strings \
+ -Werror=declaration-after-statement \
+- -Werror=shorten-64-to-32 \
+ -Werror=implicit-function-declaration \
+- -Werror=division-by-zero \
+ -Werror=deprecated-declarations \
+ -Wno-packed-bitfield-compat \
+ $extra_warning \