]>
Commit | Line | Data |
---|---|---|
a50ef3ef MK |
1 | # TODO: |
2 | # - Make FlightGear-extra-planes for subset of planes from | |
3 | # http://www.flightgear.org/Downloads/aircraft/index.shtml | |
4 | ||
b64a59c0 JR |
5 | # |
6 | # Conditional build: | |
7 | %bcond_without data # don't build data package (for quick test build) | |
8 | # | |
d34c95c6 | 9 | Summary: Free Flight Simulator |
610acf07 | 10 | Summary(pl.UTF-8): darmowy symulator lotu |
d34c95c6 | 11 | Name: FlightGear |
0c8a774f | 12 | Version: 3.2.0 |
756ca1e7 | 13 | Release: 3 |
c1c0842e | 14 | License: GPL |
711dfa5c | 15 | Group: X11/Applications/Games |
46bc8cac | 16 | Source0: ftp://mirrors.ibiblio.org/pub/mirrors/flightgear/ftp/Source/flightgear-%{version}.tar.bz2 |
2c5745df | 17 | # Source0-md5: 0a16920cc22ea070f8bb345e76c55e05 |
0c8a774f | 18 | Source1: ftp://mirrors.ibiblio.org/pub/mirrors/flightgear/ftp/Shared/%{name}-data-%{version}.tar.bz2 |
2c5745df | 19 | # Source1-md5: 24774fae7199bcbc5e23672f4a586884 |
46bc8cac BS |
20 | #Source2: ftp://ftp.flightgear.org/pub/fgfs/Everything-0.7/Base-Packages/fgfs-docs-0.7.7.tar.gz |
21 | ## Source2-md5: 31f35d3e63e522565e8990ead99e7507 | |
22 | Patch0: flightgear-cmake.patch | |
934b87b5 | 23 | Patch1: OpenSceneGraph-3.3.2.patch |
e5414c2b | 24 | Patch2: rtti-fix.patch |
8f23fd40 | 25 | URL: http://www.flightgear.org/ |
a153cd5e | 26 | BuildRequires: OpenAL-devel |
d34c95c6 | 27 | BuildRequires: OpenGL-devel |
aaa9c0e2 | 28 | BuildRequires: OpenSceneGraph-devel |
46bc8cac | 29 | BuildRequires: SimGear-devel = %{version} |
175f976e | 30 | BuildRequires: cmake |
aaa9c0e2 | 31 | BuildRequires: flite-devel |
175f976e | 32 | BuildRequires: fltk-gl-devel |
a3031fc6 | 33 | BuildRequires: freeglut-devel |
aaa9c0e2 | 34 | BuildRequires: libgsm-devel |
c1c0842e | 35 | BuildRequires: libstdc++-devel |
aaa9c0e2 JR |
36 | BuildRequires: speex-devel |
37 | BuildRequires: sqlite3-devel | |
a3031fc6 | 38 | BuildRequires: plib-devel >= 1.8.5-3 |
d34c95c6 | 39 | BuildRequires: zlib-devel |
175f976e | 40 | Requires: %{name}-data = %{version} |
8f23fd40 | 41 | Requires: OpenGL |
46bc8cac | 42 | Requires: OpenSceneGraph-plugins |
cac4e65d | 43 | Requires: plib >= 1.8.4 |
d34c95c6 SZ |
44 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
45 | ||
175f976e | 46 | %define _noautoreqdep libGL.so.1 libGLU.so.1 libGLcore.so.1 |
d34c95c6 SZ |
47 | |
48 | %description | |
711dfa5c AM |
49 | The Flight Gear project is working to create a sophisticated flight |
50 | simulator framework for the development and pursuit of interesting | |
51 | flight simulator ideas. We are developing a solid basic sim that can | |
52 | be expanded and improved upon by anyone interested in contributing. | |
d34c95c6 | 53 | |
3dc5f513 JR |
54 | %description -l pl.UTF-8 |
55 | Projekt Flight Gear to wyrafinowany symulator lotów pozwalający | |
56 | rozpowszechniać idee tego typu symulacji. | |
d34c95c6 | 57 | |
175f976e ER |
58 | %package data |
59 | Summary: FlightGear base scenery and data files | |
60 | License: GPL v2+ | |
61 | Group: Applications/Games | |
62 | %if "%{_rpmversion}" >= "5" | |
63 | BuildArch: noarch | |
64 | %endif | |
65 | ||
66 | %description data | |
67 | This package contains the base scenery for FlightGear and must be | |
68 | installed | |
69 | ||
d34c95c6 | 70 | %prep |
b64a59c0 | 71 | %setup -q -n flightgear-%{version} %{?with_data:-a 1} |
3fc14c12 | 72 | %patch0 -p1 |
934b87b5 | 73 | %patch1 -p1 |
e5414c2b | 74 | %patch2 -p1 |
a50ef3ef | 75 | |
175f976e ER |
76 | cat > runfgfs <<'EOF' |
77 | #!/bin/sh | |
78 | exec %{_bindir}/fgfs --fg-root=%{_datadir}/games/%{name}/fgdata "$@" | |
79 | EOF | |
dc205acb | 80 | |
d34c95c6 | 81 | %build |
46bc8cac BS |
82 | install -d build |
83 | cd build | |
aaa9c0e2 JR |
84 | %cmake .. \ |
85 | -DSYSTEM_SQLITE:BOOL=ON | |
86 | ||
d34c95c6 SZ |
87 | %{__make} |
88 | ||
89 | %install | |
90 | rm -rf $RPM_BUILD_ROOT | |
46bc8cac | 91 | install -d $RPM_BUILD_ROOT%{_datadir}/games/%{name} |
aaa9c0e2 | 92 | |
46bc8cac | 93 | %{__make} -C build install \ |
f0896299 | 94 | DESTDIR=$RPM_BUILD_ROOT |
d34c95c6 | 95 | |
175f976e | 96 | install -p runfgfs $RPM_BUILD_ROOT%{_bindir} |
b64a59c0 | 97 | %if %{with data} |
175f976e | 98 | cp -a fgdata $RPM_BUILD_ROOT%{_datadir}/games/%{name} |
b64a59c0 | 99 | %endif |
d34c95c6 | 100 | |
d34c95c6 SZ |
101 | %clean |
102 | rm -rf $RPM_BUILD_ROOT | |
103 | ||
104 | %files | |
105 | %defattr(644,root,root,755) | |
46bc8cac | 106 | %doc AUTHORS NEWS docs-mini/* |
fcf6484d | 107 | %attr(755,root,root) %{_bindir}/* |
2819a467 | 108 | %{_mandir}/*/* |
175f976e | 109 | |
b64a59c0 | 110 | %if %{with data} |
175f976e ER |
111 | %files data |
112 | %defattr(644,root,root,755) | |
113 | %{_datadir}/games/%{name} | |
b64a59c0 | 114 | %endif |