-Source0: ftp://ftp.sourceforge.net/pub/sourceforge/firebird/%{name}-%{version}.src.tar.gz
-Source1: ftp://ftp.sourceforge.net/pub/sourceforge/firebird/bootkit-%{version}.tar.gz
-Source2: http://www.ibphoenix.com/downloads/60All.zip
-Source3: http://www.ibphoenix.com/downloads/ib_4_0_docs.tar.gz
-Source4: http://www.ibphoenix.com/downloads/isc_docs.zip
-# missing isc4.gbak generated by: make isql || : ; make gdef gsec secutity_db
-Source5: %{name}-isc4.gbak
-# missing save.c generated by gpre after building pixar w/o save.o and then other stuff
-Patch0: %{name}-bootkit-missing.patch
-# dirty "fixes" for missing error contants and conflict with isql from unixODBC
-Patch1: %{name}-fix.patch
-# ksh supports only [! ] globs, not [^ ]
-Patch2: %{name}-ksh.patch
-URL: http://firebird.sourceforge.net/
-BuildRequires: unzip
-Requires: %{name}-lib = %{version}
+Source0: http://dl.sourceforge.net/firebird/Firebird-%{version}-0.tar.bz2
+# Source0-md5: e663417416b4dc808d6ace991e6b783f
+Source1: http://www.firebirdsql.org/pdfmanual/Firebird-2.0-QuickStart.pdf
+# Source1-md5: 676e5b294a04e3cd12b9298a776e19eb
+Source2: http://www.firebirdsql.org/pdfmanual/Using-Firebird_(wip).pdf
+# Source2-md5: 9eb90583c200bdd7292a80ecc1df1178
+Source3: http://www.firebirdsql.org/pdfmanual/Firebird-Null-Guide.pdf
+# Source3-md5: d1f8ba75fe3bb9eb9d203ce3f82a1a1a
+Source4: http://www.firebirdsql.org/pdfmanual/Firebird-Generator-Guide.pdf
+# Source4-md5: 44e7568ef477072a8ad5f381c3e12a75
+Source5: http://www.firebirdsql.org/pdfmanual/MSSQL-to-Firebird.pdf
+# Source5-md5: 1bd4a168e550910fc899e2aa125d83a3
+Source6: http://www.firebirdsql.org/pdfmanual/Firebird-nbackup.pdf
+# Source6-md5: 7ef8a8b9a899d06bec2a5da0bb5fea0e
+Source7: http://www.firebirdsql.org/pdfmanual/Firebird-Utils-WIP.pdf
+# Source7-md5: 39b9a4f3c9d9e27d985e9277ae163ceb
+Source8: http://www.firebirdnews.org/docs/fb2min.pdf
+# Source8-md5: ebac312c0afbe97b1850bdc74c553c28
+Source9: http://www.firebirdsql.org/doc/contrib/fb_2_0_errorcodes.pdf
+# Source9-md5: 2acf2ff63c4ba3a1c590989e19bb253e
+Source100: firebird.init
+Source101: firebird.sysconfig
+Source102: firebird.inetd
+Patch0: %{name}-chmod.patch
+Patch1: %{name}-editline.patch
+Patch2: %{name}-va.patch
+Patch3: %{name}-morearchs.patch
+Patch4: %{name}-gcc4.patch
+Patch5: %{name}-fix-os-detection.dpatch
+Patch6: %{name}-fix-pthreads-detect.dpatch
+Patch7: %{name}-link-with-g++.dpatch
+Patch8: %{name}-no-custom-errno-and-sys_XXerrXX.dpatch
+Patch9: %{name}-opt-bypass-redundant-sort.dpatch
+Patch10: %{name}-security-remote-preauth-crash.dpatch
+Patch11: %{name}-separate-file-and-sem-perms.dpatch
+Patch12: %{name}-ppc.patch
+Patch13: %{name}-64bit.patch
+URL: http://www.firebirdsql.org/
+BuildRequires: autoconf
+BuildRequires: automake
+BuildRequires: bison
+BuildRequires: libicu-devel
+BuildRequires: libstdc++-devel
+BuildRequires: libtool
+BuildRequires: ncurses-devel
+BuildRequires: psmisc >= 22.5-2
+BuildRequires: rpmbuild(macros) >= 1.268
+Requires: %{name}-lib = %{version}-%{release}
+%if %{with ss}
+Requires(post,preun): /sbin/chkconfig
+Requires: rc-scripts
+%endif
+# 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} %{x8664} sparc sparcv9 alpha ppc