1 |
root |
1.1 |
# |
2 |
root |
1.34 |
# This file is part of Deliantra, the Roguelike Realtime MMORPG. |
3 |
root |
1.30 |
# |
4 |
root |
1.41 |
# Copyright (©) 2007,2008,2009,2010 Marc Alexander Lehmann / Robin Redeker / the Deliantra team |
5 |
root |
1.40 |
# Copyright (©) 2001 Mark Wedel & Crossfire Development Team |
6 |
|
|
# Copyright (©) 1992 Frank Tore Johansen |
7 |
root |
1.30 |
# |
8 |
root |
1.38 |
# Deliantra is free software: you can redistribute it and/or modify it under |
9 |
|
|
# the terms of the Affero GNU General Public License as published by the |
10 |
|
|
# Free Software Foundation, either version 3 of the License, or (at your |
11 |
|
|
# option) any later version. |
12 |
root |
1.30 |
# |
13 |
root |
1.31 |
# This program is distributed in the hope that it will be useful, |
14 |
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
15 |
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
16 |
|
|
# GNU General Public License for more details. |
17 |
root |
1.30 |
# |
18 |
root |
1.38 |
# You should have received a copy of the Affero GNU General Public License |
19 |
|
|
# and the GNU General Public License along with this program. If not, see |
20 |
|
|
# <http://www.gnu.org/licenses/>. |
21 |
root |
1.30 |
# |
22 |
root |
1.34 |
# The authors can be reached via e-mail to <support@deliantra.net> |
23 |
root |
1.1 |
# |
24 |
|
|
|
25 |
|
|
pkgstatedir = @pkgstatedir@ |
26 |
|
|
pkgconfdir = @pkgconfdir@ |
27 |
|
|
|
28 |
root |
1.32 |
nobase_dist_pkgdata_DATA = artifacts formulae races \ |
29 |
root |
1.35 |
attackmess materials cf.pm |
30 |
root |
1.1 |
|
31 |
root |
1.24 |
pmdir = $(pkgdatadir)/cf |
32 |
root |
1.37 |
dist_pm_DATA = cf/pod.pm cf/match.pm cf/mapscript.pm |
33 |
root |
1.24 |
|
34 |
|
|
admdir = $(pkgdatadir)/adm |
35 |
|
|
dist_adm_DATA = adm/map_info adm/map_expand.pl adm/mapslitter.pl adm/archsearch.pl adm/collect_images.pl |
36 |
|
|
|
37 |
root |
1.39 |
CONF_FILES = settings dm_file exp_table config |
38 |
root |
1.26 |
VAR_FILES = highscore bookarch temp.maps |
39 |
root |
1.28 |
EXTRA_DIST = README $(CONF_FILES) |
40 |
root |
1.1 |
|
41 |
root |
1.28 |
MAINTAINERCLEANFILES = Makefile.in |
42 |
root |
1.1 |
|
43 |
|
|
PERL = @PERL@ |
44 |
|
|
|
45 |
root |
1.35 |
install-data-local: |
46 |
root |
1.1 |
@$(NORMAL_INSTALL) |
47 |
root |
1.29 |
$(mkinstalldirs) -m 755 $(DESTDIR)$(pkgdatadir)/maps |
48 |
root |
1.28 |
$(mkinstalldirs) -m 755 $(DESTDIR)$(pkgconfdir) |
49 |
root |
1.1 |
for i in $(CONF_FILES); do \ |
50 |
|
|
if [ ! -f $(DESTDIR)$(pkgconfdir)/$$i ]; then \ |
51 |
|
|
echo "Installing $$i"; \ |
52 |
|
|
$(INSTALL_DATA) $(srcdir)/$$i $(DESTDIR)$(pkgconfdir); \ |
53 |
|
|
fi \ |
54 |
|
|
done |
55 |
root |
1.24 |
$(mkinstalldirs) -m 755 $(DESTDIR)$(pkgstatedir) |
56 |
root |
1.1 |
for i in $(VAR_FILES) ; do \ |
57 |
|
|
touch $(DESTDIR)$(pkgstatedir)/$$i ; \ |
58 |
|
|
done |
59 |
root |
1.24 |
@for i in datafiles players unique-items template-maps maps random db tmp; do \ |
60 |
root |
1.1 |
if [ ! -d $(DESTDIR)$(pkgstatedir)/$$i ]; then \ |
61 |
|
|
echo "Creating directory $(pkgstatedir)/$$i"; \ |
62 |
root |
1.24 |
$(mkinstalldirs) -m 755 $(DESTDIR)$(pkgstatedir)/$$i; \ |
63 |
root |
1.1 |
fi; \ |
64 |
|
|
done |
65 |
|
|
|
66 |
|
|
# Uninstall unchanged config/var files so make distcheck is happy |
67 |
|
|
# but leave changed file, so no configuration/game state is lost |
68 |
|
|
uninstall-local: |
69 |
|
|
-for i in $(CONF_FILES); do \ |
70 |
|
|
if test ! -f $(DESTDIR)$(pkgconfdir)/$$i ; then \ |
71 |
|
|
continue ; \ |
72 |
|
|
fi ; \ |
73 |
|
|
if diff -q $(srcdir)/$$i $(DESTDIR)$(pkgconfdir)/$$i ; then \ |
74 |
|
|
rm -f $(DESTDIR)$(pkgconfdir)/$$i ; \ |
75 |
|
|
fi ; \ |
76 |
|
|
done |
77 |
|
|
-for i in $(VAR_FILES) ; do \ |
78 |
|
|
if test ! -f $(DESTDIR)$(pkgstatedir)/$$i ; then \ |
79 |
|
|
continue ;\ |
80 |
|
|
fi ; \ |
81 |
root |
1.18 |
if ! [ -s "$(DESTDIR)$(pkgstatedir)/$$i" ] ; then \ |
82 |
root |
1.1 |
rm -f $(DESTDIR)$(pkgstatedir)/$$i ; \ |
83 |
|
|
fi ; \ |
84 |
|
|
done |
85 |
|
|
|
86 |
|
|
|