[keepassx/f17] fix FTBFS

Tom Callaway spot at fedoraproject.org
Fri Mar 30 22:20:49 UTC 2012


commit 92d28f875b73335b536d70f8c8a025b5d6a4f4be
Author: Tom Callaway <spot at fedoraproject.org>
Date:   Fri Mar 30 18:20:43 2012 -0400

    fix FTBFS

 keepassx-0.4.3-gcc47.patch |   11 +++++++++++
 keepassx.spec              |   22 ++++++----------------
 2 files changed, 17 insertions(+), 16 deletions(-)
---
diff --git a/keepassx-0.4.3-gcc47.patch b/keepassx-0.4.3-gcc47.patch
new file mode 100644
index 0000000..6593505
--- /dev/null
+++ b/keepassx-0.4.3-gcc47.patch
@@ -0,0 +1,11 @@
+diff -up keepassx-0.4.3/src/lib/random.cpp.gcc47 keepassx-0.4.3/src/lib/random.cpp
+--- keepassx-0.4.3/src/lib/random.cpp.gcc47	2012-03-30 18:17:25.913476536 -0400
++++ keepassx-0.4.3/src/lib/random.cpp	2012-03-30 18:17:33.346409646 -0400
+@@ -20,6 +20,7 @@
+ 
+ #include "random.h"
+ #include <cstdlib>
++#include <unistd.h>
+ 
+ 
+ #if defined(Q_WS_X11) || defined(Q_WS_MAC)
diff --git a/keepassx.spec b/keepassx.spec
index d4fccf8..5c67962 100644
--- a/keepassx.spec
+++ b/keepassx.spec
@@ -1,17 +1,14 @@
 Name:           keepassx
 Version:        0.4.3
-Release:        4%{?dist}
+Release:        5%{?dist}
 Summary:        Cross-platform password manager
-
 Group:          User Interface/Desktops
 License:        GPLv2+
 URL:            http://keepassx.sourceforge.net
 Source0:        http://download.sf.net/keepassx/keepassx-%{version}.tar.gz
 Patch1:         keepassx-0.3.3-gcc43.patch
-BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
-
+Patch2:         keepassx-0.4.3-gcc47.patch
 BuildRequires:  qt4-devel > 4.1, libXtst-devel, ImageMagick, desktop-file-utils
-
 Requires:       hicolor-icon-theme
 
 %description
@@ -31,11 +28,10 @@ Twofish encryption algorithm using a 256 bit key. Therefore the saved
 information can be considered as quite safe. KeePassX uses a database format
 that is compatible with KeePass Password Safe for MS Windows.
 
-
 %prep
 %setup -q
 %patch1 -p0 -b .gcc43
-
+%patch2 -p1 -b .gcc47
 
 %build
 export CFLAGS=$RPM_OPT_FLAGS
@@ -43,9 +39,7 @@ export CXXFLAGS=$RPM_OPT_FLAGS
 qmake-qt4 PREFIX=%{_prefix}
 make %{?_smp_mflags}
 
-
 %install
-rm -rf $RPM_BUILD_ROOT
 make install INSTALL_ROOT=$RPM_BUILD_ROOT
 
 # Use png in _datadir/icons/hicolor instead of xpm in pixmaps
@@ -93,13 +87,7 @@ update-mime-database %{_datadir}/mime &> /dev/null || :
 %posttrans
 gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
 
-
-%clean
-rm -rf $RPM_BUILD_ROOT
-
-
 %files
-%defattr(-,root,root,-)
 %doc share/keepassx/license.html
 %{_bindir}/keepassx
 %{_datadir}/keepassx
@@ -108,8 +96,10 @@ rm -rf $RPM_BUILD_ROOT
 %{_datadir}/mime/packages/*.xml
 %{_datadir}/icons/hicolor/*/apps/keepassx.png
 
-
 %changelog
+* Fri Mar 30 2012 Tom Callaway <spot at fedoraproject.org> - 0.4.3-5
+- fix FTBFS on gcc 4.7
+
 * Tue Feb 28 2012 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 0.4.3-4
 - Rebuilt for c++ ABI breakage
 


More information about the scm-commits mailing list