chiark / gitweb /
Some more clang preparations
authorFredrik Fornwall <fredrik@fornwall.net>
Sat, 3 Sep 2016 21:48:41 +0000 (17:48 -0400)
committerFredrik Fornwall <fredrik@fornwall.net>
Sat, 3 Sep 2016 21:48:41 +0000 (17:48 -0400)
packages/apt/build.sh
packages/autossh/build.sh
packages/busybox/build.sh
packages/cboard/build.sh
packages/nano/build.sh
packages/psmisc/build.sh

index dc9289c14f633242ce746836c99f029396f80167..4c8bd0f786559739d912b88823c698c15a5ac793 100644 (file)
@@ -14,13 +14,13 @@ TERMUX_PKG_FOLDERNAME=apt-${TERMUX_PKG_VERSION}
 TERMUX_PKG_ESSENTIAL=yes
 TERMUX_PKG_CONFFILES="etc/apt/sources.list"
 
-# Some files use STD*_FILENO without including <unistd.h> where they are declared.
-# Define them here to avoid having to patch files:
-CXXFLAGS+=" -DSTDIN_FILENO=0 -DSTDOUT_FILENO=1 -DSTDERR_FILENO=2 -DAI_IDN=0"
-
 termux_step_pre_configure () {
+       # Some files use STD*_FILENO without including <unistd.h> where they are declared.
+       # Define them here to avoid having to patch files:
+       CXXFLAGS+=" -DSTDIN_FILENO=0 -DSTDOUT_FILENO=1 -DSTDERR_FILENO=2 -DAI_IDN=0"
+
        cp $TERMUX_COMMON_CACHEDIR/config.{guess,sub} $TERMUX_PKG_SRCDIR/buildlib
-        perl -p -i -e "s/TERMUX_ARCH/$TERMUX_ARCH/" $TERMUX_PKG_SRCDIR/configure
+       perl -p -i -e "s/TERMUX_ARCH/$TERMUX_ARCH/" $TERMUX_PKG_SRCDIR/configure
 
        rm $TERMUX_PKG_SRCDIR/apt-pkg/{cdrom.cc,indexcopy.cc}
 }
index 2fc22c4f5a43ddcf8b2b397cfd2bce0d89abf51b..be5bd787d82eab1936c4dc4d3d944e2e4211bf0e 100644 (file)
@@ -6,5 +6,7 @@ TERMUX_PKG_BUILD_IN_SRC="yes"
 TERMUX_PKG_DEPENDS="openssh"
 TERMUX_PKG_EXTRA_CONFIGURE_ARGS="--mandir=$TERMUX_PREFIX/share/man ac_cv_path_ssh=$TERMUX_PREFIX/bin/ssh"
 
-# For syslog logging:
-LDFLAGS+=" -llog"
+termux_step_pre_configure () {
+       # For syslog logging:
+       LDFLAGS+=" -llog"
+}
index 169c361e5873ee7897dc735142ccf236d35e5edc..63dc4f56448c8e99caadc01c2ded0807b56bffa9 100755 (executable)
@@ -11,7 +11,9 @@ TERMUX_PKG_CONFLICTS="coreutils (<< 8.25-4)"
 # NOTE: sed on mac does not work for building busybox, install gnu-sed with
 #       homebrew using the --with-default-names option.
 
-CFLAGS+=" -llog -DTERMUX_EXPOSE_MEMPCPY=1" # Android system liblog.so for syslog
+termux_step_pre_configure () {
+       CFLAGS+=" -llog -DTERMUX_EXPOSE_MEMPCPY=1" # Android system liblog.so for syslog
+}
 
 termux_step_configure () {
        # Bug in gold linker with busybox in android r10e:
@@ -35,7 +37,7 @@ termux_step_post_make_install () {
        cd $TERMUX_PREFIX/bin/applets
        for f in `cat $TERMUX_PKG_SRCDIR/busybox.links`; do ln -s ../busybox `basename $f`; done
 
-        # The 'ash' and 'env' applets are special in that they go into $PREFIX/bin:
+       # The 'ash' and 'env' applets are special in that they go into $PREFIX/bin:
        cd $TERMUX_PREFIX/bin
        ln -f -s busybox ash
        ln -f -s busybox env
index 9f354fb0bdba8fb20254a657aedbaa3bc6673338..340480aa19e3d04de12fd86be23958970c3245c6 100644 (file)
@@ -4,5 +4,7 @@ TERMUX_PKG_VERSION=0.7.3
 TERMUX_PKG_SRCURL=http://downloads.sourceforge.net/project/c-board/${TERMUX_PKG_VERSION}/cboard-${TERMUX_PKG_VERSION}.tar.bz2
 TERMUX_PKG_DEPENDS="libandroid-support,libandroid-glob,gnuchess, ncurses, ncurses-ui-libs"
 
-CFLAGS+=" -DLINE_MAX=_POSIX2_LINE_MAX"
-LDFLAGS+=" -landroid-glob"
+termux_step_pre_configure () {
+       CFLAGS+=" -DLINE_MAX=_POSIX2_LINE_MAX"
+       LDFLAGS+=" -landroid-glob"
+}
index 699ee8f29bf6035e6ab32d5fd8d815b9f0983a08..ef776562e516b690de9184b8986d8e71dd9b0f67 100644 (file)
@@ -7,7 +7,9 @@ TERMUX_PKG_DEPENDS="libandroid-support,libandroid-glob,ncurses"
 TERMUX_PKG_EXTRA_CONFIGURE_ARGS="--enable-utf8 --disable-libmagic"
 TERMUX_PKG_RM_AFTER_INSTALL="bin/rnano share/man/man1/rnano.1 share/nano/man-html"
 
-LDFLAGS+=" -landroid-glob"
+termux_step_pre_configure() {
+       LDFLAGS+=" -landroid-glob"
+}
 
 termux_step_post_make_install () {
        # Configure nano to use syntax highlighting:
index aa099a61f8eb05fea68595e4f21b900fa8617b03..a2b6a842c38623a45e81e4d38d63022adbf28833 100644 (file)
@@ -5,4 +5,6 @@ TERMUX_PKG_VERSION=22.21
 TERMUX_PKG_SRCURL=http://downloads.sourceforge.net/project/psmisc/psmisc/psmisc-${TERMUX_PKG_VERSION}.tar.gz
 TERMUX_PKG_RM_AFTER_INSTALL="bin/pstree.x11"
 
-CFLAGS+=" -DTERMUX_EXPOSE_MEMPCPY=1"
+termux_step_pre_configure() {
+       CFLAGS+=" -DTERMUX_EXPOSE_MEMPCPY=1"
+}