Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

new pkgs to gpkg #99

Merged
merged 1 commit into from
Sep 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions gpkg/libcurl/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ TERMUX_PKG_HOMEPAGE=https://curl.se/
TERMUX_PKG_DESCRIPTION="Easy-to-use client-side URL transfer library"
TERMUX_PKG_LICENSE="MIT"
TERMUX_PKG_MAINTAINER="@termux-pacman"
TERMUX_PKG_VERSION="8.2.1"
TERMUX_PKG_VERSION="8.3.0"
TERMUX_PKG_SRCURL=https://github.com/curl/curl/releases/download/curl-${TERMUX_PKG_VERSION//./_}/curl-${TERMUX_PKG_VERSION}.tar.xz
TERMUX_PKG_SHA256=dd322f6bd0a20e6cebdfd388f69e98c3d183bed792cf4713c8a7ef498cba4894
TERMUX_PKG_SHA256=376d627767d6c4f05105ab6d497b0d9aba7111770dd9d995225478209c37ea63
TERMUX_PKG_DEPENDS="libnghttp2-glibc, libssh2-glibc, openssl-glibc (>= 3.0.3), krb5-glibc, brotli-glibc"
TERMUX_PKG_ESSENTIAL=true
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
TERMUX_SUBPKG_DESCRIPTION="A collection of utilities to read, create and modify ELF binary files"
TERMUX_SUBPKG_INCLUDE="glibc/bin/eu-* glibc/etc/profile.d/debuginfod.* glibc/share/man/man8/* glibc/share/man/man1/*"
TERMUX_SUBPKG_DEPENDS="libarchive-glibc, libasm-glibc, libdebuginfod-glibc, libdw-glibc, libmicrohttpd, libsqlite"
TERMUX_SUBPKG_DEPENDS="libarchive-glibc, libasm-glibc, libdebuginfod-glibc, libdw-glibc, libmicrohttpd-glibc, libsqlite-glibc"
13 changes: 13 additions & 0 deletions gpkg/libffi/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
TERMUX_PKG_HOMEPAGE=https://sourceware.org/libffi/
TERMUX_PKG_DESCRIPTION="Library providing a portable, high level programming interface to various calling conventions"
TERMUX_PKG_LICENSE="MIT"
TERMUX_PKG_MAINTAINER="@termux-pacman"
TERMUX_PKG_VERSION=3.4.4
TERMUX_PKG_SRCURL=https://github.com/libffi/libffi/releases/download/v${TERMUX_PKG_VERSION}/libffi-${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_SHA256=d66c56ad259a82cf2a9dfc408b32bf5da52371500b84745f7fb8b645712df676
TERMUX_PKG_DEPENDS="glibc"
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
--disable-multi-os-directory
--disable-exec-static-tramp
--enable-pax_emutramp
"
2 changes: 1 addition & 1 deletion gpkg/libgmp/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ TERMUX_PKG_MAINTAINER="@termux-pacman"
TERMUX_PKG_VERSION=6.3.0
TERMUX_PKG_SRCURL=https://mirrors.kernel.org/gnu/gmp/gmp-${TERMUX_PKG_VERSION}.tar.xz
TERMUX_PKG_SHA256=a3c2b80201b89e68616f4ad30bc66aee4927c3ce50e33929ca819d5c43538898
TERMUX_PKG_DEPENDS="gcc-glibc-libs-dev"
TERMUX_PKG_DEPENDS="glibc"
19 changes: 19 additions & 0 deletions gpkg/libgnutls/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
TERMUX_PKG_HOMEPAGE=https://www.gnutls.org/
TERMUX_PKG_DESCRIPTION="Secure communications library implementing the SSL, TLS and DTLS protocols and technologies around them"
TERMUX_PKG_LICENSE="LGPL-2.1, GPL-3.0"
TERMUX_PKG_MAINTAINER="@termux-pacmam"
_MAJOR_VERSION=3.8
TERMUX_PKG_VERSION=${_MAJOR_VERSION}.1
TERMUX_PKG_SRCURL=https://www.gnupg.org/ftp/gcrypt/gnutls/v${_MAJOR_VERSION}/gnutls-${TERMUX_PKG_VERSION}.tar.xz
TERMUX_PKG_SHA256=ba8b9e15ae20aba88f44661978f5b5863494316fe7e722ede9d069fe6294829c
TERMUX_PKG_DEPENDS="libgmp-glibc, libtasn1-glibc, readline-glibc, zlib-glibc, libnettle-glibc, p11-kit-glibc, libidn2-glibc, zstd-glibc, libunistring-glibc, brotli-glibc"
TERMUX_PKG_BUILD_IN_SRC=true
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
--disable-static
--with-idn
--with-brotli
--with-zstd
--enable-openssl-compatibility
--with-default-trust-store-pkcs11="pkcs11:"
"
#--with-tpm2
2 changes: 2 additions & 0 deletions gpkg/libgnutls/gnutls.subpackage.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
TERMUX_SUBPKG_INCLUDE="glibc/bin/ glibc/share/man/man1/"
TERMUX_SUBPKG_DESCRIPTION="Commandline utilities for interfacing with the gnutls library"
17 changes: 17 additions & 0 deletions gpkg/libmicrohttpd/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
TERMUX_PKG_HOMEPAGE=http://www.gnu.org/software/libmicrohttpd/
TERMUX_PKG_DESCRIPTION="A small C library that is supposed to make it easy to run an HTTP server as part of another application"
TERMUX_PKG_LICENSE="LGPL-2.1"
TERMUX_PKG_MAINTAINER="@termux-pacman"
TERMUX_PKG_VERSION=0.9.77
TERMUX_PKG_SRCURL=https://ftp.gnu.org/gnu/libmicrohttpd/libmicrohttpd-$TERMUX_PKG_VERSION.tar.gz
TERMUX_PKG_SHA256=9e7023a151120060d2806a6ea4c13ca9933ece4eacfc5c9464d20edddb76b0a0
TERMUX_PKG_DEPENDS="libgnutls-glibc"
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
--disable-dependency-tracking
--disable-examples
--enable-curl
--enable-https
--enable-largefile
--enable-messages
--with-pic
"
8 changes: 8 additions & 0 deletions gpkg/libnettle/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
TERMUX_PKG_HOMEPAGE=https://www.lysator.liu.se/~nisse/nettle/
TERMUX_PKG_DESCRIPTION="Cryptographic library that is designed to fit easily in more or less any context"
TERMUX_PKG_LICENSE="GPL-2.0, LGPL-3.0"
TERMUX_PKG_MAINTAINER="@termux-pacman"
TERMUX_PKG_VERSION=3.9.1
TERMUX_PKG_SRCURL=https://mirrors.kernel.org/gnu/nettle/nettle-${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_SHA256=ccfeff981b0ca71bbd6fbcb054f407c60ffb644389a5be80d6716d5b550c6ce3
TERMUX_PKG_DEPENDS="libgmp-glibc, gcc-glibc-libs-dev"
2 changes: 2 additions & 0 deletions gpkg/libnettle/nettle.subpackage.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
TERMUX_SUBPKG_INCLUDE="glibc/bin/ glibc/share/man/man1/"
TERMUX_SUBPKG_DESCRIPTION="Low level cryptographic tools"
52 changes: 52 additions & 0 deletions gpkg/libsqlite/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
TERMUX_PKG_HOMEPAGE=https://www.sqlite.org
TERMUX_PKG_DESCRIPTION="A C library that implements an SQL database engine"
TERMUX_PKG_LICENSE="Public Domain"
TERMUX_PKG_MAINTAINER="@termux-pacman"
_SQLITE_SRCVER=3430100
_SQLITE_YEAR=2023
TERMUX_PKG_VERSION=3.43.1
TERMUX_PKG_SRCURL=https://www.sqlite.org/${_SQLITE_YEAR}/sqlite-src-${_SQLITE_SRCVER}.zip
TERMUX_PKG_SHA256=22e9c2ef49fe6f8a2dbc93c4d3dce09c6d6a4f563de52b0a8171ad49a8c72917
TERMUX_PKG_DEPENDS="zlib-glibc"
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
--disable-static
--enable-fts3
--enable-fts4
--enable-fts5
--enable-rtree
TCLLIBDIR=$TERMUX_PREFIX/lib/sqlite$TERMUX_PKG_VERSION
"

termux_step_pre_configure() {
export CFLAGS="${CFLAGS/_FORTIFY_SOURCE=3/_FORTIFY_SOURCE=2}"
export CXXFLAGS="${CXXFLAGS/_FORTIFY_SOURCE=3/_FORTIFY_SOURCE=2}"
export CPPFLAGS="$CPPFLAGS \
-DSQLITE_ENABLE_COLUMN_METADATA=1 \
-DSQLITE_ENABLE_UNLOCK_NOTIFY \
-DSQLITE_ENABLE_DBSTAT_VTAB=1 \
-DSQLITE_ENABLE_FTS3_TOKENIZER=1 \
-DSQLITE_ENABLE_FTS3_PARENTHESIS \
-DSQLITE_SECURE_DELETE \
-DSQLITE_ENABLE_STMTVTAB \
-DSQLITE_MAX_VARIABLE_NUMBER=250000 \
-DSQLITE_MAX_EXPR_DEPTH=10000 \
-DSQLITE_ENABLE_MATH_FUNCTIONS"
}

termux_step_make() {
sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
make
make showdb showjournal showstat4 showwal sqldiff sqlite3_analyzer
}

termux_step_post_make_install() {
install -m755 showdb showjournal showstat4 showwal sqldiff sqlite3_analyzer lemon $TERMUX_PREFIX/bin/

install -m755 -d $TERMUX_PREFIX/share/man/man1
install -m644 $TERMUX_PKG_SRCDIR/sqlite3.1 $TERMUX_PREFIX/share/man/man1/

install -m755 -d $TERMUX_PREFIX/share/man/mann
install -m644 $TERMUX_PKG_SRCDIR/autoconf/tea/doc/sqlite3.n $TERMUX_PREFIX/share/man/mann/

install -Dm644 lempar.c $TERMUX_PREFIX/share/lemon/lempar.c
}
4 changes: 4 additions & 0 deletions gpkg/libsqlite/lemon.subpackage.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
TERMUX_SUBPKG_INCLUDE="glibc/bin/lemon glibc/share/lemon/lempar.c glibc/share/man/mann/"
TERMUX_SUBPKG_DESCRIPTION="A parser generator"
TERMUX_SUBPKG_DEPEND_ON_PARENT="no"
TERMUX_SUBPKG_DEPENDS="glibc, gcc-glibc-libs-dev"
65 changes: 65 additions & 0 deletions gpkg/libsqlite/setdirs.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
diff --git a/ext/lsm1/lsm-test/lsmtest_main.c b/ext/lsm1/lsm-test/lsmtest_main.c
index f4a3ac0..04d7447 100644
--- a/ext/lsm1/lsm-test/lsmtest_main.c
+++ b/ext/lsm1/lsm-test/lsmtest_main.c
@@ -695,7 +695,7 @@ int do_speed_test2(int nArg, char **azArg){
}

#if 0
- pLog = fopen("/tmp/speed.log", "w");
+ pLog = fopen("@TERMUX_PREFIX_CLASSICAL@/tmp/speed.log", "w");
tdb_lsm_write_hook(pDb, do_speed_write_hook2, (void *)pLog);
#endif

@@ -895,7 +895,7 @@ int do_speed_tests(int nArg, char **azArg){

pLsm = configure_lsm_db(pDb);
#if 0
- pLog = fopen("/tmp/speed.log", "w");
+ pLog = fopen("@TERMUX_PREFIX_CLASSICAL@/tmp/speed.log", "w");
tdb_lsm_write_hook(pDb, do_speed_write_hook2, (void *)pLog);
#endif

diff --git a/src/os_unix.c b/src/os_unix.c
index 59f67d1..04aa8ab 100644
--- a/src/os_unix.c
+++ b/src/os_unix.c
@@ -5851,9 +5851,7 @@ static int fillInUnixFile(
static const char *azTempDirs[] = {
0,
0,
- "/var/tmp",
- "/usr/tmp",
- "/tmp",
+ "@TERMUX_PREFIX_CLASSICAL@/tmp",
"."
};

diff --git a/src/os_win.c b/src/os_win.c
index dc16c08..90b1688 100644
--- a/src/os_win.c
+++ b/src/os_win.c
@@ -4799,9 +4799,7 @@ static int winGetTempname(sqlite3_vfs *pVfs, char **pzBuf){
0, /* getenv("TMP") */
0, /* getenv("TEMP") */
0, /* getenv("USERPROFILE") */
- "/var/tmp",
- "/usr/tmp",
- "/tmp",
+ "@TERMUX_PREFIX_CLASSICAL@/tmp",
".",
0 /* List terminator */
};
diff --git a/tool/lemon.c b/tool/lemon.c
index 7804837..63f8e78 100644
--- a/tool/lemon.c
+++ b/tool/lemon.c
@@ -3551,7 +3551,7 @@ PRIVATE char *pathsearch(char *argv0, char *name, int modemask)
*cp = c;
}else{
pathlist = getenv("PATH");
- if( pathlist==0 ) pathlist = ".:/bin:/usr/bin";
+ if( pathlist==0 ) pathlist = ".:@TERMUX_PREFIX@/bin";
pathbuf = (char *) malloc( lemonStrlen(pathlist) + 1 );
path = (char *)malloc( lemonStrlen(pathlist)+lemonStrlen(name)+2 );
if( (pathbuf != 0) && (path!=0) ){
4 changes: 4 additions & 0 deletions gpkg/libsqlite/sqlite-analyzer.subpackage.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
TERMUX_SUBPKG_INCLUDE="glibc/bin/sqlite3_analyzer"
TERMUX_SUBPKG_DESCRIPTION="An analysis program for sqlite3 database files"
TERMUX_SUBPKG_DEPEND_ON_PARENT=deps
TERMUX_SUBPKG_DEPENDS="tcl-glibc"
4 changes: 4 additions & 0 deletions gpkg/libsqlite/sqlite-tcl.subpackage.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
TERMUX_SUBPKG_INCLUDE="glibc/lib/sqlite*"
TERMUX_SUBPKG_DESCRIPTION="Sqlite Tcl Extension Architecture (TEA)"
TERMUX_SUBPKG_DEPEND_ON_PARENT=deps
TERMUX_SUBPKG_DEPENDS="tcl-glibc"
12 changes: 12 additions & 0 deletions gpkg/libsqlite/sqlite.subpackage.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
TERMUX_SUBPKG_INCLUDE="
glibc/bin/showdb
glibc/bin/showjournal
glibc/bin/showstat4
glibc/bin/showwal
glibc/bin/sqldiff
glibc/bin/sqlite3
glibc/share/man/man1/
"
TERMUX_SUBPKG_DESCRIPTION="Command line shell for SQLite"
TERMUX_SUBPKG_DEPEND_ON_PARENT=deps
TERMUX_SUBPKG_DEPENDS="readline-glibc"
8 changes: 8 additions & 0 deletions gpkg/libtasn1/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
TERMUX_PKG_HOMEPAGE=https://www.gnu.org/software/libtasn1/
TERMUX_PKG_DESCRIPTION="This is GNU Libtasn1, a small ASN.1 library"
TERMUX_PKG_LICENSE="LGPL-2.1"
TERMUX_PKG_MAINTAINER="@termux-pacman"
TERMUX_PKG_VERSION=4.19.0
TERMUX_PKG_SRCURL=https://ftp.gnu.org/gnu/libtasn1/libtasn1-${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_SHA256=1613f0ac1cf484d6ec0ce3b8c06d56263cc7242f1c23b30d82d23de345a63f7a
TERMUX_PKG_DEPENDS="glibc"
14 changes: 14 additions & 0 deletions gpkg/p11-kit/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
TERMUX_PKG_HOMEPAGE="https://p11-glue.github.io/p11-glue/p11-kit.html"
TERMUX_PKG_DESCRIPTION="Provides a way to load and enumerate PKCS#11 modules"
TERMUX_PKG_LICENSE="BSD 3-Clause"
TERMUX_PKG_MAINTAINER="@termux-pacman"
TERMUX_PKG_VERSION=0.25.0
TERMUX_PKG_SRCURL="https://github.com/p11-glue/p11-kit/releases/download/$TERMUX_PKG_VERSION/p11-kit-$TERMUX_PKG_VERSION.tar.xz"
TERMUX_PKG_SHA256=d55583bcdde83d86579cabe3a8f7f2638675fef01d23cace733ff748fc354706
TERMUX_PKG_DEPENDS="libffi-glibc, libtasn1-glibc"
TERMUX_PKG_BUILD_DEPENDS="bash-completion-glibc"
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
--disable-static
--with-trust-paths=$TERMUX_PREFIX/etc/ca-certificates/trust-source:$TERMUX_PREFIX/share/ca-certificates/trust-source
"

52 changes: 52 additions & 0 deletions gpkg/tcl/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
TERMUX_PKG_HOMEPAGE=https://www.tcl.tk/
TERMUX_PKG_DESCRIPTION="Powerful but easy to learn dynamic programming language"
TERMUX_PKG_LICENSE="custom"
TERMUX_PKG_LICENSE_FILE="../license.terms"
TERMUX_PKG_MAINTAINER="@termux-pacman"
TERMUX_PKG_VERSION=8.6.13
TERMUX_PKG_SRCURL=https://downloads.sourceforge.net/project/tcl/Tcl/${TERMUX_PKG_VERSION}/tcl${TERMUX_PKG_VERSION}-src.tar.gz
TERMUX_PKG_SHA256=43a1fae7412f61ff11de2cfd05d28cfc3a73762f354a417c62370a54e2caf066
TERMUX_PKG_DEPENDS="zlib-glibc, gcc-glibc-libs-dev"
TERMUX_PKG_BUILD_IN_SRC=true
TERMUX_PKG_NO_STATICSPLIT=true
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
--mandir=$TERMUX_PREFIX/share/man
--enable-man-symlinks
--enable-threads
--enable-64bit
"

termux_step_pre_configure() {
rm -rf $TERMUX_PKG_SRCDIR/pkgs/sqlite3* # libsqlite-tcl is a separate package
TERMUX_PKG_SRCDIR=$TERMUX_PKG_SRCDIR/unix
}

termux_step_post_make_install() {
# expect needs private headers
make install-private-headers

ln -sf tclsh${TERMUX_PKG_VERSION%.*} $TERMUX_PREFIX/bin/tclsh
ln -sf libtcl${TERMUX_PKG_VERSION%.*}.so $TERMUX_PREFIX/lib/libtcl.so
install -Dm644 $TERMUX_PKG_SRCDIR/tcl.m4 -t $TERMUX_PREFIX/share/aclocal
chmod 644 $TERMUX_PREFIX/lib/libtclstub8.6.a

# remove buildroot traces
local _tclver=8.6
sed -e "s#$TERMUX_PKG_BUILDDIR#$TERMUX_PREFIX/lib#" \
-e "s#$TERMUX_PKG_BUILDDIR#$TERMUX_PREFIX/include#" \
-e "s#'{$TERMUX_PREFIX/lib} '#'$TERMUX_PREFIX/lib/tcl$_tclver'#" \
-i $TERMUX_PREFIX/lib/tclConfig.sh

local tdbcver=tdbc1.1.5
sed -e "s#$TERMUX_PKG_BUILDDIR/pkgs/$tdbcver#$TERMUX_PREFIX/lib/$tdbcver#" \
-e "s#$TERMUX_PKG_BUILDDIR/pkgs/$tdbcver/generic#$TERMUX_PREFIX/include#" \
-e "s#$TERMUX_PKG_BUILDDIR/pkgs/$tdbcver/library#$TERMUX_PREFIX/lib/tcl${TERMUX_PKG_VERSION%.*}#" \
-e "s#$TERMUX_PKG_BUILDDIR/pkgs/$tdbcver#$TERMUX_PREFIX/include#" \
-i $TERMUX_PREFIX/lib/$tdbcver/tdbcConfig.sh

local itclver=itcl4.2.3
sed -e "s#$TERMUX_PKG_BUILDDIR/pkgs/$itclver#$TERMUX_PREFIX/lib/$itclver#" \
-e "s#$TERMUX_PKG_BUILDDIR/pkgs/$itclver/generic#$TERMUX_PREFIX/include#" \
-e "s#$TERMUX_PKG_BUILDDIR/pkgs/$itclver#$TERMUX_PREFIX/include#" \
-i $TERMUX_PREFIX/lib/$itclver/itclConfig.sh
}