~x2go/x2go/x2goclient_master

458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
1
Name:           x2goclient
1914 by X2Go Release Manager
Continue development
2
Version:        4.1.2.3
469 by Mike Gabriel
make sure our RPM package version is lower than a package version from EPEL
3
Release:        0.0x2go1%{?dist}
1970 by Mihai Moldovan
x2goclient.spec: add version switching support. Use Qt 5 for FC31+, RHEL 8 and *SuSE 15.3+.
4
5
# Default to Qt 4 for now.
6
%define         qt_version 4
7
# FC31+ or EPEL 8.
8
# Tumbleweed or *SuSE 15.3+.
1974 by Mihai Moldovan
x2goclient.spec: typo fix in vendor macro.
9
%if ( "%{?_vendor}" == "redhat" && ( 0%{?fedora} > 31 || 0%{?el8} ) ) || ( "%{?_vendor}" == "suse" && ( 0%{?suse_version} > 1500 || 0%{?sle_version} >= 150200 ) )
1970 by Mihai Moldovan
x2goclient.spec: add version switching support. Use Qt 5 for FC31+, RHEL 8 and *SuSE 15.3+.
10
%define         qt_version 5
11
%endif
12
13
14
Summary:        X2Go Client application (Qt%{qt_version})
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
15
707 by Mike Gabriel
Add x2goclient-rpmlintrc file.
16
%if 0%{?suse_version}
17
Group:          Production/Networking/Remote Desktop
18
License:        GPL-2.0+
19
%else
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
20
Group:          Applications/Communications
21
License:        GPLv2+
707 by Mike Gabriel
Add x2goclient-rpmlintrc file.
22
%endif
23
1736 by Mihai Moldovan
misc: change http:// to https:// where appropriate, but in actual code and translation files for now.
24
URL:            https://www.x2go.org
25
Source0:        https://code.x2go.org/releases/source/%{name}/%{name}-%{version}.tar.gz
707 by Mike Gabriel
Add x2goclient-rpmlintrc file.
26
Source1:        x2goclient-rpmlintrc
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
27
28
BuildRequires:  cups-devel
29
BuildRequires:  desktop-file-utils
688 by Mike Gabriel
x2goclient.spec: Adapt to building for openSUSE/SLES.
30
709 by Mike Gabriel
In openSUSE, it is openldap2-devel, in Fedora/RHEL it is openldap-devel.
31
%if 0%{?suse_version}
1970 by Mihai Moldovan
x2goclient.spec: add version switching support. Use Qt 5 for FC31+, RHEL 8 and *SuSE 15.3+.
32
buildrequires:  openldap2-devel
33
%else
34
BuildRequires:  openldap-devel
35
%endif
36
1976 by Mihai Moldovan
x2goclient.spec: rework Qt5 dependencies.
37
%if %{qt_version} == 4
1970 by Mihai Moldovan
x2goclient.spec: add version switching support. Use Qt 5 for FC31+, RHEL 8 and *SuSE 15.3+.
38
%if 0%{?suse_version}
698 by Mike Gabriel
x2goclient: Add to R for openSUSE: libqt4-devel.
39
BuildRequires:  libqt4-devel
705 by Mike Gabriel
x2goclient.spec: Fix version comparison.
40
%if 0%{?suse_version} >= 1310
696 by Mike Gabriel
openSUSE: Make Qt4 Linguist tools available for Makefile.
41
BuildRequires:  libqt4-linguist
704 by Mike Gabriel
The libqt4-linguist split off happened in openSUSE 13.1.
42
%endif
696 by Mike Gabriel
openSUSE: Make Qt4 Linguist tools available for Makefile.
43
%else
478 by Mike Gabriel
x2goclient.spec: rather build EPEL-6 package against qt4-devel
44
%if 0%{?el5} || 0%{?el6}
474 by Mike Gabriel
x2goclient.spec: more fixes for EPEL-5
45
BuildRequires:  qt4-devel
46
%else
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
47
BuildRequires:  qt-devel
474 by Mike Gabriel
x2goclient.spec: more fixes for EPEL-5
48
%endif
1979 by Mihai Moldovan
x2goclient.spec: fix missing %endif in Qt-4-BuildRequires section.
49
%endif
1970 by Mihai Moldovan
x2goclient.spec: add version switching support. Use Qt 5 for FC31+, RHEL 8 and *SuSE 15.3+.
50
%else
51
%if %{qt_version} == 5
1976 by Mihai Moldovan
x2goclient.spec: rework Qt5 dependencies.
52
BuildRequires:  pkgconfig(Qt5Core)
53
BuildRequires:  pkgconfig(Qt5Gui)
54
BuildRequires:  pkgconfig(Qt5Svg)
55
BuildRequires:  pkgconfig(Qt5Widgets)
1984 by Mihai Moldovan
x2goclient.spec: add BuildRequires on Qt5X11Extras.
56
BuildRequires:  pkgconfig(Qt5X11Extras)
1976 by Mihai Moldovan
x2goclient.spec: rework Qt5 dependencies.
57
%if 0%{?suse_version}
58
BuildRequires:  libqt5-linguist
59
%else
60
BuildRequires:  qt5-linguist
1970 by Mihai Moldovan
x2goclient.spec: add version switching support. Use Qt 5 for FC31+, RHEL 8 and *SuSE 15.3+.
61
%endif
62
%endif
696 by Mike Gabriel
openSUSE: Make Qt4 Linguist tools available for Makefile.
63
%endif
688 by Mike Gabriel
x2goclient.spec: Adapt to building for openSUSE/SLES.
64
65
%if "%{?_vendor}" == "redhat"
66
%if 0%{?fedora} || 0%{?el7}
67
BuildRequires:  man2html-core
68
%else
69
BuildRequires:  man
70
%endif
1177 by Mihai Moldovan
x2goclient.spec: whitespace only.
71
BuildRequires:  libssh-devel >= 0.5.5-2.1x2go1
72
BuildRequires:  libXpm-devel, libX11-devel
688 by Mike Gabriel
x2goclient.spec: Adapt to building for openSUSE/SLES.
73
%endif
74
1808 by Mihai Moldovan
x2goclient.spec: EPEL packages need to depend upon pkgconfig for now, not pkg-config.
75
%if 0%{?el5} || 0%{?el6} || 0%{?el7}
76
# EPEL still calls the package pkconfig for some reason.
77
BuildRequires:  pkgconfig
78
%else
1803 by Mihai Moldovan
x2goclient.spec: build-depend on pkg-config.
79
BuildRequires:  pkg-config
1811 by Mihai Moldovan
x2goclient.spec: it's %endif, not %fi.
80
%endif
1803 by Mihai Moldovan
x2goclient.spec: build-depend on pkg-config.
81
1809 by Mihai Moldovan
x2goclient.spec: pull in redhat-rpm-config manually.
82
%if 0%{?fedora} || 0%{?rhel}
83
# For some reason qt(4)-dev doesn't depend upon redhat-rpm-config,
84
# but the GCC spec file is still used, which leads to gcc failing
85
# due to a missing annobin plugin during compilation.
86
# Let's build-depend upon redhat-rpm-config for now manually.
87
BuildRequires:  redhat-rpm-config
88
%endif
89
690 by Mike Gabriel
typo fix
90
%if "%{?_vendor}" == "suse"
1177 by Mihai Moldovan
x2goclient.spec: whitespace only.
91
BuildRequires:  fdupes update-desktop-files
688 by Mike Gabriel
x2goclient.spec: Adapt to building for openSUSE/SLES.
92
%if 0%{?suse_version} >= 1130
1177 by Mihai Moldovan
x2goclient.spec: whitespace only.
93
BuildRequires:  pkgconfig(libssh) >= 0.6.3
94
BuildRequires:  pkgconfig(x11) pkgconfig(xpm) pkgconfig(xproto)
688 by Mike Gabriel
x2goclient.spec: Adapt to building for openSUSE/SLES.
95
%endif
96
%if 0%{?suse_version} && 0%{?suse_version} < 1130
1177 by Mihai Moldovan
x2goclient.spec: whitespace only.
97
BuildRequires:  libssh-devel >= 0.6.3
98
BuildRequires:  xorg-x11-libXpm-devel xorg-x11-proto-devel
99
BuildRequires:  xorg-x11-libX11-devel
688 by Mike Gabriel
x2goclient.spec: Adapt to building for openSUSE/SLES.
100
%endif
101
%endif
102
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
103
Requires:       hicolor-icon-theme
104
Requires:       nxproxy
710 by Mike Gabriel
In openSUSE, openssh is openssh (not openssh-clients / openssh-server).
105
%if 0%{?suse_version}
106
Requires:       openssh
107
%else
481 by Mike Gabriel
Split up package into bin:packages: x2goclient, x2goplugin, x2goplugin-provider.
108
Requires:       openssh-clients, openssh-server
710 by Mike Gabriel
In openSUSE, openssh is openssh (not openssh-clients / openssh-server).
109
%endif
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
110
688 by Mike Gabriel
x2goclient.spec: Adapt to building for openSUSE/SLES.
111
%if "%{?_vendor}" == "suse"
1177 by Mihai Moldovan
x2goclient.spec: whitespace only.
112
Requires:       terminus-font
688 by Mike Gabriel
x2goclient.spec: Adapt to building for openSUSE/SLES.
113
%endif
114
%if "%{?_vendor}" == "redhat"
1177 by Mihai Moldovan
x2goclient.spec: whitespace only.
115
Requires:       terminus-fonts
688 by Mike Gabriel
x2goclient.spec: Adapt to building for openSUSE/SLES.
116
%endif
117
%if 0%{?suse_version} >= 1100
1177 by Mihai Moldovan
x2goclient.spec: whitespace only.
118
Suggests:       pinentry-x2go
688 by Mike Gabriel
x2goclient.spec: Adapt to building for openSUSE/SLES.
119
%endif
120
471 by Mike Gabriel
x2goclient.spec: (hopefully) fix distro version checks
121
%if 0%{?el5}
467 by Mike Gabriel
typo fix
122
# For compatibility with EPEL5
123
BuildRoot:      %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
792 by Mike Gabriel
x2goclient.spec: Always set BuildRoot: parameter.
124
%else
125
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
471 by Mike Gabriel
x2goclient.spec: (hopefully) fix distro version checks
126
%endif
467 by Mike Gabriel
typo fix
127
1735 by Mihai Moldovan
x2goclient.spec: remove plugin references.
128
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
129
%description
506 by Mike Gabriel
x2goclient.spec: fix spelling of serverbased/server-based
130
X2Go is a server-based computing environment with
481 by Mike Gabriel
Split up package into bin:packages: x2goclient, x2goplugin, x2goplugin-provider.
131
    - session resuming
132
    - low bandwidth support
133
    - session brokerage support
134
    - client-side mass storage mounting support
135
    - client-side printing support
136
    - audio support
137
    - authentication by smartcard and USB stick
138
1970 by Mihai Moldovan
x2goclient.spec: add version switching support. Use Qt 5 for FC31+, RHEL 8 and *SuSE 15.3+.
139
X2Go Client is a graphical client (Qt%{qt_version}) for the X2Go system.
481 by Mike Gabriel
Split up package into bin:packages: x2goclient, x2goplugin, x2goplugin-provider.
140
You can use it to connect to running sessions and start new sessions.
141
142
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
143
%prep
144
%setup -q
145
# Fix up install issues
146
sed -i -e 's/-o root -g root//' Makefile
846 by Mihai Moldovan
general: move txt/ to res/text/ and update references in:
147
test -f ChangeLog && cp ChangeLog res/txt/changelog || test -f debian/changelog && cp debian/changelog res/txt/changelog || true
148
test -f ChangeLog.gitlog && cp ChangeLog.gitlog res/txt/git-info || true
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
149
481 by Mike Gabriel
Split up package into bin:packages: x2goclient, x2goplugin, x2goplugin-provider.
150
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
151
%build
1970 by Mihai Moldovan
x2goclient.spec: add version switching support. Use Qt 5 for FC31+, RHEL 8 and *SuSE 15.3+.
152
%define make_call make %{?_smp_mflags} CXXFLAGS='%{optflags}' QMAKE_OPTS='QMAKE_STRIP=:' QT_VERSION='%{qt_version}'
153
%if %{qt_version} == 4
1975 by Mihai Moldovan
x2goclient.spec: expand %{_qt4_bindir} to integer if it's set, instead of using it as a string in the condition (which then leads to parsing error).
154
%if 0%{?_qt4_bindir:1}
1981 by Mihai Moldovan
x2goclient.spec: correctly quote PATH overrides.
155
export 'PATH=%{_qt4_bindir}:'"${PATH}"
1971 by Mihai Moldovan
x2goclient.spec: don't try to prepend %{_qt4_bindir} if the macro is not defined.
156
%endif
1970 by Mihai Moldovan
x2goclient.spec: add version switching support. Use Qt 5 for FC31+, RHEL 8 and *SuSE 15.3+.
157
%if 0%{?el5}
158
%{make_call} QMAKE_BINARY='%{_libdir}/qt4/bin/qmake' LRELEASE_BINARY='%{_libdir}/qt4/bin/lrelease'
159
%else
160
%if 0%{?suse_version}
161
%{make_call} QMAKE_BINARY='%{_bindir}/qmake' LRELEASE_BINARY='%{_bindir}/lrelease'
162
%else
163
%{make_call}
164
%endif
165
%endif
166
%else
167
%if %{qt_version} == 5
1980 by Mihai Moldovan
x2goclient.spec: use %{_qt5_bindir} macro analogous to the Qt 4 variant.
168
%if 0%{?_qt5_bindir:1}
1982 by Mihai Moldovan
x2goclient.spec: fix syntax error in Qt 5 PATH override.
169
export 'PATH=%{_qt5_bindir}:'"${PATH}"
1980 by Mihai Moldovan
x2goclient.spec: use %{_qt5_bindir} macro analogous to the Qt 4 variant.
170
%endif
1985 by Mihai Moldovan
x2goclient.spec: also use/handle %{_libqt5_bindir}, as used by *SuSE.
171
%if 0%{?_libqt5_bindir:1}
172
export 'PATH=%{_libqt5_bindir}:'"${PATH}"
173
%endif
1970 by Mihai Moldovan
x2goclient.spec: add version switching support. Use Qt 5 for FC31+, RHEL 8 and *SuSE 15.3+.
174
%{make_call}
175
%endif
176
%endif
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
177
481 by Mike Gabriel
Split up package into bin:packages: x2goclient, x2goplugin, x2goplugin-provider.
178
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
179
%install
180
make install DESTDIR=%{buildroot} PREFIX=%{_prefix}
181
desktop-file-validate %{buildroot}%{_datadir}/applications/%{name}.desktop
182
706 by Mike Gabriel
x2goclient.spec: typo fix
183
%if 0%{?suse_version}
688 by Mike Gabriel
x2goclient.spec: Adapt to building for openSUSE/SLES.
184
%suse_update_desktop_file -r x2goclient Utility WebUtility
185
%fdupes %buildroot
186
%endif
187
1735 by Mihai Moldovan
x2goclient.spec: remove plugin references.
188
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
189
%post
190
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
1941 by Mike Gabriel
x2goclient.spec: Install x-x2go.xml into bin:pkg and run update-mime-database during postinst.
191
/usr/bin/update-mime-database /usr/share/mime &>/dev/null || :
1735 by Mihai Moldovan
x2goclient.spec: remove plugin references.
192
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
193
%postun
194
if [ $1 -eq 0 ] ; then
195
    /bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null
196
    /usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
197
fi
198
199
%posttrans
200
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
201
202
203
%files
700 by Mike Gabriel
x2goclient.spec: Own more directories (rpmlint-based FTBFS).
204
%defattr(-,root,root)
1139 by Mihai Moldovan
misc: whitespace only.
205
%doc AUTHORS COPYING LICENSE
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
206
%{_bindir}/%{name}
207
%{_datadir}/applications/%{name}.desktop
1941 by Mike Gabriel
x2goclient.spec: Install x-x2go.xml into bin:pkg and run update-mime-database during postinst.
208
%{_datadir}/mime/packages/x-x2go.xml
700 by Mike Gabriel
x2goclient.spec: Own more directories (rpmlint-based FTBFS).
209
%dir %{_datadir}/icons/hicolor
210
%dir %{_datadir}/icons/hicolor/128x128
211
%dir %{_datadir}/icons/hicolor/128x128/apps
212
%dir %{_datadir}/icons/hicolor/16x16
213
%dir %{_datadir}/icons/hicolor/16x16/apps
214
%dir %{_datadir}/icons/hicolor/32x32
215
%dir %{_datadir}/icons/hicolor/32x32/apps
216
%dir %{_datadir}/icons/hicolor/64x64
217
%dir %{_datadir}/icons/hicolor/64x64/apps
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
218
%{_datadir}/icons/hicolor/128x128/apps/%{name}.png
219
%{_datadir}/icons/hicolor/16x16/apps/%{name}.png
220
%{_datadir}/icons/hicolor/32x32/apps/%{name}.png
221
%{_datadir}/icons/hicolor/64x64/apps/%{name}.png
222
%{_datadir}/%{name}/
481 by Mike Gabriel
Split up package into bin:packages: x2goclient, x2goplugin, x2goplugin-provider.
223
%{_mandir}/man1/%{name}.1.gz
224
225
458 by Mike Gabriel
Ship x2goclient.spec (RPM package definitions) in upstream project.
226
%changelog