raphgro pushed to qtsingleapplication (f22). "merge with master"

notifications at fedoraproject.org notifications at fedoraproject.org
Mon Apr 27 12:58:18 UTC 2015


>From 08f75b834d2e5fb6d6825ce25fd68186098162bf Mon Sep 17 00:00:00 2001
From: Raphael Groner <projects.rg at smart.ms>
Date: Sun, 26 Apr 2015 19:57:48 +0200
Subject: build for Qt5 (rhbz#1206841)


diff --git a/.gitignore b/.gitignore
index c1e01ed..01859c6 100644
--- a/.gitignore
+++ b/.gitignore
@@ -5,3 +5,4 @@ qtsingleapplication-2.6_1-opensource.tar.gz
 /LICENSE.GPL3
 /LICENSE.LGPL
 /LGPL_EXCEPTION
+/qtsingleapplication-8c2c3f0bde67e64c627c903b718bec92ace28680.tar.gz
diff --git a/qtsingleapplication.spec b/qtsingleapplication.spec
index 9e79516..57bb159 100644
--- a/qtsingleapplication.spec
+++ b/qtsingleapplication.spec
@@ -1,13 +1,13 @@
-%global commit fd22bee22274975c56f1c10d87ee9fd2c0818f83
+%global commit 8c2c3f0bde67e64c627c903b718bec92ace28680
 
 Summary:    Qt library to start applications only once per user
 Name:       qtsingleapplication
 Version:    2.6.1
-Release:    12%{?dist}
-Group:      System Environment/Libraries
+Release:    13%{?dist}
+
 License:    GPLv3 or LGPLv2 with exceptions
 URL:        http://doc.qt.digia.com/solutions/4/qtsingleapplication/qtsingleapplication.html
-Source0:    https://qt.gitorious.org/qt-solutions/qt-solutions/archive/%{commit}.tar.gz
+Source0:    https://qt.gitorious.org/qt-solutions/qt-solutions/archive/%{commit}.tar.gz#/%{name}-%{commit}.tar.gz
 # Proposed upstream in https://codereview.qt-project.org/#/c/92417/
 Source1:    qtsingleapplication.prf
 # Proposed upstream in https://codereview.qt-project.org/#/c/92416/
@@ -24,12 +24,6 @@ Patch0:     qtsingleapplication-build-qtsinglecoreapplication.patch
 # Proposed upstream in https://codereview.qt-project.org/#/c/92415/
 Patch1:     qtsingleapplication-remove-included-qtlockedfile.patch
 
-BuildRoot:  %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
-BuildRequires:  qt4-devel
-BuildRequires:  qtlockedfile-devel
-
-%{?_qt4_version:Requires: qt4%{?_isa} >= %{_qt4_version}}
-
 %description
 For some applications it is useful or even critical that they are started
 only once by any user. Future attempts to start the application should
@@ -39,19 +33,22 @@ actions, e.g. loading a file, in that instance.
 The QtSingleApplication class provides an interface to detect a running
 instance, and to send command strings to that instance.
 
-%package    devel
+BuildRequires: qt4-devel qtlockedfile-devel
+BuildRequires: qt5-qtbase-devel qtlockedfile-qt5-devel
+
+%package devel
 Summary:    Development files for %{name}
-Group:      Development/Libraries
+BuildArch:  noarch
 Requires:   %{name} = %{version}-%{release}
 Requires:   qt4-devel
 
-%description    devel
+%description devel
 This package contains libraries and header files for developing applications
 that use QtSingleApplication.
 
 %package -n qtsinglecoreapplication
 Summary:    Qt library to start applications only once per user
-Group:      System Environment/Libraries
+Requires:   qt4
 
 %description -n qtsinglecoreapplication
 For some applications it is useful or even critical that they are started
@@ -64,7 +61,7 @@ is provided, which avoids dependency on QtGui.
 
 %package -n qtsinglecoreapplication-devel
 Summary:    Development files for qtsinglecoreapplication
-Group:      Development/Libraries
+BuildArch:  noarch
 Requires:   qtsinglecoreapplication = %{version}-%{release}
 Requires:   qt4-devel
 
@@ -72,62 +69,105 @@ Requires:   qt4-devel
 This package contains libraries and header files for developing applications
 that use QtSingleCoreApplication.
 
+%package qt5
+Summary:    Qt5 library to start applications only once per user
+Requires:   qt5-qtbase
+
+%description qt5
+For some applications it is useful or even critical that they are started
+only once by any user. Future attempts to start the application should
+activate any already running instance, and possibly perform requested
+actions, e.g. loading a file, in that instance.
+
+This is a special build against Qt5.
+
+%package qt5-devel
+Summary:    Development files for %{name}-qt5
+BuildArch:  noarch
+Requires:   %{name}-qt5 = %{version}-%{release}
+Requires:   qt5-devel
+
+%description qt5-devel
+This package contains libraries and header files for developing applications
+that use QtSingleApplication with Qt5.
+
+%package -n qtsinglecoreapplication-qt5
+Summary:    Qt library to start applications only once per user (Qt5)
+Requires:   qt5-qtbase
+
+%description -n qtsinglecoreapplication-qt5
+For some applications it is useful or even critical that they are started
+only once by any user. Future attempts to start the application should
+activate any already running instance, and possibly perform requested
+actions, e.g. loading a file, in that instance.
+
+For console (non-GUI) applications, the QtSingleCoreApplication variant
+is provided, which avoids dependency on QtGui.
+
+This is a special build against Qt5.
+
+%package -n qtsinglecoreapplication-qt5-devel
+Summary:    Development files for qtsinglecoreapplication-qt5
+BuildArch:  noarch
+Requires:   qtsinglecoreapplication-qt5 = %{version}-%{release}
+Requires:   qt5-qtbase-devel
+
+%description -n qtsinglecoreapplication-qt5-devel
+This package contains libraries and header files for developing applications
+that use QtSingleCoreApplication.
+
+
 %prep
-%setup -q -n qt-solutions-qt-solutions/%{name}
+%setup -qnqt-solutions-qt-solutions/%{name}
 %patch0 -p0
 %patch1 -p0
+mkdir licenses
+cp -p %{SOURCE3} %{SOURCE4} %{SOURCE5} licenses
 
 # We already disabled bundling this extrenal library.
 # But just to make sure:
+sed -i 's,qtlockedfile\.h,QtSolutions/\0,' src/qtlocalpeer.h
 rm src/{QtLocked,qtlocked}*
 
 
 %build
 # Does not use GNU configure
 ./configure -library
-%{_qt4_qmake}
+%{qmake_qt4}
+make %{?_smp_mflags}
+mkdir qt5
+pushd qt5
+%{qmake_qt5} ..
 make %{?_smp_mflags}
+popd
 
 
 %install
-rm -rf $RPM_BUILD_ROOT
-
 # libraries
-mkdir -p $RPM_BUILD_ROOT%{_libdir}
-cp -a lib/* $RPM_BUILD_ROOT%{_libdir}
-chmod 755 $RPM_BUILD_ROOT%{_libdir}/*.so.*.*.*
+mkdir -p %{buildroot}%{_libdir}
+cp -a lib/* %{buildroot}%{_libdir}
+chmod 755 %{buildroot}%{_libdir}/*.so*
 
 # headers
-mkdir -p $RPM_BUILD_ROOT%{_includedir}/QtSolutions
-cp -a \
+for qtdir in %{_qt4_headerdir} %{_qt5_headerdir} ; do
+ d=%{buildroot}$qtdir/QtSolutions ;
+ mkdir -p $d ;
+ cp -a \
     src/qtsingleapplication.h \
     src/QtSingleApplication \
     src/qtsinglecoreapplication.h \
     src/QtSingleCoreApplication \
-    $RPM_BUILD_ROOT%{_includedir}/QtSolutions
-
-mkdir -p $RPM_BUILD_ROOT%{_qt4_datadir}/mkspecs/features
-cp -a %{SOURCE1} %{SOURCE2} $RPM_BUILD_ROOT%{_qt4_datadir}/mkspecs/features/
-
-mkdir -p $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
-cp %{SOURCE3} $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
-cp %{SOURCE4} $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
-cp %{SOURCE5} $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
-mkdir -p $RPM_BUILD_ROOT%{_docdir}/%{name}-devel-%{version}
-cp %{SOURCE3} $RPM_BUILD_ROOT%{_docdir}/%{name}-devel-%{version}
-cp %{SOURCE4} $RPM_BUILD_ROOT%{_docdir}/%{name}-devel-%{version}
-cp %{SOURCE5} $RPM_BUILD_ROOT%{_docdir}/%{name}-devel-%{version}
-mkdir -p $RPM_BUILD_ROOT%{_docdir}/qtsinglecoreapplication-%{version}
-cp %{SOURCE3} $RPM_BUILD_ROOT%{_docdir}/qtsinglecoreapplication-%{version}
-cp %{SOURCE4} $RPM_BUILD_ROOT%{_docdir}/qtsinglecoreapplication-%{version}
-cp %{SOURCE5} $RPM_BUILD_ROOT%{_docdir}/qtsinglecoreapplication-%{version}
-mkdir -p $RPM_BUILD_ROOT%{_docdir}/qtsinglecoreapplication-devel-%{version}
-cp %{SOURCE3} $RPM_BUILD_ROOT%{_docdir}/qtsinglecoreapplication-devel-%{version}
-cp %{SOURCE4} $RPM_BUILD_ROOT%{_docdir}/qtsinglecoreapplication-devel-%{version}
-cp %{SOURCE5} $RPM_BUILD_ROOT%{_docdir}/qtsinglecoreapplication-devel-%{version}
+    $d ;
+done
+
+for qtdir in %{_qt4_datadir} %{_qt5_datadir} ; do
+ d=%{buildroot}$qtdir/mkspecs/features ;
+ mkdir -p $d ;
+ cp -a %{SOURCE1} %{SOURCE2} $d ;
+done
 
 %clean
-rm -rf $RPM_BUILD_ROOT
+rm -rf %{buildroot}
 
 %post -p /sbin/ldconfig
 
@@ -138,36 +178,67 @@ rm -rf $RPM_BUILD_ROOT
 %postun -n qtsinglecoreapplication -p /sbin/ldconfig
 
 %files
-%defattr(-,root,root,-)
+%license licenses/*
 %doc README.TXT
-%doc %{_docdir}/%{name}-%{version}
-%{_qt4_libdir}/lib*SingleApplication*.so.*
+# Caution! Unversioned so file goes into -devel
+%{_qt4_libdir}/libQtSolutions_SingleApplication*.so.*
 
 %files devel
-%defattr(-,root,root,-)
-%doc doc examples
-%doc %{_docdir}/%{name}-devel-%{version}
-%{_qt4_libdir}/lib*SingleApplication*.so
+%doc doc/html/ examples/
+%{_qt4_libdir}/libQtSolutions_SingleApplication*.so
 %dir %{_qt4_headerdir}/QtSolutions/
 %{_qt4_headerdir}/QtSolutions/QtSingleApplication
 %{_qt4_headerdir}/QtSolutions/%{name}.h
 %{_qt4_datadir}/mkspecs/features/%{name}.prf
 
 %files -n qtsinglecoreapplication
-%defattr(-,root,root,-)
-%doc %{_docdir}/qtsinglecoreapplication-%{version}
-%{_qt4_libdir}/lib*SingleCoreApplication*.so.*
+%license licenses/*
+# Caution! Unversioned so file goes into -devel
+%{_qt4_libdir}/libQtSolutions_SingleCoreApplication*.so.*
 
 %files -n qtsinglecoreapplication-devel
-%defattr(-,root,root,-)
-%doc %{_docdir}/qtsinglecoreapplication-devel-%{version}
-%{_qt4_libdir}/lib*SingleCoreApplication*.so
+%{_qt4_libdir}/libQtSolutions_SingleCoreApplication*.so
 %dir %{_qt4_headerdir}/QtSolutions/
 %{_qt4_headerdir}/QtSolutions/QtSingleCoreApplication
 %{_qt4_headerdir}/QtSolutions/qtsinglecoreapplication.h
 %{_qt4_datadir}/mkspecs/features/qtsinglecoreapplication.prf
 
+%files qt5
+%license licenses/*
+%doc README.TXT
+# Caution! Unversioned so file goes into -devel
+%{_qt5_libdir}/libQt5*SingleApplication*.so.*
+
+%files qt5-devel
+%doc doc/html/ examples/
+%{_qt5_libdir}/libQt5*SingleApplication*.so
+%dir %{_qt5_headerdir}/QtSolutions/
+%{_qt5_headerdir}/QtSolutions/QtSingleApplication
+%{_qt5_headerdir}/QtSolutions/%{name}.h
+%{_qt5_datadir}/mkspecs/features/%{name}.prf
+
+%files -n qtsinglecoreapplication-qt5
+%license licenses/*
+# Caution! Unversioned so file goes into -devel
+%{_qt5_libdir}/libQt5*SingleCoreApplication*.so.*
+
+%files -n qtsinglecoreapplication-qt5-devel
+%{_qt5_libdir}/libQt5*SingleCoreApplication*.so
+%dir %{_qt5_headerdir}/QtSolutions/
+%{_qt5_headerdir}/QtSolutions/QtSingleCoreApplication
+%{_qt5_headerdir}/QtSolutions/qtsinglecoreapplication.h
+%{_qt5_datadir}/mkspecs/features/qtsinglecoreapplication.prf
+
+
 %changelog
+* Sat Apr 25 2015 Raphael Groner <projects.rg at smart.ms> - 2.6.1-13
+- use latest commit hash of dedicated folder at upstream
+- build subpackage for Qt5
+- remove deprecated spec file entries
+- use license macro and improve license patches
+- replace with new buildroot macro
+- use noarch for devel subpackages
+
 * Sun Aug 17 2014 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 2.6.1-12
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
 
diff --git a/sources b/sources
index 7e2e077..ac1eead 100644
--- a/sources
+++ b/sources
@@ -4,3 +4,4 @@
 d32239bcb673463ab874e80d47fae504  LICENSE.GPL3
 4fbd65380cdd255951079008b364516c  LICENSE.LGPL
 d48d97e7f8a2a60038b263713ce3651a  LGPL_EXCEPTION
+53d384783a6043e2321f845a7e31edbe  qtsingleapplication-8c2c3f0bde67e64c627c903b718bec92ace28680.tar.gz
-- 
cgit v0.10.2


>From 72c6b576facb2b73e7ed4daa7cbcb96ecdc1d196 Mon Sep 17 00:00:00 2001
From: Raphael Groner <projects.rg at smart.ms>
Date: Sun, 26 Apr 2015 20:18:08 +0200
Subject: revert noarch, fix bogus changelog


diff --git a/qtsingleapplication.spec b/qtsingleapplication.spec
index 57bb159..f022514 100644
--- a/qtsingleapplication.spec
+++ b/qtsingleapplication.spec
@@ -38,7 +38,6 @@ BuildRequires: qt5-qtbase-devel qtlockedfile-qt5-devel
 
 %package devel
 Summary:    Development files for %{name}
-BuildArch:  noarch
 Requires:   %{name} = %{version}-%{release}
 Requires:   qt4-devel
 
@@ -61,7 +60,6 @@ is provided, which avoids dependency on QtGui.
 
 %package -n qtsinglecoreapplication-devel
 Summary:    Development files for qtsinglecoreapplication
-BuildArch:  noarch
 Requires:   qtsinglecoreapplication = %{version}-%{release}
 Requires:   qt4-devel
 
@@ -83,7 +81,6 @@ This is a special build against Qt5.
 
 %package qt5-devel
 Summary:    Development files for %{name}-qt5
-BuildArch:  noarch
 Requires:   %{name}-qt5 = %{version}-%{release}
 Requires:   qt5-devel
 
@@ -108,7 +105,6 @@ This is a special build against Qt5.
 
 %package -n qtsinglecoreapplication-qt5-devel
 Summary:    Development files for qtsinglecoreapplication-qt5
-BuildArch:  noarch
 Requires:   qtsinglecoreapplication-qt5 = %{version}-%{release}
 Requires:   qt5-qtbase-devel
 
@@ -237,7 +233,6 @@ rm -rf %{buildroot}
 - remove deprecated spec file entries
 - use license macro and improve license patches
 - replace with new buildroot macro
-- use noarch for devel subpackages
 
 * Sun Aug 17 2014 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 2.6.1-12
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
@@ -273,7 +268,7 @@ rm -rf %{buildroot}
 * Fri Jul 16 2010 Orcan Ogetbil <oget[dot]fedora[at]gmail[dot]com> 2.6.1-2
 - Add additional API to support clementine.
 
-* Sun Jun 04 2010 Orcan Ogetbil <oget[dot]fedora[at]gmail[dot]com> 2.6.1-1
+* Fri Jun 04 2010 Orcan Ogetbil <oget[dot]fedora[at]gmail[dot]com> 2.6.1-1
 - Change version to 2.6.1. Upstream uses weird version convention 2.6_1
 - Own the directory %%{_qt4_headerdir}/QtSolutions/
 
-- 
cgit v0.10.2


>From 82c3fd07dc7c5d730c1227e861707f516f0086da Mon Sep 17 00:00:00 2001
From: Raphael Groner <projects.rg at smart.ms>
Date: Mon, 27 Apr 2015 11:25:50 +0200
Subject: fix BR


diff --git a/qtsingleapplication.spec b/qtsingleapplication.spec
index f022514..7f0ef2f 100644
--- a/qtsingleapplication.spec
+++ b/qtsingleapplication.spec
@@ -24,6 +24,9 @@ Patch0:     qtsingleapplication-build-qtsinglecoreapplication.patch
 # Proposed upstream in https://codereview.qt-project.org/#/c/92415/
 Patch1:     qtsingleapplication-remove-included-qtlockedfile.patch
 
+BuildRequires: qt4-devel qtlockedfile-devel
+BuildRequires: qt5-qtbase-devel qtlockedfile-qt5-devel
+
 %description
 For some applications it is useful or even critical that they are started
 only once by any user. Future attempts to start the application should
@@ -33,9 +36,6 @@ actions, e.g. loading a file, in that instance.
 The QtSingleApplication class provides an interface to detect a running
 instance, and to send command strings to that instance.
 
-BuildRequires: qt4-devel qtlockedfile-devel
-BuildRequires: qt5-qtbase-devel qtlockedfile-qt5-devel
-
 %package devel
 Summary:    Development files for %{name}
 Requires:   %{name} = %{version}-%{release}
-- 
cgit v0.10.2


>From 72e5a5ec00d4acf89f744659062d91227ca66b95 Mon Sep 17 00:00:00 2001
From: Raphael Groner <projects.rg at smart.ms>
Date: Mon, 27 Apr 2015 11:42:31 +0200
Subject: fix BR again


diff --git a/qtsingleapplication.spec b/qtsingleapplication.spec
index 7f0ef2f..5dc3d9f 100644
--- a/qtsingleapplication.spec
+++ b/qtsingleapplication.spec
@@ -82,7 +82,7 @@ This is a special build against Qt5.
 %package qt5-devel
 Summary:    Development files for %{name}-qt5
 Requires:   %{name}-qt5 = %{version}-%{release}
-Requires:   qt5-devel
+Requires:   qt5-qtbase-devel
 
 %description qt5-devel
 This package contains libraries and header files for developing applications
-- 
cgit v0.10.2


>From ec8be6f25b11b8628c18f6d4962aeafd34326ae4 Mon Sep 17 00:00:00 2001
From: Raphael Groner <projects.rg at smart.ms>
Date: Mon, 27 Apr 2015 11:48:35 +0200
Subject: bump Release to identicate BR fixes


diff --git a/qtsingleapplication.spec b/qtsingleapplication.spec
index 5dc3d9f..081d9b2 100644
--- a/qtsingleapplication.spec
+++ b/qtsingleapplication.spec
@@ -3,7 +3,7 @@
 Summary:    Qt library to start applications only once per user
 Name:       qtsingleapplication
 Version:    2.6.1
-Release:    13%{?dist}
+Release:    14%{?dist}
 
 License:    GPLv3 or LGPLv2 with exceptions
 URL:        http://doc.qt.digia.com/solutions/4/qtsingleapplication/qtsingleapplication.html
@@ -227,6 +227,9 @@ rm -rf %{buildroot}
 
 
 %changelog
+* Mon Apr 27 2015 Raphael Groner <projects.rg at smart.ms> - 2.6.1-14
+- bump Release to identicate BR fixes
+
 * Sat Apr 25 2015 Raphael Groner <projects.rg at smart.ms> - 2.6.1-13
 - use latest commit hash of dedicated folder at upstream
 - build subpackage for Qt5
-- 
cgit v0.10.2


	http://pkgs.fedoraproject.org/cgit/qtsingleapplication.git/commit/?h=f22&id=86abdbdbcc96c356737a6cd5d915b41e3441086b


More information about the scm-commits mailing list