1 |
%define game_version %{version} |
2 |
|
3 |
Name: minetest |
4 |
Version: 5.0.0 |
5 |
Release: %mkrel 1 |
6 |
Summary: Open source voxel game engine and InfiniMiner/Minecraft-inspired game |
7 |
Group: Games/Simulation |
8 |
License: LGPLv2+ and CC-BY-SA 3.0 |
9 |
URL: http://minetest.net |
10 |
Source0: https://github.com/minetest/minetest/archive/%{version}/%{name}-%{version}.tar.gz |
11 |
Source1: https://github.com/minetest/minetest_game/archive/%{version}/%{name}_game-%{game_version}.tar.gz |
12 |
|
13 |
BuildRequires: cmake |
14 |
BuildRequires: bzip2-devel |
15 |
BuildRequires: gettext |
16 |
BuildRequires: gmp-devel |
17 |
BuildRequires: irrlicht-devel |
18 |
BuildRequires: pkgconfig(jsoncpp) |
19 |
BuildRequires: pkgconfig(freetype2) |
20 |
BuildRequires: pkgconfig(gl) |
21 |
BuildRequires: pkgconfig(leveldb) |
22 |
BuildRequires: pkgconfig(libcurl) |
23 |
BuildRequires: pkgconfig(libjpeg) |
24 |
BuildRequires: pkgconfig(libpng) |
25 |
BuildRequires: pkgconfig(luajit) |
26 |
BuildRequires: pkgconfig(openal) |
27 |
BuildRequires: pkgconfig(ncursesw) |
28 |
BuildRequires: pkgconfig(sqlite3) |
29 |
BuildRequires: pkgconfig(vorbisfile) |
30 |
BuildRequires: pkgconfig(x11) |
31 |
BuildRequires: pkgconfig(zlib) |
32 |
|
33 |
%description |
34 |
Minetest in an open source voxel game engine. You can play one of the many |
35 |
games designed by its community, mod a game to your liking, make your own |
36 |
game, or play on a multiplayer server. |
37 |
|
38 |
The base package comes with the default Minetest game and some pre-installed |
39 |
mods, which should provide a gaming experience similar to Minecraft. |
40 |
|
41 |
%prep |
42 |
%autosetup -p1 -a 1 |
43 |
|
44 |
# purge bundled jsoncpp and lua, and gmp |
45 |
rm -rf lib/jsoncpp lib/lua lib/gmp |
46 |
|
47 |
%build |
48 |
%cmake \ |
49 |
-DRUN_IN_PLACE=0 \ |
50 |
-DBUILD_SHARED_LIBS=OFF \ |
51 |
-DCUSTOM_BINDIR:STRING=%{_gamesbindir} \ |
52 |
-DCUSTOM_LOCALEDIR:STRING=%{_datadir}/locale \ |
53 |
-DCUSTOM_SHAREDIR:STRING=%{_gamesdatadir}/%{name} \ |
54 |
-DENABLE_CURL:BOOL=ON \ |
55 |
-DENABLE_FREETYPE:BOOL=ON \ |
56 |
-DENABLE_GETTEXT:BOOL=ON \ |
57 |
-DENABLE_LEVELDB:BOOL=ON \ |
58 |
-DENABLE_REDIS:BOOL=OFF \ |
59 |
-DENABLE_SOUND:BOOL=ON \ |
60 |
-DENABLE_SYSTEM_GMP:BOOL=ON \ |
61 |
-DENABLE_SYSTEM_JSONCPP:BOOL=ON |
62 |
%make_build |
63 |
|
64 |
%install |
65 |
%make_install -C build |
66 |
install -d %{buildroot}%{_gamesdatadir}/%{name}/games/%{name}_game |
67 |
cp -r %{name}_game-%{game_version}/* %{buildroot}%{_gamesdatadir}/%{name}/games/%{name}_game |
68 |
|
69 |
rm -rf %{buildroot}%{_gamesdatadir}/%{name}/client/serverlist/.gitignore |
70 |
|
71 |
%find_lang %{name} |
72 |
|
73 |
%files -f %{name}.lang |
74 |
%doc doc/* CONTRIBUTING.md README.md minetest.conf.example |
75 |
%license LICENSE.txt |
76 |
%{_gamesbindir}/%{name} |
77 |
%{_gamesdatadir}/%{name}/ |
78 |
%{_datadir}/applications/net.minetest.%{name}.desktop |
79 |
%{_datadir}/metainfo/net.minetest.%{name}.appdata.xml |
80 |
%{_iconsdir}/hicolor/*/apps/%{name}.* |
81 |
%{_mandir}/man6/%{name}.6* |
82 |
%{_mandir}/man6/%{name}server.6* |