diff --git a/db51-5.1.25-gcc-8.patch b/db51-5.1.25-gcc-8.patch new file mode 100644 index 0000000..d3abb8d --- /dev/null +++ b/db51-5.1.25-gcc-8.patch @@ -0,0 +1,33 @@ +diff --git a/package/berkeleydb/0002-atomic_compare_exchange.patch b/package/berkeleydb/0002-atomic_compare_exchange.patch +new file mode 100644 +index 0000000000..81e18ac96f +--- /dev/null ++++ b/package/berkeleydb/0002-atomic_compare_exchange.patch +@@ -0,0 +1,27 @@ ++Rename __atomic_compare_exchange to not clash with gcc built-in ++ ++Downloaded from ++https://src.fedoraproject.org/cgit/rpms/libdb.git/commit/?id=d6841b3b46a51db98c162347211a5a64d154ea37 ++ ++Signed-off-by: Bernd Kuhls ++ ++--- db-5.3.28/src/dbinc/atomic.h.old 2018-05-23 09:20:04.216914922 +0200 +++++ db-5.3.28/src/dbinc/atomic.h 2018-05-23 09:20:49.510057897 +0200 ++@@ -144,7 +144,7 @@ ++ #define atomic_inc(env, p) __atomic_inc(p) ++ #define atomic_dec(env, p) __atomic_dec(p) ++ #define atomic_compare_exchange(env, p, o, n) \ ++- __atomic_compare_exchange((p), (o), (n)) +++ __db_atomic_compare_exchange((p), (o), (n)) ++ static inline int __atomic_inc(db_atomic_t *p) ++ { ++ int temp; ++@@ -176,7 +176,7 @@ ++ * http://gcc.gnu.org/onlinedocs/gcc-4.1.0/gcc/Atomic-Builtins.html ++ * which configure could be changed to use. ++ */ ++-static inline int __atomic_compare_exchange( +++static inline int __db_atomic_compare_exchange( ++ db_atomic_t *p, atomic_value_t oldval, atomic_value_t newval) ++ { ++ atomic_value_t was; diff --git a/db51.spec b/db51.spec index b91a510..77cb94c 100644 --- a/db51.spec +++ b/db51.spec @@ -3,7 +3,7 @@ %define majvershort %(echo %version | cut -d . -f1-2 | tr -d .) Name: db51 Version: 5.1.25 -Release: 4mamba +Release: 5mamba Summary: The Berkeley DB database library Group: System/Libraries Vendor: openmamba @@ -16,19 +16,16 @@ Patch2: db4-jni-casting.diff Patch3: bdb-transactions.diff Patch4: btree.diff Patch5: java.diff +Patch6: db51-5.1.25-gcc-8.patch License: GPL ## AUTOBUILDREQ-BEGIN BuildRequires: glibc-devel BuildRequires: libgcc -BuildRequires: libstdc++6-devel ## AUTOBUILDREQ-END %if "%{stage1}" != "1" -BuildRequires: jpackage-utils -BuildRequires: jdk +BuildRequires: javapackages %endif BuildRequires: sharutils -#Provides: db48 -BuildRoot: %{_tmppath}/%{name}-%{version}-root %description The Berkeley Database (Berkeley DB) is a programmatic toolkit that provides embedded database support for both traditional and client/server applications. @@ -39,9 +36,6 @@ It is used by many applications, including Python and Perl, so this should be in %package -n libdb%{majvershort} Summary: The Berkeley DB database library Group: System/Libraries -Provides: libdb -Obsoletes: libdb -#Provides: libdb48 %description -n libdb%{majvershort} The Berkeley Database (Berkeley DB) is a programmatic toolkit that provides embedded database support for both traditional and client/server applications. @@ -53,7 +47,6 @@ It is used by many applications, including Python and Perl, so this should be in Summary: Tools for the managing Berkeley DB Group: System/Libraries Requires: libdb%{majvershort} = %{version}-%{release} -#Provides: libdb48-devel %description -n db%{majvershort}-tools The Berkeley Database (Berkeley DB) is a programmatic toolkit that provides embedded database support for both traditional and client/server applications. @@ -63,9 +56,6 @@ This package contains the tools for managing Berkeley DB. Summary: Development files for the Berkeley DB library. Group: Development/Libraries Requires: libdb%{majvershort} = %{version}-%{release} -Provides: libdb-devel -Obsoletes: libdb-devel -#Provides: libdb48-devel %description -n libdb%{majvershort}-devel The Berkeley Database (Berkeley DB) is a programmatic toolkit that provides embedded database support for both traditional and client/server applications. @@ -75,7 +65,6 @@ This package contains the header files, libraries, and documentation for buildin Summary: Static library files for the Berkeley DB library. Group: Development/Libraries Requires: libdb%{majvershort} = %{version}-%{release} -#Provides: libdb48-devel %description -n libdb%{majvershort}-static The Berkeley Database (Berkeley DB) is a programmatic toolkit that provides embedded database support for both traditional and client/server applications. @@ -85,9 +74,6 @@ This package contains the static library files for the Berkeley DB library. Summary: Java bindings for the Berkeley DB library Group: System/Libraries Requires: libdb%{majvershort} = %{version}-%{release} -Provides: libdb-java -Obsoletes: libdb-java -#Provides: libdb48-java %description -n libdb%{majvershort}-java Java bindings for the Berkeley DB library. @@ -99,10 +85,11 @@ Group: Documentation %description apidocs Berkeley DB API documentation. -%prep -[ "%{buildroot}" != / ] && rm -rf "%{buildroot}" +%debug_package +%prep %setup -q -n db-%{version} +%patch6 -p1 %build cd build_unix @@ -120,27 +107,25 @@ JAVA_HOME=%{_jvmdir}/jdk/ \ --prefix=%{_prefix} \ --libdir=%{_libdir} \ --datadir=%{_datadir} \ - --includedir=%{_includedir}/db-%{majver} \ - --enable-cxx \ --enable-compat185 \ + --includedir=%{_includedir}/db-%{majver} \ %if "%{stage1}" != "1" --enable-java \ %endif --with-mutex="$mutex" +# --enable-cxx \ # --program-suffix=-51 %make %install +[ "%{buildroot}" != / ] && rm -rf "%{buildroot}" cd build_unix %makeinstall # prefix=%{buildroot}%{_prefix} includedir=%{buildroot}%{_includedir} -mkdir -p %{buildroot}%{_datadir}/doc/libdb4-%{version} -mv %{buildroot}%{_prefix}/docs/* \ - %{buildroot}%{_datadir}/doc/libdb4-%{version} -rmdir %{buildroot}%{_prefix}/docs +rm -rf %{buildroot}/usr/docs/* # make this version thre system default pushd %{buildroot}%{_bindir} @@ -182,7 +167,7 @@ fi %files -n libdb%{majvershort} %defattr(-,root,root) %{_libdir}/libdb-%{majver}.so -%{_libdir}/libdb_cxx-%{majver}.so +#%{_libdir}/libdb_cxx-%{majver}.so %{_libdir}/libdb.so.%{majver} %files -n db%{majvershort}-tools @@ -198,18 +183,14 @@ fi %{_includedir}/db_cxx.h %{_libdir}/*.la %{_libdir}/libdb-%{MAJver}.so -%{_libdir}/libdb_cxx.so -%{_libdir}/libdb_cxx-%{MAJver}.so +#%{_libdir}/libdb_cxx.so +#%{_libdir}/libdb_cxx-%{MAJver}.so %{_libdir}/libdb.so %files -n libdb%{majvershort}-static %defattr(-,root,root) %{_libdir}/*.a -%files apidocs -%defattr(-,root,root) -%{_docdir}/libdb4-%{version}/* - %if "%{stage1}" != "1" %files -n libdb%{majvershort}-java %defattr(-,root,root) @@ -222,6 +203,9 @@ fi %endif %changelog +* Sun Jun 21 2020 Silvan Calarco 5.1.25-5mamba +- don't obsolete libdb + * Sat Oct 15 2011 Silvan Calarco 5.1.25-4mamba - install headers in more canonical patch %{_includedir}/db-5.1 insted of %{_includedir}/db51; add legacy symlink @@ -286,7 +270,7 @@ fi * Fri May 07 2004 Silvan Calarco 4.1.25-6qilnx - rebuild with --enable-compat185 -* Tue Sep 15 2003 Silvan Calarco 4.1.25-5qilnx +* Mon Sep 15 2003 Silvan Calarco 4.1.25-5qilnx - Added symlink /usr/include/db.h so that db4 is system default version * Tue Sep 09 2003 Silvan Calarco 4.1.25-4qilnx