6 %bcond_with libY # build with libY
7 %bcond_with jsw # uild with joystick support
9 %define shortname searchandrescue
10 %define data_ver 1.3.0
11 Summary: Search And Rescue - Linux flight simulator
12 Summary(pl.UTF-8): Search And Rescue - symulator lotu śmigłowca
17 Group: X11/Applications/Games
18 Source0: http://downloads.sourceforge.net/searchandrescue/Program/%{name}-%{version}.tar.gz
19 # Source0-md5: a3fdc0bf0414a027da7ced635ec5ee25
20 Source1: http://downloads.sourceforge.net/searchandrescue/Data_Files/%{name}-data-%{data_ver}.tar.gz
21 # Source1-md5: 53d6986bd53e7e2b5de0d7bd996a1910
22 Patch0: %{name}-flags.patch
23 Patch1: %{name}-v3dtex.patch
24 URL: http://searchandrescue.sourceforge.net/
25 BuildRequires: OpenGL-devel
26 %{?with_liby:BuildRequires: libY-devel}
27 %{?with_jsw:BuildRequires: libjsw-devel}
28 BuildRequires: xorg-xserver-server-devel
30 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
32 %define _noautoreqdep libGL.so.1 libGLU.so.1
35 Linux flight simulator.
37 %description -l pl.UTF-8
38 Symulator lotu śmigłowcem.
41 %setup -q -n %{shortname}_%{version}
50 LDFLAGS="%{rpmldflags}" \
51 OPTCFLAGS="%{rpmcflags} %{!?debug:-fomit-frame-pointer}" \
52 OPTCPPFLAGS="%{rpmcxxflags}"
55 rm -rf $RPM_BUILD_ROOT
56 install -d $RPM_BUILD_ROOT%{_datadir}/games/%{shortname}
59 PREFIX=$RPM_BUILD_ROOT%{_prefix} \
60 GAMES_DIR=$RPM_BUILD_ROOT%{_bindir} \
61 MAN_DIR=$RPM_BUILD_ROOT%{_mandir}/man6 \
62 SHARE_GAMES_DIR=$RPM_BUILD_ROOT%{_datadir} \
63 SHADE_ICONS_DIR=$RPM_BUILD_ROOT%{_pixmapsdir}
66 tar xvf %{SOURCE1} -C $RPM_BUILD_ROOT%{_datadir}/games/%{shortname}
69 rm -rf $RPM_BUILD_ROOT
72 %defattr(644,root,root,755)
73 %doc AUTHORS INSTALL README
74 %attr(755,root,root) %{_bindir}/SearchAndRescue
75 %{_datadir}/games/%{shortname}
76 %{_pixmapsdir}/SearchAndRescue.xpm
77 %{_mandir}/man6/SearchAndRescue.6*