1 Summary: Qt library to start applications only once per user
2 Name: QtSingleApplication
5 License: GPL v3 or LGPL v2 with exceptions
7 URL: http://qt.nokia.com/products/appdev/add-on-products/catalog/4/Utilities/qtsingleapplication
8 Source0: http://get.qt.nokia.com/qt/solutions/lgpl/qtsingleapplication-%{version}_1-opensource.tar.gz
9 # Source0-md5: 902795eb13ecedbdc112f00d7ec22949
10 Source1: qtsingleapplication.prf
11 Source2: qtsinglecoreapplication.prf
12 Patch0: qtsingleapplication-build.diff
13 Patch1: qtsingleapplication-dont-bundle-external-libs.patch
14 Patch2: clementine.patch
15 BuildRequires: QtCore-devel
16 BuildRequires: QtGui-devel
17 BuildRequires: QtLockedFile-devel
18 BuildRequires: QtNetwork-devel
19 BuildRequires: libstdc++-devel
20 BuildRequires: qt4-build
21 BuildRequires: qt4-qmake
22 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
24 %define _qt4_datadir %{_datadir}/qt4
27 For some applications it is useful or even critical that they are
28 started only once by any user. Future attempts to start the
29 application should activate any already running instance, and possibly
30 perform requested actions, e.g. loading a file, in that instance.
32 The QtSingleApplication class provides an interface to detect a
33 running instance, and to send command strings to that instance.
35 For console (non-GUI) applications, the QtSingleCoreApplication
36 variant is provided, which avoids dependency on QtGui.
39 Summary: Development files for QtSingleApplication
40 Group: Development/Libraries
41 Requires: %{name} = %{version}-%{release}
46 This package contains libraries and header files for developing
47 applications that use QtSingleApplication.
50 %setup -q -n qtsingleapplication-%{version}_1-opensource
55 # We already disabled bundling this extrenal library.
56 # But just to make sure:
57 rm src/{QtLocked,qtlocked}*
60 touch .licenseAccepted
61 # Does not use GNU configure
65 # XXX fix QtLockedFile package
66 qmake-qt4 INCLUDEPATH+=%{_includedir}/QtSolutions
70 rm -rf $RPM_BUILD_ROOT
73 install -d $RPM_BUILD_ROOT%{_libdir}
74 cp -a lib/* $RPM_BUILD_ROOT%{_libdir}
75 rm $RPM_BUILD_ROOT%{_libdir}/lib*.so.1.0
78 install -d $RPM_BUILD_ROOT%{_includedir}/qt4/QtSolutions
80 src/qtsingleapplication.h \
81 src/QtSingleApplication \
82 src/qtsinglecoreapplication.h \
83 src/QtSingleCoreApplication \
84 $RPM_BUILD_ROOT%{_includedir}/qt4/QtSolutions
86 install -d $RPM_BUILD_ROOT%{_qt4_datadir}/mkspecs/features
87 cp -a %{SOURCE1} %{SOURCE2} $RPM_BUILD_ROOT%{_qt4_datadir}/mkspecs/features
90 rm -rf $RPM_BUILD_ROOT
92 %post -p /sbin/ldconfig
93 %postun -p /sbin/ldconfig
96 %defattr(644,root,root,755)
97 %doc LGPL_EXCEPTION.txt LICENSE.* README.TXT
98 %attr(755,root,root) %{_libdir}/libQtSolutions_SingleApplication-%{version}.so.*.*.*
99 %attr(755,root,root) %ghost %{_libdir}/libQtSolutions_SingleApplication-%{version}.so.1
100 %attr(755,root,root) %{_libdir}/libQtSolutions_SingleCoreApplication-%{version}.so.*.*.*
101 %attr(755,root,root) %ghost %{_libdir}/libQtSolutions_SingleCoreApplication-%{version}.so.1
104 %defattr(644,root,root,755)
106 %{_libdir}/libQtSolutions_SingleApplication-%{version}.so
107 %{_libdir}/libQtSolutions_SingleCoreApplication-%{version}.so
108 # XXX dir shared dir with QtLockedFile.spec
109 %dir %{_includedir}/qt4/QtSolutions
110 %{_includedir}/qt4/QtSolutions/QtSingleApplication
111 %{_includedir}/qt4/QtSolutions/QtSingleCoreApplication
112 %{_includedir}/qt4/QtSolutions/qtsingleapplication.h
113 %{_includedir}/qt4/QtSolutions/qtsinglecoreapplication.h
114 %{_qt4_datadir}/mkspecs/features/qtsingleapplication.prf
115 %{_qt4_datadir}/mkspecs/features/qtsinglecoreapplication.prf