summaryrefslogtreecommitdiff
path: root/Makefile-giscanner.am
blob: e8def0ee0b1a62ec6bc5863c478d12e3c833b71d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
## Process this file with automake to produce Makefile.in

BUILT_SOURCES += 		\
	scannerparser.c		\
	scannerparser.h 	\
	scannerlexer.c 		\
	scannerlexer.h

AM_YFLAGS = -d -t

# Why do I have to do this automake?
scannerlexer.h: scannerlexer.c

noinst_LTLIBRARIES += libgiscanner.la

libgiscanner_la_SOURCES = \
	giscanner/sourcescanner.c				\
	giscanner/sourcescanner.h				\
	giscanner/scannerlexer.l				\
	giscanner/scannerparser.y				\
	giscanner/grealpath.h
libgiscanner_la_CPPFLAGS = -I$(top_srcdir)/girepository -I$(top_srcdir)/giscanner
libgiscanner_la_LIBADD = $(GOBJECT_LIBS) $(GIO_LIBS)
libgiscanner_la_CFLAGS = $(GOBJECT_CFLAGS) $(GIO_CFLAGS)

# Python module
pkgpyexecdir = $(pkglibdir)/giscanner
pkgpyexec_LTLIBRARIES = _giscanner.la
pkgpyexec_PYTHON =		\
	giscanner/__init__.py		\
	giscanner/annotationmain.py	\
	giscanner/annotationparser.py	\
	giscanner/ast.py		\
	giscanner/cachestore.py		\
	giscanner/codegen.py		\
	giscanner/docmain.py	\
	giscanner/docwriter.py		\
	giscanner/dumper.py		\
	giscanner/introspectablepass.py	\
	giscanner/girparser.py		\
	giscanner/girwriter.py		\
	giscanner/gdumpparser.py 	\
	giscanner/libtoolimporter.py	\
	giscanner/odict.py		\
	giscanner/maintransformer.py	\
	giscanner/message.py		\
	giscanner/shlibs.py		\
	giscanner/scannermain.py	\
	giscanner/sectionparser.py	\
	giscanner/sourcescanner.py	\
	giscanner/testcodegen.py	\
	giscanner/transformer.py	\
	giscanner/utils.py		\
	giscanner/xmlwriter.py

templatedir = $(pkglibdir)
nobase_dist_template_DATA =		\
	giscanner/doctemplates/base.tmpl	\
	giscanner/doctemplates/class.tmpl	\
	giscanner/doctemplates/namespace.tmpl	\
	giscanner/doctemplates/C/class.tmpl	\
	giscanner/doctemplates/C/constructor.tmpl	\
	giscanner/doctemplates/C/default.tmpl	\
	giscanner/doctemplates/C/enum.tmpl	\
	giscanner/doctemplates/C/function.tmpl	\
	giscanner/doctemplates/C/method.tmpl		\
	giscanner/doctemplates/C/namespace.tmpl	\
	giscanner/doctemplates/C/property.tmpl	\
	giscanner/doctemplates/C/record.tmpl	\
	giscanner/doctemplates/C/signal.tmpl	\
	giscanner/doctemplates/C/vfunc.tmpl	\
	giscanner/doctemplates/Python/class.tmpl	\
	giscanner/doctemplates/Python/constructor.tmpl	\
	giscanner/doctemplates/Python/default.tmpl	\
	giscanner/doctemplates/Python/enum.tmpl	\
	giscanner/doctemplates/Python/function.tmpl	\
	giscanner/doctemplates/Python/method.tmpl	\
	giscanner/doctemplates/Python/namespace.tmpl	\
	giscanner/doctemplates/Python/property.tmpl	\
	giscanner/doctemplates/Python/record.tmpl	\
	giscanner/doctemplates/Python/signal.tmpl	\
	giscanner/doctemplates/Python/vfunc.tmpl	\
	giscanner/doctemplates/Gjs/class.tmpl	\
	giscanner/doctemplates/Gjs/constructor.tmpl	\
	giscanner/doctemplates/Gjs/default.tmpl	\
	giscanner/doctemplates/Gjs/enum.tmpl	\
	giscanner/doctemplates/Gjs/function.tmpl	\
	giscanner/doctemplates/Gjs/method.tmpl	\
	giscanner/doctemplates/Gjs/namespace.tmpl	\
	giscanner/doctemplates/Gjs/property.tmpl	\
	giscanner/doctemplates/Gjs/record.tmpl	\
	giscanner/doctemplates/Gjs/signal.tmpl	\
	giscanner/doctemplates/Gjs/vfunc.tmpl

_giscanner_la_CFLAGS = \
	$(PYTHON_INCLUDES) \
	$(GOBJECT_CFLAGS) \
	-I$(top_srcdir)/giscanner
_giscanner_la_LIBADD = libgiscanner.la $(GOBJECT_LIBS)

_giscanner_la_LDFLAGS = \
	-module -avoid-version -export-symbols-regex init_giscanner

if OS_WIN32
# Windows requires Python extension modules to be explicitly
# linked to libpython. Extension modules are shared libaries
# (.dll files), but need to be called .pyd for Python to load
# them as extension modules.
_giscanner_la_LIBADD += \
	$(PYTHON_LIBS)

_giscanner_la_LDFLAGS += \
	-no-undefined \
	-shrext ".pyd"
endif

_giscanner_la_SOURCES = giscanner/giscannermodule.c