1
# Copyright (C) 2000-2006 MySQL AB
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.
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.
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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
16
# This file is public domain and comes with NO WARRANTY of any kind
19
LIBMYSQLCLIENT_LA = $(top_builddir)/libmysql_r/libmysqlclient_r.la
21
LIBMYSQLCLIENT_LA = $(top_builddir)/libmysql/libmysqlclient.la
24
INCLUDES = -I$(top_builddir)/include \
25
-I$(top_srcdir)/include \
28
LIBS = @CLIENT_LIBS@ -lz
30
LDADD= @CLIENT_EXTRA_LDFLAGS@ $(CLIENT_THREAD_LIBS) \
31
$(top_builddir)/libmysql/libmysqlclient.la -lz
33
noinst_HEADERS = sql_string.h completion_hash.h my_readline.h \
36
EXTRA_DIST = get_password.c CMakeLists.txt echo.c
38
BUILT_SOURCES = link_sources
40
CLEANFILES = $(BUILT_SOURCES)
42
bin_PROGRAMS = mysql \
53
mysql_SOURCES = mysql.cc readline.cc sql_string.cc \
55
mysql_LDADD = -lreadline @TERMCAP_LIB@ \
56
$(LDADD) $(CXXLDFLAGS)
57
mysqladmin_SOURCES = mysqladmin.cc
59
mysqlbinlog_SOURCES = mysqlbinlog.cc \
60
$(top_srcdir)/mysys/mf_tempdir.c \
61
$(top_srcdir)/mysys/my_new.cc \
62
$(top_srcdir)/mysys/my_bit.c \
63
$(top_srcdir)/mysys/my_bitmap.c \
64
$(top_srcdir)/mysys/base64.c
65
mysqlbinlog_LDADD = $(LDADD) $(CXXLDFLAGS)
67
mysqldump_SOURCES= mysqldump.c \
69
$(top_srcdir)/mysys/mf_getdate.c
71
mysqlimport_SOURCES= mysqlimport.c
73
mysqlimport_LDADD = $(CXXLDFLAGS) $(CLIENT_THREAD_LIBS) \
74
@CLIENT_EXTRA_LDFLAGS@ \
75
$(LIBMYSQLCLIENT_LA) \
76
$(top_builddir)/mysys/libmysys.a
78
mysqlshow_SOURCES= mysqlshow.c
80
mysqlslap_SOURCES= mysqlslap.c
81
mysqlslap_CFLAGS= -DTHREAD -UUNDEF_THREADS_HACK
82
mysqlslap_LDADD = $(CXXLDFLAGS) $(CLIENT_THREAD_LIBS) \
83
@CLIENT_EXTRA_LDFLAGS@ \
84
$(LIBMYSQLCLIENT_LA) \
85
$(top_builddir)/mysys/libmysys.a
87
mysqltest_SOURCES= mysqltest.c \
88
$(top_srcdir)/mysys/my_getsystime.c \
89
$(top_srcdir)/mysys/my_copy.c \
90
$(top_srcdir)/mysys/my_mkdir.c
91
mysqltest_LDADD = $(top_builddir)/regex/libregex.a $(LDADD)
93
mysql_upgrade_SOURCES= mysql_upgrade.c \
94
$(top_srcdir)/mysys/my_getpagesize.c
97
DEFS = -DUNDEF_THREADS_HACK \
98
-DDEFAULT_MYSQL_HOME="\"$(prefix)\"" \
99
-DDATADIR="\"$(localstatedir)\""
101
sql_src=log_event.h mysql_priv.h rpl_constants.h \
102
log_event.cc my_decimal.h my_decimal.cc \
103
log_event_old.h log_event_old.cc \
104
rpl_record_old.h rpl_record_old.cc
105
strings_src=decimal.c dtoa.c
108
for f in $(sql_src) ; do \
110
@LN_CP_F@ $(top_srcdir)/sql/$$f $$f; \
112
for f in $(strings_src) ; do \
113
rm -f $(srcdir)/$$f; \
114
@LN_CP_F@ $(top_srcdir)/strings/$$f $$f; \
116
rm -f $(srcdir)/my_user.c; \
117
@LN_CP_F@ $(top_srcdir)/sql-common/my_user.c my_user.c;
118
echo timestamp > link_sources;
120
# Don't update the files from bitkeeper