# # spec file for package gdbm # # Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # Name: gdbm %define lname libgdbm4 Url: http://www.gnu.org.ua/software/gdbm/ #!BuildIgnore: man # bug437293 %ifarch ppc64 Obsoletes: gdbm-64bit %endif # Version: 1.11 Release: 3.1.2 Summary: GNU dbm key/data database License: GPL-3.0+ Group: System/Libraries Source: ftp://prep.ai.mit.edu/gnu/gdbm/gdbm-%{version}.tar.gz Source2: baselibs.conf # ENHANCE-FOR-UPSTREM i@marguerite.su - add zh_CN translation. And I'll submit it to upstream. Source3: zh_CN.gmo # FIX-FOR-UPSTREAM i@marguerite.su - remove the build date from src/version.c Patch4: gdbm-no-build-date.patch BuildRequires: autoconf >= 2.63 BuildRequires: automake >= 1.11 BuildRequires: libtool BuildRequires: makeinfo BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildArch: i486 %description GNU dbm is a library of database functions that use extensible hashing and work similar to the standard UNIX dbm. These routines are provided to a programmer needing to create and manipulate a hashed database. The basic use of GDBM is to store key/data pairs in a data file. Each key must be unique and each key is paired with only one data item. The library provides primitives for storing key/data pairs, searching and retrieving the data by its key and deleting a key along with its data. It also supports sequential iteration over all key/data pairs in a database. For compatibility with programs using old UNIX dbm functions, the package also provides traditional dbm and ndbm interfaces. %package -n %lname Summary: GNU dbm key/data database License: GPL-3.0+ Group: System/Libraries # O/P added in 12.2 Obsoletes: gdbm < %{version}-%{release} Provides: gdbm = %{version}-%{release} %description -n %lname GNU dbm is a library of database functions that use extensible hashing and work similar to the standard UNIX dbm. These routines are provided to a programmer needing to create and manipulate a hashed database. The basic use of GDBM is to store key/data pairs in a data file. Each key must be unique and each key is paired with only one data item. The library provides primitives for storing key/data pairs, searching and retrieving the data by its key and deleting a key along with its data. It also supports sequential iteration over all key/data pairs in a database. For compatibility with programs using old UNIX dbm functions, the package also provides traditional dbm and ndbm interfaces. %package devel Summary: Include Files and Libraries mandatory for Development License: GPL-3.0+ and LGPL-2.1+ Group: Development/Libraries/C and C++ #Requires(pre): %install_info_prereq Requires: gdbm = %{version} Provides: gdbm:/usr/lib/libgdbm.so # bug437293 %ifarch ppc64 Obsoletes: gdbm-devel-64bit %endif # %description devel This package contains all necessary include files and libraries needed to develop applications that require these. %prep %setup -q %patch4 %build aclocal autoreconf --force --install %ifarch sparc64 export CC="gcc -m64" %endif export CFLAGS="%{optflags} -Wa,--noexecstack" %configure --enable-libgdbm-compat make %{?_smp_mflags}; %install %make_install echo "/* GNU ld script Use the shared library, but some functions are only in the static library, so try that secondarily. */ GROUP ( %{_libdir}/libgdbm.so %{_libdir}/libgdbm_compat.so )" > %{buildroot}/%{_libdir}/libndbm.so echo "/* GNU ld script Use the shared library, but some functions are only in the static library, so try that secondarily. */ GROUP ( %{_libdir}/libgdbm.a %{_libdir}/libgdbm_compat.a )" > %{buildroot}/%{_libdir}/libndbm.a mkdir -p %{buildroot}%{_datadir}/locale/zh_CN/LC_MESSAGES/ cp -r %{SOURCE3} %{buildroot}%{_datadir}/locale/zh_CN/LC_MESSAGES/%{name}.mo %find_lang %{name} %post -n %lname -p /sbin/ldconfig %postun -n %lname -p /sbin/ldconfig %files -n %lname -f %{name}.lang %defattr(-,root,root) %doc COPYING README NEWS %{_libdir}/libgdbm.so.4 %{_libdir}/libgdbm.so.4.0.0 %{_libdir}/libgdbm_compat.so.4 %{_libdir}/libgdbm_compat.so.4.0.0 %files devel %defattr(-,root,root) %{_bindir}/* %{_includedir}/dbm.h %{_includedir}/gdbm.h %{_includedir}/ndbm.h %{_infodir}/gdbm.info.gz %{_libdir}/libgdbm.a %{_libdir}/libgdbm.so %{_libdir}/libgdbm_compat.a %{_libdir}/libgdbm_compat.so %{_libdir}/libndbm.a %{_libdir}/libndbm.so %{_mandir}/man1/*.gz %{_mandir}/man3/gdbm.3.gz %exclude %{_libdir}/*.la %post devel %install_info --info-dir=%{_infodir} %{_infodir}/%{name}.info.gz %postun devel %install_info_delete --info-dir=%{_infodir} %{_infodir}/%{name}.info.gz %changelog * Mon Aug 18 2014 fcrozat@suse.com - Add obsoletes to baselibs.conf. * Mon Mar 31 2014 pgajdos@suse.com - update to 1.11: * Improved dump format. * New function: gdbm_count. * New utilities: gdbm_dump and gdbm_load. * gdbmtool * Wed Mar 6 2013 jengelh@inai.de - Specify exact version requirements for build * Mon Mar 4 2013 pgajdos@suse.com - buildrequire makeinfo * Wed Feb 6 2013 cfarrell@suse.com - license update: GPL-3.0+ See the COPYING file * Fri Feb 1 2013 coolo@suse.com - update license to new format * Mon Sep 24 2012 i@marguerite.su - update baselibs.conf * Sun Sep 23 2012 i@marguerite.su - update to 1.10 * fully internationalized. available in Finnish ,German, Japanese, Polish and Ukrainian * Support for close-on-exec flag in gdbm_open (see GDBM_CLOEXEC in the docs) * Improved testgdbm command system * Fixed Bug #150, should handle read(2) returning less data * Fixed Bug #151, uses uninitialized memory content * Fixed handling of NDBM databases in read-only mode - add zh_CN translation * manually add. will submit to upstream. - drop gdbm-1.8.3.diff (Patch0) * seems this one is useless. - regenerate and change gdbm-1.8.3-no-build-date.patch (Patch4) to gdbm-no-build-date.patch * its an universal solution no matter the version. - drop gdbm-protoize_dbm_headers.patch (Patch1) * upstream fixed. - drop gdbm-prototype_static_functions.patch (Patch2) * upstream fixed. - drop gdbm-fix_testprogs.patch (Patch3) * upstream code change. now useless. * Fri Mar 2 2012 andrea.turrini@gmail.com - Fixed typos in gdbm.spec descriptions * Tue Feb 7 2012 coolo@suse.com - fix baselibs.conf * Sun Feb 5 2012 jengelh@medozas.de - Name library package according to shlib policy - Update description, source text from GNU homepage * Sun Feb 5 2012 jengelh@medozas.de - Remove redundant tags/sections - Replace /usr/%%_lib by simpler %%_libdir * Sat Oct 1 2011 coolo@suse.com - add libtool as buildrequire to make the spec file more reliable * Tue Sep 21 2010 pgajdos@suse.cz - fixed wrong header of dbmclose() in our protoize_dbm_headers.patch [bnc#640700] * Sun Aug 29 2010 cristian.rodriguez@opensuse.org - DO not include a compile date in the resulting binaries * Mon Jun 28 2010 jengelh@medozas.de - use %%_smp_mflags * Sun Dec 13 2009 jengelh@medozas.de - add baselibs.conf as a source * Sun Dec 6 2009 jengelh@medozas.de - Enable parallel building for gdbm package * Wed Dec 10 2008 olh@suse.de - use Obsoletes: -XXbit only for ppc64 to help solver during distupgrade (bnc#437293) * Mon Nov 24 2008 olh@suse.de - obsolete old -XXbit packages (bnc#437293) * Thu Apr 10 2008 ro@suse.de - added baselibs.conf file to build xxbit packages for multilib support * Thu Feb 28 2008 pth@suse.de - Add ANSI prototypes to dbm.h and ndbm.h (protected by macros) - Provide full prototype for static function. - Fix test* apps by including appropriate headers and calling fgets instead of gets. * Wed Dec 26 2007 crrodriguez@suse.de - both libgdbm.la and libgdbm_compat.la had empty dependency_libs and has been removed. - fix library-without-ldconfig-post* errors * Wed Jan 25 2006 mls@suse.de - converted neededforbuild to BuildRequires * Wed Aug 24 2005 kukuk@suse.de - Don't reuse old temporary files in gdbm_reorganize [#105763] * Mon Aug 30 2004 schwab@suse.de - Fix uses of libtool. * Fri Nov 21 2003 kukuk@suse.de - Compile with no execstack - Build as normal user * Wed Jul 2 2003 kukuk@suse.de - Remove man from buildsystem * Mon May 12 2003 kukuk@suse.de - Use defattr * Thu Apr 24 2003 ro@suse.de - fix install_info --delete call and move from preun to postun * Fri Feb 7 2003 ro@suse.de - added install_info macros * Fri Jan 10 2003 kukuk@suse.de - Use fcntl instead of flock for locking * Mon Dec 2 2002 kukuk@suse.de - Update to gdbm 1.8.3 (lot of bug fixes) * Fri Aug 9 2002 kukuk@suse.de - Fix requires for gdbm-devel [Bug #17543] * Thu May 30 2002 olh@suse.de - use aclocal + autoreconf --force --install, fix for ppc64 * Wed Apr 17 2002 kukuk@suse.de - Remove gdbm 1.7.3 * Tue Dec 11 2001 froh@suse.de - the Makefile.in of gdbm 1.7 is missing @libdir@, instead of patching that we follow sparc64 and ia64 and just ommit gdbm 1.7 on s390x. * Thu Mar 22 2001 ro@suse.de - added split-aliases as provides * Fri Oct 27 2000 kukuk@suse.de - Create devel subpackage * Mon Sep 25 2000 kukuk@suse.de - Use BuildRoot * Thu Jun 1 2000 kukuk@suse.de - Add group tag * Tue Apr 4 2000 kukuk@suse.de - Add ltconfig fix * Tue Apr 4 2000 kukuk@suse.de - Add automake to need for build * Mon Apr 3 2000 bk@suse.de - s390 team added config.{sub,guess} update macros for s390 * Thu Feb 3 2000 schwab@suse.de - Update config.{guess,sub} to latest version. * Fri Jan 21 2000 kukuk@suse.de - Move /usr/{info,man} -> /usr/share/{info,man} * Mon Oct 18 1999 kukuk@suse.de - gdbm 1.8.0: Fix memory leak * Mon Sep 13 1999 bs@suse.de - ran old prepare_spec on spec file to switch to new prepare_spec. * Fri Aug 27 1999 kukuk@suse.de - Fix file list * Thu Aug 26 1999 kukuk@suse.de - Add libgdbm 1.8.0 as default * Mon Jun 28 1999 kukuk@suse.de - Add libndbm.so and libndbm.a link * Mon Mar 1 1999 ro@suse.de - added ndbm.h for glibc-2.1 * Mon Feb 22 1999 ro@suse.de - link explicitly with -lc * Fri Dec 18 1998 ro@suse.de - respect alpha in specfile * Mon Dec 7 1998 ro@suse.de - pack ndbm.h only for libc5 * Mon Oct 20 1997 ro@suse.de - ready for autobuild * Thu Jan 2 1997 florian@suse.de - add ndbm.h header files