]> git.pld-linux.org Git - packages/gemrb.git/blob - gemrb.spec
BR: glew-devel when building with GL backend
[packages/gemrb.git] / gemrb.spec
1 #
2 # Conditional build:
3 %bcond_with     gles    # build GLES backend
4
5 Summary:        Emulator of BioWare's Infinity game engine
6 Summary(pl.UTF-8):      Emulator silnika gier Infinity firmy BioWare
7 Name:           gemrb
8 Version:        0.8.7
9 Release:        0.1
10 License:        GPL v2+
11 Group:          Applications/Emulators
12 Source0:        https://downloads.sourceforge.net/gemrb/%{name}-%{version}-sources.tar.gz
13 # Source0-md5:  d1bf1dd8ca03ce9649b52240d363f357
14 Patch0:         %{name}-config_file.patch
15 URL:            http://gemrb.sourceforge.net/
16 BuildRequires:  OpenAL-devel
17 %{!?with_gles:BuildRequires:    OpenGL-devel}
18 %{?with_gles:BuildRequires:     OpenGLESv2-devel}
19 BuildRequires:  SDL2-devel
20 BuildRequires:  SDL2_mixer-devel
21 BuildRequires:  cmake >= 3.1
22 BuildRequires:  freetype-devel
23 %{!?with_gles:BuildRequires:    glew-devel}
24 BuildRequires:  libpng-devel
25 BuildRequires:  libstdc++-devel >= 6:4.8.1
26 BuildRequires:  libvorbis-devel
27 BuildRequires:  pkgconfig
28 BuildRequires:  python-devel >= 1:2.3.0
29 BuildRequires:  python-modules
30 BuildRequires:  rpmbuild(macros) >= 1.605
31 BuildRequires:  vlc-devel
32 BuildRequires:  zlib-devel
33 Requires(post,postun):  desktop-file-utils
34 Requires(post,postun):  gtk-update-icon-cache
35 Requires(post,postun):  hicolor-icon-theme
36 Suggests:       synce-unshield
37 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
38
39 %description
40 This Game Engine is a port of the original Infinity Engine (the one of
41 Baldur's Gate, Planescape: Torment, Icewind Dale) to Linux/Unix, MacOs
42 X and Windows with some Enhancements.
43
44 %description -l pl.UTF-8
45 Silnik ten jest portem oryginalnego silnika Infinity Engine (używanego
46 przez Baldur's Gate, Planescape: Torment, Icewind Dale) dla systemów
47 Linux/Unix, MacOS i Windows. Silnik posiada kilka ulepszeń.
48
49 %prep
50 %setup -q
51 %patch0 -p1
52
53 %{__sed} -i -e '1s,/usr/bin/python$,%{__python},' admin/extend2da.py
54
55 %build
56 install -d build
57 cd build
58 %cmake .. \
59         -DBIN_DIR="%{_bindir}" \
60         -DSYSCONF_DIR="%{_sysconfdir}/gemrb" \
61         -DLIB_DIR="%{_libdir}" \
62         -DPLUGIN_DIR="%{_libdir}/gemrb/plugins" \
63         -DDATA_DIR="%{_datadir}/gemrb" \
64         -DMAN_DIR="%{_mandir}/man6" \
65         -DICON_DIR="%{_pixmapsdir}" \
66         -DSVG_DIR="%{_iconsdir}/hicolor/scalable/apps" \
67         -DMENU_DIR="%{_desktopdir}" \
68         -DOPENGL_BACKEND=%{!?with_gles:OpenGL}%{?with_gles:GLES} \
69         -DSDL_BACKEND=SDL2
70 %{__make}
71
72 %install
73 rm -rf $RPM_BUILD_ROOT
74
75 %{__make} install -C build \
76         DESTDIR=$RPM_BUILD_ROOT
77
78 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}
79 %{__rm} $RPM_BUILD_ROOT%{_sysconfdir}/gemrb/GemRB.cfg{.noinstall,}.sample
80 %{__mv} $RPM_BUILD_ROOT%{_sysconfdir}/gemrb/{GemRB.cfg,gemrb.cfg}
81
82 %clean
83 rm -rf $RPM_BUILD_ROOT
84
85 %post
86 /sbin/ldconfig
87 %update_desktop_database_post
88 %update_icon_cache hicolor
89
90 %postun
91 /sbin/ldconfig
92 %update_desktop_database_postun
93 %update_icon_cache hicolor
94
95 %files
96 %defattr(644,root,root,755)
97 %doc AUTHORS CONTRIBUTING.md NEWS README.md %{name}/{docs/en/*.txt,GemRB.cfg*.sample}
98 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/gemrb/gemrb.cfg
99 %attr(755,root,root) %{_bindir}/gemrb
100 %attr(755,root,root) %{_libdir}/libgemrb_core.so.*.*.*
101 %dir %{_libdir}/gemrb
102 %dir %{_libdir}/gemrb/plugins
103 %attr(755,root,root) %{_libdir}/gemrb/plugins/*.so
104 %{_datadir}/gemrb
105 %{_mandir}/man6/gemrb.6*
106 %{_desktopdir}/gemrb.desktop
107 %{_iconsdir}/hicolor/scalable/apps/gemrb.svg
108 %{_pixmapsdir}/gemrb.png
This page took 0.080234 seconds and 3 git commands to generate.