termux-packages/packages/grep/build.sh

22 lines
1.1 KiB
Bash
Raw Normal View History

2016-12-07 23:12:47 +01:00
TERMUX_PKG_HOMEPAGE=https://www.gnu.org/software/grep/
2015-06-13 01:03:31 +02:00
TERMUX_PKG_DESCRIPTION="Command which searches one or more input files for lines containing a match to a specified pattern"
2019-01-21 13:53:58 +01:00
TERMUX_PKG_LICENSE="GPL-3.0"
2020-01-09 23:33:08 +01:00
TERMUX_PKG_VERSION=3.4
TERMUX_PKG_SRCURL=https://mirrors.kernel.org/gnu/grep/grep-${TERMUX_PKG_VERSION}.tar.xz
2020-01-09 23:33:08 +01:00
TERMUX_PKG_SHA256=58e6751c41a7c25bfc6e9363a41786cff3ba5709cf11d5ad903cf7cce31cc3fb
TERMUX_PKG_DEPENDS="libandroid-support, pcre"
TERMUX_PKG_ESSENTIAL=true
termux_step_pre_configure() {
if $TERMUX_DEBUG; then
# When doing debug build, -D_FORTIFY_SOURCE=2 gives this error:
# /home/builder/.termux-build/_cache/19b-aarch64-24-v5/bin/../sysroot/usr/include/bits/fortify/stdio.h:51:53: error: use of undeclared identifier '__USE_FORTIFY_LEVEL'
# return __builtin___vsnprintf_chk(dest, size, 0, __bos(dest), format, ap);
# ^
# lib/cdefs.h:123:48: note: expanded from macro '__bos'
# #define __bos(ptr) __builtin_object_size (ptr, __USE_FORTIFY_LEVEL > 1)
# ^
export CFLAGS=${CFLAGS/-D_FORTIFY_SOURCE=2/}
fi
}