~drizzle-trunk/drizzle/development

992.1.25 by Monty Taylor
Moved myisam to new plugin system.
1
#  Copyright (C) 2009 Sun Microsystems
2
#
3
#  This program is free software; you can redistribute it and/or modify
4
#  it under the terms of the GNU General Public License as published by
5
#  the Free Software Foundation; version 2 of the License.
6
#
7
#  This program is distributed in the hope that it will be useful,
8
#  but WITHOUT ANY WARRANTY; without even the implied warranty of
9
#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
10
#  GNU General Public License for more details.
11
#
12
#  You should have received a copy of the GNU General Public License
13
#  along with this program; if not, write to the Free Software
14
#  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
1 by brian
clean slate
15
722.2.9 by Monty Taylor
I _think_ I've got the plug.in triggering rebuild thing going on right.
16
ACLOCAL_AMFLAGS = -I m4 --force
475 by Monty Taylor
Added m4 files for deficient systems. Changed include mechanism to not need
17
1 by brian
clean slate
18
# Process this file with automake to create Makefile.in
312.1.8 by Monty Taylor
Don't build po dir if we don't have gettext.
19
if BUILD_GETTEXT
20
  po=po
21
endif
1 by brian
clean slate
22
992.1.15 by Monty Taylor
Moved mysys build into root Makefile.
23
SUBDIRS = ${po} \
815.1.1 by Monty Taylor
Add timegm which is missing on Solaris.
24
	  gnulib \
992.1.17 by Monty Taylor
Moved extra/ into root Makefile.am
25
	  drizzled/message \
992.1.15 by Monty Taylor
Moved mysys build into root Makefile.
26
	  . \
997.2.19 by Monty Taylor
Reverted back to building drizzled in drizzled.
27
	  drizzled \
187 by Brian Aker
Fixed tab issue
28
	  tests \
29
	  support-files
30
997.2.19 by Monty Taylor
Reverted back to building drizzled in drizzled.
31
BUILT_SOURCES=		drizzled/configmake.h
32
EXTRA_DIST=		config/config.rpath m4/gnulib-cache.m4 \
1003.2.2 by Monty Taylor
Fixed autorun.sh to actually work from a tarball.
33
			config/plugin.ac config/plugin.am \
34
			config/autorun.sh
1022.2.28 by Monty Taylor
Build/dist fixes. Added my_print_defaults back for now - test_run needs it. But now it's a noinst. Moving forward, it either needs to be renamed and installed properly, or it needs to have its functionality wrapped up into something else.
35
997.2.19 by Monty Taylor
Reverted back to building drizzled in drizzled.
36
CLEANFILES=		${BUILT_SOURCES}
37
DISTCLEANFILES=		ac_available_languages_fragment
38
MAINTAINERCLEANFILES=	autom4te.cache
992.1.18 by Monty Taylor
Moved client build into root Makefile.
39
40
CLIENT_LDADD=		mysys/libmysys.la \
41
			mystrings/libmystrings.la \
42
			$(LIBDRIZZLE) $(LIBINTL) $(LIBZ) \
43
			client/libgetpassword.la
44
45
noinst_LTLIBRARIES= \
46
		client/libgetpassword.la \
47
		mysys/libmysys.la \
48
		mystrings/libmystrings.la
992.1.15 by Monty Taylor
Moved mysys build into root Makefile.
49
1022.2.24 by Monty Taylor
Removed my_print_defaults, innochecksum and mysql_waitpid. Two are crap - one does't belong here.
50
noinst_PROGRAMS=\
1022.2.28 by Monty Taylor
Build/dist fixes. Added my_print_defaults back for now - test_run needs it. But now it's a noinst. Moving forward, it either needs to be renamed and installed properly, or it needs to have its functionality wrapped up into something else.
51
		client/drizzletest \
52
		extra/my_print_defaults
1022.2.26 by Monty Taylor
Fixed an oops.
53
997.2.13 by Monty Taylor
Made client programs install properly.
54
bin_PROGRAMS= \
992.1.18 by Monty Taylor
Moved client build into root Makefile.
55
		client/drizzle \
56
		client/drizzlecheck \
57
		client/drizzledump \
58
		client/drizzleimport \
1022.2.26 by Monty Taylor
Fixed an oops.
59
		client/drizzleslap
992.1.17 by Monty Taylor
Moved extra/ into root Makefile.am
60
1022.2.25 by Monty Taylor
Imported manpages for the things we ship. Started to edit the names of thing. Changed the port/password options in the drizzle.1 manpage.
61
man_MANS=\
62
		client/drizzle.1 \
63
		client/drizzlecheck.1 \
64
		client/drizzled.8 \
65
		client/drizzledump.1 \
66
		client/drizzleimport.1 \
67
		client/drizzleslap.1
992.1.18 by Monty Taylor
Moved client build into root Makefile.
68
69
client_libgetpassword_la_SOURCES= client/get_password.cc
70
992.1.15 by Monty Taylor
Moved mysys build into root Makefile.
71
noinst_HEADERS=	\
992.1.18 by Monty Taylor
Moved client build into root Makefile.
72
		client/client_priv.h \
994.2.4 by Monty Taylor
Blast. Fixed some make distcheck issues.
73
		client/errname.h \
992.1.18 by Monty Taylor
Moved client build into root Makefile.
74
		client/get_password.h \
75
		client/my_readline.h \
992.1.15 by Monty Taylor
Moved mysys build into root Makefile.
76
		drizzled/configmake.h \
992.1.16 by Monty Taylor
Moved mystrings build into root Makefile.
77
		mystrings/decimal.h \
78
		mystrings/m_ctype.h \
79
		mystrings/m_string.h \
80
		mystrings/my_uctype.h \
994.2.4 by Monty Taylor
Blast. Fixed some make distcheck issues.
81
		mystrings/t_ctype.h \
82
		mystrings/utf8.h \
992.1.15 by Monty Taylor
Moved mysys build into root Makefile.
83
		mysys/aio_result.h \
84
		mysys/base64.h \
85
		mysys/definitions.h \
86
		mysys/drizzle_time.h \
87
		mysys/hash.h \
88
		mysys/iocache.h \
89
		mysys/my_alloc.h \
90
		mysys/my_bit.h \
1005.2.1 by Monty Taylor
Reverted a crap-ton of padraig's work.
91
		mysys/my_bitmap.h \
992.1.15 by Monty Taylor
Moved mysys build into root Makefile.
92
		mysys/my_dir.h \
93
		mysys/my_getopt.h \
94
		mysys/my_pthread.h \
95
		mysys/my_static.h \
96
		mysys/my_sys.h \
97
		mysys/my_time.h \
98
		mysys/my_tree.h \
99
		mysys/mysys_err.h \
100
		mysys/mysys_priv.h \
101
		mysys/sha1.h \
102
		mysys/thr_lock.h \
103
		mysys/typelib.h
104
992.1.16 by Monty Taylor
Moved mystrings build into root Makefile.
105
mystrings_libmystrings_la_SOURCES= \
106
		mystrings/bmove_upp.cc \
107
		mystrings/ctype-bin.cc \
108
		mystrings/ctype-extra.cc \
109
		mystrings/ctype-mb.cc \
110
		mystrings/ctype-simple.cc \
111
		mystrings/ctype-uca.cc \
112
		mystrings/ctype-utf8.cc \
113
		mystrings/ctype.cc \
114
		mystrings/decimal.cc \
115
		mystrings/dtoa.cc \
116
		mystrings/int2str.cc \
117
		mystrings/is_prefix.cc \
118
		mystrings/llstr.cc \
119
		mystrings/longlong2str.cc \
999.1.1 by Toru Maesaka
Removed str2int() from the original string library by MySQL. Use strtol(3) instead.
120
		mystrings/my_strtoll10.cc
992.1.16 by Monty Taylor
Moved mystrings build into root Makefile.
121
992.1.15 by Monty Taylor
Moved mysys build into root Makefile.
122
mysys_libmysys_la_SOURCES= \
123
		mysys/array.cc \
124
		mysys/base64.cc \
125
		mysys/charset-def.cc \
126
		mysys/charset.cc \
127
		mysys/checksum.cc \
128
		mysys/default.cc \
129
		mysys/default_modify.cc \
130
		mysys/errors.cc \
131
		mysys/hash.cc \
132
		mysys/mf_arr_appstr.cc \
133
		mysys/mf_cache.cc \
134
		mysys/mf_dirname.cc \
135
		mysys/mf_fn_ext.cc \
136
		mysys/mf_format.cc \
137
		mysys/mf_getdate.cc \
138
		mysys/mf_iocache.cc \
139
		mysys/mf_iocache2.cc \
140
		mysys/mf_loadpath.cc \
141
		mysys/mf_pack.cc \
142
		mysys/mf_qsort.cc \
143
		mysys/mf_qsort2.cc \
144
		mysys/mf_radix.cc \
145
		mysys/mf_same.cc \
146
		mysys/mf_sort.cc \
147
		mysys/mf_tempfile.cc \
148
		mysys/mf_wcomp.cc \
149
		mysys/mulalloc.cc \
150
		mysys/my_access.cc \
151
		mysys/my_alloc.cc \
152
		mysys/my_bit.cc \
1005.2.1 by Monty Taylor
Reverted a crap-ton of padraig's work.
153
		mysys/my_bitmap.cc \
992.1.15 by Monty Taylor
Moved mysys build into root Makefile.
154
		mysys/my_copy.cc \
155
		mysys/my_create.cc \
156
		mysys/my_delete.cc \
157
		mysys/my_dup.cc \
158
		mysys/my_error.cc \
159
		mysys/my_getopt.cc \
160
		mysys/my_getsystime.cc \
161
		mysys/my_init.cc \
162
		mysys/my_lib.cc \
163
		mysys/my_open.cc \
164
		mysys/my_read.cc \
165
		mysys/my_redel.cc \
166
		mysys/my_rename.cc \
167
		mysys/my_static.cc \
168
		mysys/my_symlink.cc \
169
		mysys/my_symlink2.cc \
170
		mysys/my_sync.cc \
171
		mysys/my_thr_init.cc \
172
		mysys/my_time.cc \
173
		mysys/my_write.cc \
174
		mysys/ptr_cmp.cc \
175
		mysys/sha1.cc \
176
		mysys/thr_lock.cc \
177
		mysys/tree.cc \
178
		mysys/typelib.cc
722.1.4 by Monty Taylor
Removed all the setting of DEFS everywhere. Use configmake.h to get the values
179
992.1.18 by Monty Taylor
Moved client build into root Makefile.
180
client_drizzle_SOURCES=		client/drizzle.cc client/readline.cc
181
client_drizzle_LDADD=		${CLIENT_LDADD} ${READLINE_LIBS}
182
183
client_drizzlecheck_SOURCES =	client/drizzlecheck.cc
184
client_drizzlecheck_LDADD=	${CLIENT_LDADD}
185
186
client_drizzledump_SOURCES=	client/drizzledump.cc
187
client_drizzledump_LDADD=	${CLIENT_LDADD}
188
189
client_drizzleimport_SOURCES=	client/drizzleimport.cc
190
client_drizzleimport_LDADD=	${CLIENT_LDADD}
191
192
client_drizzleslap_SOURCES=	client/drizzleslap.cc
193
client_drizzleslap_LDADD=	${CLIENT_LDADD}
194
195
client_drizzletest_SOURCES=	client/drizzletest.cc
196
client_drizzletest_LDADD=	${CLIENT_LDADD} ${LIBPCRE}
197
992.1.21 by Monty Taylor
First pass at replacing plugin.m4.
198
EXTRA_LTLIBRARIES=
199
pkgplugin_LTLIBRARIES=
200
include config/plugin.am
201
1022.2.28 by Monty Taylor
Build/dist fixes. Added my_print_defaults back for now - test_run needs it. But now it's a noinst. Moving forward, it either needs to be renamed and installed properly, or it needs to have its functionality wrapped up into something else.
202
extra_my_print_defaults_SOURCES= extra/my_print_defaults.cc
203
extra_my_print_defaults_LDADD= \
204
		$(top_builddir)/mysys/libmysys.la \
205
		$(top_builddir)/mystrings/libmystrings.la \
206
		$(LIBINTL)
207
208
EXTRA_DIST+=	${man_MANS}
77.1.106 by Monty Taylor
Another batch of distclean fixes.
209
187 by Brian Aker
Fixed tab issue
210
.PHONY: test \
211
    test-force \
212
    test-full \
213
    test-force-full \
214
    test-force-mem \
215
    test-pl \
216
    test-force-pl \
217
    test-full-pl \
218
    test-force-full-pl \
219
    test-force-pl-mem \
220
    test-ps test-nr \
221
    test-pr test-ns \
222
    test-binlog-statement \
223
    test-ext-funcs \
224
    test-ext-rpl \
225
    test-ext-jp \
226
    test-ext-stress \
227
    test-ext \
228
    test-fast \
229
    test-fast-cursor \
230
    test-fast-view \
656.1.11 by Monty Taylor
Added indent rule and uncrustify config.
231
    test-full-qa \
232
    indent
1 by brian
clean slate
233
234
# Target 'test' will run the regression test suite using the built server.
235
#
236
# If you are running in a shared environment, users can avoid clashing
237
# port numbers by setting individual small numbers 1-100 to the
168 by Brian Aker
Rename of test (better tab completion!)
238
# environment variable MTR_BUILD_THREAD. The script "test-run"
1 by brian
clean slate
239
# will then calculate the various port numbers it needs from this,
240
# making sure each user use different ports.
241
242
test-nr:
187 by Brian Aker
Fixed tab issue
243
	cd tests ; \
244
	  ./test-run $(force) --mysqld=--binlog-format=row
1 by brian
clean slate
245
246
test-ns:
187 by Brian Aker
Fixed tab issue
247
	cd tests ; \
248
	  ./test-run $(force) $(mem) --mysqld=--binlog-format=mixed
1 by brian
clean slate
249
250
test-binlog-statement:
187 by Brian Aker
Fixed tab issue
251
	cd tests ; \
252
	  ./test-run $(force) --mysqld=--binlog-format=statement
1 by brian
clean slate
253
53.2.5 by Monty Taylor
Add Jay's test optoins at the target of make test.
254
test: test-drizzle
255
256
test-drizzle:
187 by Brian Aker
Fixed tab issue
257
	cd tests ; \
942.1.4 by Monty Taylor
Moved big tests to big suite. Added make target "make test-big" to allow for easy running of the big tests.
258
	$(MAKE) $(AM_MAKEFLAGS) test-drizzle
259
260
test-big:
261
	cd tests ; \
262
	$(MAKE) $(AM_MAKEFLAGS) test-big
264.3.1 by Jay Pipes
* Added Doxyfile configuration for doxygen builds
263
264
doxygen:
265
	doxygen Doxyfile
656.1.11 by Monty Taylor
Added indent rule and uncrustify config.
266
267
indent:
268
	for f in `find ${top_srcdir} -type f | grep -v innobase |\
269
                  ${EGREP} '\.(cc|c|h)$$' ` ; do \
270
            uncrustify -f $$f -c ${top_srcdir}/config/uncrustify.cfg \
271
               -o indentoutput.tmp && mv indentoutput.tmp "$$f" ;\
272
        done
722.1.4 by Monty Taylor
Removed all the setting of DEFS everywhere. Use configmake.h to get the values
273
274
drizzled/configmake.h: ${top_srcdir}/Makefile.in
275
	@echo "Making $@"
276
	@rm -f $@-t $@
277
	@{ echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
278
	  echo '#define PREFIX "$(prefix)"'; \
279
	  echo '#define EXEC_PREFIX "$(exec_prefix)"'; \
280
	  echo '#define BINDIR "$(bindir)"'; \
281
	  echo '#define SBINDIR "$(sbindir)"'; \
282
	  echo '#define LIBEXECDIR "$(libexecdir)"'; \
283
	  echo '#define DATAROOTDIR "$(datarootdir)"'; \
284
	  echo '#define DATADIR "$(datadir)"'; \
285
	  echo '#define SYSCONFDIR "$(sysconfdir)"'; \
286
	  echo '#define SHAREDSTATEDIR "$(sharedstatedir)"'; \
287
	  echo '#define LOCALSTATEDIR "$(localstatedir)"'; \
288
	  echo '#define INCLUDEDIR "$(includedir)"'; \
289
	  echo '#define OLDINCLUDEDIR "$(oldincludedir)"'; \
290
	  echo '#define DOCDIR "$(docdir)"'; \
291
	  echo '#define INFODIR "$(infodir)"'; \
292
	  echo '#define HTMLDIR "$(htmldir)"'; \
293
	  echo '#define DVIDIR "$(dvidir)"'; \
294
	  echo '#define PDFDIR "$(pdfdir)"'; \
295
	  echo '#define PSDIR "$(psdir)"'; \
296
	  echo '#define LIBDIR "$(libdir)"'; \
297
	  echo '#define LISPDIR "$(lispdir)"'; \
298
	  echo '#define LOCALEDIR "$(localedir)"'; \
299
	  echo '#define MANDIR "$(mandir)"'; \
300
	  echo '#define MANEXT "$(manext)"'; \
301
	  echo '#define PKGDATADIR "$(pkgdatadir)"'; \
302
	  echo '#define PKGINCLUDEDIR "$(pkgincludedir)"'; \
303
	  echo '#define PKGLIBDIR "$(pkglibdir)"'; \
304
	  echo '#define PKGLIBEXECDIR "$(pkglibexecdir)"'; \
305
	  echo '#define PKGPLUGINDIR "$(pkgplugindir)"'; \
306
	} | sed '/""/d' > $@-t
307
	@if diff $@-t $@ >/dev/null 2>&1 ; then \
308
	  rm @-t ; \
309
	else \
310
	  mv $@-t $@ ; \
311
	fi
312
779.1.25 by Monty Taylor
Put in LCOV checks. Put output in subdir.
313
if HAVE_LCOV
314
873.2.36 by Monty Taylor
Fix to clean up flags.
315
lcov: lcov-clean test lcov/index.html
779.1.20 by Monty Taylor
Added lcov commands.
316
779.1.25 by Monty Taylor
Put in LCOV checks. Put output in subdir.
317
lcov/drizzle.output: drizzled/drizzled
318
	mkdir -p lcov
319
	${LCOV} --directory ${top_srcdir}/lcov --capture --output-file lcov/drizzle.output
779.1.20 by Monty Taylor
Added lcov commands.
320
779.1.25 by Monty Taylor
Put in LCOV checks. Put output in subdir.
321
lcov/index.html: lcov/drizzle.output
322
	${GENHTML} -o lcov lcov/drizzle.output
779.1.20 by Monty Taylor
Added lcov commands.
323
324
lcov-clean:
325
	ln -fs pars/pars0lex.l ${top_srcdir}/storage/innobase/pars0lex.l
326
	ln -fs pars/lexyy.c ${top_srcdir}/storage/innobase/lexyy.c
327
	ln -fs pars/pars0grm.c ${top_srcdir}/storage/innobase/pars0grm.c
328
	ln -fs pars/pars0grm.y ${top_srcdir}/storage/innobase/pars0grm.y
329
779.1.25 by Monty Taylor
Put in LCOV checks. Put output in subdir.
330
	${LCOV} --directory ${top_srcdir} --zerocounters
779.1.20 by Monty Taylor
Added lcov commands.
331
779.1.25 by Monty Taylor
Put in LCOV checks. Put output in subdir.
332
endif