summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2024-07-24 10:37:26 +0000
committerCoprDistGit <infra@openeuler.org>2024-07-24 10:37:26 +0000
commit2828cc3592dd9617f7c68809291ae8447c0dfe74 (patch)
treee2f73e9a1e875cc230002fc9bfc914d38e4b0db0
parentf58ba82add50053aae3009ccbde7538113966b4a (diff)
automatic import of freetdsopeneuler24.03_LTS
-rw-r--r--.gitignore1
-rw-r--r--freetds-tds_sysdep_public.h15
-rw-r--r--freetds.spec117
-rw-r--r--sources1
4 files changed, 134 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore
index e69de29..2e6b069 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/freetds-1.4.22.tar.bz2
diff --git a/freetds-tds_sysdep_public.h b/freetds-tds_sysdep_public.h
new file mode 100644
index 0000000..02824c0
--- /dev/null
+++ b/freetds-tds_sysdep_public.h
@@ -0,0 +1,15 @@
+/*
+ * To avoid multiarch conflicts, we differentiate the 32/64 bit length
+ * specific header names. This file is a wrapper to include the proper
+ * arch-specific header at compile time.
+ */
+
+#include <bits/wordsize.h>
+
+#if __WORDSIZE == 32
+#include <tds_sysdep_public_32.h>
+#elif __WORDSIZE == 64
+#include <tds_sysdep_public_64.h>
+#else
+#error "Unknown word size"
+#endif
diff --git a/freetds.spec b/freetds.spec
new file mode 100644
index 0000000..f3dc709
--- /dev/null
+++ b/freetds.spec
@@ -0,0 +1,117 @@
+Name: freetds
+Summary: Implementation of the TDS (Tabular DataStream) protocol
+Version: 1.4.22
+Release: 1
+License: GPL-2.0-or-later AND LGPL-2.1-or-later
+URL: https://www.freetds.org/
+
+Source0: https://www.freetds.org/files/stable/%{name}-%{version}.tar.bz2
+Source1: freetds-tds_sysdep_public.h
+
+BuildRequires: unixODBC-devel readline-devel gnutls-devel krb5-devel git
+BuildRequires: libgcrypt-devel libtool doxygen docbook-style-dsssl gperf
+
+Provides: %{name}-libs = %{version}-%{release}
+Obsoletes: %{name}-libs < %{version}-%{release}
+
+%description
+FreeTDS is an open source implementation of the TDS (Tabular
+Data Stream) protocol used by these databases for their own clients.
+It supports many different flavors of the protocol and three APIs
+to access it. FreeTDS includes call level interfaces for DB-Lib,
+CT-Lib, and ODBC.
+
+
+%package devel
+Summary: Header files and development libraries for %{name}
+Requires: %{name} = %{version}-%{release}
+
+%description devel
+This package contains the header files and development libraries
+for %{name}. If you like to develop programs using %{name}, you will need
+to install %{name}-devel.
+
+%package_help
+
+%prep
+%autosetup -p1
+
+sed -i '1 s,#!.*/perl,#!%{__perl},' samples/*.pl
+
+chmod 644 samples/*.sh
+
+%build
+
+[ -f configure ] || NOCONFIGURE=yes ./autogen.sh
+
+%configure \
+ --disable-dependency-tracking --disable-rpath --disable-static \
+ --with-tdsver="auto" --with-unixodbc="%{_prefix}" --enable-msdblib \
+ --enable-sybase-compat --with-gnutls --enable-krb5
+
+sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|' libtool
+sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_RIE|' libtool
+
+%make_build DOCBOOK_DSL="`rpm -ql docbook-style-dsssl | fgrep html/docbook.dsl`"
+
+
+%install
+
+%make_install
+
+%delete_la
+chmod -x $RPM_BUILD_ROOT%{_sysconfdir}/*
+
+mv -f $RPM_BUILD_ROOT%{_includedir}/tds_sysdep_public.h $RPM_BUILD_ROOT%{_includedir}/tds_sysdep_public_64.h
+install -p -m 644 %{S:1} $RPM_BUILD_ROOT%{_includedir}/tds_sysdep_public.h
+
+rm -f samples/{Makefile*,*.in,README}
+
+mv -f samples/unixodbc.freetds.driver.template samples/unixodbc.freetds.driver.template-64
+
+install -d samples-odbc
+mv -f samples/*odbc* samples-odbc
+
+mv -f $RPM_BUILD_ROOT%{_docdir}/%{name} docdir
+find docdir -type f -exec chmod -x {} \;
+
+%files
+%license COPYING.txt COPYING_LIB.txt
+%doc AUTHORS.md README.md samples-odbc
+%doc docdir/userguide docdir/images
+%{_bindir}/*
+%{_libdir}/*.so.*
+%{_libdir}/libtdsodbc.so
+%config(noreplace) %{_sysconfdir}/*.conf
+
+
+%files devel
+%doc samples
+%{_libdir}/*.so
+%exclude %{_libdir}/libtdsodbc.so
+%{_includedir}/*
+
+
+%files help
+%{_mandir}/man?/*
+%doc docdir/reference TODO.md doc/*.html NEWS.md
+
+
+%changelog
+* Wed Jul 24 2024 Funda Wang <fundawang@yeah.net> - 1.4.22-1
+- Update to version 1.4.22
+
+* Tue Dec 05 2023 Ge Wang <wang__ge@126.com> - 1.4.9-1
+- Update to version 1.4.9
+
+* Tue Oct 17 2023 wangkai <13474090681@163.com> - 1.4.3-1
+- Update to 1.4.3
+
+* Sat Nov 12 2022 hua <dchang@zhixundn.com> - 1.3.4-1
+- update to 1.3.4
+
+* Wed Feb 09 2022 wangkai <wangkai385@huawei.com> - 1.00.38-8
+- Fix CVE-2019-13508
+
+* Thu Nov 28 2019 Wanjiankang <wanjiankang@huawei.com> - 1.00.38-7
+- Initial package.
diff --git a/sources b/sources
new file mode 100644
index 0000000..e4631e2
--- /dev/null
+++ b/sources
@@ -0,0 +1 @@
+bad20df14b23b385d2ce6a180955f8a4 freetds-1.4.22.tar.bz2