new package: libiodbc
This commit is contained in:
parent
a190390bb7
commit
dcb185c626
12
packages/libiodbc/build.sh
Normal file
12
packages/libiodbc/build.sh
Normal file
@ -0,0 +1,12 @@
|
||||
TERMUX_PKG_HOMEPAGE=http://www.iodbc.org/
|
||||
TERMUX_PKG_DESCRIPTION="Independent Open DataBase Connectivity for Linux, MacOS X and Unix systems"
|
||||
TERMUX_PKG_LICENSE="LGPL-2.0, BSD 3-Clause"
|
||||
TERMUX_PKG_LICENSE_FILE="LICENSE, LICENSE.BSD, LICENSE.LGPL"
|
||||
TERMUX_PKG_MAINTAINER="@termux"
|
||||
TERMUX_PKG_VERSION=3.52.15
|
||||
TERMUX_PKG_SRCURL=https://github.com/openlink/iODBC/releases/download/v${TERMUX_PKG_VERSION}/libiodbc-${TERMUX_PKG_VERSION}.tar.gz
|
||||
TERMUX_PKG_SHA256=c74541e3327fc9a1c7ccf103645471c67bc014542d70f572476eb07c0b2dd43c
|
||||
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
|
||||
--disable-libodbc
|
||||
--with-layout=gnu
|
||||
"
|
13
packages/libiodbc/include-sqlext.h.patch
Normal file
13
packages/libiodbc/include-sqlext.h.patch
Normal file
@ -0,0 +1,13 @@
|
||||
--- a/include/sqlext.h
|
||||
+++ b/include/sqlext.h
|
||||
@@ -476,8 +476,8 @@
|
||||
#define SQL_OPT_TRACE_FILE_DEFAULT "\\SQL.LOG"
|
||||
#define SQL_OPT_TRACE_FILE_DEFAULTW L"\\SQL.LOG"
|
||||
#else
|
||||
-#define SQL_OPT_TRACE_FILE_DEFAULT "/tmp/odbc.log"
|
||||
-#define SQL_OPT_TRACE_FILE_DEFAULTW L"/tmp/odbc.log"
|
||||
+#define SQL_OPT_TRACE_FILE_DEFAULT "@TERMUX_PREFIX@/tmp/odbc.log"
|
||||
+#define SQL_OPT_TRACE_FILE_DEFAULTW L"@TERMUX_PREFIX@/tmp/odbc.log"
|
||||
#endif
|
||||
|
||||
|
24
packages/libiodbc/iodbcinst-SQLInstallDriver.c.patch
Normal file
24
packages/libiodbc/iodbcinst-SQLInstallDriver.c.patch
Normal file
@ -0,0 +1,24 @@
|
||||
--- a/iodbcinst/SQLInstallDriver.c
|
||||
+++ b/iodbcinst/SQLInstallDriver.c
|
||||
@@ -168,8 +168,8 @@
|
||||
STRNCPY (lpszPath, "/boot/beos/system/lib", cbPathMax - 1);
|
||||
if (STRLEN (lpszPath) != STRLEN ("/boot/beos/system/lib"))
|
||||
#else
|
||||
- STRNCPY (lpszPath, "/usr/local/lib", cbPathMax - 1);
|
||||
- if (STRLEN (lpszPath) != STRLEN ("/usr/local/lib"))
|
||||
+ STRNCPY (lpszPath, "@TERMUX_PREFIX@/local/lib", cbPathMax - 1);
|
||||
+ if (STRLEN (lpszPath) != STRLEN ("@TERMUX_PREFIX@/local/lib"))
|
||||
#endif
|
||||
{
|
||||
PUSH_ERROR (ODBC_ERROR_INVALID_BUFF_LEN);
|
||||
@@ -182,8 +182,8 @@
|
||||
STRNCPY (lpszPath, "/boot/home/config/lib", cbPathMax - 1);
|
||||
if (STRLEN (lpszPath) != STRLEN ("/boot/home/config/lib"))
|
||||
#else
|
||||
- STRNCPY (lpszPath, "/usr/lib", cbPathMax - 1);
|
||||
- if (STRLEN (lpszPath) != STRLEN ("/usr/lib"))
|
||||
+ STRNCPY (lpszPath, "@TERMUX_PREFIX@/lib", cbPathMax - 1);
|
||||
+ if (STRLEN (lpszPath) != STRLEN ("@TERMUX_PREFIX@/lib"))
|
||||
#endif
|
||||
{
|
||||
PUSH_ERROR (ODBC_ERROR_INVALID_BUFF_LEN);
|
26
packages/libiodbc/iodbcinst-SQLInstallDriverEx.c.patch
Normal file
26
packages/libiodbc/iodbcinst-SQLInstallDriverEx.c.patch
Normal file
@ -0,0 +1,26 @@
|
||||
--- a/iodbcinst/SQLInstallDriverEx.c
|
||||
+++ b/iodbcinst/SQLInstallDriverEx.c
|
||||
@@ -155,9 +155,9 @@
|
||||
goto done;
|
||||
}
|
||||
#else
|
||||
- if (access ("/usr/local/lib", R_OK | W_OK | X_OK) == 0)
|
||||
+ if (access ("@TERMUX_PREFIX@/local/lib", R_OK | W_OK | X_OK) == 0)
|
||||
{
|
||||
- len = STRLEN ("/usr/local/lib");
|
||||
+ len = STRLEN ("@TERMUX_PREFIX@/local/lib");
|
||||
goto done;
|
||||
}
|
||||
#endif
|
||||
@@ -169,9 +169,9 @@
|
||||
goto done;
|
||||
}
|
||||
#else
|
||||
- if (access ("/usr/lib", R_OK | W_OK | X_OK) == 0)
|
||||
+ if (access ("@TERMUX_PREFIX@/lib", R_OK | W_OK | X_OK) == 0)
|
||||
{
|
||||
- len = STRLEN ("/usr/lib");
|
||||
+ len = STRLEN ("@TERMUX_PREFIX@/lib");
|
||||
goto done;
|
||||
}
|
||||
#endif
|
Loading…
Reference in New Issue
Block a user