File: Makefile.am

package info (click to toggle)
glib2.0 2.58.3-2
  • links: PTS, VCS
  • area: main
  • in suites: buster, buster-proposed-updates
  • size: 48,744 kB
  • sloc: ansic: 452,196; xml: 16,781; python: 6,149; makefile: 3,776; sh: 1,499; perl: 1,140; cpp: 9
file content (160 lines) | stat: -rw-r--r-- 4,388 bytes parent folder | download | duplicates (2)
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
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
include $(top_srcdir)/glib.mk

SUBDIRS = gobject refcount

LDADD = $(top_builddir)/glib/libglib-2.0.la
AM_CPPFLAGS = $(gmodule_INCLUDES) $(GLIB_DEBUG_FLAGS)
DEFS = -DGLIB_DISABLE_DEPRECATION_WARNINGS -DG_LOG_DOMAIN=\"GLib\"
AM_CFLAGS = -g

# Some random programs that appear not to be testcases and not used from any testcases
check_PROGRAMS += \
	testgdateparser				\
	unicode-normalize			\
	$(NULL)

# So far, this is the only gtester-ified testcase here
test_programs = \
	testglib				\
	$(NULL)

# These are not yet gtester-ified, so mark them as for 'installed' only so we
# don't run them under the framework.  We will handle them manually below.
installed_test_programs = \
	testgdate				\
	datetime				\
	atomic-test				\
	bit-test				\
	child-test				\
	completion-test				\
	dirname-test				\
	file-test				\
	env-test				\
	gio-test				\
	mainloop-test				\
	mapping-test				\
	onceinit				\
	asyncqueue-test				\
	qsort-test				\
	relation-test				\
	slice-concurrent			\
	slice-threadinit			\
	sources					\
	thread-test				\
	threadpool-test				\
	type-test				\
	unicode-caseconv			\
	unicode-encoding			\
	$(NULL)

test_extra_programs = \
	slice-test				\
	slice-color				\
	assert-msg-test				\
	unicode-collate				\
	$(NULL)

if OS_UNIX
test_programs += \
	spawn-test				\
	iochannel-test				\
	$(NULL)

# These don't appear to work installed and we don't want to run them under gtester either...
dist_uninstalled_test_extra_scripts = \
	run-collate-tests.sh			\
	run-assert-msg-test.sh			\
	$(NULL)
endif

dist_test_data = \
	iochannel-test-infile			\
	casemap.txt				\
	casefold.txt				\
	utf8.txt				\
	$(NULL)

# Run the 'installed' tests manually in-tree.
# This will cause them to be built even if installed tests are disabled.
check_PROGRAMS += $(installed_test_programs) $(installed_test_extra_programs)
check_SCRIPTS += $(installed_test_scripts)
TESTS += $(installed_test_programs) $(dist_uninstalled_test_extra_scripts)
AM_TESTS_ENVIRONMENT = \
	G_TEST_SRCDIR=$(abs_srcdir)				\
	G_TEST_BUILDDIR=$(abs_builddir)				\
	LIBCHARSET_ALIAS_DIR=$(top_builddir)/glib/libcharset	\
	MALLOC_CHECK_=2						\
	MALLOC_PERTURB_=$$(($${RANDOM:-256} % 256))

test_programs += module-test
module_test_DEPENDENCIES = libmoduletestplugin_a.la libmoduletestplugin_b.la
module_test_LDADD = $(top_builddir)/gmodule/libgmodule-2.0.la $(LDADD)
module_test_LDFLAGS = $(G_MODULE_LDFLAGS)
slice_test_SOURCES = slice-test.c memchunks.c
slice_color_SOURCES = slice-color.c memchunks.c
slice_threadinit_LDADD = $(top_builddir)/gthread/libgthread-2.0.la $(LDADD)

test_ltlibraries = libmoduletestplugin_a.la libmoduletestplugin_b.la

libmoduletestplugin_a_la_SOURCES = libmoduletestplugin_a.c
libmoduletestplugin_a_la_LDFLAGS = $(G_MODULE_LDFLAGS) -avoid-version -module $(no_undefined)
libmoduletestplugin_a_la_LIBADD = $(G_MODULE_LIBS) ../gmodule/libgmodule-2.0.la ../glib/libglib-2.0.la

libmoduletestplugin_b_la_SOURCES = libmoduletestplugin_b.c
libmoduletestplugin_b_la_LDFLAGS = $(G_MODULE_LDFLAGS) -avoid-version -module $(no_undefined)
libmoduletestplugin_b_la_LIBADD = $(G_MODULE_LIBS) ../gmodule/libgmodule-2.0.la ../glib/libglib-2.0.la

if !ENABLE_INSTALLED_TESTS
# see http://lists.gnu.org/archive/html/bug-libtool/2013-05/msg00009.html and gio/tests/Makefile.am
libmoduletestplugin_a_la_LDFLAGS += -rpath /
libmoduletestplugin_b_la_LDFLAGS += -rpath /
endif

dist-hook: $(BUILT_EXTRA_DIST)
	files='$(BUILT_EXTRA_DIST)';				\
	for f in $$files; do					\
	  if test -f $$f; then d=.; else d=$(srcdir); fi;	\
	  cp $$d/$$f $(distdir) || exit 1;			\
	done
	mkdir $(distdir)/collate;				\
	for f in $(srcdir)/collate/* ; do			\
	  if test -f $$f; then cp $$f $(distdir)/collate; fi;	\
	done

if HAVE_CXX
installed_test_programs += cxx-test
cxx_test_SOURCES = cxx-test.cpp
endif

if ENABLE_TIMELOOP
installed_test_programs += timeloop
endif

if PLATFORM_WIN32
no_undefined = -no-undefined

module_test_exp = module-test.exp

module-test.exp: module-test.o
	$(DLLTOOL) --output-exp module-test.exp module-test.o

installed_test_extra_programs = spawn-test-win32-gui

spawn_test_win32_gui_LDFLAGS = -mwindows

endif

EXTRA_DIST += \
	$(test_scripts)				\
	gen-casefold-txt.py			\
	gen-casemap-txt.py			\
	iochannel-test-infile			\
	timeloop-basic.c			\
	assert-msg-test.gdb

DISTCLEANFILES +=		\
	iochannel-test-outfile	\
	file-test-get-contents	\
	maptest		\
	mapchild		\
	collate.out