forked from abbat/avalon
-
Notifications
You must be signed in to change notification settings - Fork 0
/
avalon3.spec
69 lines (53 loc) · 2.09 KB
/
avalon3.spec
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
Name: avalon3
Version: 3.0.1
Release: 1
Summary: RSDN offline client
Group: Applications/Internet
License: BSD-2-clause
URL: https://github.com/abbat/avalon
Conflicts: avalon, avalon2
BuildRequires: aspell-devel, zlib-devel
Source0: https://build.opensuse.org/source/home:antonbatenev:avalon/avalon3/avalon3_%{version}.tar.bz2
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%if 0%{?suse_version}
BuildRequires: libqt5-qtbase-devel, libqt5-qttools-devel, libqt5-qtsvg-devel, libQt5WebKitWidgets-devel
%else
BuildRequires: qt5-qtbase-devel, qt5-qttools-devel, qt5-qtsvg-devel, qt5-qtwebkit-devel
%endif
%description
Offile client for Russian Software Developer Network
%prep
%setup -q -n %{name}
%build
export builddir=$(pwd)
qmake-qt5 -project -recursive -Wall -nopwd -o avalon.pro \
"CONFIG += release" \
"QT += network sql core widgets webkitwidgets" \
"INCLUDEPATH += src" \
"DEFINES += AVALON_PACKAGE" \
"LIBS += -laspell -lz" \
"QMAKE_CPPFLAGS *= ${RPM_OPT_FLAGS}" \
"QMAKE_CFLAGS *= ${RPM_OPT_FLAGS}" \
"QMAKE_CXXFLAGS *= ${RPM_OPT_FLAGS}" \
"QMAKE_LFLAGS *= ${RPM_LD_FLAGS}" \
"${builddir}/src"
qmake-qt5 avalon.pro
make %{?_smp_mflags}
%install
install -d %{buildroot}%{_bindir}
install -d %{buildroot}%{_datadir}/pixmaps
install -d %{buildroot}%{_datadir}/applications
install -m755 avalon %{buildroot}%{_bindir}/avalon
install -m644 src/icons/avalon.xpm %{buildroot}%{_datadir}/pixmaps/avalon.xpm
install -m644 avalon.desktop %{buildroot}%{_datadir}/applications/avalon.desktop
%clean
rm -rf %{buildroot}
%files
%defattr(-,root,root,-)
%doc README.md
%{_bindir}/avalon
%{_datadir}/pixmaps/avalon.xpm
%{_datadir}/applications/avalon.desktop
%changelog
* Fri Nov 5 2021 Anton Batenev <antonbatenev@yandex.ru> 3.0.1-1
- Initial RPM release