%define name metakit %define version 2.4.9.7 %define release %mkrel 4 %define major 1 %define libname %mklibname %{name} %{major} %define soname libmk4.so.1 Summary: Embeddable database Name: %{name} Version: %{version} Release: %{release} License: GPL Group: System/Libraries BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot Source: http://www.equi4.com/pub/mk/%{name}-%{version}.tar.gz Patch0: metakit-2.4.9.7-flags.patch Patch1: metakit-2.4.9.6-alt-soname.patch URL: http://www.equi4.com/metakit/ BuildRequires: tcl-devel python-devel %description MetaKit is an embeddable database which runs on Unix, Windows, Macintosh, and other platforms. It lets you build applications which store their data efficiently, in a portable way, and which will not need a complex runtime installation. In terms of the data model, MetaKit takes the middle ground between RDBMS, OODBMS, and flat-file databases - yet it is quite different from each of them. %package -n %{libname} Summary: Main library for %{name}, a embeddable database Group: System/Libraries Provides: %name = %{version}-%{release} %description -n %{libname} This package contains the library needed to run programs dynamically linked with %{name}. MetaKit is an embeddable database which runs on Unix, Windows, Macintosh, and other platforms. It lets you build applications which store their data efficiently, in a portable way, and which will not need a complex runtime installation. In terms of the data model, MetaKit takes the middle ground between RDBMS, OODBMS, and flat-file databases - yet it is quite different from each of them. %package -n %{libname}-devel Summary: Files to compile programs that will use %{name} Group: Development/C Requires: %{libname} = %{version} Provides: lib%{name}-devel = %{version}-%{release} Provides: %{name}-devel = %{version}-%{release} Provides: %libname-devel = %version-%release %description -n %{libname}-devel This package contains the headers that programmers will need to develop applications which will use %{name}. MetaKit is an embeddable database which runs on Unix, Windows, Macintosh, and other platforms. It lets you build applications which store their data efficiently, in a portable way, and which will not need a complex runtime installation. In terms of the data model, MetaKit takes the middle ground between RDBMS, OODBMS, and flat-file databases - yet it is quite different from each of them. %package -n python-%name Summary: Python bindings for %name, a embeddable database Group: System/Libraries Requires: %libname python Provides: Mk4py mk4py %name-python Obsoletes: %name-python %description -n python-%name Python bindings for %name MetaKit is an embeddable database which runs on Unix, Windows, Macintosh, and other platforms. It lets you build applications which store their data efficiently, in a portable way, and which will not need a complex runtime installation. In terms of the data model, MetaKit takes the middle ground between RDBMS, OODBMS, and flat-file databases - yet it is quite different from each of them. %package -n %name-tcl Summary: Tcl bindings for %name, a embeddable database Group: System/Libraries Requires: %libname tcl Provides: Mk4tcl mk4tcl %description -n %name-tcl Tcl bindings for %name MetaKit is an embeddable database which runs on Unix, Windows, Macintosh, and other platforms. It lets you build applications which store their data efficiently, in a portable way, and which will not need a complex runtime installation. In terms of the data model, MetaKit takes the middle ground between RDBMS, OODBMS, and flat-file databases - yet it is quite different from each of them. %prep %setup -q %patch0 -p0 %patch1 -p1 rm -rf builds/tests/CVS %build cd unix perl -pi -e "s/^CXXFLAGS.*/CXXFLAGS = $RPM_OPT_FLAGS -fPIC/" Makefile.in perl -p -i -e "s|python2.3|python%{pyver}||g" configure cd ../builds CONFIGURE_TOP="../unix" %configure2_5x --enable-python --with-python=/usr --with-tcl=/usr/include %make MK4_SONAME=%soname export LD_LIBRARY_PATH=`pwd` make test %install rm -rf %buildroot mkdir -p %buildroot/%py_sitedir %makeinstall_std -C builds MK4_SONAME=%soname if [ "%{_prefix}/lib" != "%{_libdir}" ]; then mv %buildroot%{_prefix}/lib/Mk4tcl %buildroot%{_libdir}/ fi %clean rm -rf %buildroot %if %mdkversion < 200900 %post -n %{libname} -p /sbin/ldconfig %endif %if %mdkversion < 200900 %postun -n %{libname} -p /sbin/ldconfig %endif %files -n %{libname} %defattr(-, root, root) %doc README %{_libdir}/*.so.* %files -n %{libname}-devel %defattr(-, root, root) %doc README CHANGES doc demos examples %{_libdir}/*.so %{_includedir}/* %files -n python-%name %defattr(-, root, root) %doc README %py_sitedir/Mk4py.so %py_sitedir/metakit.py %files -n %name-tcl %defattr(-, root, root) %doc doc/tcl.html doc/tcl.gif doc/e4s.gif %{_libdir}/Mk4tcl %changelog * Tue Jul 29 2008 Thierry Vignaud <tvignaud@mandriva.com> 2.4.9.7-4mdv2009.0 + Revision: 252345 - rebuild + Pixel <pixel@mandriva.com> - do not call ldconfig in %%post/%%postun, it is now handled by filetriggers * Thu Jan 03 2008 Olivier Blin <oblin@mandriva.com> 2.4.9.7-2mdv2008.1 + Revision: 140953 - restore BuildRoot + Thierry Vignaud <tvignaud@mandriva.com> - kill re-definition of %%buildroot on Pixel's request * Sun Aug 26 2007 Pascal Terjan <pterjan@mandriva.org> 2.4.9.7-2mdv2008.0 + Revision: 71486 - 2.4.9.7 - Add P1 to get again a soname (Patch from Alt) - Move tcl lib in lib64 on 64 bits - Add -fPIC - Fix build (missing -I) * Fri Nov 04 2005 Michael Scherer <misc@mandriva.org> 2.4.9.3-3mdk - fix naming of python module - enhance description - use macro - mkrel * Mon Jan 10 2005 Austin Acton <austin@mandrake.org> 2.4.9.3-2mdk - rebuild for python * Sat Jul 17 2004 Michael Scherer <misc@mandrake.org> 2.4.9.3-1mdk - New release 2.4.9.3 - rpmbuildupdate aware * Mon Apr 07 2003 Guillaume Cottenceau <gc@mandrakesoft.com> 2.4.9.2-2mdk - add another provides to the -devel * Mon Mar 31 2003 Austin Acton <aacton@yorku.ca> 2.4.9.2-1mdk - cleanup spec - update - use mklibname - add docs, demos - add python and tcl extensions - redo patch * Tue Jan 28 2003 Lenny Cartier <lenny@mandrakesoft.com> 2.4.6-3mdk - rebuild * Thu Sep 05 2002 Lenny Cartier <lenny@mandrakesoft.com> 2.4.6-2mdk - rebuild * Mon Jun 03 2002 Guillaume Cottenceau <gc@mandrakesoft.com> 2.4.6-1mdk - recompile against latest libstdc++ - new version - provide library version so that we can use dynamic library as usual * Mon Feb 18 2002 Guillaume Cottenceau <gc@mandrakesoft.com> 2.4.3-1mdk - first mdk release as a separate package (was previously inside simgear)