File uae.spec of Package uae

# spec file for package e-uae
%define fullvers 0.8.29-WIP4
%define finalvers 0.8.29_WIP4

Name:           uae
Summary:        A Commodore Amiga emulator
Summary(de):    Ein Commodore Amiga Emulator
License:        GPL
Group:          System/Emulators/Other
Packager:       Dirk Stöcker <opensuse@dstoecker.de>
URL:            http://www.rcdrummond.net/uae/
Version:        %{finalvers}
Release:        1
Source0:        e-uae-%{fullvers}.tar.bz2
Source1:        uae
Source2:        uae.desktop
Source3:        uae_16x16.png
Source4:        uae_22x22.png
Source5:        uae_32x32.png
Source6:        uae_48x48.png
Source7:        uae_64x64.png
Patch:          fixcompiler.patch
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildRequires:  zlib-devel ncurses-devel gcc-c++ SDL-devel
BuildRequires:  atk-devel
BuildRequires:  fontconfig-devel
BuildRequires:  freetype2-devel
BuildRequires:  glib2-devel
BuildRequires:  glibc-devel
BuildRequires:  gtk2
BuildRequires:  gtk2-devel
BuildRequires:  libpng-devel
BuildRequires:  update-desktop-files
BuildRequires:  pango-devel
BuildRequires:  xkeyboard-config
BuildRequires:  autoconf
BuildRequires:  automake
#Requires:       atk
#Requires:       fontconfig
#Requires:       freetype2
#Requires:       glib2
#Requires:       glibc
#Requires:       gtk2
#Requires:       libogg
#Requires:       libpng
#Requires:       pango
Autoreqprov:    on

%if 0%{?suse_version}
# for >= 11.1 validity tests
BuildRequires:  kdelibs3 gnome-icon-theme
%endif

%debug_package

%description
This is a version of UAE, the Ubiquitous Amiga Emulator, with an
emulation core based on WinUAE. It attempts to bring many of
the great features of WinUAE to non-Windows platforms.

%description -l de
Dies ist eine Version von UAE, the Ubiquitous Amiga Emulator, basierend
auf der Basis von WinUAE. Es versucht die vielen großartigen
Features der WinUAE-Version auch für nicht-Windows Plattformen zur
Verfügung zu stellen.

%prep
%setup -q -n e-uae-%{fullvers}
%patch -p1
cp %{S:1} docs/

%build
autoreconf -fi
%{configure} --enable-sound --enable-ui --enable-threads
%{__make} all

%install
[ "${RPM_BUILD_ROOT}" != "/" ] && %{__rm} -rf ${RPM_BUILD_ROOT}
cd src
%{__install} -m 755 -d ${RPM_BUILD_ROOT}%{_bindir}
%{__install} -m 755 -d ${RPM_BUILD_ROOT}%{_libdir}/uae
%{__install} -m 755 uae ${RPM_BUILD_ROOT}%{_bindir}/
%{__install} -m 755 readdisk ${RPM_BUILD_ROOT}%{_libdir}/uae
cd -
cp -a amiga ${RPM_BUILD_ROOT}%{_libdir}/uae
#
# for ROM images
%{__install} -d ${RPM_BUILD_ROOT}%{_libdir}/ei
%{__install} -m 644 %{S:1} ${RPM_BUILD_ROOT}%{_libdir}/ei/uae
#
# menu entry
%{__mkdir_p} ${RPM_BUILD_ROOT}%{_datadir}/applications/
%{__install} -m 644 %{S:2} ${RPM_BUILD_ROOT}%{_datadir}/applications/uae.desktop
%{suse_update_config -f . }
#
# Icons
%{__mkdir_p} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/hicolor/16x16/apps
%{__mkdir_p} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/locolor/16x16/apps
%{__mkdir_p} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/crystalsvg/16x16/apps
%{__install} -m 644 %{S:3} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/hicolor/16x16/apps/uae.png
ln -s ../../../hicolor/16x16/apps/uae.png ${RPM_BUILD_ROOT}/opt/kde3/share/icons/locolor/16x16/apps/uae.png
ln -s ../../../hicolor/16x16/apps/uae.png ${RPM_BUILD_ROOT}/opt/kde3/share/icons/crystalsvg/16x16/apps/uae.png
%{__mkdir_p} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/hicolor/22x22/apps
%{__mkdir_p} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/locolor/22x22/apps
%{__mkdir_p} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/crystalsvg/22x22/apps
%{__install} -m 644 %{S:4} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/hicolor/22x22/apps/uae.png
ln -s ../../../hicolor/22x22/apps/uae.png ${RPM_BUILD_ROOT}/opt/kde3/share/icons/locolor/22x22/apps/uae.png
ln -s ../../../hicolor/22x22/apps/uae.png ${RPM_BUILD_ROOT}/opt/kde3/share/icons/crystalsvg/22x22/apps/uae.png
%{__mkdir_p} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/hicolor/32x32/apps
%{__mkdir_p} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/locolor/32x32/apps
%{__mkdir_p} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/crystalsvg/32x32/apps
%{__install} -m 644 %{S:5} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/hicolor/32x32/apps/uae.png
ln -s ../../../hicolor/32x32/apps/uae.png ${RPM_BUILD_ROOT}/opt/kde3/share/icons/locolor/32x32/apps/uae.png
ln -s ../../../hicolor/32x32/apps/uae.png ${RPM_BUILD_ROOT}/opt/kde3/share/icons/crystalsvg/32x32/apps/uae.png
%{__mkdir_p} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/hicolor/48x48/apps
%{__mkdir_p} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/locolor/48x48/apps
%{__mkdir_p} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/crystalsvg/48x48/apps
%{__install} -m 644 %{S:6} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/hicolor/48x48/apps/uae.png
ln -s ../../../hicolor/48x48/apps/uae.png ${RPM_BUILD_ROOT}/opt/kde3/share/icons/locolor/48x48/apps/uae.png
ln -s ../../../hicolor/48x48/apps/uae.png ${RPM_BUILD_ROOT}/opt/kde3/share/icons/crystalsvg/48x48/apps/uae.png
%{__mkdir_p} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/hicolor/64x64/apps
%{__mkdir_p} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/locolor/64x64/apps
%{__mkdir_p} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/crystalsvg/64x64/apps
%{__install} -m 644 %{S:7} ${RPM_BUILD_ROOT}/opt/kde3/share/icons/hicolor/64x64/apps/uae.png
ln -s ../../../hicolor/64x64/apps/uae.png ${RPM_BUILD_ROOT}/opt/kde3/share/icons/locolor/64x64/apps/uae.png
ln -s ../../../hicolor/64x64/apps/uae.png ${RPM_BUILD_ROOT}/opt/kde3/share/icons/crystalsvg/64x64/apps/uae.png
%{__rm} -rf ${RPM_BUILD_ROOT}%{_datadir}/pixmaps

%clean
[ "${RPM_BUILD_ROOT}" != "/" ] && %{__rm} -rf ${RPM_BUILD_ROOT}

%files
%defattr(-, root, root)
%doc docs/* COPYING src/ChangeLog
%{_libdir}/uae
%exclude %{_libdir}/uae/amiga/source/*.c
%dir %{_libdir}/ei
%{_libdir}/ei/*
%{_datadir}/applications/*
%attr(755,root,root) %{_bindir}/uae
/opt/kde3/share/icons/*/*/apps/uae.png

%changelog
* Sun Sep 30 2007 Dirk Stöcker <opensuse@dstoecker.de> 0.8.29_WIP4
- update to 0.8.29-WIP4
- adapted to openSUSE build service
* Thu Sep 22 2005 Manfred Tremmel 0.8.28
- update to 0.8.28
* Sat Sep 10 2005 Manfred Tremmel 0.8.28
- update to 0.8.28 RC2
* Sat Jan 08 2005 Manfred Tremmel 0.8.27
- update to 0.8.27 final
- cleanups in the spec-file
* Wed Oct 27 2004 Manfred Tremmel 0.8.27rc2
- update to 0.8.27rc2
* Mon Oct 18 2004 Manfred Tremmel
- Initial version