SDL.spec.in
changeset 1133 609c060fd2a2
parent 1008 5fb02068b648
child 1361 19418e4422cb
     1.1 --- a/SDL.spec.in	Thu Aug 25 20:31:58 2005 +0000
     1.2 +++ b/SDL.spec.in	Thu Sep 08 06:16:14 2005 +0000
     1.3 @@ -1,18 +1,16 @@
     1.4 -%define name @PACKAGE@
     1.5 -%define version @VERSION@
     1.6 -%define release 1
     1.7 -
     1.8  Summary: Simple DirectMedia Layer
     1.9 -Name: %{name}
    1.10 -Version: %{version}
    1.11 -Release: %{release}
    1.12 -Source0: %{name}-%{version}.tar.gz
    1.13 +Name: @PACKAGE@
    1.14 +Version: @VERSION@
    1.15 +Release: 1
    1.16 +Source: http://www.libsdl.org/release/%{name}-%{version}.tar.gz
    1.17  URL: http://www.libsdl.org/
    1.18 -Copyright: LGPL
    1.19 +License: LGPL
    1.20  Group: System Environment/Libraries
    1.21 -BuildRoot: /var/tmp/%{name}-buildroot
    1.22 +BuildRoot: %{_tmppath}/%{name}-%{version}-buildroot
    1.23  Prefix: %{_prefix}
    1.24 +%ifos linux
    1.25  Provides: libSDL-1.1.so.0
    1.26 +%endif
    1.27  
    1.28  %description
    1.29  This is the Simple DirectMedia Layer, a generic API that provides low
    1.30 @@ -22,7 +20,7 @@
    1.31  %package devel
    1.32  Summary: Libraries, includes and more to develop SDL applications.
    1.33  Group: Development/Libraries
    1.34 -Requires: %{name}
    1.35 +Requires: %{name} = %{version}
    1.36  
    1.37  %description devel
    1.38  This is the Simple DirectMedia Layer, a generic API that provides low
    1.39 @@ -34,40 +32,62 @@
    1.40  
    1.41  
    1.42  %prep
    1.43 -rm -rf ${RPM_BUILD_ROOT}
    1.44 -
    1.45  %setup -q 
    1.46  
    1.47  %build
    1.48 +%ifos linux
    1.49  CFLAGS="$RPM_OPT_FLAGS" ./configure --prefix=%{prefix} --disable-video-svga --disable-video-ggi --disable-video-aalib --disable-debug --enable-dlopen --enable-esd-shared --enable-arts-shared
    1.50 +%else
    1.51 +%configure --disable-debug --enable-dlopen
    1.52 +%endif
    1.53  make
    1.54  
    1.55  %install
    1.56  rm -rf $RPM_BUILD_ROOT
    1.57 +%ifos linux
    1.58  make install prefix=$RPM_BUILD_ROOT/%{prefix}
    1.59  ln -s libSDL-1.2.so.0 $RPM_BUILD_ROOT/%{prefix}/lib/libSDL-1.1.so.0
    1.60 +%else
    1.61 +%makeinstall
    1.62 +%endif
    1.63  
    1.64  %clean
    1.65  rm -rf $RPM_BUILD_ROOT
    1.66  
    1.67 +%ifnos darwin
    1.68 +%define __defattr %defattr(-,root,root)
    1.69 +%define __soext so
    1.70 +%else
    1.71 +%define __defattr %defattr(-,root,wheel)
    1.72 +%define __soext dylib
    1.73 +%endif
    1.74 +
    1.75  %files
    1.76 -%defattr(-,root,root)
    1.77 +%{__defattr}
    1.78  %doc README-SDL.txt COPYING CREDITS BUGS
    1.79 -%{prefix}/lib/lib*.so.*
    1.80 +%ifnos darwin
    1.81 +%{_libdir}/lib*.%{__soext}.*
    1.82 +%else
    1.83 +%{_libdir}/lib*.*.%{__soext}
    1.84 +%endif
    1.85  
    1.86  %files devel
    1.87  %defattr(-,root,root)
    1.88  %doc README README-SDL.txt COPYING CREDITS BUGS WhatsNew docs.html
    1.89  %doc docs/index.html docs/html
    1.90 -%{prefix}/bin/*-config
    1.91 -%{prefix}/lib/lib*.a
    1.92 -%{prefix}/lib/lib*.la
    1.93 -%{prefix}/lib/lib*.so
    1.94 -%{prefix}/include/SDL/
    1.95 -%{prefix}/man/man3/*
    1.96 -%{prefix}/share/aclocal/*
    1.97 +%{_bindir}/*-config
    1.98 +%{_libdir}/lib*.a
    1.99 +%{_libdir}/lib*.la
   1.100 +%{_libdir}/lib*.%{__soext}
   1.101 +%dir %{_includedir}/SDL
   1.102 +%{_includedir}/SDL/*.h
   1.103 +%{_mandir}/man3/*
   1.104 +%{_datadir}/aclocal/*
   1.105  
   1.106  %changelog
   1.107 +* Mon Jan 03 2004 Anders Bjorklund <afb@algonet.se>
   1.108 +- Added support for Darwin, updated spec file
   1.109 +
   1.110  * Wed Jan 19 2000 Sam Lantinga <slouken@libsdl.org>
   1.111  - Re-integrated spec file into SDL distribution
   1.112  - 'name' and 'version' come from configure