]> git.pld-linux.org Git - packages/QtSingleApplication.git/blob - QtSingleApplication.spec
- more fixes from rhbz: use QtLockedFile add .prf
[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:        2
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 Patch0:         qtsingleapplication-build.diff
12 Patch1:         qtsingleapplication-dont-bundle-external-libs.patch
13 BuildRequires:  QtLockedFile-devel
14 BuildRequires:  qt4-build
15 BuildRequires:  qt4-qmake
16 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
17
18 %define         _qt4_datadir    %{_datadir}/qt4
19
20 %description
21 For some applications it is useful or even critical that they are
22 started only once by any user. Future attempts to start the
23 application should activate any already running instance, and possibly
24 perform requested actions, e.g. loading a file, in that instance.
25
26 The QtSingleApplication class provides an interface to detect a
27 running instance, and to send command strings to that instance.
28
29 For console (non-GUI) applications, the QtSingleCoreApplication
30 variant is provided, which avoids dependency on QtGui.
31
32 %package        devel
33 Summary:        Development files for QtSingleApplication
34 Group:          Development/Libraries
35 Requires:       %{name} = %{version}-%{release}
36 Requires:       qt4-build
37 Requires:       qt4-qmake
38
39 %description    devel
40 This package contains libraries and header files for developing
41 applications that use QtSingleApplication.
42
43 %prep
44 %setup -q -n qtsingleapplication-%{version}_1-opensource
45 %patch0 -p1
46 %patch1 -p1
47
48 # We already disabled bundling this extrenal library.
49 # But just to make sure:
50 rm src/{QtLocked,qtlocked}*
51
52 %build
53 touch .licenseAccepted
54 # Does not use GNU configure
55 ./configure \
56         -library
57
58 # XXX fix QtLockedFile package
59 qmake-qt4 INCLUDEPATH+=%{_includedir}/QtSolutions
60 %{__make}
61
62 %install
63 rm -rf $RPM_BUILD_ROOT
64
65 # libraries
66 install -d $RPM_BUILD_ROOT%{_libdir}
67 cp -a lib/* $RPM_BUILD_ROOT%{_libdir}
68 rm $RPM_BUILD_ROOT%{_libdir}/lib*.so.1.0
69
70 # headers
71 install -d $RPM_BUILD_ROOT%{_includedir}/QtSolutions
72 cp -a \
73     src/qtsingleapplication.h \
74     src/QtSingleApplication \
75     src/qtsinglecoreapplication.h \
76     src/QtSingleCoreApplication \
77     $RPM_BUILD_ROOT%{_includedir}/QtSolutions
78
79 install -d $RPM_BUILD_ROOT%{_qt4_datadir}/mkspecs/features
80 cp -a %{SOURCE1} $RPM_BUILD_ROOT%{_qt4_datadir}/mkspecs/features
81
82 %clean
83 rm -rf $RPM_BUILD_ROOT
84
85 %post   -p /sbin/ldconfig
86 %postun -p /sbin/ldconfig
87
88 %files
89 %defattr(644,root,root,755)
90 %doc LGPL_EXCEPTION.txt LICENSE.* README.TXT
91 %attr(755,root,root) %{_libdir}/libQtSolutions_SingleApplication-%{version}.so.*.*.*
92 %attr(755,root,root) %ghost %{_libdir}/libQtSolutions_SingleApplication-%{version}.so.1
93
94 %files devel
95 %defattr(644,root,root,755)
96 %doc doc examples
97 %{_libdir}/libQtSolutions_SingleApplication-%{version}.so
98 # XXX dir shared dir with QtLockedFile.spec
99 %dir %{_includedir}/QtSolutions
100 %{_includedir}/QtSolutions/QtSingleApplication
101 %{_includedir}/QtSolutions/QtSingleCoreApplication
102 %{_includedir}/QtSolutions/qtsingleapplication.h
103 %{_includedir}/QtSolutions/qtsinglecoreapplication.h
104 %{_qt4_datadir}/mkspecs/features/qtsingleapplication.prf
This page took 0.278001 seconds and 3 git commands to generate.