First step for something doing static friction stuff.
[simgear.git] / SimGear.spec.in
blob4c88771cb03a6daba3d8037dfcd572c53d5ac827
1 %define ver @VERSION@
2 %define rel 1
3 %define prefix /usr
5 Summary: Simulator Construction Gear.
6 Name: @PACKAGE@
7 Version: %ver
8 Release: %rel
9 Copyright: LGPL
10 Group: Libraries/Graphics
11 Source: %{name}-%{version}.tar.gz
12 #URL:
13 BuildRoot: /tmp/%{name}-%{version}-%{rel}-root
14 Packager: Fill In As You Wish
15 Docdir: %{prefix}/doc
17 %description
18 This package contains a tools and libraries useful for constructing
19 simulation and visualization applications such as FlightGear or TerraGear.
21 Authors:
22 N/A
24 %prep
25 %setup -n %{name}-%{version}
28 %build
29 # Needed for snapshot releases.
30 if [ ! -f configure ]; then
31 CFLAGS="$RPM_OPT_FLAGS" ./autogen.sh --prefix=%prefix
32 else
33 CFLAGS="$RPM_OPT_FLAGS" ./configure --prefix=%prefix
36 if [ "$SMP" != "" ]; then
37 JSMP = '"MAKE=make -k -j $SMP"'
40 make ${JSMP};
43 %install
44 [ -d ${RPM_BUILD_ROOT} ] && rm -rf ${RPM_BUILD_ROOT}
46 make prefix=${RPM_BUILD_ROOT}%{prefix} install
49 # Generating file lists and store them in file-lists
50 # Starting with the directory listings
52 find ${RPM_BUILD_ROOT}%{prefix}/{bin,include,lib} -type d | sed "s#^${RPM_BUILD_ROOT}#\%attr (-\,root\,root) \%dir #" > file-lists
53 %{?ETCDR:find ${RPM_BUILD_ROOT}%{!?SYSCF:%{prefix}}/etc -type d | sed "s#^${RPM_BUILD_ROOT}#\%attr (-\,root\,root) \%dir #" >> file-lists}
56 # Then, the file listings
58 echo "%defattr (-, root, root)" >> file-lists
59 %{?ETCDR:find ${RPM_BUILD_ROOT}%{!?SYSCF:%{prefix}}/etc/%{name}.conf -type f | sed -e "s#^${RPM_BUILD_ROOT}#%config #g" >> file-lists}
60 find ${RPM_BUILD_ROOT}%{prefix} -type f | sed -e "s#^${RPM_BUILD_ROOT}##g" >> file-lists
63 %clean
64 (cd ..; rm -rf %{name}-%{version} ${RPM_BUILD_ROOT})
67 %files -f file-lists
68 %defattr (-, root, root)
69 %doc AUTHORS
70 %doc COPYING
71 %doc ChangeLog
72 %doc INSTALL
73 %doc NEWS
74 %doc README
75 %doc %{name}.spec.in