Fix index
[proj/mysql-extras.git] / 02040_all_embedded-library-shared-5.1.50.patch
1 Convert all of the static libraries for the embedded libmysqld to build as
2 shared.
3
4 This enables amarok's mysql extension to properly build as a shared object,
5 without statically including libmysqld or nor forcing libmysqld to be built
6 with -fPIC.
7
8 Thanks to <pageexec@freemail.hu> for the @plt fixes.
9 Thanks to Diego Elio Pettenò <flameeyes@gentoo.org> for all the extensive build
10 system help with libtool conversions.
11 Thanks to Maciej Mrozowski <reavertm@gentoo.org> for working in the redo of the
12 patch for mysql-5.1.
13
14 Gentoo-Bug: 238487
15 Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=238487
16 MySQL-Bug-URL: http://bugs.mysql.com/bug.php?id=39288
17 MySQL-Bug: 39288
18 MySQL-Lists-URL: http://lists.mysql.com/internals/35947
19 X-Patch-URL: http://bugs.gentoo.org/attachment.cgi?id=188019&action=view
20 Signed-off-by: Jorge Manuel B. S. Vicetto <jmbsvicetto@gentoo.org>
21 Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
22 Signed-off-by: Kristian Nielsen <knielsen@knielsen-hq.org>
23
24 === modified file 'client/Makefile.am'
25 --- client/Makefile.am  2010-08-27 14:12:44 +0000
26 +++ client/Makefile.am  2010-09-16 12:49:35 +0000
27 @@ -75,7 +75,8 @@
28  mysqlimport_LDADD =            $(CXXLDFLAGS) $(CLIENT_THREAD_LIBS) \
29                                 @CLIENT_EXTRA_LDFLAGS@ \
30                                 $(LIBMYSQLCLIENT_LA) \
31 -                               $(top_builddir)/mysys/libmysys.a
32 +                               $(top_builddir)/mysys/libmysys.la \
33 +                               $(top_builddir)/strings/libmystrings.la
34  
35  mysqlshow_SOURCES=             mysqlshow.c
36  
37 @@ -84,15 +85,17 @@
38  mysqlslap_LDADD =              $(CXXLDFLAGS) $(CLIENT_THREAD_LIBS) \
39                                 @CLIENT_EXTRA_LDFLAGS@ \
40                                 $(LIBMYSQLCLIENT_LA) \
41 -                               $(top_builddir)/mysys/libmysys.a
42 +                               $(top_builddir)/mysys/libmysys.la \
43 +                               $(top_builddir)/strings/libmystrings.la
44  
45  mysqltest_SOURCES=             mysqltest.cc
46  mysqltest_CXXFLAGS=            -DTHREAD -UMYSQL_CLIENT_NO_THREADS
47  mysqltest_LDADD =              $(CXXLDFLAGS) $(CLIENT_THREAD_LIBS) \
48                                 @CLIENT_EXTRA_LDFLAGS@ \
49                                 $(LIBMYSQLCLIENT_LA) \
50 -                               $(top_builddir)/mysys/libmysys.a \
51 -                               $(top_builddir)/regex/libregex.a \
52 +                               $(top_builddir)/mysys/libmysys.la \
53 +                               $(top_builddir)/regex/libregex.la \
54 +                               $(top_builddir)/strings/libmystrings.la \
55                                 $(CLIENT_THREAD_LIBS)
56  
57  mysql_upgrade_SOURCES=          mysql_upgrade.c \
58
59 === modified file 'config/ac-macros/plugins.m4'
60 --- config/ac-macros/plugins.m4 2009-12-22 10:33:20 +0000
61 +++ config/ac-macros/plugins.m4 2010-09-16 12:49:35 +0000
62 @@ -115,18 +115,32 @@
63  dnl Macro: MYSQL_PLUGIN_STATIC
64  dnl
65  dnl SYNOPSIS
66 -dnl   MYSQL_PLUGIN_STATIC([name],[libmyplugin.a])
67 +dnl   MYSQL_PLUGIN_STATIC([name],[libmyplugin.a],[libmyplugin_embedded.a])
68  dnl
69  dnl DESCRIPTION
70 -dnl   Declare the name for the static library 
71 +dnl   Declare the name for the static library
72 +dnl
73 +dnl   Third argument is optional, only needed for special plugins that depend
74 +dnl   on server internals and have source files that must be compiled specially
75 +dnl   with -DEMBEDDED_LIBRARY for embedded server. If specified, the third
76 +dnl   argument is used to link embedded server instead of the second.
77  dnl
78  dnl ---------------------------------------------------------------------------
79  
80  AC_DEFUN([MYSQL_PLUGIN_STATIC],[
81   MYSQL_REQUIRE_PLUGIN([$1])
82   m4_define([MYSQL_PLUGIN_STATIC_]AS_TR_CPP([$1]), [$2])
83 + ifelse($#, 3, [
84 +   m4_define([MYSQL_PLUGIN_EMBEDDED_]AS_TR_CPP([$1]), [$3])
85 + ])
86  ])
87  
88 +dnl ---------------------------------------------------------------------------
89 +dnl Substitution variable to use to compile source files specially for
90 +dnl embedded server.
91 +dnl To be used by plugins that have sources that depend on server internals.
92 +dnl ---------------------------------------------------------------------------
93 +AC_SUBST([plugin_embedded_defs], ["-DEMBEDDED_LIBRARY -DMYSQL_SERVER"])
94  
95  dnl ---------------------------------------------------------------------------
96  dnl Macro: MYSQL_PLUGIN_DYNAMIC
97 @@ -254,29 +268,6 @@
98  ])
99  
100  dnl ---------------------------------------------------------------------------
101 -dnl Macro: MYSQL_PLUGIN_DEPENDS_ON_MYSQL_INTERNALS
102 -dnl
103 -dnl SYNOPSIS
104 -dnl   MYSQL_PLUGIN_DEPENDS_ON_MYSQL_INTERNALS([name],[file name])
105 -dnl
106 -dnl DESCRIPTION
107 -dnl   Some modules in plugins keep dependance on structures
108 -dnl   declared in sql/ (THD class usually)
109 -dnl   That has to be fixed in the future, but until then
110 -dnl   we have to recompile these modules when we want to
111 -dnl   to compile server parts with the different #defines
112 -dnl   Normally it happens when we compile the embedded server
113 -dnl   Thus one should mark such files in his handler using this macro
114 -dnl    (currently only one such a file per plugin is supported)
115 -dnl
116 -dnl ---------------------------------------------------------------------------
117 -
118 -AC_DEFUN([MYSQL_PLUGIN_DEPENDS_ON_MYSQL_INTERNALS],[
119 - MYSQL_REQUIRE_PLUGIN([$1])
120 - m4_define([MYSQL_PLUGIN_DEPENDS_ON_MYSQL_INTERNALS_]AS_TR_CPP([$1]), [$2])
121 -])
122 -
123 -dnl ---------------------------------------------------------------------------
124  dnl Macro: MYSQL_CONFIGURE_PLUGINS
125  dnl
126  dnl SYNOPSIS
127 @@ -336,11 +328,25 @@
128    [MYSQL_PLUGIN_DYNAMIC_]AS_TR_CPP([$1]),
129    [MYSQL_PLUGIN_MANDATORY_]AS_TR_CPP([$1]),
130    [MYSQL_PLUGIN_DISABLED_]AS_TR_CPP([$1]),
131 -  [MYSQL_PLUGIN_DEPENDS_ON_MYSQL_INTERNALS_]AS_TR_CPP([$1]),
132 +  [MYSQL_PLUGIN_EMBEDDED_]AS_TR_CPP([$1]),
133    [MYSQL_PLUGIN_ACTIONS_]AS_TR_CPP([$1])
134   )
135  ])
136  
137 +# __MYSQL_EMIT_CHECK_PLUGIN arguments:
138 +#
139 +#  1 - plugin identifying name
140 +#  2 - plugin identifying name, with `-' replaced by `_'
141 +#  3 - plugin long name
142 +#  4 - plugin description
143 +#  5 - mysql_plugin_define (eg. WITH_xxx_STORAGE_ENGINE)
144 +#  6 - directory
145 +#  7 - static target (if supports static build)
146 +#  8 - dynamic target (if supports dynamic build)
147 +#  9 - mandatory flag
148 +# 10 - disabled flag
149 +# 11 - static target for libmysqld (if different from mysqld)
150 +# 12 - actions
151  AC_DEFUN([__MYSQL_EMIT_CHECK_PLUGIN],[
152   m4_ifdef([$5],[
153    AH_TEMPLATE($5, [Include ]$4[ into mysqld])
154 @@ -407,6 +413,7 @@
155         ])
156         AC_SUBST([plugin_]$2[_shared_target], "$8")
157         AC_SUBST([plugin_]$2[_static_target], [""])
158 +       AC_SUBST([plugin_]$2[_embedded_static_target], [""])
159         [with_plugin_]$2=yes
160         AC_MSG_RESULT([plugin])
161         m4_ifdef([$6],[
162 @@ -421,32 +428,47 @@
163        ])
164      else
165        m4_ifdef([$7],[
166 -       ifelse(m4_bregexp($7, [^lib[^.]+\.a$]), -2, [
167 -dnl change above "-2" to "0" to enable this section
168 -dnl Although this is "pretty", it breaks libmysqld build
169 -        m4_ifdef([$6],[
170 -         mysql_use_plugin_dir="$6"
171 -         mysql_plugin_libs="$mysql_plugin_libs -L[\$(top_builddir)]/$6"
172 -        ])
173 -        mysql_plugin_libs="$mysql_plugin_libs dnl
174 -[-l]m4_bregexp($7, [^lib\([^.]+\)], [\1])"
175 -       ], m4_bregexp($7, [^\\\$]), 0, [
176 +       ifelse(m4_bregexp($7, [^\\\$]), 0, [
177          m4_ifdef([$6],[
178           mysql_use_plugin_dir="$6"
179          ])
180          mysql_plugin_libs="$mysql_plugin_libs $7"
181 +        m4_ifdef([$11],[
182 +          mysql_embedded_plugin_libs="$mysql_embedded_plugin_libs $11"
183 +        ],[
184 +          mysql_embedded_plugin_libs="$mysql_embedded_plugin_libs $7"
185 +        ])
186         ], [
187          m4_ifdef([$6],[
188           mysql_use_plugin_dir="$6"
189           mysql_plugin_libs="$mysql_plugin_libs \$(top_builddir)/$6/$7"
190 +         m4_ifdef([$11],[
191 +           mysql_embedded_plugin_libs="$mysql_embedded_plugin_libs \$(top_builddir)/$6/$11"
192 +         ],[
193 +           mysql_embedded_plugin_libs="$mysql_embedded_plugin_libs \$(top_builddir)/$6/$7"
194 +         ])
195          ],[
196           mysql_plugin_libs="$mysql_plugin_libs $7"
197 +         m4_ifdef([$11],[
198 +           mysql_embedded_plugin_libs="$mysql_embedded_plugin_libs $11"
199 +         ],[
200 +           mysql_embedded_plugin_libs="$mysql_embedded_plugin_libs $7"
201 +         ])
202          ])
203         ])
204         m4_ifdef([$5],[
205          AC_DEFINE($5)
206         ])
207         AC_SUBST([plugin_]$2[_static_target], "$7")
208 +       m4_ifdef([$11], [
209 +         if test "$with_embedded_server" = "yes"; then
210 +           AC_SUBST([plugin_]$2[_embedded_static_target], "$11")
211 +         else
212 +           AC_SUBST([plugin_]$2[_embedded_static_target], [""])
213 +         fi
214 +       ], [
215 +         AC_SUBST([plugin_]$2[_embedded_static_target], [""])
216 +       ])
217         AC_SUBST([plugin_]$2[_shared_target], [""])
218        ],[
219         m4_ifdef([$6],[
220 @@ -463,12 +485,6 @@
221        mysql_plugin_defs="$mysql_plugin_defs, [builtin_]$2[_plugin]"
222        [with_plugin_]$2=yes
223        AC_MSG_RESULT([yes])
224 -      m4_ifdef([$11],[
225 -       condition_dependent_plugin_modules="$condition_dependent_plugin_modules m4_bregexp($11, [[^/]+$], [\&])"
226 -       condition_dependent_plugin_objects="$condition_dependent_plugin_objects m4_bregexp($11, [[^/]+\.], [\&o])"
227 -       condition_dependent_plugin_links="$condition_dependent_plugin_links $6/$11"
228 -       condition_dependent_plugin_includes="$condition_dependent_plugin_includes -I[\$(top_srcdir)]/$6/m4_bregexp($11, [^.+[/$]], [\&])"
229 -      ])
230      fi
231    fi
232  
233 @@ -516,6 +530,14 @@
234   ])
235  ])
236  
237 +dnl If not building libmysqld embedded server, then there is no need to build
238 +dnl shared object versions of static plugins.
239 +if test "$with_embedded_server" = "yes"; then
240 +  AC_SUBST([plugin_static_if_no_embedded], "")
241 +else
242 +  AC_SUBST([plugin_static_if_no_embedded], "-static")
243 +fi
244 +
245  AC_DEFUN([_MYSQL_EMIT_PLUGIN_ACTIONS],[
246   ifelse($#, 0, [], $#, 1, [
247    _MYSQL_EMIT_PLUGIN_ACTION([$1])
248
249 === modified file 'configure.in'
250 --- configure.in        2010-08-27 14:12:44 +0000
251 +++ configure.in        2010-09-16 12:49:35 +0000
252 @@ -2483,8 +2483,6 @@
253  
254  dnl -- ndbcluster requires partition to be enabled
255  
256 -MYSQL_CONFIGURE_PLUGINS([none])
257 -
258  # Only build client code?
259  AC_ARG_WITH(server,
260      [  --without-server        Only build the client.],
261 @@ -2498,6 +2496,8 @@
262      [with_embedded_server=no]
263  )
264  
265 +MYSQL_CONFIGURE_PLUGINS([none])
266 +
267  AC_ARG_WITH(query_cache,
268      [  --without-query-cache   Do not build query cache.],
269      [with_query_cache=$withval],
270 @@ -2801,9 +2801,6 @@
271  then
272    AC_DEFINE([THREAD], [1],
273              [Define if you want to have threaded code. This may be undef on client code])
274 -  # Avoid _PROGRAMS names
275 -  THREAD_LOBJECTS="thr_alarm.o thr_lock.o thr_mutex.o thr_rwlock.o my_pthread.o my_thr_init.o mf_keycache.o"
276 -  AC_SUBST(THREAD_LOBJECTS)
277  fi
278  AM_CONDITIONAL(NEED_THREAD, test "$with_server" != "no" -o "$THREAD_SAFE_CLIENT" != "no")
279  
280 @@ -2831,6 +2828,7 @@
281  
282  AC_SUBST(mysql_plugin_dirs)
283  AC_SUBST(mysql_plugin_libs)
284 +AC_SUBST(mysql_embedded_plugin_libs)
285  AC_SUBST(mysql_plugin_defs)
286
287
288 === modified file 'dbug/Makefile.am'
289 --- dbug/Makefile.am    2010-08-27 14:12:44 +0000
290 +++ dbug/Makefile.am    2010-09-16 12:49:35 +0000
291 @@ -16,10 +16,10 @@
292  # MA 02111-1307, USA
293  
294  INCLUDES =              -I$(top_builddir)/include -I$(top_srcdir)/include
295 -LDADD =                 libdbug.a ../mysys/libmysys.a ../strings/libmystrings.a
296 -pkglib_LIBRARIES =      libdbug.a
297 +LDADD =                 libdbug.la ../mysys/libmysys.la ../strings/libmystrings.la $(ZLIB_LIBS)
298 +pkglib_LTLIBRARIES =   libdbug.la
299  noinst_HEADERS =        dbug_long.h
300 -libdbug_a_SOURCES =     dbug.c sanity.c
301 +libdbug_la_SOURCES =   dbug.c sanity.c
302  EXTRA_DIST =            CMakeLists.txt example1.c example2.c example3.c \
303                          user.r monty.doc dbug_add_tags.pl \
304                          my_main.c main.c factorial.c dbug_analyze.c \
305
306 === modified file 'extra/Makefile.am'
307 --- extra/Makefile.am   2010-08-27 14:12:44 +0000
308 +++ extra/Makefile.am   2010-09-16 12:49:35 +0000
309 @@ -15,8 +15,8 @@
310  
311  INCLUDES =             -I$(top_builddir)/include -I$(top_srcdir)/include \
312                         -I$(top_srcdir)/sql
313 -LDADD =                        @CLIENT_EXTRA_LDFLAGS@ ../mysys/libmysys.a \
314 -                       ../dbug/libdbug.a ../strings/libmystrings.a \
315 +LDADD =                        @CLIENT_EXTRA_LDFLAGS@ ../mysys/libmysys.la \
316 +                       ../dbug/libdbug.la ../strings/libmystrings.la \
317                         $(ZLIB_LIBS)
318  BUILT_SOURCES=         $(top_builddir)/include/mysqld_error.h \
319                          $(top_builddir)/include/sql_state.h \
320
321 === modified file 'libmysqld/Makefile.am'
322 --- libmysqld/Makefile.am       2010-08-27 14:12:44 +0000
323 +++ libmysqld/Makefile.am       2010-09-16 12:49:35 +0000
324 @@ -17,95 +17,90 @@
325  #
326  # This file is public domain and comes with NO WARRANTY of any kind
327  
328 -MYSQLDATAdir =         $(localstatedir)
329 -MYSQLSHAREdir =                $(pkgdatadir)
330 -MYSQLBASEdir=          $(prefix)
331 -MYSQLLIBdir=            $(libdir)
332 -pkgplugindir =         $(pkglibdir)/plugin
333 +MYSQLDATAdir = $(localstatedir)
334 +MYSQLSHAREdir =        $(pkgdatadir)
335 +MYSQLBASEdir = $(prefix)
336 +MYSQLLIBdir =  $(libdir)
337 +pkgplugindir = $(pkglibdir)/plugin
338  
339 -EXTRA_DIST =           libmysqld.def CMakeLists.txt
340 -DEFS =                 -DEMBEDDED_LIBRARY -DMYSQL_SERVER \
341 +EXTRA_DIST =   libmysqld.def CMakeLists.txt
342 +DEFS =         -DEMBEDDED_LIBRARY -DMYSQL_SERVER \
343                         -DDEFAULT_MYSQL_HOME="\"$(MYSQLBASEdir)\"" \
344                         -DMYSQL_DATADIR="\"$(MYSQLDATAdir)\"" \
345                         -DSHAREDIR="\"$(MYSQLSHAREdir)\"" \
346                         -DPLUGINDIR="\"$(pkgplugindir)\""
347 -INCLUDES=              -I$(top_builddir)/include -I$(top_srcdir)/include \
348 +INCLUDES =     -I$(top_builddir)/include -I$(top_srcdir)/include \
349                         -I$(top_builddir)/sql -I$(top_srcdir)/sql \
350                         -I$(top_srcdir)/sql/examples \
351                         -I$(top_srcdir)/regex \
352 -                       $(openssl_includes) @ZLIB_INCLUDES@ \
353 -                       @condition_dependent_plugin_includes@
354 +                       $(openssl_includes) $(ZLIB_INCLUDES) \
355 +                       @condition_dependent_plugin_includes@ \
356 +                       $(ndbcluster_includes)
357  
358 -noinst_LIBRARIES =     libmysqld_int.a
359 -pkglib_LIBRARIES =     libmysqld.a
360 -SUBDIRS =              . examples
361 +pkglib_LTLIBRARIES =   libmysqld.la
362 +SUBDIRS =      . examples
363  libmysqld_sources=     libmysqld.c lib_sql.cc emb_qcache.cc
364  libmysqlsources =      errmsg.c get_password.c libmysql.c client.c pack.c \
365 -                        my_time.c
366 +                       my_time.c
367  
368  noinst_HEADERS =       embedded_priv.h emb_qcache.h
369  
370 -sqlsources = derror.cc field.cc field_conv.cc strfunc.cc filesort.cc \
371 -            ha_ndbcluster.cc ha_ndbcluster_cond.cc \
372 -       ha_ndbcluster_binlog.cc ha_partition.cc \
373 -       handler.cc sql_handler.cc \
374 -       hostname.cc init.cc password.c \
375 -       item.cc item_buff.cc item_cmpfunc.cc item_create.cc \
376 -       item_func.cc item_strfunc.cc item_sum.cc item_timefunc.cc \
377 -       item_geofunc.cc item_subselect.cc item_row.cc\
378 -       item_xmlfunc.cc \
379 -       key.cc lock.cc log.cc sql_state.c \
380 -       log_event.cc rpl_record.cc \
381 -       log_event_old.cc rpl_record_old.cc \
382 -       protocol.cc net_serv.cc opt_range.cc \
383 -       opt_sum.cc procedure.cc records.cc sql_acl.cc \
384 -       sql_load.cc discover.cc sql_locale.cc \
385 -       sql_profile.cc \
386 -       sql_analyse.cc sql_base.cc sql_cache.cc sql_class.cc \
387 -       sql_crypt.cc sql_db.cc sql_delete.cc sql_error.cc sql_insert.cc \
388 -       sql_lex.cc sql_list.cc sql_manager.cc sql_map.cc \
389 -       scheduler.cc sql_connect.cc sql_parse.cc \
390 -       sql_prepare.cc sql_derived.cc sql_rename.cc \
391 -       sql_select.cc sql_do.cc sql_show.cc set_var.cc \
392 -       sql_string.cc sql_table.cc sql_test.cc sql_udf.cc \
393 -       sql_update.cc sql_yacc.cc table.cc thr_malloc.cc time.cc \
394 -       unireg.cc uniques.cc sql_union.cc hash_filo.cc \
395 -       spatial.cc gstream.cc sql_help.cc tztime.cc sql_cursor.cc \
396 -       sp_head.cc sp_pcontext.cc sp.cc sp_cache.cc sp_rcontext.cc \
397 -       parse_file.cc sql_view.cc sql_trigger.cc my_decimal.cc \
398 -       rpl_filter.cc sql_partition.cc sql_builtin.cc sql_plugin.cc \
399 -       debug_sync.cc \
400 -       sql_tablespace.cc \
401 -       rpl_injector.cc my_user.c partition_info.cc \
402 -       sql_servers.cc event_parse_data.cc
403 -
404 -libmysqld_int_a_SOURCES= $(libmysqld_sources)
405 -nodist_libmysqld_int_a_SOURCES= $(libmysqlsources) $(sqlsources)
406 -libmysqld_a_SOURCES=
407 -
408 -sqlstoragesources =    $(EXTRA_libmysqld_a_SOURCES)
409 -storagesources = @condition_dependent_plugin_modules@
410 -storageobjects = @condition_dependent_plugin_objects@
411 -storagesourceslinks = @condition_dependent_plugin_links@
412 +sqlsources =   derror.cc field.cc field_conv.cc strfunc.cc filesort.cc \
413 +                       ha_ndbcluster.cc ha_ndbcluster_cond.cc \
414 +                       ha_ndbcluster_binlog.cc ha_partition.cc \
415 +                       handler.cc sql_handler.cc \
416 +                       hostname.cc init.cc password.c \
417 +                       item.cc item_buff.cc item_cmpfunc.cc item_create.cc \
418 +                       item_func.cc item_strfunc.cc item_sum.cc item_timefunc.cc \
419 +                       item_geofunc.cc item_subselect.cc item_row.cc\
420 +                       item_xmlfunc.cc \
421 +                       key.cc lock.cc log.cc sql_state.c \
422 +                       log_event.cc rpl_record.cc \
423 +                       log_event_old.cc rpl_record_old.cc \
424 +                       protocol.cc net_serv.cc opt_range.cc \
425 +                       opt_sum.cc procedure.cc records.cc sql_acl.cc \
426 +                       sql_load.cc discover.cc sql_locale.cc \
427 +                       sql_profile.cc \
428 +                       sql_analyse.cc sql_base.cc sql_cache.cc sql_class.cc \
429 +                       sql_crypt.cc sql_db.cc sql_delete.cc sql_error.cc sql_insert.cc \
430 +                       sql_lex.cc sql_list.cc sql_manager.cc sql_map.cc \
431 +                       scheduler.cc sql_connect.cc sql_parse.cc \
432 +                       sql_prepare.cc sql_derived.cc sql_rename.cc \
433 +                       sql_select.cc sql_do.cc sql_show.cc set_var.cc \
434 +                       sql_string.cc sql_table.cc sql_test.cc sql_udf.cc \
435 +                       sql_update.cc sql_yacc.cc table.cc thr_malloc.cc time.cc \
436 +                       unireg.cc uniques.cc sql_union.cc hash_filo.cc \
437 +                       spatial.cc gstream.cc sql_help.cc tztime.cc sql_cursor.cc \
438 +                       sp_head.cc sp_pcontext.cc sp.cc sp_cache.cc sp_rcontext.cc \
439 +                       parse_file.cc sql_view.cc sql_trigger.cc my_decimal.cc \
440 +                       rpl_filter.cc sql_partition.cc sql_builtin.cc sql_plugin.cc \
441 +                       debug_sync.cc \
442 +                       sql_tablespace.cc \
443 +                       rpl_injector.cc my_user.c partition_info.cc \
444 +                       sql_servers.cc event_parse_data.cc
445  
446  # automake misses these
447  sql_yacc.cc sql_yacc.h: $(top_srcdir)/sql/sql_yacc.yy
448  
449  # The following libraries should be included in libmysqld.a
450 -INC_LIB=       $(top_builddir)/regex/libregex.a \
451 -               $(top_builddir)/mysys/libmysys.a \
452 -               $(top_builddir)/strings/libmystrings.a \
453 -               $(top_builddir)/dbug/libdbug.a \
454 -               $(top_builddir)/vio/libvio.a \
455 -                @NDB_SCI_LIBS@ \
456 -               @mysql_plugin_libs@ \
457 -               $(yassl_inc_libs)
458 +INC_LIB=       $(top_builddir)/regex/libregex.la \
459 +                       $(top_builddir)/mysys/libmysys.la \
460 +                       $(top_builddir)/strings/libmystrings.la \
461 +                       $(top_builddir)/dbug/libdbug.la \
462 +                       $(top_builddir)/vio/libvio.la \
463 +                       $(NDB_SCI_LIBS) \
464 +                       $(mysql_embedded_plugin_libs) \
465 +                       $(yassl_inc_libs)
466  
467  if HAVE_YASSL
468 -yassl_inc_libs=        $(top_builddir)/extra/yassl/src/.libs/libyassl.a \
469 -               $(top_builddir)/extra/yassl/taocrypt/src/.libs/libtaocrypt.a
470 +yassl_inc_libs=        $(top_builddir)/extra/yassl/src/libyassl.la \
471 +               $(top_builddir)/extra/yassl/taocrypt/src/libtaocrypt.la
472  endif
473  
474 +libmysqld_la_SOURCES=  $(libmysqld_sources)
475 +nodist_libmysqld_la_SOURCES=   $(libmysqlsources) $(sqlsources)
476 +libmysqld_la_LIBADD =  $(INC_LIB)
477 +
478  # Storage engine specific compilation options
479  ha_ndbcluster.o:ha_ndbcluster.cc
480                 $(CXXCOMPILE) @ndbcluster_includes@ $(LM_CFLAGS) -c $<
481 @@ -139,44 +134,6 @@
482  ha_myisammrg.o:ha_myisammrg.cc
483                 $(CXXCOMPILE) $(LM_CFLAGS) -c $<
484  
485 -#
486 -# To make it easy for the end user to use the embedded library we
487 -# generate a total libmysqld.a from all library files,
488 -
489 -# note - InnoDB libraries have circular dependencies, so in INC_LIB
490 -# few libraries are present two times. Metrowerks linker doesn't like
491 -# it at all. Traditional ar has no problems with it, but still there's no
492 -# need to add the same file twice to the library, so 'sort -u' save us
493 -# some time and spares unnecessary work.
494 -
495 -libmysqld.a:   libmysqld_int.a $(INC_LIB) $(libmysqld_a_DEPENDENCIES) $(storageobjects)
496 -if DARWIN_MWCC
497 -       mwld -lib -o $@ libmysqld_int.a `echo $(INC_LIB) | sort -u` $(storageobjects)
498 -else
499 -               -rm -f libmysqld.a
500 -               if test "$(host_os)" = "netware" ; \
501 -               then \
502 -                 $(libmysqld_a_AR) libmysqld.a $(INC_LIB) libmysqld_int.a $(storageobjects); \
503 -               else \
504 -                 current_dir=`pwd`; \
505 -                 rm -rf tmp; mkdir tmp; \
506 -                 (for arc in $(INC_LIB) ./libmysqld_int.a; do \
507 -                   arpath=`echo $$arc|sed 's|[^/]*$$||'|sed 's|\.libs/$$||'`; \
508 -                   artmp=`echo $$arc|sed 's|^.*/|tmp/lib-|'`; \
509 -                   for F in `$(AR) t $$arc | grep -v SYMDEF`; do \
510 -                     if test -e "$$arpath/$$F" ; then echo "$$arpath/$$F"; else \
511 -                     mkdir $$artmp; cd $$artmp > /dev/null; \
512 -                     $(AR) x ../../$$arc; \
513 -                     cd $$current_dir > /dev/null; \
514 -                     ls $$artmp/* | grep -v SYMDEF; \
515 -                     continue 2; fi; done; \
516 -                 done; echo $(libmysqld_a_DEPENDENCIES) ) | sort -u | xargs $(AR) cq libmysqld.a ; \
517 -                 $(AR) r libmysqld.a $(storageobjects); \
518 -                 $(RANLIB) libmysqld.a ; \
519 -                 rm -rf tmp; \
520 -               fi
521 -endif
522 -
523  ## XXX: any time the client interface changes, we'll need to bump
524  ## the version info for libmysqld; however, it's possible for the
525  ## libmysqld interface to change without affecting the standard
526 @@ -187,7 +144,7 @@
527  
528  BUILT_SOURCES = link_sources
529  
530 -CLEANFILES = $(BUILT_SOURCES)
531 +CLEANFILES = libmysqld.la
532  
533  link_sources:
534           for f in $(sqlsources); do \
535 @@ -208,20 +165,6 @@
536               @LN_CP_F@ $(top_builddir)/libmysql/$$f $$f; \
537             fi ; \
538           done; \
539 -         if test -n "$(sqlstoragesources)" ; \
540 -         then \
541 -           for f in "$(sqlstoragesources)"; do \
542 -             rm -f "$$f"; \
543 -             @LN_CP_F@ `find $(srcdir)/../sql -name "$$f"` "$$f"; \
544 -           done; \
545 -         fi; \
546 -         if test -n "$(storagesources)" ; \
547 -         then \
548 -           rm -f $(storagesources); \
549 -           for f in $(storagesourceslinks); do \
550 -             @LN_CP_F@ $(top_srcdir)/$$f . ; \
551 -           done; \
552 -         fi; \
553           rm -f client_settings.h; \
554           @LN_CP_F@ $(top_srcdir)/libmysql/client_settings.h \
555                                            client_settings.h; \
556 @@ -229,7 +172,7 @@
557  
558  
559  clean-local:
560 -       rm -f `echo $(sqlsources) $(libmysqlsources) $(sqlstoragesources) $(storagesources) | sed "s;\.lo;.c;g"`; \
561 +       rm -f `echo $(sqlsources) $(libmysqlsources) | sed "s;\.lo;.c;g"`; \
562         rm -f client_settings.h
563  
564  # Don't update the files from bitkeeper
565 === modified file 'libmysqld/examples/Makefile.am'
566 --- libmysqld/examples/Makefile.am      2010-07-16 07:15:22 +0000
567 +++ libmysqld/examples/Makefile.am      2010-09-16 12:49:35 +0000
568 @@ -37,12 +37,16 @@
569                 -I$(top_srcdir) -I$(top_srcdir)/client -I$(top_srcdir)/regex \
570                 $(openssl_includes)
571  LIBS =         @LIBS@ @WRAPLIBS@ @CLIENT_LIBS@ $(yassl_libs)
572 -LDADD =                @CLIENT_EXTRA_LDFLAGS@ ../libmysqld.a @LIBDL@ $(CXXLDFLAGS) \
573 -                @NDB_SCI_LIBS@
574 +LDADD =                @CLIENT_EXTRA_LDFLAGS@ ../libmysqld.la @LIBDL@ $(CXXLDFLAGS) \
575 +                @NDB_SCI_LIBS@ \
576 +               $(top_builddir)/mysys/libmysys.la \
577 +               $(top_builddir)/strings/libmystrings.la \
578 +               $(top_builddir)/dbug/libdbug.la \
579 +               $(ZLIB_LIBS)
580  
581  mysqltest_embedded_LINK = $(CXXLINK)
582  nodist_mysqltest_embedded_SOURCES =    mysqltest.cc
583 -mysqltest_embedded_LDADD =     $(LDADD) $(top_builddir)/regex/libregex.a \
584 +mysqltest_embedded_LDADD =     $(LDADD) $(top_builddir)/regex/libregex.la \
585                                 @MYSQLD_EXTRA_LDFLAGS@
586  
587  nodist_mysql_SOURCES = mysql.cc readline.cc completion_hash.cc \
588
589 === modified file 'mysys/Makefile.am'
590 --- mysys/Makefile.am   2010-08-27 14:12:44 +0000
591 +++ mysys/Makefile.am   2010-09-16 12:49:35 +0000
592 @@ -18,10 +18,10 @@
593  MYSQLBASEdir=          $(prefix)
594  INCLUDES =             @ZLIB_INCLUDES@ -I$(top_builddir)/include \
595                         -I$(top_srcdir)/include -I$(srcdir)
596 -pkglib_LIBRARIES =     libmysys.a
597 -LDADD =                        libmysys.a $(top_builddir)/strings/libmystrings.a $(top_builddir)/dbug/libdbug.a
598 +pkglib_LTLIBRARIES =   libmysys.la
599 +LDADD =                        libmysys.la $(top_builddir)/strings/libmystrings.la $(top_builddir)/dbug/libdbug.la
600  noinst_HEADERS =       mysys_priv.h my_static.h my_handler_errors.h
601 -libmysys_a_SOURCES =    my_init.c my_getwd.c mf_getdate.c my_mmap.c \
602 +libmysys_la_SOURCES =    my_init.c my_getwd.c mf_getdate.c my_mmap.c \
603                         mf_path.c mf_loadpath.c my_file.c \
604                         my_open.c my_create.c my_dup.c my_seek.c my_read.c \
605                         my_pread.c my_write.c my_getpagesize.c \
606 @@ -57,18 +57,18 @@
607  # mf_keycache is used only in the server, so it is safe to leave the file
608  # out of the non-threaded library.
609  # In fact, it will currently not compile without thread support.
610 -libmysys_a_SOURCES +=   mf_keycache.c
611 +libmysys_la_SOURCES +=   thr_alarm.c thr_lock.c thr_mutex.c thr_rwlock.c \
612 +                       my_pthread.c my_thr_init.c mf_keycache.c
613  endif
614  
615  EXTRA_DIST =           thr_alarm.c thr_lock.c my_pthread.c my_thr_init.c \
616                         thr_mutex.c thr_rwlock.c \
617                         CMakeLists.txt mf_soundex.c \
618                         my_conio.c my_wincond.c my_winthread.c
619 -libmysys_a_LIBADD =    @THREAD_LOBJECTS@
620 -# test_dir_DEPENDENCIES=       $(LIBRARIES)
621 -# testhash_DEPENDENCIES=       $(LIBRARIES)
622 -# test_charset_DEPENDENCIES=   $(LIBRARIES)
623 -# charset2html_DEPENDENCIES=   $(LIBRARIES)
624 +# test_dir_DEPENDENCIES=       $(LTLIBRARIES)
625 +# testhash_DEPENDENCIES=       $(LTLIBRARIES)
626 +# test_charset_DEPENDENCIES=   $(LTLIBRARIES)
627 +# charset2html_DEPENDENCIES=   $(LTLIBRARIES)
628  DEFS =                 -DDEFAULT_BASEDIR=\"$(prefix)\" \
629                         -DMYSQL_DATADIR="\"$(MYSQLDATAdir)\"" \
630                         -DDEFAULT_CHARSET_HOME="\"$(MYSQLBASEdir)\"" \
631 @@ -78,8 +79,6 @@
632                         -DDEFAULT_SYSCONFDIR="\"$(sysconfdir)\"" \
633                          @DEFS@
634  
635 -libmysys_a_DEPENDENCIES= @THREAD_LOBJECTS@
636 -
637  # I hope this always does the right thing. Otherwise this is only test programs
638  FLAGS=$(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) @NOINST_LDFLAGS@
639  
640 @@ -88,47 +87,47 @@
641  # which automaticly removes the object files you use to compile a final program
642  #
643  
644 -test_bitmap$(EXEEXT): my_bitmap.c $(LIBRARIES)
645 +test_bitmap$(EXEEXT): my_bitmap.c $(LTLIBRARIES)
646         $(LINK) $(FLAGS) -DMAIN  ./my_bitmap.c $(LDADD) $(LIBS)
647  
648 -test_priority_queue$(EXEEXT): queues.c $(LIBRARIES)
649 +test_priority_queue$(EXEEXT): queues.c $(LTLIBRARIES)
650         $(LINK) $(FLAGS) -DMAIN  ./queues.c $(LDADD) $(LIBS)
651  
652 -test_thr_alarm$(EXEEXT): thr_alarm.c $(LIBRARIES)
653 +test_thr_alarm$(EXEEXT): thr_alarm.c $(LTLIBRARIES)
654         $(CP) $(srcdir)/thr_alarm.c ./test_thr_alarm.c
655         $(LINK) $(FLAGS) -DMAIN  ./test_thr_alarm.c $(LDADD) $(LIBS)
656         $(RM) -f ./test_thr_alarm.c
657  
658 -test_thr_lock$(EXEEXT): thr_lock.c $(LIBRARIES)
659 +test_thr_lock$(EXEEXT): thr_lock.c $(LTLIBRARIES)
660         $(CP) $(srcdir)/thr_lock.c test_thr_lock.c
661         $(LINK) $(FLAGS) -DMAIN  ./test_thr_lock.c $(LDADD) $(LIBS)
662         $(RM) -f ./test_thr_lock.c
663  
664 -test_vsnprintf$(EXEEXT): my_vsnprintf.c $(LIBRARIES)
665 +test_vsnprintf$(EXEEXT): my_vsnprintf.c $(LTLIBRARIES)
666         $(CP) $(srcdir)/my_vsnprintf.c test_vsnprintf.c
667         $(LINK) $(FLAGS) -DMAIN ./test_vsnprintf.c $(LDADD) $(LIBS)
668         $(RM) -f test_vsnprintf.c
669  
670 -test_io_cache$(EXEEXT): mf_iocache.c $(LIBRARIES)
671 +test_io_cache$(EXEEXT): mf_iocache.c $(LTLIBRARIES)
672         $(CP) $(srcdir)/mf_iocache.c test_io_cache.c
673         $(LINK) $(FLAGS) -DMAIN ./test_io_cache.c $(LDADD) $(LIBS)
674         $(RM) -f test_io_cache.c
675  
676 -test_dir$(EXEEXT): test_dir.c $(LIBRARIES)
677 +test_dir$(EXEEXT): test_dir.c $(LTLIBRARIES)
678         $(LINK) $(FLAGS) -DMAIN $(srcdir)/test_dir.c $(LDADD) $(LIBS)
679  
680 -test_charset$(EXEEXT): test_charset.c $(LIBRARIES)
681 +test_charset$(EXEEXT): test_charset.c $(LTLIBRARIES)
682         $(LINK) $(FLAGS) -DMAIN $(srcdir)/test_charset.c $(LDADD) $(LIBS)
683  
684 -testhash$(EXEEXT): testhash.c $(LIBRARIES)
685 +testhash$(EXEEXT): testhash.c $(LTLIBRARIES)
686         $(LINK) $(FLAGS) -DMAIN $(srcdir)/testhash.c $(LDADD) $(LIBS)
687  
688 -test_gethwaddr$(EXEEXT): my_gethwaddr.c $(LIBRARIES)
689 +test_gethwaddr$(EXEEXT): my_gethwaddr.c $(LTLIBRARIES)
690         $(CP) $(srcdir)/my_gethwaddr.c ./test_gethwaddr.c
691         $(LINK) $(FLAGS) -DMAIN  ./test_gethwaddr.c $(LDADD) $(LIBS)
692         $(RM) -f ./test_gethwaddr.c
693  
694 -test_base64$(EXEEXT): base64.c $(LIBRARIES)
695 +test_base64$(EXEEXT): base64.c $(LTLIBRARIES)
696         $(CP) $(srcdir)/base64.c ./test_base64.c
697         $(LINK) $(FLAGS) -DMAIN  ./test_base64.c $(LDADD) $(LIBS)
698         $(RM) -f ./test_base64.c
699 === modified file 'netware/BUILD/compile-linux-tools'
700 --- netware/BUILD/compile-linux-tools   2010-09-25 16:02:57.650003347 +0000
701 +++ netware/BUILD/compile-linux-tools   2010-09-25 16:04:17.953336677 +0000
702 @@ -34,14 +34,14 @@
703  # Create mysql_version.h which was deleted my previous step
704  ./config.status include/mysql_version.h
705                                                                                                                               
706 -(cd dbug; make libdbug.a)
707 -(cd strings; make libmystrings.a)
708 -(cd mysys; make libmysys.a)
709 -(cd storage/heap; make libheap.a)
710 -(cd vio; make libvio.a)
711 -(cd regex; make libregex.a)
712 -(cd storage/myisam; make libmyisam.a)
713 -(cd storage/myisammrg; make libmyisammrg.a)
714 +(cd dbug; make libdbug.la)
715 +(cd strings; make libmystrings.la)
716 +(cd mysys; make libmysys.la)
717 +(cd storage/heap; make libheap.la)
718 +(cd vio; make libvio.la)
719 +(cd regex; make libregex.la)
720 +(cd storage/myisam; make libmyisam.la)
721 +(cd storage/myisammrg; make libmyisammrg.la)
722  (cd extra; make comp_err)
723  (cd libmysql; make conf_to_src)
724  (cd libmysql_r; make conf_to_src)
725 === modified file 'netware/Makefile.am'
726 --- netware/Makefile.am 2010-09-25 16:02:57.646670013 +0000
727 +++ netware/Makefile.am 2010-09-25 16:03:34.123336683 +0000
728 @@ -16,8 +16,8 @@
729  
730  if HAVE_NETWARE
731  INCLUDES =                     -I$(top_builddir)/include -I$(top_srcdir)/include -I..
732 -LDADD =                                @CLIENT_EXTRA_LDFLAGS@ ../mysys/libmysys.a \
733 -                               ../dbug/libdbug.a ../strings/libmystrings.a
734 +LDADD =                                @CLIENT_EXTRA_LDFLAGS@ ../mysys/libmysys.la \
735 +                               ../dbug/libdbug.la ../strings/libmystrings.la
736  bin_PROGRAMS =                 mysqld_safe mysql_install_db mysql_test_run libmysql
737  mysqld_safe_SOURCES=           mysqld_safe.c my_manage.c
738  mysql_install_db_SOURCES=      mysql_install_db.c my_manage.c
739 === modified file 'regex/Makefile.am'
740 --- regex/Makefile.am   2010-08-27 14:12:44 +0000
741 +++ regex/Makefile.am   2010-09-16 12:49:35 +0000
742 @@ -16,10 +16,10 @@
743  # MA 02111-1307, USA
744  
745  INCLUDES =             -I$(top_builddir)/include -I$(top_srcdir)/include
746 -noinst_LIBRARIES =     libregex.a
747 -LDADD=                 libregex.a $(top_builddir)/strings/libmystrings.a
748 +noinst_LTLIBRARIES =   libregex.la
749 +LDADD=                 libregex.la $(top_builddir)/strings/libmystrings.la
750  noinst_HEADERS =       cclass.h cname.h regex2.h utils.h engine.c my_regex.h
751 -libregex_a_SOURCES =   regerror.c regcomp.c regexec.c regfree.c reginit.c
752 +libregex_la_SOURCES =  regerror.c regcomp.c regexec.c regfree.c reginit.c
753  noinst_PROGRAMS =      re
754  re_SOURCES =           split.c debug.c main.c
755  re_LDFLAGS= @NOINST_LDFLAGS@
756
757 === modified file 'server-tools/instance-manager/Makefile.am'
758 --- server-tools/instance-manager/Makefile.am   2007-02-18 12:45:28 +0000
759 +++ server-tools/instance-manager/Makefile.am   2010-09-16 12:49:35 +0000
760 @@ -87,10 +87,10 @@
761  mysqlmanager_LDADD=    @CLIENT_EXTRA_LDFLAGS@ \
762                         liboptions.la \
763                         libnet.a \
764 -                       $(top_builddir)/vio/libvio.a \
765 -                       $(top_builddir)/mysys/libmysys.a \
766 -                       $(top_builddir)/strings/libmystrings.a \
767 -                       $(top_builddir)/dbug/libdbug.a \
768 +                       $(top_builddir)/vio/libvio.la \
769 +                       $(top_builddir)/mysys/libmysys.la \
770 +                       $(top_builddir)/strings/libmystrings.la \
771 +                       $(top_builddir)/dbug/libdbug.la \
772                         @openssl_libs@ @yassl_libs@ @ZLIB_LIBS@
773  
774  EXTRA_DIST =           WindowsService.cpp WindowsService.h IMService.cpp \
775
776 === modified file 'sql/Makefile.am'
777 --- sql/Makefile.am     2010-08-27 14:12:44 +0000
778 +++ sql/Makefile.am     2010-09-16 12:49:35 +0000
779 @@ -32,13 +32,13 @@
780  noinst_LTLIBRARIES=    libndb.la \
781                         udf_example.la
782  
783 -SUPPORTING_LIBS =      $(top_builddir)/vio/libvio.a \
784 -                       $(top_builddir)/mysys/libmysys.a \
785 -                       $(top_builddir)/dbug/libdbug.a \
786 -                       $(top_builddir)/regex/libregex.a \
787 -                       $(top_builddir)/strings/libmystrings.a
788 +SUPPORTING_LIBS =      $(top_builddir)/vio/libvio.la \
789 +                       $(top_builddir)/mysys/libmysys.la \
790 +                       $(top_builddir)/dbug/libdbug.la \
791 +                       $(top_builddir)/regex/libregex.la \
792 +                       $(top_builddir)/strings/libmystrings.la
793  mysqld_DEPENDENCIES=   @mysql_plugin_libs@ $(SUPPORTING_LIBS) libndb.la
794 -LDADD = $(SUPPORTING_LIBS) @ZLIB_LIBS@ @NDB_SCI_LIBS@
795 +LDADD = $(SUPPORTING_LIBS) @ZLIB_LIBS@ @NDB_SCI_LIBS@ $(openssl_libs) $(yassl_libs)
796  mysqld_LDADD =         libndb.la \
797                         @MYSQLD_EXTRA_LDFLAGS@ \
798                         @pstack_libs@ \
799 === modified file 'storage/archive/Makefile.am'
800 --- storage/archive/Makefile.am 2010-07-09 11:37:51 +0000
801 +++ storage/archive/Makefile.am 2010-09-16 12:49:35 +0000
802 @@ -33,7 +33,7 @@
803  noinst_HEADERS =       ha_archive.h azlib.h
804  noinst_PROGRAMS        =       archive_test archive_reader
805  
806 -EXTRA_LTLIBRARIES =    ha_archive.la
807 +EXTRA_LTLIBRARIES =    libarchive.la ha_archive.la
808  pkgplugin_LTLIBRARIES =        @plugin_archive_shared_target@
809  ha_archive_la_LDFLAGS =        -module -rpath $(pkgplugindir)
810  ha_archive_la_CXXFLAGS=        $(AM_CXXFLAGS) -DMYSQL_DYNAMIC_PLUGIN
811 @@ -41,26 +41,25 @@
812  ha_archive_la_SOURCES =        ha_archive.cc azio.c
813  
814  
815 -EXTRA_LIBRARIES =      libarchive.a
816 -noinst_LIBRARIES =     @plugin_archive_static_target@
817 -libarchive_a_CXXFLAGS =        $(AM_CXXFLAGS)
818 -libarchive_a_CFLAGS =  $(AM_CFLAGS)
819 -libarchive_a_SOURCES = ha_archive.cc azio.c
820 +noinst_LTLIBRARIES =   @plugin_archive_static_target@
821 +libarchive_la_CXXFLAGS =       $(AM_CXXFLAGS) @plugin_static_if_no_embedded@
822 +libarchive_la_CFLAGS = $(AM_CFLAGS) @plugin_static_if_no_embedded@
823 +libarchive_la_SOURCES =        ha_archive.cc azio.c
824  
825  
826  archive_test_SOURCES = archive_test.c azio.c
827  archive_test_CFLAGS =  $(AM_CFLAGS)
828 -archive_test_LDADD =   $(top_builddir)/mysys/libmysys.a \
829 -                       $(top_builddir)/dbug/libdbug.a \
830 -                       $(top_builddir)/strings/libmystrings.a \
831 +archive_test_LDADD =   $(top_builddir)/mysys/libmysys.la \
832 +                       $(top_builddir)/dbug/libdbug.la \
833 +                       $(top_builddir)/strings/libmystrings.la \
834                         @ZLIB_LIBS@
835  archive_test_LDFLAGS = @NOINST_LDFLAGS@
836  
837  archive_reader_SOURCES = archive_reader.c azio.c
838  archive_reader_CFLAGS =        $(AM_CFLAGS)
839 -archive_reader_LDADD = $(top_builddir)/mysys/libmysys.a \
840 -                       $(top_builddir)/dbug/libdbug.a \
841 -                       $(top_builddir)/strings/libmystrings.a \
842 +archive_reader_LDADD = $(top_builddir)/mysys/libmysys.la \
843 +                       $(top_builddir)/dbug/libdbug.la \
844 +                       $(top_builddir)/strings/libmystrings.la \
845                         @ZLIB_LIBS@
846  archive_reader_LDFLAGS = @NOINST_LDFLAGS@
847  
848
849 === modified file 'storage/archive/plug.in'
850 --- storage/archive/plug.in     2006-05-06 11:43:18 +0000
851 +++ storage/archive/plug.in     2010-09-16 12:49:35 +0000
852 @@ -1,4 +1,4 @@
853  MYSQL_STORAGE_ENGINE(archive,,  [Archive Storage Engine],
854          [Archive Storage Engine], [max,max-no-ndb])
855 -MYSQL_PLUGIN_STATIC(archive,    [libarchive.a])
856 +MYSQL_PLUGIN_STATIC(archive,    [libarchive.la])
857  MYSQL_PLUGIN_DYNAMIC(archive,   [ha_archive.la])
858
859 === modified file 'storage/blackhole/Makefile.am'
860 --- storage/blackhole/Makefile.am       2010-07-09 11:37:51 +0000
861 +++ storage/blackhole/Makefile.am       2010-09-16 12:49:35 +0000
862 @@ -32,7 +32,7 @@
863  
864  noinst_HEADERS =       ha_blackhole.h
865  
866 -EXTRA_LTLIBRARIES =    ha_blackhole.la
867 +EXTRA_LTLIBRARIES =    libblackhole.la ha_blackhole.la
868  pkgplugin_LTLIBRARIES =        @plugin_blackhole_shared_target@
869  ha_blackhole_la_LDFLAGS=-module -rpath $(pkgplugindir)
870  ha_blackhole_la_CXXFLAGS=$(AM_CXXFLAGS) -DMYSQL_DYNAMIC_PLUGIN
871 @@ -40,11 +40,10 @@
872  ha_blackhole_la_SOURCES=ha_blackhole.cc
873  
874  
875 -EXTRA_LIBRARIES =      libblackhole.a
876 -noinst_LIBRARIES =     @plugin_blackhole_static_target@
877 -libblackhole_a_CXXFLAGS=$(AM_CXXFLAGS)
878 -libblackhole_a_CFLAGS =        $(AM_CFLAGS)
879 -libblackhole_a_SOURCES=        ha_blackhole.cc
880 +noinst_LTLIBRARIES =   @plugin_blackhole_static_target@
881 +libblackhole_la_CXXFLAGS=$(AM_CXXFLAGS)  @plugin_static_if_no_embedded@
882 +libblackhole_la_CFLAGS =       $(AM_CFLAGS) @plugin_static_if_no_embedded@
883 +libblackhole_la_SOURCES=       ha_blackhole.cc
884  
885  
886  EXTRA_DIST =           CMakeLists.txt plug.in
887
888 === modified file 'storage/blackhole/plug.in'
889 --- storage/blackhole/plug.in   2006-08-19 04:19:19 +0000
890 +++ storage/blackhole/plug.in   2010-09-16 12:49:35 +0000
891 @@ -1,6 +1,6 @@
892  MYSQL_STORAGE_ENGINE(blackhole,,[Blackhole Storage Engine],
893          [Basic Write-only Read-never tables], [max,max-no-ndb])
894  MYSQL_PLUGIN_DIRECTORY(blackhole, [storage/blackhole])
895 -MYSQL_PLUGIN_STATIC(blackhole,  [libblackhole.a])
896 +MYSQL_PLUGIN_STATIC(blackhole,  [libblackhole.la])
897  MYSQL_PLUGIN_DYNAMIC(blackhole, [ha_blackhole.la])
898  
899
900 === modified file 'storage/csv/Makefile.am'
901 --- storage/csv/Makefile.am     2010-07-09 11:37:51 +0000
902 +++ storage/csv/Makefile.am     2010-09-16 12:49:35 +0000
903 @@ -29,16 +29,15 @@
904  DEFS = @DEFS@
905  noinst_HEADERS   =     ha_tina.h transparent_file.h
906  
907 -EXTRA_LTLIBRARIES =    ha_csv.la
908 +EXTRA_LTLIBRARIES =    libcsv.la ha_csv.la
909  pkglib_LTLIBRARIES =   @plugin_csv_shared_target@
910  ha_csv_la_LDFLAGS =    -module -rpath $(MYSQLLIBdir)
911  ha_csv_la_CXXFLAGS =   $(AM_CXXFLAGS) -DMYSQL_PLUGIN
912  ha_csv_la_SOURCES =    transparent_file.cc ha_tina.cc 
913  
914 -EXTRA_LIBRARIES =      libcsv.a
915 -noinst_LIBRARIES =     @plugin_csv_static_target@
916 -libcsv_a_CXXFLAGS =    $(AM_CXXFLAGS)
917 -libcsv_a_SOURCES =     transparent_file.cc ha_tina.cc
918 +noinst_LTLIBRARIES =   @plugin_csv_static_target@
919 +libcsv_la_CXXFLAGS =   $(AM_CXXFLAGS)  @plugin_static_if_no_embedded@
920 +libcsv_la_SOURCES =    transparent_file.cc ha_tina.cc
921  
922  EXTRA_DIST =           CMakeLists.txt plug.in
923  # Don't update the files from bitkeeper
924
925 === modified file 'storage/csv/plug.in'
926 --- storage/csv/plug.in 2006-08-19 04:19:19 +0000
927 +++ storage/csv/plug.in 2010-09-16 12:49:35 +0000
928 @@ -1,5 +1,5 @@
929  MYSQL_STORAGE_ENGINE(csv,,      [CSV Storage Engine],
930          [Stores tables in text CSV format])
931  MYSQL_PLUGIN_DIRECTORY(csv,     [storage/csv])
932 -MYSQL_PLUGIN_STATIC(csv,        [libcsv.a])
933 +MYSQL_PLUGIN_STATIC(csv,        [libcsv.la])
934  MYSQL_PLUGIN_MANDATORY(csv)     dnl Used for logging
935
936 === modified file 'storage/example/Makefile.am'
937 --- storage/example/Makefile.am 2010-07-09 11:37:51 +0000
938 +++ storage/example/Makefile.am 2010-09-16 12:49:35 +0000
939 @@ -32,7 +32,7 @@
940  
941  noinst_HEADERS =       ha_example.h
942  
943 -EXTRA_LTLIBRARIES =    ha_example.la
944 +EXTRA_LTLIBRARIES =    libexample.la ha_example.la
945  pkgplugin_LTLIBRARIES =        @plugin_example_shared_target@
946  ha_example_la_LDFLAGS =        -module -rpath $(pkgplugindir)
947  ha_example_la_CXXFLAGS=        $(AM_CXXFLAGS) -DMYSQL_DYNAMIC_PLUGIN
948 @@ -40,11 +40,10 @@
949  ha_example_la_SOURCES =        ha_example.cc
950  
951  
952 -EXTRA_LIBRARIES =      libexample.a
953 -noinst_LIBRARIES =     @plugin_example_static_target@
954 -libexample_a_CXXFLAGS =        $(AM_CXXFLAGS)
955 -libexample_a_CFLAGS =  $(AM_CFLAGS)
956 -libexample_a_SOURCES=  ha_example.cc
957 +noinst_LTLIBRARIES =   @plugin_example_static_target@
958 +libexample_la_CXXFLAGS =       $(AM_CXXFLAGS)  @plugin_static_if_no_embedded@
959 +libexample_la_CFLAGS = $(AM_CFLAGS)  @plugin_static_if_no_embedded@
960 +libexample_la_SOURCES= ha_example.cc
961  
962  
963  EXTRA_DIST =           CMakeLists.txt plug.in
964
965 === modified file 'storage/federated/Makefile.am'
966 --- storage/federated/Makefile.am       2010-08-27 14:12:44 +0000
967 +++ storage/federated/Makefile.am       2010-09-16 12:49:35 +0000
968 @@ -32,7 +32,7 @@
969  
970  noinst_HEADERS =       ha_federated.h
971  
972 -EXTRA_LTLIBRARIES =    ha_federated.la
973 +EXTRA_LTLIBRARIES =    libfederated.la libfederated_embedded.la ha_federated.la
974  pkgplugin_LTLIBRARIES =        @plugin_federated_shared_target@
975  ha_federated_la_LDFLAGS =      -module -rpath $(pkgplugindir)
976  ha_federated_la_CXXFLAGS=      $(AM_CXXFLAGS) -DMYSQL_DYNAMIC_PLUGIN
977 @@ -40,11 +40,14 @@
978  ha_federated_la_SOURCES =      ha_federated.cc
979  
980  
981 -EXTRA_LIBRARIES =      libfederated.a
982 -noinst_LIBRARIES =     @plugin_federated_static_target@
983 -libfederated_a_CXXFLAGS =      $(AM_CXXFLAGS)
984 -libfederated_a_CFLAGS =        $(AM_CFLAGS)
985 -libfederated_a_SOURCES=        ha_federated.cc
986 +noinst_LTLIBRARIES =   @plugin_federated_static_target@ @plugin_federated_embedded_static_target@
987 +libfederated_la_CXXFLAGS =     $(AM_CXXFLAGS) @plugin_static_if_no_embedded@
988 +libfederated_la_CFLAGS =       $(AM_CFLAGS) @plugin_static_if_no_embedded@
989 +libfederated_la_SOURCES=       ha_federated.cc
990 +
991 +libfederated_embedded_la_CXXFLAGS =    $(AM_CXXFLAGS) @plugin_embedded_defs@
992 +libfederated_embedded_la_CFLAGS =  $(AM_CFLAGS) @plugin_embedded_defs@
993 +libfederated_embedded_la_SOURCES=  ha_federated.cc
994  
995  
996  EXTRA_DIST =           CMakeLists.txt plug.in
997 === modified file 'storage/federated/plug.in'
998 --- storage/federated/plug.in   2010-06-09 21:29:18 +0000
999 +++ storage/federated/plug.in   2010-09-16 12:49:35 +0000
1000 @@ -1,5 +1,4 @@
1001  MYSQL_STORAGE_ENGINE(federated,,[Federated Storage Engine],
1002          [Connects to tables on remote MySQL servers], [max,max-no-ndb])
1003 -MYSQL_PLUGIN_STATIC(federated,    [libfederated.a])
1004 +MYSQL_PLUGIN_STATIC(federated,    [libfederated.a], [libfederated_embedded.la])
1005  MYSQL_PLUGIN_DYNAMIC(federated,   [ha_federated.la])
1006 -MYSQL_PLUGIN_DEPENDS_ON_MYSQL_INTERNALS(federated, [ha_federated.cc])
1007 === modified file 'storage/heap/Makefile.am'
1008 --- storage/heap/Makefile.am    2006-12-31 00:32:21 +0000
1009 +++ storage/heap/Makefile.am    2010-09-16 12:49:35 +0000
1010 @@ -26,27 +26,41 @@
1011  LDADD =
1012  
1013  DEFS =                  @DEFS@
1014 -pkglib_LIBRARIES =     libheap.a
1015 +pkglib_LTLIBRARIES =   libheap.la
1016 +noinst_LTLIBRARIES =   libheap_s.la libheap_common.la \
1017 +                       @plugin_heap_embedded_static_target@
1018 +EXTRA_LTLIBRARIES =    libheap_embedded.la
1019 +
1020  noinst_PROGRAMS        =       hp_test1 hp_test2
1021 -noinst_LIBRARIES =     libheap.a
1022  hp_test1_LDFLAGS = @NOINST_LDFLAGS@
1023 -hp_test1_LDADD =       libheap.a \
1024 -                       $(top_builddir)/mysys/libmysys.a \
1025 -                       $(top_builddir)/dbug/libdbug.a \
1026 -                       $(top_builddir)/strings/libmystrings.a
1027 +hp_test1_LDADD =       libheap.la \
1028 +                       $(top_builddir)/mysys/libmysys.la \
1029 +                       $(top_builddir)/dbug/libdbug.la \
1030 +                       $(top_builddir)/strings/libmystrings.la
1031  hp_test2_LDFLAGS = @NOINST_LDFLAGS@
1032 -hp_test2_LDADD =       libheap.a \
1033 -                       $(top_builddir)/mysys/libmysys.a \
1034 -                       $(top_builddir)/dbug/libdbug.a \
1035 -                       $(top_builddir)/strings/libmystrings.a
1036 +hp_test2_LDADD =       libheap.la \
1037 +                       $(top_builddir)/mysys/libmysys.la \
1038 +                       $(top_builddir)/dbug/libdbug.la \
1039 +                       $(top_builddir)/strings/libmystrings.la
1040  noinst_HEADERS =       heapdef.h ha_heap.h
1041 -libheap_a_SOURCES =    hp_open.c hp_extra.c hp_close.c hp_panic.c hp_info.c \
1042 +libheap_common_la_SOURCES =    hp_open.c hp_extra.c hp_close.c hp_panic.c hp_info.c \
1043                         hp_rrnd.c hp_scan.c hp_update.c hp_write.c hp_delete.c \
1044                         hp_rsame.c hp_create.c hp_rename.c hp_rfirst.c \
1045                         hp_rnext.c hp_rlast.c hp_rprev.c hp_clear.c \
1046                         hp_rkey.c hp_block.c \
1047 -                       ha_heap.cc \
1048                         hp_hash.c _check.c _rectest.c hp_static.c
1049 +libheap_common_la_CFLAGS =     $(AM_LDFLAGS) @plugin_static_if_no_embedded@
1050 +
1051 +libheap_s_la_SOURCES = ha_heap.cc
1052 +libheap_s_la_CFLAGS =  $(AM_CFLAGS) @plugin_static_if_no_embedded@
1053 +libheap_s_la_CXXFLAGS =        $(AM_CXXFLAGS) @plugin_static_if_no_embedded@
1054 +libheap_s_la_LIBADD =  libheap_common.la
1055 +libheap_embedded_la_SOURCES =  ha_heap.cc
1056 +libheap_embedded_la_LIBADD =   libheap_common.la
1057 +libheap_embedded_la_CXXFLAGS = @plugin_embedded_defs@
1058 +libheap_la_SOURCES =   
1059 +libheap_la_LIBADD =    libheap_s.la
1060 +libheap_la_LDFLAGS =   -static
1061  
1062  
1063  EXTRA_DIST =           CMakeLists.txt plug.in
1064
1065 === modified file 'storage/heap/plug.in'
1066 --- storage/heap/plug.in        2006-10-18 12:03:37 +0000
1067 +++ storage/heap/plug.in        2010-09-16 12:49:35 +0000
1068 @@ -1,7 +1,6 @@
1069  MYSQL_STORAGE_ENGINE(heap,no,   [Memory Storage Engine],
1070          [Volatile memory based tables])
1071  MYSQL_PLUGIN_DIRECTORY(heap,    [storage/heap])
1072 -MYSQL_PLUGIN_STATIC(heap,       [libheap.a])
1073 +MYSQL_PLUGIN_STATIC(heap,       [libheap_s.la], [libheap_embedded.la])
1074  MYSQL_PLUGIN_MANDATORY(heap)    dnl Memory tables
1075 -MYSQL_PLUGIN_DEPENDS_ON_MYSQL_INTERNALS(heap, [ha_heap.cc])
1076  
1077
1078 === modified file 'storage/innodbase/Makefile.am'
1079 --- storage/innobase/Makefile.am        2010-09-25 18:01:14.340003346 +0000
1080 +++ storage/innobase/Makefile.am        2010-09-25 18:06:15.086670017 +0000
1081 @@ -15,21 +15,20 @@
1082  
1083  # Process this file with automake to create Makefile.in
1084  
1085 -MYSQLDATAdir=          $(localstatedir)
1086 -MYSQLSHAREdir=         $(pkgdatadir)
1087 -MYSQLBASEdir=          $(prefix)
1088 -MYSQLLIBdir=           $(pkglibdir)
1089 -pkgplugindir=          $(pkglibdir)/plugin
1090 -INCLUDES=              -I$(top_srcdir)/include -I$(top_builddir)/include \
1091 +MYSQLDATAdir = $(localstatedir)
1092 +MYSQLSHAREdir =        $(pkgdatadir)
1093 +MYSQLBASEdir = $(prefix)
1094 +MYSQLLIBdir =  $(pkglibdir)
1095 +pkgplugindir = $(pkglibdir)/plugin
1096 +INCLUDES =     -I$(top_srcdir)/include -I$(top_builddir)/include \
1097                         -I$(top_srcdir)/regex \
1098                         -I$(top_srcdir)/storage/innobase/include \
1099                         -I$(top_srcdir)/sql \
1100                         -I$(srcdir)
1101  
1102 -DEFS=                  @DEFS@
1103 +DEFS=  @DEFS@
1104  
1105 -
1106 -noinst_HEADERS=                include/btr0btr.h include/btr0btr.ic            \
1107 +noinst_HEADERS =       include/btr0btr.h include/btr0btr.ic            \
1108                         include/btr0cur.h include/btr0cur.ic            \
1109                         include/btr0pcur.h include/btr0pcur.ic          \
1110                         include/btr0sea.h include/btr0sea.ic            \
1111 @@ -122,9 +121,8 @@
1112                         include/ut0list.ic include/ut0wqueue.h          \
1113                         include/ha_prototypes.h handler/ha_innodb.h
1114  
1115 -EXTRA_LIBRARIES=       libinnobase.a
1116 -noinst_LIBRARIES=      @plugin_innobase_static_target@
1117 -libinnobase_a_SOURCES= btr/btr0btr.c btr/btr0cur.c btr/btr0pcur.c      \
1118 +noinst_LTLIBRARIES =   @plugin_innobase_static_target@
1119 +libinnobase_la_SOURCES =       btr/btr0btr.c btr/btr0cur.c btr/btr0pcur.c      \
1120                         btr/btr0sea.c buf/buf0buf.c buf/buf0flu.c       \
1121                         buf/buf0lru.c buf/buf0rea.c data/data0data.c    \
1122                         data/data0type.c dict/dict0boot.c               \
1123 @@ -156,18 +154,18 @@
1124                         ut/ut0ut.c ut/ut0vec.c ut/ut0wqueue.c           \
1125                         handler/ha_innodb.cc
1126  
1127 -libinnobase_a_CXXFLAGS=        $(AM_CXXFLAGS)
1128 -libinnobase_a_CFLAGS=  $(AM_CFLAGS)
1129 +libinnobase_la_CXXFLAGS =      $(AM_CXXFLAGS)
1130 +libinnobase_la_CFLAGS =        $(AM_CFLAGS)
1131  
1132 -EXTRA_LTLIBRARIES=     ha_innodb.la
1133 -pkgplugin_LTLIBRARIES= @plugin_innobase_shared_target@
1134 +EXTRA_LTLIBRARIES =    libinnobase.la ha_innodb.la
1135 +pkgplugin_LTLIBRARIES =        @plugin_innobase_shared_target@
1136  
1137 -ha_innodb_la_LDFLAGS=  -module -rpath $(pkgplugindir)
1138 -ha_innodb_la_CXXFLAGS= $(AM_CXXFLAGS) $(INNODB_DYNAMIC_CFLAGS)
1139 -ha_innodb_la_CFLAGS=   $(AM_CFLAGS) $(INNODB_DYNAMIC_CFLAGS)
1140 -ha_innodb_la_SOURCES=  $(libinnobase_a_SOURCES)
1141 +ha_innodb_la_LDFLAGS = -module -rpath $(pkgplugindir)
1142 +ha_innodb_la_CXXFLAGS =        $(AM_CXXFLAGS) $(INNODB_DYNAMIC_CFLAGS)
1143 +ha_innodb_la_CFLAGS =  $(AM_CFLAGS) $(INNODB_DYNAMIC_CFLAGS)
1144 +ha_innodb_la_SOURCES = $(libinnobase_la_SOURCES)
1145  
1146 -EXTRA_DIST=            CMakeLists.txt plug.in \
1147 +EXTRA_DIST =   CMakeLists.txt plug.in \
1148                         pars/make_bison.sh pars/make_flex.sh \
1149                         pars/pars0grm.y pars/pars0lex.l
1150  
1151 === modified file 'storage/innodbase/plug.in'
1152 --- storage/innobase/plug.in    2010-09-25 18:01:14.340003346 +0000
1153 +++ storage/innobase/plug.in    2010-09-25 18:06:15.086670017 +0000
1154 @@ -1,7 +1,7 @@
1155  MYSQL_STORAGE_ENGINE(innobase, innodb, [InnoDB Storage Engine],
1156          [Transactional Tables using InnoDB], [max,max-no-ndb])
1157  MYSQL_PLUGIN_DIRECTORY(innobase, [storage/innobase])
1158 -MYSQL_PLUGIN_STATIC(innobase,   [libinnobase.a])
1159 +MYSQL_PLUGIN_STATIC(innobase,   [libinnobase.la])
1160  MYSQL_PLUGIN_DYNAMIC(innobase,  [ha_innodb.la])
1161  MYSQL_PLUGIN_ACTIONS(innobase,  [
1162    AC_CHECK_LIB(rt, aio_read, [innodb_system_libs="-lrt"])
1163 === modified file 'storage/innodb_plugin/Makefile.am'
1164 --- storage/innodb_plugin/Makefile.am   2010-07-09 11:37:51 +0000
1165 +++ storage/innodb_plugin/Makefile.am   2010-09-16 12:49:35 +0000
1166 @@ -228,9 +228,8 @@
1167                         include/ut0wqueue.h     \
1168                         mem/mem0dbg.c
1169  
1170 -EXTRA_LIBRARIES=       libinnobase.a
1171 -noinst_LIBRARIES=      @plugin_innodb_plugin_static_target@
1172 -libinnobase_a_SOURCES= \
1173 +noinst_LTLIBRARIES=    @plugin_innodb_plugin_static_target@
1174 +libinnobase_la_SOURCES=        \
1175                         btr/btr0btr.c                   \
1176                         btr/btr0cur.c                   \
1177                         btr/btr0pcur.c                  \
1178 @@ -325,16 +324,16 @@
1179                         ut/ut0vec.c                     \
1180                         ut/ut0wqueue.c
1181  
1182 -libinnobase_a_CXXFLAGS=        $(AM_CXXFLAGS)
1183 -libinnobase_a_CFLAGS=  $(AM_CFLAGS)
1184 +libinnobase_la_CXXFLAGS=       $(AM_CXXFLAGS) @plugin_static_if_no_embedded@
1185 +libinnobase_la_CFLAGS= $(AM_CFLAGS) @plugin_static_if_no_embedded@
1186  
1187 -EXTRA_LTLIBRARIES=     ha_innodb_plugin.la
1188 +EXTRA_LTLIBRARIES=     libinnobase.la ha_innodb_plugin.la
1189  pkgplugin_LTLIBRARIES= @plugin_innodb_plugin_shared_target@
1190  
1191  ha_innodb_plugin_la_LDFLAGS=   -module -rpath $(pkgplugindir)
1192  ha_innodb_plugin_la_CXXFLAGS=  $(AM_CXXFLAGS) $(INNODB_DYNAMIC_CFLAGS)
1193  ha_innodb_plugin_la_CFLAGS=    $(AM_CFLAGS) $(INNODB_DYNAMIC_CFLAGS)
1194 -ha_innodb_plugin_la_SOURCES=   $(libinnobase_a_SOURCES)
1195 +ha_innodb_plugin_la_SOURCES=   $(libinnobase_la_SOURCES)
1196  
1197  EXTRA_DIST=            CMakeLists.txt plug.in \
1198                         pars/make_bison.sh pars/make_flex.sh \
1199
1200 === modified file 'storage/myisam/Makefile.am'
1201 --- storage/myisam/Makefile.am  2009-10-23 16:48:54 +0000
1202 +++ storage/myisam/Makefile.am  2010-09-16 12:49:35 +0000
1203 @@ -30,60 +30,64 @@
1204  EXTRA_DIST =           mi_test_all.sh mi_test_all.res ft_stem.c CMakeLists.txt plug.in
1205  pkgdata_DATA =         mi_test_all mi_test_all.res
1206  
1207 -pkglib_LIBRARIES =     libmyisam.a
1208 +pkglib_LTLIBRARIES =   libmyisam.la
1209 +noinst_LTLIBRARIES =   libmyisam_common.la libmyisam_s.la \
1210 +                       @plugin_myisam_embedded_static_target@
1211 +EXTRA_LTLIBRARIES =    libmyisam_embedded.la
1212 +
1213  bin_PROGRAMS =         myisamchk myisamlog myisampack myisam_ftdump
1214 -myisamchk_DEPENDENCIES=        $(LIBRARIES)
1215 -myisamchk_LDADD=               @CLIENT_EXTRA_LDFLAGS@ libmyisam.a \
1216 -                       $(top_builddir)/mysys/libmysys.a \
1217 -                       $(top_builddir)/dbug/libdbug.a \
1218 -                       $(top_builddir)/strings/libmystrings.a @ZLIB_LIBS@
1219 -myisamlog_DEPENDENCIES=        $(LIBRARIES)
1220 -myisamlog_LDADD=               @CLIENT_EXTRA_LDFLAGS@ libmyisam.a \
1221 -                       $(top_builddir)/mysys/libmysys.a \
1222 -                       $(top_builddir)/dbug/libdbug.a \
1223 -                       $(top_builddir)/strings/libmystrings.a @ZLIB_LIBS@
1224 -myisampack_DEPENDENCIES=$(LIBRARIES)
1225 -myisampack_LDADD=              @CLIENT_EXTRA_LDFLAGS@ libmyisam.a \
1226 -                       $(top_builddir)/mysys/libmysys.a \
1227 -                       $(top_builddir)/dbug/libdbug.a \
1228 -                       $(top_builddir)/strings/libmystrings.a @ZLIB_LIBS@
1229 +myisamchk_DEPENDENCIES=        $(LTLIBRARIES)
1230 +myisamchk_LDADD=               @CLIENT_EXTRA_LDFLAGS@ libmyisam.la \
1231 +                       $(top_builddir)/mysys/libmysys.la \
1232 +                       $(top_builddir)/dbug/libdbug.la \
1233 +                       $(top_builddir)/strings/libmystrings.la @ZLIB_LIBS@
1234 +myisamlog_DEPENDENCIES=        $(LTLIBRARIES)
1235 +myisamlog_LDADD=               @CLIENT_EXTRA_LDFLAGS@ libmyisam.la \
1236 +                       $(top_builddir)/mysys/libmysys.la \
1237 +                       $(top_builddir)/dbug/libdbug.la \
1238 +                       $(top_builddir)/strings/libmystrings.la @ZLIB_LIBS@
1239 +myisampack_DEPENDENCIES=$(LTLIBRARIES)
1240 +myisampack_LDADD=              @CLIENT_EXTRA_LDFLAGS@ libmyisam.la \
1241 +                       $(top_builddir)/mysys/libmysys.la \
1242 +                       $(top_builddir)/dbug/libdbug.la \
1243 +                       $(top_builddir)/strings/libmystrings.la @ZLIB_LIBS@
1244  noinst_PROGRAMS =      mi_test1 mi_test2 mi_test3 rt_test sp_test #ft_test1 ft_eval
1245  noinst_HEADERS =       myisamdef.h rt_index.h rt_key.h rt_mbr.h sp_defs.h \
1246                         fulltext.h ftdefs.h ft_test1.h ft_eval.h \
1247                         ha_myisam.h
1248 -mi_test1_DEPENDENCIES= $(LIBRARIES)
1249 -mi_test1_LDADD=                @CLIENT_EXTRA_LDFLAGS@ libmyisam.a \
1250 -                       $(top_builddir)/mysys/libmysys.a \
1251 -                       $(top_builddir)/dbug/libdbug.a \
1252 -                       $(top_builddir)/strings/libmystrings.a @ZLIB_LIBS@
1253 -mi_test2_DEPENDENCIES= $(LIBRARIES)
1254 -mi_test2_LDADD=                @CLIENT_EXTRA_LDFLAGS@ libmyisam.a \
1255 -                       $(top_builddir)/mysys/libmysys.a \
1256 -                       $(top_builddir)/dbug/libdbug.a \
1257 -                       $(top_builddir)/strings/libmystrings.a @ZLIB_LIBS@
1258 -mi_test3_DEPENDENCIES= $(LIBRARIES)
1259 -mi_test3_LDADD=                @CLIENT_EXTRA_LDFLAGS@ libmyisam.a \
1260 -                       $(top_builddir)/mysys/libmysys.a \
1261 -                       $(top_builddir)/dbug/libdbug.a \
1262 -                       $(top_builddir)/strings/libmystrings.a @ZLIB_LIBS@
1263 -#ft_test1_DEPENDENCIES=        $(LIBRARIES)
1264 -#ft_eval_DEPENDENCIES= $(LIBRARIES)
1265 -myisam_ftdump_DEPENDENCIES=    $(LIBRARIES)
1266 -myisam_ftdump_LDADD =                  @CLIENT_EXTRA_LDFLAGS@ libmyisam.a \
1267 -                       $(top_builddir)/mysys/libmysys.a \
1268 -                       $(top_builddir)/dbug/libdbug.a \
1269 -                       $(top_builddir)/strings/libmystrings.a @ZLIB_LIBS@
1270 -rt_test_DEPENDENCIES=  $(LIBRARIES)
1271 -rt_test_LDADD =                        @CLIENT_EXTRA_LDFLAGS@ libmyisam.a \
1272 -                       $(top_builddir)/mysys/libmysys.a \
1273 -                       $(top_builddir)/dbug/libdbug.a \
1274 -                       $(top_builddir)/strings/libmystrings.a @ZLIB_LIBS@
1275 -sp_test_DEPENDENCIES=  $(LIBRARIES)
1276 -sp_test_LDADD =                        @CLIENT_EXTRA_LDFLAGS@ libmyisam.a \
1277 -                       $(top_builddir)/mysys/libmysys.a \
1278 -                       $(top_builddir)/dbug/libdbug.a \
1279 -                       $(top_builddir)/strings/libmystrings.a @ZLIB_LIBS@
1280 -libmyisam_a_SOURCES =  mi_open.c mi_extra.c mi_info.c mi_rkey.c \
1281 +mi_test1_DEPENDENCIES= $(LTLIBRARIES)
1282 +mi_test1_LDADD=                @CLIENT_EXTRA_LDFLAGS@ libmyisam.la \
1283 +                       $(top_builddir)/mysys/libmysys.la \
1284 +                       $(top_builddir)/dbug/libdbug.la \
1285 +                       $(top_builddir)/strings/libmystrings.la @ZLIB_LIBS@
1286 +mi_test2_DEPENDENCIES= $(LTLIBRARIES)
1287 +mi_test2_LDADD=                @CLIENT_EXTRA_LDFLAGS@ libmyisam.la \
1288 +                       $(top_builddir)/mysys/libmysys.la \
1289 +                       $(top_builddir)/dbug/libdbug.la \
1290 +                       $(top_builddir)/strings/libmystrings.la @ZLIB_LIBS@
1291 +mi_test3_DEPENDENCIES= $(LTLIBRARIES)
1292 +mi_test3_LDADD=                @CLIENT_EXTRA_LDFLAGS@ libmyisam.la \
1293 +                       $(top_builddir)/mysys/libmysys.la \
1294 +                       $(top_builddir)/dbug/libdbug.la \
1295 +                       $(top_builddir)/strings/libmystrings.la @ZLIB_LIBS@
1296 +#ft_test1_DEPENDENCIES=        $(LTLIBRARIES)
1297 +#ft_eval_DEPENDENCIES= $(LTLIBRARIES)
1298 +myisam_ftdump_DEPENDENCIES=    $(LTLIBRARIES)
1299 +myisam_ftdump_LDADD =                  @CLIENT_EXTRA_LDFLAGS@ libmyisam.la \
1300 +                       $(top_builddir)/mysys/libmysys.la \
1301 +                       $(top_builddir)/dbug/libdbug.la \
1302 +                       $(top_builddir)/strings/libmystrings.la @ZLIB_LIBS@
1303 +rt_test_DEPENDENCIES=  $(LTLIBRARIES)
1304 +rt_test_LDADD =                        @CLIENT_EXTRA_LDFLAGS@ libmyisam.la \
1305 +                       $(top_builddir)/mysys/libmysys.la \
1306 +                       $(top_builddir)/dbug/libdbug.la \
1307 +                       $(top_builddir)/strings/libmystrings.la @ZLIB_LIBS@
1308 +sp_test_DEPENDENCIES=  $(LTLIBRARIES)
1309 +sp_test_LDADD =                        @CLIENT_EXTRA_LDFLAGS@ libmyisam.la \
1310 +                       $(top_builddir)/mysys/libmysys.la \
1311 +                       $(top_builddir)/dbug/libdbug.la \
1312 +                       $(top_builddir)/strings/libmystrings.la @ZLIB_LIBS@
1313 +libmyisam_common_la_SOURCES =  mi_open.c mi_extra.c mi_info.c mi_rkey.c \
1314                         mi_rnext.c mi_rnext_same.c \
1315                         mi_search.c mi_page.c mi_key.c mi_locking.c \
1316                         mi_rrnd.c mi_scan.c mi_cache.c \
1317 @@ -98,8 +102,23 @@
1318                         mi_keycache.c mi_preload.c \
1319                         ft_parser.c ft_stopwords.c ft_static.c \
1320                         ft_update.c ft_boolean_search.c ft_nlq_search.c sort.c \
1321 -                       ha_myisam.cc \
1322                         rt_index.c rt_key.c rt_mbr.c rt_split.c sp_key.c
1323 +libmyisam_common_la_CFLAGS =   $(AM_CFLAGS) @plugin_static_if_no_embedded@
1324 +libmyisam_s_la_SOURCES =       ha_myisam.cc
1325 +libmyisam_s_la_CXXFLAGS =      $(AM_CXXFLAGS) @plugin_static_if_no_embedded@
1326 +libmyisam_s_la_LIBADD =        libmyisam_common.la
1327 +libmyisam_embedded_la_SOURCES =        ha_myisam.cc
1328 +libmyisam_embedded_la_LIBADD = libmyisam_common.la
1329 +libmyisam_embedded_la_CXXFLAGS =       $(AM_CXXFLAGS) @plugin_embedded_defs@
1330 +# libmyisam  references symbols inside mysqld.
1331 +# This means we cannot use it as shared library, as these references causes
1332 +# undefined symbol errors at load time.
1333 +# But a static library works (as long as those parts that references
1334 +# problematic symbols are not linked).
1335 +libmyisam_la_LDFLAGS = -static
1336 +libmyisam_la_SOURCES = 
1337 +libmyisam_la_LIBADD =  libmyisam_s.la
1338 +
1339  CLEANFILES =           test?.MY? FT?.MY? isam.log mi_test_all rt_test.MY? sp_test.MY?
1340  
1341  # Move to automake rules ?
1342
1343 === modified file 'storage/myisam/plug.in'
1344 --- storage/myisam/plug.in      2008-10-10 15:28:41 +0000
1345 +++ storage/myisam/plug.in      2010-09-16 12:49:35 +0000
1346 @@ -1,7 +1,5 @@
1347  MYSQL_STORAGE_ENGINE(myisam,no, [MyISAM Storage Engine],
1348          [Traditional non-transactional MySQL tables])
1349  MYSQL_PLUGIN_DIRECTORY(myisam,  [storage/myisam])
1350 -MYSQL_PLUGIN_STATIC(myisam,     [libmyisam.a])
1351 +MYSQL_PLUGIN_STATIC(myisam,     [libmyisam_s.la], [libmyisam_embedded.la])
1352  MYSQL_PLUGIN_MANDATORY(myisam)  dnl Default
1353 -MYSQL_PLUGIN_DEPENDS_ON_MYSQL_INTERNALS(myisam, [ha_myisam.cc])
1354 -
1355 === modified file 'storage/myisammrg/Makefile.am'
1356 --- storage/myisammrg/Makefile.am       2008-04-25 21:45:58 +0000
1357 +++ storage/myisammrg/Makefile.am       2010-09-16 12:49:35 +0000
1358 @@ -26,16 +26,29 @@
1359  LDADD =
1360  
1361  DEFS =                  @DEFS@
1362 -pkglib_LIBRARIES =     libmyisammrg.a
1363 +pkglib_LTLIBRARIES =   libmyisammrg.la
1364 +noinst_LTLIBRARIES =   libmyisammrg_s.la libmyisammrg_common.la \
1365 +                       @plugin_myisammrg_embedded_static_target@
1366 +EXTRA_LTLIBRARIES =    libmyisammrg_embedded.la
1367  noinst_HEADERS =       myrg_def.h ha_myisammrg.h
1368 -noinst_LIBRARIES =     libmyisammrg.a
1369 -libmyisammrg_a_SOURCES = myrg_open.c myrg_extra.c myrg_info.c myrg_locking.c \
1370 +libmyisammrg_common_la_SOURCES = myrg_open.c myrg_extra.c myrg_info.c myrg_locking.c \
1371                         myrg_rrnd.c myrg_update.c myrg_delete.c myrg_rsame.c \
1372                         myrg_panic.c myrg_close.c myrg_create.c myrg_static.c \
1373                         myrg_rkey.c myrg_rfirst.c myrg_rlast.c myrg_rnext.c \
1374                         myrg_rprev.c myrg_queue.c myrg_write.c myrg_range.c \
1375 -                       ha_myisammrg.cc \
1376                         myrg_rnext_same.c myrg_records.c
1377 +libmyisammrg_common_la_CFLAGS = $(AM_CFLAGS) @plugin_static_if_no_embedded@
1378 +libmyisammrg_s_la_SOURCES = ha_myisammrg.cc
1379 +libmyisammrg_s_la_CXXFLAGS = $(AM_CXXFLAGS) @plugin_static_if_no_embedded@
1380 +libmyisammrg_s_la_LIBADD = libmyisammrg_common.la
1381 +libmyisammrg_embedded_la_SOURCES = ha_myisammrg.cc
1382 +libmyisammrg_embedded_la_CFLAGS = $(AM_CFLAGS) @plugin_embedded_defs@
1383 +libmyisammrg_embedded_la_LIBADD = libmyisammrg_common.la
1384 +libmyisammrg_embedded_la_CXXFLAGS =    $(AM_CXXFLAGS) @plugin_embedded_defs@
1385 +libmyisammrg_la_SOURCES =      
1386 +libmyisammrg_la_LIBADD =       libmyisammrg_s.la
1387 +libmyisammrg_la_LDFLAGS =      -static
1388 +
1389  
1390  
1391  EXTRA_DIST =           CMakeLists.txt plug.in
1392
1393 === modified file 'storage/myisammrg/plug.in'
1394 --- storage/myisammrg/plug.in   2006-10-18 12:03:37 +0000
1395 +++ storage/myisammrg/plug.in   2010-09-16 12:49:35 +0000
1396 @@ -1,6 +1,5 @@
1397  MYSQL_STORAGE_ENGINE(myisammrg,no,[MyISAM MERGE Engine],
1398          [Merge multiple MySQL tables into one])
1399  MYSQL_PLUGIN_DIRECTORY(myisammrg,[storage/myisammrg])
1400 -MYSQL_PLUGIN_STATIC(myisammrg,  [libmyisammrg.a])
1401 +MYSQL_PLUGIN_STATIC(myisammrg,  [libmyisammrg_s.la], [libmyisammrg_embedded.la])
1402  MYSQL_PLUGIN_MANDATORY(myisammrg)
1403 -MYSQL_PLUGIN_DEPENDS_ON_MYSQL_INTERNALS(myisammrg, [ha_myisammrg.cc])
1404
1405 === modified file 'storage/ndb/src/common/util/Makefile.am'
1406 --- storage/ndb/src/common/util/Makefile.am     2010-04-01 11:19:15 +0000
1407 +++ storage/ndb/src/common/util/Makefile.am     2010-09-16 12:49:35 +0000
1408 @@ -31,9 +31,9 @@
1409  testBitmask_SOURCES =  testBitmask.cpp
1410  testBitmask_LDFLAGS = @ndb_bin_am_ldflags@ \
1411    $(top_builddir)/storage/ndb/src/libndbclient.la \
1412 -         $(top_builddir)/dbug/libdbug.a \
1413 -         $(top_builddir)/mysys/libmysys.a \
1414 -         $(top_builddir)/strings/libmystrings.a
1415 +         $(top_builddir)/dbug/libdbug.la \
1416 +         $(top_builddir)/mysys/libmysys.la \
1417 +         $(top_builddir)/strings/libmystrings.la
1418  
1419  testBitmask.cpp : Bitmask.cpp
1420         rm -f testBitmask.cpp
1421
1422 === modified file 'storage/ndb/config/type_ndbapitest.mk.am'
1423 --- storage/ndb/config/type_ndbapitest.mk.am    2010-09-25 16:02:57.696670015 +0000
1424 +++ storage/ndb/config/type_ndbapitest.mk.am    2010-09-25 16:07:41.000002672 +0000
1425 @@ -13,19 +13,20 @@
1426  # along with this program; if not, write to the Free Software
1427  # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
1428  
1429 -LDADD += $(top_builddir)/storage/ndb/test/src/libNDBT.a \
1430 -         $(top_builddir)/storage/ndb/src/libndbclient.la \
1431 -         $(top_builddir)/dbug/libdbug.a \
1432 -         $(top_builddir)/mysys/libmysys.a \
1433 -         $(top_builddir)/strings/libmystrings.a @NDB_SCI_LIBS@
1434 +LDADD +=       $(top_builddir)/storage/ndb/test/src/libNDBT.a \
1435 +               $(top_builddir)/storage/ndb/src/libndbclient.la \
1436 +               $(top_builddir)/dbug/libdbug.la \
1437 +               $(top_builddir)/mysys/libmysys.la \
1438 +               $(top_builddir)/strings/libmystrings.la @NDB_SCI_LIBS@ \
1439 +               $(ZLIB_LIBS)
1440  
1441 -INCLUDES += -I$(top_srcdir) \
1442 -       -I$(top_builddir)/include \
1443 -       -I$(top_builddir)/storage/ndb/include \
1444 -       -I$(top_srcdir)/include \
1445 -       -I$(top_srcdir)/storage/ndb/include \
1446 -        -I$(top_srcdir)/storage/ndb/include/ndbapi \
1447 -        -I$(top_srcdir)/storage/ndb/include/util \
1448 -        -I$(top_srcdir)/storage/ndb/include/portlib \
1449 -        -I$(top_srcdir)/storage/ndb/test/include \
1450 -        -I$(top_srcdir)/storage/ndb/include/mgmapi
1451 +INCLUDES +=    -I$(top_srcdir) \
1452 +               -I$(top_builddir)/include \
1453 +               -I$(top_builddir)/storage/ndb/include \
1454 +               -I$(top_srcdir)/include \
1455 +               -I$(top_srcdir)/storage/ndb/include \
1456 +               -I$(top_srcdir)/storage/ndb/include/ndbapi \
1457 +               -I$(top_srcdir)/storage/ndb/include/util \
1458 +               -I$(top_srcdir)/storage/ndb/include/portlib \
1459 +               -I$(top_srcdir)/storage/ndb/test/include \
1460 +               -I$(top_srcdir)/storage/ndb/include/mgmapi
1461 === modified file 'storage/ndb/config/type_ndbapitools.mk.am'
1462 --- storage/ndb/config/type_ndbapitools.mk.am   2010-09-25 16:02:57.696670015 +0000
1463 +++ storage/ndb/config/type_ndbapitools.mk.am   2010-09-25 16:08:01.260003396 +0000
1464 @@ -13,20 +13,21 @@
1465  # along with this program; if not, write to the Free Software
1466  # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
1467  
1468 -LDADD += \
1469 -         $(top_builddir)/storage/ndb/src/libndbclient.la \
1470 -         $(top_builddir)/dbug/libdbug.a \
1471 -         $(top_builddir)/mysys/libmysys.a \
1472 -         $(top_builddir)/strings/libmystrings.a @NDB_SCI_LIBS@ @ZLIB_LIBS@
1473 +LDADD +=       \
1474 +               $(top_builddir)/storage/ndb/src/libndbclient.la \
1475 +               $(top_builddir)/dbug/libdbug.la \
1476 +               $(top_builddir)/mysys/libmysys.la \
1477 +               $(top_builddir)/strings/libmystrings.la @NDB_SCI_LIBS@ \
1478 +               $(ZLIB_LIBS)
1479  
1480 -INCLUDES += -I$(srcdir) \
1481 -       -I$(top_builddir)/include \
1482 -       -I$(top_builddir)/storage/ndb/include \
1483 -       -I$(top_srcdir)/include \
1484 -       -I$(top_srcdir)/storage/ndb/include \
1485 -        -I$(top_srcdir)/storage/ndb/include/ndbapi \
1486 -        -I$(top_srcdir)/storage/ndb/include/util \
1487 -        -I$(top_srcdir)/storage/ndb/include/portlib \
1488 -        -I$(top_srcdir)/storage/ndb/test/include \
1489 -        -I$(top_srcdir)/storage/ndb/include/mgmapi \
1490 -        -I$(top_srcdir)/storage/ndb/include/kernel
1491 +INCLUDES +=    -I$(srcdir) \
1492 +               -I$(top_builddir)/include \
1493 +               -I$(top_builddir)/storage/ndb/include \
1494 +               -I$(top_srcdir)/include \
1495 +               -I$(top_srcdir)/storage/ndb/include \
1496 +               -I$(top_srcdir)/storage/ndb/include/ndbapi \
1497 +               -I$(top_srcdir)/storage/ndb/include/util \
1498 +               -I$(top_srcdir)/storage/ndb/include/portlib \
1499 +               -I$(top_srcdir)/storage/ndb/test/include \
1500 +               -I$(top_srcdir)/storage/ndb/include/mgmapi \
1501 +               -I$(top_srcdir)/storage/ndb/include/kernel
1502 === modified file 'storage/ndb/config/win-libraries'
1503 --- storage/ndb/config/win-libraries    2010-09-25 16:02:57.696670015 +0000
1504 +++ storage/ndb/config/win-libraries    2010-09-25 16:05:27.550003650 +0000
1505 @@ -21,7 +21,7 @@
1506  # the same goes for mysys and strings
1507    lib=$i
1508    case $i in
1509 -  *libdbug.a | *libmysys.a | *libmystrings.a) 
1510 +  *libdbug.la | *libmysys.la | *libmystrings.la) 
1511    lib=`echo $i | sed s'!dbug\/lib!!' | sed 's!mysys\/lib!!' | sed 's!strings\/libmy!!'`
1512    echo "Changing from $i to $lib"
1513    ;;
1514 === modified file 'storage/ndb/src/cw/cpcd/Makefile.am'
1515 --- storage/ndb/src/cw/cpcd/Makefile.am 2007-02-13 01:38:54 +0000
1516 +++ storage/ndb/src/cw/cpcd/Makefile.am 2010-09-16 12:49:35 +0000
1517 @@ -19,9 +19,9 @@
1518  
1519  LDADD_LOC = \
1520              $(top_builddir)/storage/ndb/src/libndbclient.la      \
1521 -            $(top_builddir)/dbug/libdbug.a \
1522 -            $(top_builddir)/mysys/libmysys.a \
1523 -            $(top_builddir)/strings/libmystrings.a @NDB_SCI_LIBS@
1524 +            $(top_builddir)/dbug/libdbug.la \
1525 +            $(top_builddir)/mysys/libmysys.la \
1526 +            $(top_builddir)/strings/libmystrings.la @NDB_SCI_LIBS@
1527  
1528  include $(top_srcdir)/storage/ndb/config/common.mk.am
1529  include $(top_srcdir)/storage/ndb/config/type_util.mk.am
1530 === modified file 'storage/ndb/src/kernel/Makefile.am'
1531 --- storage/ndb/src/kernel/Makefile.am  2006-12-31 00:32:21 +0000
1532 +++ storage/ndb/src/kernel/Makefile.am  2010-09-16 12:49:35 +0000
1533 @@ -53,9 +53,10 @@
1534                $(top_builddir)/storage/ndb/src/mgmapi/libmgmapi.la \
1535                $(top_builddir)/storage/ndb/src/common/portlib/libportlib.la      \
1536                $(top_builddir)/storage/ndb/src/common/util/libgeneral.la  \
1537 -         $(top_builddir)/dbug/libdbug.a \
1538 -         $(top_builddir)/mysys/libmysys.a \
1539 -         $(top_builddir)/strings/libmystrings.a @NDB_SCI_LIBS@
1540 +               $(top_builddir)/dbug/libdbug.la \
1541 +               $(top_builddir)/mysys/libmysys.la \
1542 +               $(top_builddir)/strings/libmystrings.la @NDB_SCI_LIBS@ \
1543 +               $(ZLIB_LIBS)
1544  
1545  windoze-dsp: ndbd.dsp
1546  
1547 === modified file 'storage/ndb/src/kernel/blocks/Makefile.am'
1548 --- storage/ndb/src/kernel/blocks/Makefile.am   2006-12-31 00:32:21 +0000
1549 +++ storage/ndb/src/kernel/blocks/Makefile.am   2010-09-16 12:49:35 +0000
1550 @@ -18,7 +18,7 @@
1551         dbdih           \
1552         dblqh           \
1553         dbtup           \
1554 -        backup          
1555 +       backup          
1556  
1557  noinst_LIBRARIES = libblocks.a
1558  
1559 @@ -56,10 +56,10 @@
1560  EXTRA_PROGRAMS = ndb_print_file
1561  ndb_print_file_SOURCES = print_file.cpp diskpage.cpp dbtup/tuppage.cpp
1562  ndb_print_file_LDFLAGS = @ndb_bin_am_ldflags@ \
1563 -  $(top_builddir)/storage/ndb/src/libndbclient.la \
1564 -         $(top_builddir)/dbug/libdbug.a \
1565 -         $(top_builddir)/mysys/libmysys.a \
1566 -         $(top_builddir)/strings/libmystrings.a
1567 +               $(top_builddir)/storage/ndb/src/libndbclient.la \
1568 +               $(top_builddir)/dbug/libdbug.la \
1569 +               $(top_builddir)/mysys/libmysys.la \
1570 +               $(top_builddir)/strings/libmystrings.la
1571  
1572  include $(top_srcdir)/storage/ndb/config/common.mk.am
1573  include $(top_srcdir)/storage/ndb/config/type_kernel.mk.am
1574 === modified file 'storage/ndb/src/kernel/blocks/backup/Makefile.am'
1575 --- storage/ndb/src/kernel/blocks/backup/Makefile.am    2006-12-31 00:32:21 +0000
1576 +++ storage/ndb/src/kernel/blocks/backup/Makefile.am    2010-09-16 12:49:35 +0000
1577 @@ -17,9 +17,9 @@
1578  ndb_print_backup_file_SOURCES = read.cpp
1579  ndb_print_backup_file_LDFLAGS = @ndb_bin_am_ldflags@ \
1580    $(top_builddir)/storage/ndb/src/libndbclient.la \
1581 -         $(top_builddir)/mysys/libmysys.a \
1582 -         $(top_builddir)/dbug/libdbug.a \
1583 -         $(top_builddir)/strings/libmystrings.a
1584 +         $(top_builddir)/mysys/libmysys.la \
1585 +         $(top_builddir)/dbug/libdbug.la \
1586 +         $(top_builddir)/strings/libmystrings.la
1587  
1588  include $(top_srcdir)/storage/ndb/config/common.mk.am
1589  include $(top_srcdir)/storage/ndb/config/type_kernel.mk.am
1590
1591 === modified file 'storage/ndb/src/kernel/blocks/dbdict/Makefile.am'
1592 --- storage/ndb/src/kernel/blocks/dbdict/Makefile.am    2006-12-31 00:32:21 +0000
1593 +++ storage/ndb/src/kernel/blocks/dbdict/Makefile.am    2010-09-16 12:49:35 +0000
1594 @@ -19,17 +19,17 @@
1595  LDADD +=  \
1596           $(top_builddir)/storage/ndb/src/common/util/libgeneral.la \
1597           $(top_builddir)/storage/ndb/src/common/portlib/libportlib.la \
1598 -         $(top_builddir)/dbug/libdbug.a \
1599 -         $(top_builddir)/mysys/libmysys.a \
1600 -         $(top_builddir)/strings/libmystrings.a
1601 +         $(top_builddir)/dbug/libdbug.la \
1602 +         $(top_builddir)/mysys/libmysys.la \
1603 +         $(top_builddir)/strings/libmystrings.la
1604  
1605  ndbtools_PROGRAMS = ndb_print_schema_file
1606  ndb_print_schema_file_SOURCES = printSchemaFile.cpp
1607  ndb_print_schema_file_LDFLAGS = @ndb_bin_am_ldflags@ \
1608    $(top_builddir)/storage/ndb/src/libndbclient.la \
1609 -         $(top_builddir)/dbug/libdbug.a \
1610 -         $(top_builddir)/mysys/libmysys.a \
1611 -         $(top_builddir)/strings/libmystrings.a
1612 +         $(top_builddir)/dbug/libdbug.la \
1613 +         $(top_builddir)/mysys/libmysys.la \
1614 +         $(top_builddir)/strings/libmystrings.la
1615  
1616  # Don't update the files from bitkeeper
1617  %::SCCS/s.%
1618
1619 === modified file 'storage/ndb/src/kernel/blocks/dbdih/Makefile.am'
1620 --- storage/ndb/src/kernel/blocks/dbdih/Makefile.am     2006-12-31 00:32:21 +0000
1621 +++ storage/ndb/src/kernel/blocks/dbdih/Makefile.am     2010-09-16 12:49:35 +0000
1622 @@ -17,9 +17,9 @@
1623  ndb_print_sys_file_SOURCES = printSysfile.cpp
1624  ndb_print_sys_file_LDFLAGS = @ndb_bin_am_ldflags@ \
1625    $(top_builddir)/storage/ndb/src/libndbclient.la \
1626 -         $(top_builddir)/dbug/libdbug.a \
1627 -         $(top_builddir)/mysys/libmysys.a \
1628 -         $(top_builddir)/strings/libmystrings.a
1629 +         $(top_builddir)/dbug/libdbug.la \
1630 +         $(top_builddir)/mysys/libmysys.la \
1631 +         $(top_builddir)/strings/libmystrings.la
1632  
1633  
1634  include $(top_srcdir)/storage/ndb/config/common.mk.am
1635
1636 === modified file 'storage/ndb/src/kernel/blocks/dblqh/Makefile.am'
1637 --- storage/ndb/src/kernel/blocks/dblqh/Makefile.am     2007-05-29 21:39:57 +0000
1638 +++ storage/ndb/src/kernel/blocks/dblqh/Makefile.am     2010-09-16 12:49:35 +0000
1639 @@ -23,9 +23,9 @@
1640  
1641  ndbd_redo_log_reader_LDFLAGS = @ndb_bin_am_ldflags@ \
1642    $(top_builddir)/storage/ndb/src/libndbclient.la \
1643 -         $(top_builddir)/dbug/libdbug.a \
1644 -         $(top_builddir)/mysys/libmysys.a \
1645 -         $(top_builddir)/strings/libmystrings.a
1646 +         $(top_builddir)/dbug/libdbug.la \
1647 +         $(top_builddir)/mysys/libmysys.la \
1648 +         $(top_builddir)/strings/libmystrings.la
1649  
1650  # Don't update the files from bitkeeper
1651  %::SCCS/s.%
1652
1653 === modified file 'storage/ndb/src/kernel/blocks/dbtup/Makefile.am'
1654 --- storage/ndb/src/kernel/blocks/dbtup/Makefile.am     2006-12-31 00:32:21 +0000
1655 +++ storage/ndb/src/kernel/blocks/dbtup/Makefile.am     2010-09-16 12:49:35 +0000
1656 @@ -20,9 +20,9 @@
1657  test_varpage_SOURCES = test_varpage.cpp tuppage.cpp
1658  test_varpage_LDFLAGS = @ndb_bin_am_ldflags@ \
1659    $(top_builddir)/storage/ndb/src/libndbclient.la \
1660 -  $(top_builddir)/mysys/libmysys.a \
1661 -  $(top_builddir)/dbug/libdbug.a \
1662 -  $(top_builddir)/strings/libmystrings.a
1663 +  $(top_builddir)/mysys/libmysys.la \
1664 +  $(top_builddir)/dbug/libdbug.la \
1665 +  $(top_builddir)/strings/libmystrings.la
1666  
1667  # Don't update the files from bitkeeper
1668  %::SCCS/s.%
1669
1670 === modified file 'storage/ndb/src/kernel/vm/Makefile.am'
1671 --- storage/ndb/src/kernel/vm/Makefile.am       2006-12-31 00:32:21 +0000
1672 +++ storage/ndb/src/kernel/vm/Makefile.am       2010-09-16 12:49:35 +0000
1673 @@ -21,22 +21,22 @@
1674  noinst_LIBRARIES = libkernel.a
1675  
1676  libkernel_a_SOURCES = \
1677 -       SimulatedBlock.cpp      \
1678 -       FastScheduler.cpp               \
1679 -       TimeQueue.cpp           \
1680 -       VMSignal.cpp            \
1681 -       ThreadConfig.cpp          \
1682 -       TransporterCallback.cpp \
1683 -       Emulator.cpp            \
1684 -       Configuration.cpp               \
1685 -       WatchDog.cpp \
1686 -        SimplePropertiesSection.cpp \
1687 -        SectionReader.cpp \
1688 -        Mutex.cpp SafeCounter.cpp \
1689 -        Rope.cpp \
1690 -       ndbd_malloc.cpp ndbd_malloc_impl.cpp \
1691 -        Pool.cpp WOPool.cpp RWPool.cpp \
1692 -        DynArr256.cpp
1693 +               SimulatedBlock.cpp \
1694 +               FastScheduler.cpp \
1695 +               TimeQueue.cpp \
1696 +               VMSignal.cpp \
1697 +               ThreadConfig.cpp \
1698 +               TransporterCallback.cpp \
1699 +               Emulator.cpp \
1700 +               Configuration.cpp \
1701 +               WatchDog.cpp \
1702 +               SimplePropertiesSection.cpp \
1703 +               SectionReader.cpp \
1704 +               Mutex.cpp SafeCounter.cpp \
1705 +               Rope.cpp \
1706 +               ndbd_malloc.cpp ndbd_malloc_impl.cpp \
1707 +               Pool.cpp WOPool.cpp RWPool.cpp \
1708 +               DynArr256.cpp
1709  
1710  INCLUDES_LOC = -I$(top_srcdir)/storage/ndb/src/mgmapi
1711  
1712 @@ -49,40 +49,40 @@
1713  windoze-dsp: libkernel.dsp
1714  
1715  libkernel.dsp: Makefile \
1716 -               $(top_srcdir)/storage/ndb/config/win-lib.am \
1717 -               $(top_srcdir)/storage/ndb/config/win-name \
1718 -               $(top_srcdir)/storage/ndb/config/win-includes \
1719 -               $(top_srcdir)/storage/ndb/config/win-sources \
1720 -               $(top_srcdir)/storage/ndb/config/win-libraries
1721 -       cat $(top_srcdir)/storage/ndb/config/win-lib.am > $@
1722 -       @$(top_srcdir)/storage/ndb/config/win-name $@ $(noinst_LIBRARIES)
1723 -       @$(top_srcdir)/storage/ndb/config/win-includes $@ $(INCLUDES)
1724 -       @$(top_srcdir)/storage/ndb/config/win-sources $@ $(libkernel_a_SOURCES)
1725 -       @$(top_srcdir)/storage/ndb/config/win-libraries $@ LIB $(LDADD)
1726 +               $(top_srcdir)/storage/ndb/config/win-lib.am \
1727 +               $(top_srcdir)/storage/ndb/config/win-name \
1728 +               $(top_srcdir)/storage/ndb/config/win-includes \
1729 +               $(top_srcdir)/storage/ndb/config/win-sources \
1730 +               $(top_srcdir)/storage/ndb/config/win-libraries
1731 +               cat $(top_srcdir)/storage/ndb/config/win-lib.am > $@
1732 +               @$(top_srcdir)/storage/ndb/config/win-name $@ $(noinst_LIBRARIES)
1733 +               @$(top_srcdir)/storage/ndb/config/win-includes $@ $(INCLUDES)
1734 +               @$(top_srcdir)/storage/ndb/config/win-sources $@ $(libkernel_a_SOURCES)
1735 +               @$(top_srcdir)/storage/ndb/config/win-libraries $@ LIB $(LDADD)
1736  
1737  EXTRA_PROGRAMS = ndbd_malloc_impl_test bench_pool testDynArr256
1738  ndbd_malloc_impl_test_CXXFLAGS = -DUNIT_TEST
1739  ndbd_malloc_impl_test_SOURCES = ndbd_malloc_impl.cpp
1740  ndbd_malloc_impl_test_LDFLAGS = @ndb_bin_am_ldflags@ \
1741 -  $(top_builddir)/storage/ndb/src/libndbclient.la \
1742 -  $(top_builddir)/mysys/libmysys.a \
1743 -  $(top_builddir)/dbug/libdbug.a \
1744 -  $(top_builddir)/strings/libmystrings.a
1745 +               $(top_builddir)/storage/ndb/src/libndbclient.la \
1746 +               $(top_builddir)/mysys/libmysys.la \
1747 +               $(top_builddir)/dbug/libdbug.la \
1748 +               $(top_builddir)/strings/libmystrings.la
1749  
1750  bench_pool_SOURCES = bench_pool.cpp
1751 -bench_pool_LDFLAGS = @ndb_bin_am_ldflags@\
1752 -  libkernel.a ../error/liberror.a \
1753 -  $(top_builddir)/storage/ndb/src/libndbclient.la \
1754 -  $(top_builddir)/mysys/libmysys.a \
1755 -  $(top_builddir)/dbug/libdbug.a \
1756 -  $(top_builddir)/strings/libmystrings.a
1757 +bench_pool_LDFLAGS = @ndb_bin_am_ldflags@ \
1758 +               libkernel.a ../error/liberror.a \
1759 +               $(top_builddir)/storage/ndb/src/libndbclient.la \
1760 +               $(top_builddir)/mysys/libmysys.la \
1761 +               $(top_builddir)/dbug/libdbug.la \
1762 +               $(top_builddir)/strings/libmystrings.la
1763  
1764  testDynArr256_CXXFLAGS = -DUNIT_TEST
1765  testDynArr256_SOURCES = DynArr256.cpp
1766  testDynArr256_LDFLAGS = @ndb_bin_am_ldflags@ \
1767 -  libkernel.a ../error/liberror.a \
1768 -  $(top_builddir)/storage/ndb/src/libndbclient.la \
1769 -  $(top_builddir)/mysys/libmysys.a \
1770 -  $(top_builddir)/dbug/libdbug.a \
1771 -  $(top_builddir)/strings/libmystrings.a
1772 +               libkernel.a ../error/liberror.a \
1773 +               $(top_builddir)/storage/ndb/src/libndbclient.la \
1774 +               $(top_builddir)/mysys/libmysys.la \
1775 +               $(top_builddir)/dbug/libdbug.la \
1776 +               $(top_builddir)/strings/libmystrings.la
1777  
1778 === modified file 'storage/ndb/src/mgmclient/Makefile.am'
1779 --- storage/ndb/src/mgmclient/Makefile.am       2007-08-01 07:24:01 +0000
1780 +++ storage/ndb/src/mgmclient/Makefile.am       2010-09-16 12:49:35 +0000
1781 @@ -18,12 +18,11 @@
1782  
1783  libndbmgmclient_la_SOURCES = CommandInterpreter.cpp
1784  libndbmgmclient_la_LIBADD = ../mgmapi/libmgmapi.la \
1785 -                           ../common/logger/liblogger.la \
1786 -                           ../common/portlib/libportlib.la \
1787 -                           ../common/util/libgeneral.la \
1788 -                           ../common/portlib/libportlib.la \
1789 -                           ../common/debugger/libtrace.la
1790 -
1791 +               ../common/logger/liblogger.la \
1792 +               ../common/portlib/libportlib.la \
1793 +               ../common/util/libgeneral.la \
1794 +               ../common/portlib/libportlib.la \
1795 +               ../common/debugger/libtrace.la
1796  
1797  ndb_mgm_SOURCES = main.cpp
1798  
1799 @@ -34,13 +33,13 @@
1800              -I$(top_srcdir)/storage/ndb/src/common/mgmcommon
1801  
1802  LDADD_LOC = $(noinst_LTLIBRARIES) \
1803 -           ../common/portlib/libportlib.la \
1804 -            @readline_link@ \
1805 -            $(top_builddir)/storage/ndb/src/libndbclient.la \
1806 -            $(top_builddir)/dbug/libdbug.a \
1807 -            $(top_builddir)/mysys/libmysys.a \
1808 -            $(top_builddir)/strings/libmystrings.a \
1809 -            @TERMCAP_LIB@ @NDB_SCI_LIBS@
1810 +               ../common/portlib/libportlib.la \
1811 +               @readline_link@ \
1812 +               $(top_builddir)/storage/ndb/src/libndbclient.la \
1813 +               $(top_builddir)/dbug/libdbug.la \
1814 +               $(top_builddir)/mysys/libmysys.la \
1815 +               $(top_builddir)/strings/libmystrings.la \
1816 +               @TERMCAP_LIB@ @NDB_SCI_LIBS@
1817  
1818  ndb_mgm_LDFLAGS = @ndb_bin_am_ldflags@
1819  
1820 @@ -50,25 +49,25 @@
1821  windoze-dsp: ndb_mgm.dsp libndbmgmclient.dsp
1822  
1823  ndb_mgm.dsp: Makefile \
1824 -               $(top_srcdir)/storage/ndb/config/win-prg.am \
1825 -               $(top_srcdir)/storage/ndb/config/win-name \
1826 -               $(top_srcdir)/storage/ndb/config/win-includes \
1827 -               $(top_srcdir)/storage/ndb/config/win-sources \
1828 -               $(top_srcdir)/storage/ndb/config/win-libraries
1829 -       cat $(top_srcdir)/storage/ndb/config/win-prg.am > $@
1830 -       @$(top_srcdir)/storage/ndb/config/win-name $@ $(ndbtools_PROGRAMS)
1831 -       @$(top_srcdir)/storage/ndb/config/win-includes $@ $(INCLUDES)
1832 -       @$(top_srcdir)/storage/ndb/config/win-sources $@ $(ndb_mgm_SOURCES)
1833 -       @$(top_srcdir)/storage/ndb/config/win-libraries $@ LINK $(LDADD)
1834 +               $(top_srcdir)/storage/ndb/config/win-prg.am \
1835 +               $(top_srcdir)/storage/ndb/config/win-name \
1836 +               $(top_srcdir)/storage/ndb/config/win-includes \
1837 +               $(top_srcdir)/storage/ndb/config/win-sources \
1838 +               $(top_srcdir)/storage/ndb/config/win-libraries
1839 +               cat $(top_srcdir)/storage/ndb/config/win-prg.am > $@
1840 +               @$(top_srcdir)/storage/ndb/config/win-name $@ $(ndbtools_PROGRAMS)
1841 +               @$(top_srcdir)/storage/ndb/config/win-includes $@ $(INCLUDES)
1842 +               @$(top_srcdir)/storage/ndb/config/win-sources $@ $(ndb_mgm_SOURCES)
1843 +               @$(top_srcdir)/storage/ndb/config/win-libraries $@ LINK $(LDADD)
1844  
1845  libndbmgmclient.dsp: Makefile \
1846 -               $(top_srcdir)/storage/ndb/config/win-lib.am \
1847 -               $(top_srcdir)/storage/ndb/config/win-name \
1848 -               $(top_srcdir)/storage/ndb/config/win-includes \
1849 -               $(top_srcdir)/storage/ndb/config/win-sources \
1850 -               $(top_srcdir)/storage/ndb/config/win-libraries
1851 -       cat $(top_srcdir)/storage/ndb/config/win-lib.am > $@
1852 -       @$(top_srcdir)/storage/ndb/config/win-name $@ $(noinst_LTLIBRARIES)
1853 -       @$(top_srcdir)/storage/ndb/config/win-includes $@ $(INCLUDES)
1854 -       @$(top_srcdir)/storage/ndb/config/win-sources $@ $(libndbmgmclient_la_SOURCES)
1855 -       @$(top_srcdir)/storage/ndb/config/win-libraries $@ LIB
1856 +               $(top_srcdir)/storage/ndb/config/win-lib.am \
1857 +               $(top_srcdir)/storage/ndb/config/win-name \
1858 +               $(top_srcdir)/storage/ndb/config/win-includes \
1859 +               $(top_srcdir)/storage/ndb/config/win-sources \
1860 +               $(top_srcdir)/storage/ndb/config/win-libraries
1861 +               cat $(top_srcdir)/storage/ndb/config/win-lib.am > $@
1862 +               @$(top_srcdir)/storage/ndb/config/win-name $@ $(noinst_LTLIBRARIES)
1863 +               @$(top_srcdir)/storage/ndb/config/win-includes $@ $(INCLUDES)
1864 +               @$(top_srcdir)/storage/ndb/config/win-sources $@ $(libndbmgmclient_la_SOURCES)
1865 +               @$(top_srcdir)/storage/ndb/config/win-libraries $@ LIB
1866 === modified file 'storage/ndb/src/mgmsrv/Makefile.am'
1867 --- storage/ndb/src/mgmsrv/Makefile.am  2009-07-31 19:28:15 +0000
1868 +++ storage/ndb/src/mgmsrv/Makefile.am  2010-09-16 12:49:35 +0000
1869 @@ -22,35 +22,35 @@
1870  ndbbin_PROGRAMS = ndb_mgmd
1871  
1872  ndb_mgmd_SOURCES = \
1873 -       MgmtSrvr.cpp \
1874 -       MgmtSrvrGeneralSignalHandling.cpp \
1875 -       main.cpp \
1876 -       Services.cpp \
1877 -       convertStrToInt.cpp \
1878 -       SignalQueue.cpp \
1879 -       MgmtSrvrConfig.cpp \
1880 -       ConfigInfo.cpp \
1881 -       InitConfigFileParser.cpp \
1882 -       Config.cpp
1883 +               MgmtSrvr.cpp \
1884 +               MgmtSrvrGeneralSignalHandling.cpp \
1885 +               main.cpp \
1886 +               Services.cpp \
1887 +               convertStrToInt.cpp \
1888 +               SignalQueue.cpp \
1889 +               MgmtSrvrConfig.cpp \
1890 +               ConfigInfo.cpp \
1891 +               InitConfigFileParser.cpp \
1892 +               Config.cpp
1893  
1894  INCLUDES_LOC = -I$(top_srcdir)/storage/ndb/src/ndbapi \
1895 -               -I$(top_srcdir)/storage/ndb/src/mgmapi \
1896 -               -I$(top_srcdir)/storage/ndb/src/common/mgmcommon \
1897 -               -I$(top_srcdir)/storage/ndb/src/mgmclient
1898 +               -I$(top_srcdir)/storage/ndb/src/mgmapi \
1899 +               -I$(top_srcdir)/storage/ndb/src/common/mgmcommon \
1900 +               -I$(top_srcdir)/storage/ndb/src/mgmclient
1901  
1902  LDADD_LOC = $(top_builddir)/storage/ndb/src/mgmclient/CommandInterpreter.lo \
1903 -            $(top_builddir)/storage/ndb/src/libndbclient.la \
1904 -            $(top_builddir)/dbug/libdbug.a \
1905 -            $(top_builddir)/mysys/libmysys.a \
1906 -            $(top_builddir)/strings/libmystrings.a \
1907 -            @readline_link@ \
1908 -            @NDB_SCI_LIBS@ \
1909 -           @TERMCAP_LIB@
1910 -
1911 -DEFS_LOC =             -DDEFAULT_MYSQL_HOME="\"$(MYSQLBASEdir)\"" \
1912 -                       -DMYSQL_DATADIR="\"$(MYSQLDATAdir)\"" \
1913 -                       -DSHAREDIR="\"$(MYSQLSHAREdir)\"" \
1914 -                       -DMYSQLCLUSTERDIR="\"$(MYSQLCLUSTERdir)\""
1915 +               $(top_builddir)/storage/ndb/src/libndbclient.la \
1916 +               $(top_builddir)/dbug/libdbug.la \
1917 +               $(top_builddir)/mysys/libmysys.la \
1918 +               $(top_builddir)/strings/libmystrings.la \
1919 +               @readline_link@ \
1920 +               @NDB_SCI_LIBS@ \
1921 +               @TERMCAP_LIB@
1922 +
1923 +DEFS_LOC =     -DDEFAULT_MYSQL_HOME="\"$(MYSQLBASEdir)\"" \
1924 +               -DMYSQL_DATADIR="\"$(MYSQLDATAdir)\"" \
1925 +               -DSHAREDIR="\"$(MYSQLSHAREdir)\"" \
1926 +               -DMYSQLCLUSTERDIR="\"$(MYSQLCLUSTERdir)\""
1927  
1928  include $(top_srcdir)/storage/ndb/config/common.mk.am
1929  include $(top_srcdir)/storage/ndb/config/type_ndbapi.mk.am
1930 @@ -63,13 +63,13 @@
1931  windoze-dsp: ndb_mgmd.dsp
1932  
1933  ndb_mgmd.dsp: Makefile \
1934 -               $(top_srcdir)/storage/ndb/config/win-prg.am \
1935 -               $(top_srcdir)/storage/ndb/config/win-name \
1936 -               $(top_srcdir)/storage/ndb/config/win-includes \
1937 -               $(top_srcdir)/storage/ndb/config/win-sources \
1938 -               $(top_srcdir)/storage/ndb/config/win-libraries
1939 -       cat $(top_srcdir)/storage/ndb/config/win-prg.am > $@
1940 -       @$(top_srcdir)/storage/ndb/config/win-name $@ $(ndbbin_PROGRAMS)
1941 -       @$(top_srcdir)/storage/ndb/config/win-includes $@ $(INCLUDES)
1942 -       @$(top_srcdir)/storage/ndb/config/win-sources $@ $(ndb_mgmd_SOURCES)
1943 -       @$(top_srcdir)/storage/ndb/config/win-libraries $@ LINK $(LDADD)
1944 +               $(top_srcdir)/storage/ndb/config/win-prg.am \
1945 +               $(top_srcdir)/storage/ndb/config/win-name \
1946 +               $(top_srcdir)/storage/ndb/config/win-includes \
1947 +               $(top_srcdir)/storage/ndb/config/win-sources \
1948 +               $(top_srcdir)/storage/ndb/config/win-libraries
1949 +               cat $(top_srcdir)/storage/ndb/config/win-prg.am > $@
1950 +               @$(top_srcdir)/storage/ndb/config/win-name $@ $(ndbbin_PROGRAMS)
1951 +               @$(top_srcdir)/storage/ndb/config/win-includes $@ $(INCLUDES)
1952 +               @$(top_srcdir)/storage/ndb/config/win-sources $@ $(ndb_mgmd_SOURCES)
1953 +               @$(top_srcdir)/storage/ndb/config/win-libraries $@ LINK $(LDADD)
1954 === modified file 'storage/ndb/src/ndbapi/Makefile.am'
1955 --- storage/ndb/src/ndbapi/Makefile.am  2007-04-11 13:51:09 +0000
1956 +++ storage/ndb/src/ndbapi/Makefile.am  2010-09-16 12:49:35 +0000
1957 @@ -22,41 +22,42 @@
1958  noinst_LTLIBRARIES = libndbapi.la
1959  
1960  libndbapi_la_SOURCES = \
1961 -        TransporterFacade.cpp   \
1962 -        ClusterMgr.cpp  \
1963 -        Ndb.cpp \
1964 -        NdbPoolImpl.cpp \
1965 -        NdbPool.cpp \
1966 -        Ndblist.cpp     \
1967 -        Ndbif.cpp       \
1968 -        Ndbinit.cpp     \
1969 -        Ndberr.cpp    \
1970 -        ndberror.c    \
1971 -        NdbErrorOut.cpp    \
1972 -        NdbTransaction.cpp       \
1973 -        NdbTransactionScan.cpp \
1974 -        NdbOperation.cpp        \
1975 -        NdbOperationSearch.cpp  \
1976 -        NdbOperationScan.cpp    \
1977 -        NdbOperationInt.cpp     \
1978 -        NdbOperationDefine.cpp  \
1979 -        NdbOperationExec.cpp    \
1980 -        NdbScanOperation.cpp    NdbScanFilter.cpp \
1981 -        NdbIndexOperation.cpp   \
1982 -        NdbEventOperation.cpp   \
1983 -        NdbEventOperationImpl.cpp   \
1984 -        NdbApiSignal.cpp        \
1985 -        NdbRecAttr.cpp  \
1986 -        NdbUtil.cpp \
1987 -        NdbReceiver.cpp \
1988 -        NdbDictionary.cpp \
1989 -        NdbDictionaryImpl.cpp \
1990 -        DictCache.cpp \
1991 -        ndb_cluster_connection.cpp \
1992 -       NdbBlob.cpp \
1993 -       NdbIndexStat.cpp \
1994 -        SignalSender.cpp \
1995 -        ObjectMap.cpp
1996 +               TransporterFacade.cpp \
1997 +               ClusterMgr.cpp \
1998 +               Ndb.cpp \
1999 +               NdbPoolImpl.cpp \
2000 +               NdbPool.cpp \
2001 +               Ndblist.cpp \
2002 +               Ndbif.cpp \
2003 +               Ndbinit.cpp \
2004 +               Ndberr.cpp \
2005 +               ndberror.c \
2006 +               NdbErrorOut.cpp \
2007 +               NdbTransaction.cpp \
2008 +               NdbTransactionScan.cpp \
2009 +               NdbOperation.cpp \
2010 +               NdbOperationSearch.cpp \
2011 +               NdbOperationScan.cpp \
2012 +               NdbOperationInt.cpp \
2013 +               NdbOperationDefine.cpp \
2014 +               NdbOperationExec.cpp \
2015 +               NdbScanOperation.cpp \
2016 +               NdbScanFilter.cpp \
2017 +               NdbIndexOperation.cpp \
2018 +               NdbEventOperation.cpp \
2019 +               NdbEventOperationImpl.cpp \
2020 +               NdbApiSignal.cpp \
2021 +               NdbRecAttr.cpp \
2022 +               NdbUtil.cpp \
2023 +               NdbReceiver.cpp \
2024 +               NdbDictionary.cpp \
2025 +               NdbDictionaryImpl.cpp \
2026 +               DictCache.cpp \
2027 +               ndb_cluster_connection.cpp \
2028 +               NdbBlob.cpp \
2029 +               NdbIndexStat.cpp \
2030 +               SignalSender.cpp \
2031 +               ObjectMap.cpp
2032  
2033  INCLUDES_LOC = -I$(top_srcdir)/storage/ndb/src/mgmapi
2034  
2035 @@ -67,9 +68,10 @@
2036  include $(top_srcdir)/storage/ndb/config/type_ndbapi.mk.am
2037  
2038  ndberror_check_LDFLAGS = \
2039 -         $(top_builddir)/dbug/libdbug.a \
2040 -         $(top_builddir)/mysys/libmysys.a \
2041 -         $(top_builddir)/strings/libmystrings.a
2042 +               $(top_builddir)/dbug/libdbug.la \
2043 +               $(top_builddir)/mysys/libmysys.la \
2044 +               $(top_builddir)/strings/libmystrings.la \
2045 +               $(ZLIB_LIBS)
2046  
2047  # Don't update the files from bitkeeper
2048  %::SCCS/s.%
2049 @@ -77,13 +79,13 @@
2050  windoze-dsp: libndbapi.dsp
2051  
2052  libndbapi.dsp: Makefile \
2053 -               $(top_srcdir)/storage/ndb/config/win-lib.am \
2054 -               $(top_srcdir)/storage/ndb/config/win-name \
2055 -               $(top_srcdir)/storage/ndb/config/win-includes \
2056 -               $(top_srcdir)/storage/ndb/config/win-sources \
2057 -               $(top_srcdir)/storage/ndb/config/win-libraries
2058 -       cat $(top_srcdir)/storage/ndb/config/win-lib.am > $@
2059 -       @$(top_srcdir)/storage/ndb/config/win-name $@ $(noinst_LTLIBRARIES)
2060 -       @$(top_srcdir)/storage/ndb/config/win-includes $@ $(INCLUDES)
2061 -       @$(top_srcdir)/storage/ndb/config/win-sources $@ $(libndbapi_la_SOURCES)
2062 -       @$(top_srcdir)/storage/ndb/config/win-libraries $@ LIB $(LDADD)
2063 +               $(top_srcdir)/storage/ndb/config/win-lib.am \
2064 +               $(top_srcdir)/storage/ndb/config/win-name \
2065 +               $(top_srcdir)/storage/ndb/config/win-includes \
2066 +               $(top_srcdir)/storage/ndb/config/win-sources \
2067 +               $(top_srcdir)/storage/ndb/config/win-libraries
2068 +               cat $(top_srcdir)/storage/ndb/config/win-lib.am > $@
2069 +               @$(top_srcdir)/storage/ndb/config/win-name $@ $(noinst_LTLIBRARIES)
2070 +               @$(top_srcdir)/storage/ndb/config/win-includes $@ $(INCLUDES)
2071 +               @$(top_srcdir)/storage/ndb/config/win-sources $@ $(libndbapi_la_SOURCES)
2072 +               @$(top_srcdir)/storage/ndb/config/win-libraries $@ LIB $(LDADD)
2073 === modified file 'storage/ndb/test/run-test/Makefile.am'
2074 --- storage/ndb/test/run-test/Makefile.am       2009-10-13 18:21:42 +0000
2075 +++ storage/ndb/test/run-test/Makefile.am       2010-09-16 12:49:35 +0000
2076 @@ -34,9 +34,9 @@
2077  INCLUDES_LOC = -I$(top_srcdir)/storage/ndb/test/include
2078  LDADD_LOC = $(top_builddir)/storage/ndb/test/src/libNDBT.a \
2079             $(top_builddir)/storage/ndb/src/libndbclient.la \
2080 -            $(top_builddir)/dbug/libdbug.a \
2081 -            $(top_builddir)/mysys/libmysys.a \
2082 -            $(top_builddir)/strings/libmystrings.a @NDB_SCI_LIBS@
2083 +            $(top_builddir)/dbug/libdbug.la \
2084 +            $(top_builddir)/mysys/libmysys.la \
2085 +            $(top_builddir)/strings/libmystrings.la @NDB_SCI_LIBS@
2086  
2087  atrt_CXXFLAGS = -I$(top_srcdir)/ndb/src/mgmapi \
2088                        -I$(top_srcdir)/ndb/src/mgmsrv \
2089
2090 === modified file 'strings/Makefile.am'
2091 --- strings/Makefile.am 2010-08-27 14:12:44 +0000
2092 +++ strings/Makefile.am 2010-09-16 12:49:35 +0000
2093 @@ -16,7 +16,7 @@
2094  # This file is public domain and comes with NO WARRANTY of any kind
2095  
2096  INCLUDES =             -I$(top_builddir)/include -I$(top_srcdir)/include
2097 -pkglib_LIBRARIES =     libmystrings.a
2098 +pkglib_LTLIBRARIES =   libmystrings.la
2099  
2100  # Exact one of ASSEMBLER_X
2101  if ASSEMBLER_x86
2102 @@ -37,7 +37,7 @@
2103  endif
2104  endif
2105  
2106 -libmystrings_a_SOURCES = $(ASRCS) $(CSRCS)
2107 +libmystrings_la_SOURCES = $(ASRCS) $(CSRCS)
2108  noinst_PROGRAMS = conf_to_src
2109  CLEANFILES = str_test uctypedump test_decimal
2110  # Default charset definitions
2111 @@ -56,9 +56,9 @@
2112                         t_ctype.h my_strchr.c CMakeLists.txt \
2113                         CHARSET_INFO.txt
2114  
2115 -libmystrings_a_LIBADD=
2116 -conf_to_src_SOURCES = conf_to_src.c xml.c ctype.c
2117 -conf_to_src_LDADD=
2118 +libmystrings_la_LIBADD=
2119 +conf_to_src_SOURCES = conf_to_src.c
2120 +conf_to_src_LDADD =    libmystrings.la
2121  #force static linking of conf_to_src - essential when linking against
2122  #custom installation of libc
2123  conf_to_src_LDFLAGS= @NOINST_LDFLAGS@
2124 @@ -69,15 +69,15 @@
2125  
2126  FLAGS=$(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) @NOINST_LDFLAGS@
2127  
2128 -str_test: str_test.c $(pkglib_LIBRARIES)
2129 -       $(LINK) $(FLAGS) -DMAIN $(INCLUDES) $(srcdir)/str_test.c $(LDADD) $(pkglib_LIBRARIES)
2130 +str_test: str_test.c $(pkglib_LTLIBRARIES)
2131 +       $(LINK) $(FLAGS) -DMAIN $(INCLUDES) $(srcdir)/str_test.c $(LDADD) $(pkglib_LTLIBRARIES)
2132  
2133  uctypedump: uctypedump.c
2134         $(LINK) $(INCLUDES) $(srcdir)/uctypedump.c
2135  
2136  test_decimal$(EXEEXT): decimal.c $(pkglib_LIBRARIES)
2137         $(CP) $(srcdir)/decimal.c ./test_decimal.c
2138 -       $(LINK) $(FLAGS) -DMAIN  ./test_decimal.c $(LDADD) $(pkglib_LIBRARIES)
2139 +       $(LINK) $(FLAGS) -DMAIN  ./test_decimal.c $(LDADD) $(pkglib_LTLIBRARIES)
2140         $(RM) -f ./test_decimal.c
2141  
2142  # Don't update the files from bitkeeper
2143 === modified file 'unittest/unit.pl'
2144 --- unittest/unit.pl    2010-08-27 14:12:44 +0000
2145 +++ unittest/unit.pl    2010-09-16 12:49:35 +0000
2146 @@ -55,7 +55,7 @@
2147      my @dirs = @_;
2148      my @files;
2149      find sub { 
2150 -        $File::Find::prune = 1 if /^SCCS$/;
2151 +        $File::Find::prune = 1 if /^(SCCS|\.libs)$/;
2152          push(@files, $File::Find::name) if -x _ && /-t\z/;
2153      }, @dirs;
2154      return @files;
2155 === modified file 'unittest/mysys/Makefile.am'
2156 --- unittest/mysys/Makefile.am  2010-08-27 14:12:44 +0000
2157 +++ unittest/mysys/Makefile.am  2010-09-16 12:49:35 +0000
2158 @@ -13,15 +13,16 @@
2159  # along with this program; if not, write to the Free Software
2160  # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
2161  
2162 -AM_CPPFLAGS      = @ZLIB_INCLUDES@ -I$(top_builddir)/include 
2163 -AM_CPPFLAGS     += -I$(top_srcdir)/include -I$(top_srcdir)/unittest/mytap
2164 +AM_CPPFLAGS =  @ZLIB_INCLUDES@ -I$(top_builddir)/include 
2165 +AM_CPPFLAGS += -I$(top_srcdir)/include -I$(top_srcdir)/unittest/mytap
2166  
2167 -LDADD          = $(top_builddir)/unittest/mytap/libmytap.a \
2168 -                 $(top_builddir)/mysys/libmysys.a \
2169 -                 $(top_builddir)/dbug/libdbug.a \
2170 -                 $(top_builddir)/strings/libmystrings.a
2171 +LDADD =        $(top_builddir)/unittest/mytap/libmytap.a \
2172 +               $(top_builddir)/mysys/libmysys.la \
2173 +               $(top_builddir)/dbug/libdbug.la \
2174 +               $(top_builddir)/strings/libmystrings.la \
2175 +               $(ZLIB_LIBS)
2176  
2177 -noinst_PROGRAMS  = bitmap-t base64-t
2178 +noinst_PROGRAMS =      bitmap-t base64-t
2179  
2180  # Don't update the files from bitkeeper
2181  %::SCCS/s.%
2182 === modified file 'unittest/strings/Makefile.am'
2183 --- unittest/strings/Makefile.am        2010-07-26 05:06:18 +0000
2184 +++ unittest/strings/Makefile.am        2010-09-16 12:49:35 +0000
2185 @@ -16,10 +16,11 @@
2186  AM_CPPFLAGS      = @ZLIB_INCLUDES@ -I$(top_builddir)/include 
2187  AM_CPPFLAGS     += -I$(top_srcdir)/include -I$(top_srcdir)/unittest/mytap
2188  
2189 -LDADD          = $(top_builddir)/unittest/mytap/libmytap.a \
2190 -                 $(top_builddir)/mysys/libmysys.a \
2191 -                 $(top_builddir)/dbug/libdbug.a \
2192 -                 $(top_builddir)/strings/libmystrings.a
2193 +LDADD          = $(top_builddir)/unittest/mytap/libmytap.a \
2194 +                       $(top_builddir)/mysys/libmysys.la \
2195 +                       $(top_builddir)/dbug/libdbug.la \
2196 +                       $(top_builddir)/strings/libmystrings.la \
2197 +                       $(ZLIB_LIBS)
2198  
2199  noinst_PROGRAMS  = strings-t
2200  
2201 === modified file 'vio/Makefile.am'
2202 --- vio/Makefile.am     2010-08-27 14:12:44 +0000
2203 +++ vio/Makefile.am     2010-09-16 12:49:35 +0000
2204 @@ -16,11 +16,11 @@
2205  INCLUDES =             -I$(top_builddir)/include -I$(top_srcdir)/include \
2206                         $(openssl_includes)
2207  LDADD =                        @CLIENT_EXTRA_LDFLAGS@ $(openssl_libs) $(yassl_libs)
2208 -pkglib_LIBRARIES =     libvio.a
2209 +pkglib_LTLIBRARIES =   libvio.la
2210  
2211  noinst_HEADERS =       vio_priv.h
2212  
2213 -libvio_a_SOURCES =     vio.c viosocket.c viossl.c viosslfactories.c
2214 +libvio_la_SOURCES =    vio.c viosocket.c viossl.c viosslfactories.c
2215  
2216  EXTRA_DIST=            CMakeLists.txt
2217