]> git.pld-linux.org Git - packages/QtSingleApplication.git/blob - QtSingleApplication.spec
- install to qt4 subdir for qbittorrent to find; rel 5
[packages/QtSingleApplication.git] / QtSingleApplication.spec
1 Summary:        Qt library to start applications only once per user
2 Name:           QtSingleApplication
3 Version:        2.6
4 Release:        5
5 License:        GPL v3 or LGPL v2 with exceptions
6 Group:          Libraries
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)
23
24 %define         _qt4_datadir    %{_datadir}/qt4
25
26 %description
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.
31
32 The QtSingleApplication class provides an interface to detect a
33 running instance, and to send command strings to that instance.
34
35 For console (non-GUI) applications, the QtSingleCoreApplication
36 variant is provided, which avoids dependency on QtGui.
37
38 %package        devel
39 Summary:        Development files for QtSingleApplication
40 Group:          Development/Libraries
41 Requires:       %{name} = %{version}-%{release}
42 Requires:       qt4-build
43 Requires:       qt4-qmake
44
45 %description    devel
46 This package contains libraries and header files for developing
47 applications that use QtSingleApplication.
48
49 %prep
50 %setup -q -n qtsingleapplication-%{version}_1-opensource
51 %patch0 -p1
52 %patch1 -p1
53 %patch2 -p1
54
55 # We already disabled bundling this extrenal library.
56 # But just to make sure:
57 rm src/{QtLocked,qtlocked}*
58
59 %build
60 touch .licenseAccepted
61 # Does not use GNU configure
62 ./configure \
63         -library
64
65 # XXX fix QtLockedFile package
66 qmake-qt4 INCLUDEPATH+=%{_includedir}/QtSolutions
67 %{__make}
68
69 %install
70 rm -rf $RPM_BUILD_ROOT
71
72 # libraries
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
76
77 # headers
78 install -d $RPM_BUILD_ROOT%{_includedir}/qt4/QtSolutions
79 cp -a \
80     src/qtsingleapplication.h \
81     src/QtSingleApplication \
82     src/qtsinglecoreapplication.h \
83     src/QtSingleCoreApplication \
84     $RPM_BUILD_ROOT%{_includedir}/qt4/QtSolutions
85
86 install -d $RPM_BUILD_ROOT%{_qt4_datadir}/mkspecs/features
87 cp -a %{SOURCE1} %{SOURCE2} $RPM_BUILD_ROOT%{_qt4_datadir}/mkspecs/features
88
89 %clean
90 rm -rf $RPM_BUILD_ROOT
91
92 %post   -p /sbin/ldconfig
93 %postun -p /sbin/ldconfig
94
95 %files
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
102
103 %files devel
104 %defattr(644,root,root,755)
105 %doc doc examples
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
This page took 0.072213 seconds and 3 git commands to generate.