X-Git-Url: http://git.pld-linux.org/?p=packages%2FFirebird.git;a=blobdiff_plain;f=Firebird.spec;h=bd8536e52bb1fdf544654897bd593ee0331e5c29;hp=d461c8233707d85689166b5d6de1f8f1805c239e;hb=94aa4dfabe7110cdf90d0b1cc1735cbe1b233b45;hpb=b57d2c21f8ea772a8ae558012ee35fba7855a598 diff --git a/Firebird.spec b/Firebird.spec index d461c82..bd8536e 100644 --- a/Firebird.spec +++ b/Firebird.spec @@ -1,6 +1,11 @@ -# TODO: kill unaligned accesses (create_db,gpre_current,gbak_static,isql_static) on alpha +# TODO: +# - kill unaligned accesses (create_db,gpre_current,gbak_static,isql_static) on alpha +# - create classic server/super server subpackaged and drop bcond +# (see firebird2 on debian how to do it) +%bcond_with ss # Super Server Summary: Firebird SQL Database Server and Client tools Summary(pl): Firebird - serwer baz danych SQL oraz narzêdzia klienckie +Summary(de): Firebird - relationalen Open-Source- Datenbankmanagementsystems Name: Firebird # FirebirdCS/FirebirdSS (Classic Server/Super Server)? Version: 1.5.2.4731 @@ -15,6 +20,9 @@ Source2: http://www.ibphoenix.com/downloads/ib_4_0_docs.tar.gz # Source2-md5: f4176d5dec952ee774bb8ee74c1f715d Source3: http://www.ibphoenix.com/downloads/isc_docs.zip # Source3-md5: 66eef71c188215d10988788282c014a7 +Source4: firebird.init +Source5: firebird.sysconfig +Source6: firebird.inetd Patch0: %{name}-chmod.patch Patch1: %{name}-editline.patch Patch2: %{name}-env-overflows.patch @@ -26,12 +34,13 @@ BuildRequires: automake BuildRequires: libtool BuildRequires: libstdc++-devel BuildRequires: ncurses-devel +BuildRequires: rpmbuild(macros) >= 1.213 BuildRequires: unzip Requires: %{name}-lib = %{version}-%{release} -# official ports are x86, sparc and amd64 +# official ports are x86, sparc and x86_64 # alpha and ppc added in morearchs patch # see morearchs patch if you want to add support for more archs -ExclusiveArch: %{ix86} amd64 sparc sparcv9 alpha ppc +ExclusiveArch: %{ix86} %{x8664} sparc sparcv9 alpha ppc BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) %define ibdir %{_libdir}/interbase @@ -47,6 +56,19 @@ Firebird jest pot danych zaprojektowanym do osadzania w aplikacjach na wielu platformach. +%description -l de +Firebird ist der Open-Source-Spin-Off des weiterhin kommerziell von +Borland vertriebenen relationalen Datenbankmanagementsystemes +InterBase. Die Abspaltung erfolgte im Jahre 2000 als kurz vor Freigabe +der Version 6 des kommerziellen Vorgängers Interbase bei Borland +ernsthafte Überlegungen im Gange waren, die Weiterentwicklung +einzustellen. + +Aus Interbase 6.0 wurde Firebird 1.0, wobei dies als eine +Bugfix-Version mit nur wenigen Erweiterungen angesehen werden kann. +Eine Erweiterung von Firebird 1.0 ist der 64-Bit File I/O, so dass +auch Datenbankdateien über 2GB erzeugt werden können. + %package lib Summary: Firebird shared library Summary(pl): Biblioteka wspó³dzielona Firebird @@ -119,13 +141,13 @@ cd ../../.. %{__autoconf} %configure \ + %{?with_ss:--enable-superserver} \ --prefix=%{ibdir} \ %{?debug:--enable-debug} -# --enable-superserver # OPTFLAGS for editline export OPTFLAGS="%{rpmcflags}" -%ifarch amd64 +%ifarch %{x8664} DARCH="-DAMD64" %else %ifarch sparc sparcv9 @@ -148,8 +170,10 @@ rm -rf $RPM_BUILD_ROOT %{__make} -C src -f ../gen/Makefile.install buildImageDir +install -d $RPM_BUILD_ROOT/etc/{rc.d/init.d,sysconfig/rc-inetd} install -d $RPM_BUILD_ROOT{%{ibdir},%{_libdir},%{_includedir}} \ $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version} + install gen/firebird/lib/libfb*.a $RPM_BUILD_ROOT%{_libdir} cd gen/buildroot/%{ibdir} @@ -165,9 +189,40 @@ ln -sf libfbclient.so.1 $RPM_BUILD_ROOT%{_libdir}/libgds.so ln -sf libfbstatic.a $RPM_BUILD_ROOT%{_libdir}/libgds.a +install %{SOURCE4} $RPM_BUILD_ROOT/etc/rc.d/init.d/firebird +install %{SOURCE5} $RPM_BUILD_ROOT/etc/sysconfig/firebird +install %{SOURCE6} $RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/firebird %clean rm -rf $RPM_BUILD_ROOT +%pre +%groupadd -g 145 firebird +%useradd -u 145 -d %{ibdir} -s /bin/sh -g firebird -c "Firebird Server" firebird + +%if %{with ss} +%post +/sbin/chkconfig --add firebird +if [ -f /var/lock/subsys/firebird ]; then + /etc/rc.d/init.d/firebird restart >&2 +else + echo "Run \"/etc/rc.d/init.d/firebird start\" to start firebird." >&2 +fi + +%preun +if [ "$1" = "0" ]; then + if [ -f /var/lock/subsys/firebird ]; then + /etc/rc.d/init.d/firebird stop + fi + /sbin/chkconfig --del firebird +fi +%endif + +%postun +if [ "$1" = "0" ]; then + %userremove firebird + %groupremove firebird +fi + %post lib -p /sbin/ldconfig %postun lib -p /sbin/ldconfig @@ -186,6 +241,12 @@ rm -rf $RPM_BUILD_ROOT %{ibdir}/security.fdb %{ibdir}/aliases.conf %{ibdir}/firebird.conf +%if %{with ss} +%attr(754,root,root) /etc/rc.d/init.d/firebird +%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/firebird +%else +%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/rc-inetd/firebird +%endif %files lib %defattr(644,root,root,755)