1 |
# |
2 |
# Makefile for crossfire 0.95.0 and beyond |
3 |
# |
4 |
# This file will eventually be replaced by a configure script. But for |
5 |
# now, this simple makefile should do the job. |
6 |
# |
7 |
# Copyright (C) 1992 Frank Tore Johansen |
8 |
# Copyright (C) 2001 Mark Wedel |
9 |
# |
10 |
# This program is free software; you can redistribute it and/or modify |
11 |
# it under the terms of the GNU General Public License as published by |
12 |
# the Free Software Foundation; either version 2 of the License, or |
13 |
# (at your option) any later version. |
14 |
# |
15 |
# This program is distributed in the hope that it will be useful, |
16 |
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
17 |
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
18 |
# GNU General Public License for more details. |
19 |
# |
20 |
# You should have received a copy of the GNU General Public License |
21 |
# along with this program; if not, write to the Free Software |
22 |
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. |
23 |
# |
24 |
# The author can be reached via e-mail to mwedel@sonic.net |
25 |
|
26 |
plugindir=$(pkglibdir)/plugins |
27 |
|
28 |
MAINTAINERCLEANFILES = Makefile.in |
29 |
|
30 |
if PERL_PLUGIN |
31 |
noinst_HEADERS = ../common/include/plugin_common.h |
32 |
plugin_LTLIBRARIES = cfperl.la |
33 |
cfperl_la_SOURCES = cfperl.xs ../common/plugin_common.C |
34 |
|
35 |
cfperl_la_LIBADD = $(PERLLIB) |
36 |
cfperl_la_LDFLAGS = -module -avoid-version -Xlinker -export-dynamic -rdynamic -Xlinker -Bsymbolic |
37 |
AM_CPPFLAGS = -I$(srcdir)/include -I../common/include -I$(top_srcdir)/include $(PERLFLAGS) |
38 |
|
39 |
SUFFIXES = .xs |
40 |
|
41 |
.xs.C: typemap |
42 |
$(PERL) -MExtUtils::Embed -e xsinit -- -std cf |
43 |
$(PERL) @PERLPRIVLIBEXP@/ExtUtils/xsubpp -C++ -csuffix .C -typemap @PERLPRIVLIBEXP@/ExtUtils/typemap -typemap typemap -prototypes cfperl.xs >$@ |
44 |
|
45 |
endif |
46 |
|
47 |
proto: |
48 |
cproto -D__CEXTRACT__ -o include/plugin_template_proto.h $(CPPFLAGS) $(AM_CPPFLAGS) \ |
49 |
`echo $(SOURCES) " " | $(AWK) -v RS=" " '/.C$$/ { print }'` |
50 |
chmod 644 include/plugin_template_proto.h |
51 |
|