SHA256
1
0
forked from pool/gdbm

Accepting request 135590 from home:MargueriteSu

updated baselibs.conf. sorry I forgot it.

OBS-URL: https://build.opensuse.org/request/show/135590
OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/gdbm?expand=0&rev=23
This commit is contained in:
Ismail Dönmez
2012-09-25 13:47:24 +00:00
committed by Git OBS Bridge
parent 8db697066d
commit 6c04dfc904
13 changed files with 96 additions and 446 deletions

View File

@@ -17,7 +17,7 @@
Name: gdbm
%define lname libgdbm3
%define lname libgdbm4
Url: http://directory.fsf.org/GNU/gdbm.html
#!BuildIgnore: man
# bug437293
@@ -25,20 +25,19 @@ Url: http://directory.fsf.org/GNU/gdbm.html
Obsoletes: gdbm-64bit
%endif
#
Version: 1.8.3
Version: 1.10
Release: 0
Summary: GNU dbm key/data database
License: GPL-2.0+
Summary: GNU dbm key/data database
Group: System/Libraries
Source: ftp://prep.ai.mit.edu/gnu/gdbm/gdbm-%{version}.tar.bz2
Source: ftp://prep.ai.mit.edu/gnu/gdbm/gdbm-%{version}.tar.gz
Source2: baselibs.conf
Patch: gdbm-%{version}.dif
Patch1: gdbm-protoize_dbm_headers.patch
Patch2: gdbm-prototype_static_functions.patch
Patch3: gdbm-fix_testprogs.patch
Patch4: gdbm-1.8.3-no-build-date.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
# 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: libtool
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
GNU dbm is a library of database functions that use extensible
@@ -58,12 +57,12 @@ 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-2.0+
Summary: GNU dbm key/data database
Group: System/Libraries
# O/P added in 12.2
Obsoletes: gdbm < %version-%release
Provides: gdbm = %version-%release
Obsoletes: gdbm < %{version}-%{release}
Provides: gdbm = %{version}-%{release}
%description -n %lname
GNU dbm is a library of database functions that use extensible
@@ -83,12 +82,12 @@ 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-2.0+ ; LGPL-2.1+
Summary: Include Files and Libraries mandatory for Development
Group: Development/Libraries/C and C++
Requires(pre): %install_info_prereq
Requires: gdbm = %{version}
Provides: gdbm:/usr/lib/libgdbm.so
PreReq: %install_info_prereq
# bug437293
%ifarch ppc64
Obsoletes: gdbm-devel-64bit
@@ -99,20 +98,9 @@ Obsoletes: gdbm-devel-64bit
This package contains all necessary include files and libraries needed
to develop applications that require these.
Authors:
--------
Jason Downs <downsj@downsj.com>
Phil Nelson <phil@unicorn.wwu.edu>
%prep
%setup -q
%patch
%patch1
%patch2
%patch3
%patch4
%patch4 -p1
%build
aclocal
@@ -120,46 +108,50 @@ autoreconf --force --install
%ifarch sparc64
export CC="gcc -m64"
%endif
export CFLAGS="$RPM_OPT_FLAGS -Wa,--noexecstack"
%configure
export CFLAGS="%{optflags} -Wa,--noexecstack"
%configure --enable-libgdbm-compat
make %{?_smp_mflags};
%install
make install INSTALL_ROOT=$RPM_BUILD_ROOT
make install-compat INSTALL_ROOT=$RPM_BUILD_ROOT
%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 )" > $RPM_BUILD_ROOT/%{_libdir}/libndbm.so
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 )" > $RPM_BUILD_ROOT/%{_libdir}/libndbm.a
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
%files -n %lname -f %{name}.lang
%defattr(-,root,root)
%doc COPYING README NEWS
%_libdir/libgdbm.so.3
%_libdir/libgdbm.so.3.0.0
%_libdir/libgdbm_compat.so.3
%_libdir/libgdbm_compat.so.3.0.0
%{_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)
%{_prefix}/include/dbm.h
%{_prefix}/include/gdbm.h
%{_prefix}/include/ndbm.h
%{_bindir}/testgdbm
%{_includedir}/dbm.h
%{_includedir}/gdbm.h
%{_includedir}/ndbm.h
%{_infodir}/gdbm.info.gz
%{_prefix}/%{_lib}/libgdbm.a
%{_prefix}/%{_lib}/libgdbm.so
%{_prefix}/%{_lib}/libgdbm_compat.a
%{_prefix}/%{_lib}/libgdbm_compat.so
%{_prefix}/%{_lib}/libndbm.a
%{_prefix}/%{_lib}/libndbm.so
%{_libdir}/libgdbm.a
%{_libdir}/libgdbm.so
%{_libdir}/libgdbm_compat.a
%{_libdir}/libgdbm_compat.so
%{_libdir}/libndbm.a
%{_libdir}/libndbm.so
%{_mandir}/man3/gdbm.3.gz
%exclude %{_libdir}/*.la