swt2c / rpms / megaglest

Forked from rpms/megaglest 5 years ago
Clone
0388f82
Name:		megaglest
ecc7205
Version:	3.7.1
7972304
Release:	8%{?dist}
0388f82
Summary:	Open Source 3d real time strategy game
0388f82
License:	GPLv3+ and GPL+
0388f82
Group:		Amusements/Games
0388f82
Url:		http://megaglest.org/
0388f82
Source0:	http://downloads.sourceforge.net/%{name}/files/%{name}-source-%{version}.tar.xz
0388f82
BuildRequires:	cmake
0388f82
BuildRequires:	desktop-file-utils
0388f82
BuildRequires:	mesa-libGL-devel
0388f82
BuildRequires:	ftgl-devel
0388f82
BuildRequires:	glew-devel
0388f82
BuildRequires:	gnutls-devel
0388f82
BuildRequires:	help2man
0388f82
BuildRequires:	openjpeg-devel
0388f82
BuildRequires:	libcurl-devel
0388f82
BuildRequires:	libicu-devel
0388f82
BuildRequires:	libircclient-devel
0388f82
BuildRequires:	libjpeg-turbo-devel
0388f82
BuildRequires:	libvorbis-devel
0388f82
BuildRequires:	lua-devel
0388f82
BuildRequires:	miniupnpc-devel
0388f82
BuildRequires:	openal-soft-devel
0388f82
BuildRequires:	openssl-devel
0388f82
BuildRequires:	libpng-devel
0388f82
BuildRequires:	SDL-devel
0388f82
BuildRequires:	SDL_mixer-devel
0388f82
BuildRequires:	SDL_net-devel
0388f82
BuildRequires:	subversion
0388f82
BuildRequires:	xerces-c27-devel
0388f82
BuildRequires:	wxGTK-devel
0388f82
BuildRequires:	xorg-x11-server-Xvfb
0388f82
BuildRequires:	zlib-devel
0388f82
Requires:	glx-utils
ecc7205
Requires:	megaglest-data = %{version}
0388f82
Requires:	p7zip
0a78902
Obsoletes:	glest <= 3.2.2
0388f82
0388f82
# Correct use of XERCESC_INCLUDE and XERCESC_INCLUDE_DIR that
0388f82
# should have the same value if xerces is found.
0388f82
Patch0:		%{name}-3.6.0.3-xerces.patch
0388f82
# Correct usage of xvfb-run when generating manpages
0388f82
Patch1:		%{name}-3.6.0.2-help2man.patch
0388f82
# Do not fail with cryptic message if there are missing translations
0388f82
# just use english text
0388f82
Patch2:		%{name}-3.6.0.3-translation-missing.patch
bc02158
# http://sourceforge.net/tracker/?func=detail&aid=3598159&group_id=300350&atid=1266776
bc02158
Patch3:		%{name}-color-picking.patch
946dd47
# https://bugzilla.redhat.com/show_bug.cgi?id=924874
946dd47
# http://sourceforge.net/tracker/?func=detail&aid=3608835&group_id=300350&atid=1266776
946dd47
Patch4:		%{name}-selection.patch
7972304
# https://bugzilla.redhat.com/show_bug.cgi?id=996357
7972304
# http://megaglest.svn.sourceforge.net/viewvc/megaglest?view=revision&revision=3958
7972304
Patch5:		%{name}-miniupnpc-1.7.patch
0388f82
0388f82
%description
0388f82
MegaGlest is an open source 3D-real-time strategy game, where you control
0388f82
the armies of one of seven different factions: Tech, Magic, Egyptians,
0388f82
Indians, Norsemen, Persian or Romans. The game is setup in one of 16
0388f82
naturally looking settings, which -like the unit models- are crafted with
0388f82
great appreciation for detail. Additional game data can be downloaded from
0388f82
within the game at no cost.
0388f82
0388f82
%prep
0388f82
%setup -q
ecc7205
0388f82
%patch0 -p1
0388f82
%patch1 -p1
0388f82
%patch2 -p1
bc02158
%patch3 -p1
946dd47
%patch4 -p1
7972304
%if 0%{?fedora} >= 20
7972304
%patch5 -p1
7972304
%endif
0388f82
0388f82
%build
0388f82
mkdir -p build
0388f82
pushd build
0388f82
    export XERCESC_INCLUDE_DIR=%{_includedir}/xercesc-2.7.0
0388f82
    export XERCESC_LIBRARY_DIR=%{_libdir}/xerces-c-2.7.0
0388f82
    %cmake								\
0388f82
	-DMEGAGLEST_BIN_INSTALL_PATH=%{_bindir}				\
0388f82
	-DMEGAGLEST_ICON_INSTALL_PATH=%{_datadir}/icons			\
0388f82
	..
0388f82
    make %{?_smp_mflags}
0388f82
popd
0388f82
0388f82
%install
0388f82
make install DESTDIR=${RPM_BUILD_ROOT} -C build
0388f82
install -d $RPM_BUILD_ROOT%{_datadir}/megaglest
0388f82
for image in `ls $RPM_BUILD_ROOT%{_datadir}/icons`; do
0388f82
    [ -e $RPM_BUILD_ROOT%{_datadir}/$image ] ||
0388f82
	ln -sf %{_datadir}/icons/$image $RPM_BUILD_ROOT%{_datadir}/megaglest
0388f82
done
0388f82
# installed by megaglest-data
0388f82
rm $RPM_BUILD_ROOT%{_datadir}/megaglest/megaglest.bmp
ecc7205
for file in megaglest megaglest_editor megaglest_g3dviewer; do
ecc7205
    desktop-file-validate ${RPM_BUILD_ROOT}%{_datadir}/applications/$file.desktop
ecc7205
done
0388f82
0388f82
%files
0388f82
%doc AUTHORS.source_code.txt
0388f82
%doc CHANGELOG.txt
0388f82
%doc COPYRIGHT.source_code.txt
0388f82
%doc gnu_gpl_3.0.txt
0388f82
%doc README.txt
0388f82
%{_bindir}/*
ecc7205
%{_datadir}/applications/megaglest*.desktop
0388f82
%{_datadir}/icons/*
0388f82
%{_mandir}/man6/*.6*
0388f82
%{_datadir}/megaglest/*
0388f82
0388f82
%changelog
7972304
* Wed Aug 14 2013 pcpa <paulo.cesar.pereira.de.andrade@gmail.com> - 3.7.1-8
7972304
- Add support for minupnpc >= 1.7 (#996357)
7972304
7989045
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.7.1-7
7989045
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
7989045
946dd47
* Fri Mar 29 2013 pcpa <paulo.cesar.pereira.de.andrade@gmail.com> - 3.7.1-4
946dd47
- Correct crash with NULL unit in selection (#924874)
946dd47
4314e84
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.7.1-5
4314e84
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
4314e84
Adam Tkac 8a7d3eb
* Mon Jan 21 2013 Adam Tkac <atkac redhat com> - 3.7.1-4
Adam Tkac 8a7d3eb
- rebuild due to "jpeg8-ABI" feature drop
Adam Tkac 8a7d3eb
bc02158
* Wed Jan 16 2013 pcpa <paulo.cesar.pereira.de.andrade@gmail.com> - 3.7.1-3
bc02158
- Add patch suggested by upstream for better color picking selection mode.
bc02158
1838b38
* Thu Dec 13 2012 Adam Jackson <ajax@redhat.com> - 3.7.1-2
1838b38
- Rebuild for glew 1.9.0
1838b38
ecc7205
* Fri Nov 23 2012 pcpa <paulo.cesar.pereira.de.andrade@gmail.com> - 3.7.1-1
ecc7205
- Update to latest upstream release.
ecc7205
- Remove no longer required gcc 4.7 patch.
ecc7205
- Add versioned requires to megaglest-data.
ecc7205
0388f82
* Thu Jul 19 2012 pcpa <paulo.cesar.pereira.de.andrade@gmail.com> - 3.6.0.3-5
0388f82
- Do not use %%{_iconsdir} macro (#817315).
0388f82
- Correct libjpeg-turbo-devel build requires (#817315).
0388f82
- Add missing desktop-file-utils build requires (#817315).
0388f82
- Update license tag to match source files (#817315).
0388f82
0388f82
* Fri Jul 13 2012 pcpa <paulo.cesar.pereira.de.andrade@gmail.com> - 3.6.0.3-4
0388f82
- Add turbojpeg-devel to build requires.
0388f82
- Install documentation (#817315).
0388f82
- Correct sourceforge source url (#817315).
0388f82
0388f82
* Fri Jun  1 2012 pcpa <paulo.cesar.pereira.de.andrade@gmail.com> - 3.6.0.3-3
0388f82
- Removed %%defattr.
0388f82
- Update to build with gcc 4.7.
0388f82
- Do not own %%{_datadir}/megaglest as megaglest-data is required.
0388f82
- Remove comments about pending review requests of build requires.
0388f82
0388f82
* Wed May  2 2012 pcpa <paulo.cesar.pereira.de.andrade@gmail.com> - 3.6.0.3-2
0388f82
- Remove no longer required patch to link to openssl and static libircclient.
0388f82
- Update build requires for miniupnpc rename.
0388f82
0388f82
* Sat Apr 28 2012 pcpa <paulo.cesar.pereira.de.andrade@gmail.com> - 3.6.0.3-1
0388f82
- Initial megaglest spec.