packaging: devel subpackage take imports too
[contrib/qtwebsockets.git] / packaging / qt5-qtwebsockets.spec
1 #
2 # Copyright (c) 2015 Philippe Coval <philippe.coval@eurogiciel.fr>
3 #
4 # Permission is hereby granted, free of charge, to any person obtaining a copy
5 # of this software and associated documentation files (the "Software"), to deal
6 # in the Software without restriction, including without limitation the rights
7 # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8 # copies of the Software, and to permit persons to whom the Software is
9 # furnished to do so, subject to the following conditions:
10 #
11 # The above copyright notice and this permission notice shall be included in
12 # all copies or substantial portions of the Software.
13 #
14 # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15 # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16 # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17 # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18 # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19 # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
20 # THE SOFTWARE.
21
22 Name:           qt5-qtwebsockets
23 Version:        5.4.1
24 Release:        0
25 License:        LGPL-2.1+ or GPL-3.0
26 Summary:        Pure Qt implementation of WebSockets - both client and server
27 Url:            http://code.qt.io/cgit/qt/qtwebsockets.git
28 Group:          System/Libraries
29 # X-Vc-Url:     http://code.qt.io/git/qt/qtwebsockets.git
30 Group:          Contrib
31 Source:         %{name}-%{version}.tar.gz
32 Source1001:     %{name}.manifest
33
34 BuildRequires:  make
35 BuildRequires:  fdupes
36 BuildRequires:  pkgconfig(Qt5Core)
37 BuildRequires:  pkgconfig(Qt5Network)
38 BuildRequires:  qt5-qmake
39 BuildRequires:  qt5-qtdeclarative-qtquick-devel
40 %description
41
42 Qt is a cross-platform application and UI framework. Using Qt, you can
43 write web-enabled applications once and deploy them across desktop,
44 mobile and embedded systems without rewriting the source code.
45 .
46 This package contains the Qt module to manage websockets.
47
48 %package devel
49 Summary:    Pure Qt implementation of WebSockets - development files
50 Group:      Development/Libraries
51 Requires:   %{name} = %{version}-%{release}
52 Requires:   qt5-qtdeclarative-import-websockets = %{version}-%{release}
53 %description devel
54
55 Qt is a cross-platform application and UI framework. Using Qt, you can
56 write web-enabled applications once and deploy them across desktop,
57 mobile and embedded systems without rewriting the source code.
58 .
59 This package contains development files for Qt module to manage websockets.
60
61 %package -n qt5-qtdeclarative-import-websockets
62 Summary:    QtQml  websockets import
63 Group:      Base/Libraries
64 Requires:   %{name} = %{version}-%{release}
65 Requires:   qt5-qtdeclarative
66
67 %description -n qt5-qtdeclarative-import-websockets
68 %{description}
69
70
71 %prep
72 %setup -q -n %{name}-%{version}
73
74 %build
75 touch .git
76 cp %{SOURCE1001} .
77 QTDIR=/usr/share/qt5
78 export QTDIR
79 qmake -qt=5
80
81 %__make %{?_smp_mflags}
82
83
84 %install
85 %qmake_install
86 %fdupes %{buildroot}
87
88 %post -p /sbin/ldconfig
89
90 %postun -p /sbin/ldconfig
91
92
93 %files
94 %defattr(-,root,root)
95 %manifest %{name}.manifest
96 %{_libdir}/*.so.*
97 %{_libdir}/*.la
98 %{_libdir}/*.prl
99 %{_datadir}/*
100
101
102 %files devel
103 %manifest %{name}.manifest
104 %defattr(-,root,root,-)
105 %{_includedir}/*
106 %{_libdir}/*.so
107 %{_libdir}/pkgconfig/*
108 %{_libdir}/cmake/*/*.cmake
109
110
111 %files -n qt5-qtdeclarative-import-websockets
112 %defattr(-,root,root,-)
113 %manifest %{name}.manifest
114 %{_libdir}/qt5/qml/*
115