Blob Blame History Raw
Name:           love
Version:        0.9.2
Release:        1%{?dist}
Summary:        A free 2D game engine which enables easy game creation in Lua

#All is licensed as zlib with one exception:
#SOURCE/platform/unix/ltmain.sh is public domain
License:        zlib and Public Domain
URL:            http://love2d.org
Source0:        https://bitbucket.org/rude/%{name}/get/%{version}.tar.gz

BuildRequires:  DevIL-devel
BuildRequires:  mesa-libGL
BuildRequires:  libtiff-devel
BuildRequires:  freetype-devel
BuildRequires:  luajit-devel
BuildRequires:  physfs-devel
BuildRequires:  SDL2-devel
BuildRequires:  openal-soft-devel
BuildRequires:  libogg-devel
BuildRequires:  libvorbis-devel
BuildRequires:  flac-devel
BuildRequires:  libmodplug-devel
BuildRequires:  libmng-devel
BuildRequires:  desktop-file-utils
BuildRequires:  libtool
Requires: 	lib%{name}%{?_isa} = %{version}-%{release}
Requires:	hicolor-icon-theme
 
%description
LOVE is an open source, cross platform 2D game engine which uses the
Lua scripting language. LOVE can be used to make games of any license
allowing it to be used for both free and non-free projects.

%package -n lib%{name}
Summary:        Library for Love, A free 2D game engine

%description -n lib%{name}
This package includes the library files for LOVE.
LOVE is an open source, cross platform 2D game engine which uses the
Lua scripting language. LOVE can be used to make games of any license
allowing it to be used for both free and non-free projects.

%prep
%setup -q -n rude-%{name}-8b113c345e97
#Fixing line encoding:
sed -i 's/\r//' license.txt src/libraries/Box2D/*/*.* src/libraries/Box2D/*/*/*.*
#Fixing permissions:
chmod -x license.txt src/libraries/*/*/*.* src/libraries/Box2D/*/*/*.*

%build
platform/unix/automagic
%configure  --prefix=/usr --disable-mpg123 --enable-static=no
make %{?_smp_mflags}
 
%install
make %{?_smp_mflags} install DESTDIR=%{buildroot}
#Check Desktop file
desktop-file-validate \
  %{buildroot}%{_datadir}/applications/%{name}.desktop
#This seems to be built, despite disabling static libraries
rm -f %{buildroot}%{_libdir}/lib%{name}.la

%post
/sbin/ldconfig
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
/bin/touch --no-create %{_datadir}/mime/packages &> /dev/null || :
/usr/bin/update-desktop-database &> /dev/null || :

%postun
/sbin/ldconfig
if [ $1 -eq 0 ] ; then
    /bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null
    /usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
    /bin/touch --no-create %{_datadir}/mime/packages &> /dev/null || :
    /usr/bin/update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :
fi
/usr/bin/update-desktop-database &> /dev/null || :
 
%posttrans
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
/usr/bin/update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :

%post -n lib%{name} -p /sbin/ldconfig

%postun -n lib%{name} -p /sbin/ldconfig

%files
%doc changes.txt license.txt readme.md
%{_bindir}/%{name}
%{_datadir}/pixmaps/%{name}.svg
%{_datadir}/icons/hicolor/scalable/mimetypes/application-x-%{name}-game.svg
%{_datadir}/applications/%{name}.desktop
%{_datadir}/mime/packages/%{name}.xml
%{_mandir}/man1/%{name}.*

%files -n lib%{name}
%doc changes.txt license.txt readme.md
#Note that liblove.so is just a symlink, so a devel package is useless
%{_libdir}/lib%{name}.*
 
%changelog
* Mon May 11 2015 Jeremy Newton <alexjnewt@hotmail.com> - 0.9.2-1
- Update to 0.9.2

* Wed Nov 12 2014 Jeremy Newton <alexjnewt@hotmail.com> - 0.9.1-1
- Update to 0.9.1

* Mon Aug 18 2014 Rex Dieter <rdieter@fedoraproject.org> 0.9.0-5
- update mime scriptlets

* Sun Aug 17 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.0-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild

* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.0-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild

* Sun Jan 5 2014 Jeremy Newton <alexjnewt@hotmail.com> - 0.9.0-2
- Use repo version, fixes opengl issue

* Wed Jan 1 2014 Jeremy Newton <alexjnewt@hotmail.com> - 0.9.0-1
- New upstream 0.9.0
- Removed all patches/sources (all fixed in 0.9.0)
- Add disable-mpg123 flag and enable-static=no
- Split into 2 packages, love and liblove

* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.8.0-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild

* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.8.0-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild

* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.8.0-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild

* Tue Apr 3 2012 Jeremy Newton <alexjnewt@hotmail.com> - 0.8.0-2
- Fixed a typo in the manpage
- Fixed minor typo in files

* Tue Apr 3 2012 Jeremy Newton <alexjnewt@hotmail.com> - 0.8.0-1
- Updated spec for new upstream version

* Wed Mar 28 2012 Jeremy Newton <alexjnewt@hotmail.com> - 0.7.2-3
- Added man page
- Made more use of the name macro
- Removed unnecessary build flags
- Fixed typo in changelog

* Tue Mar 27 2012 Jeremy Newton <alexjnewt@hotmail.com> - 0.7.2-2
- Added missing build dependencies

* Tue Mar 6 2012 Jeremy Newton <alexjnewt@hotmail.com> - 0.7.2-1
- Initial Package