MySQL Lists are EOL. Please join:

List:Commits« Previous MessageNext Message »
From:Monty Taylor Date:June 18 2008 7:43pm
Subject:bzr commit into mysql-5.1-telco-6.2 branch (monty:2631) Bug#37491
View as plain text  
#At http://bazaar.launchpad.net/~mordred/mysql-server/mysql-5.1-telco-6.2

 2631 Monty Taylor	2008-06-18
      Bug#37491 ndbapi-examples build broken by the new library changes
      
      Put all of ndbapi-examples under automake control. Made the linking
      work appropriately. For now these will all build as part of the normal 
      build but will not install anywhere.
renamed:
  storage/ndb/ndbapi-examples/Makefile => storage/ndb/ndbapi-examples/Makefile.am
  storage/ndb/ndbapi-examples/mgmapi_logevent/Makefile => storage/ndb/ndbapi-examples/mgmapi_logevent/Makefile.am
  storage/ndb/ndbapi-examples/mgmapi_logevent2/Makefile => storage/ndb/ndbapi-examples/mgmapi_logevent2/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_async/Makefile => storage/ndb/ndbapi-examples/ndbapi_async/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_async1/Makefile => storage/ndb/ndbapi-examples/ndbapi_async1/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_blob/Makefile => storage/ndb/ndbapi-examples/ndbapi_blob/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_blob_ndbrecord/Makefile => storage/ndb/ndbapi-examples/ndbapi_blob_ndbrecord/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_event/Makefile => storage/ndb/ndbapi-examples/ndbapi_event/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_recattr_vs_record/Makefile => storage/ndb/ndbapi-examples/ndbapi_recattr_vs_record/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_retries/Makefile => storage/ndb/ndbapi-examples/ndbapi_retries/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_s_i_ndbrecord/Makefile => storage/ndb/ndbapi-examples/ndbapi_s_i_ndbrecord/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_scan/Makefile => storage/ndb/ndbapi-examples/ndbapi_scan/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_simple/Makefile => storage/ndb/ndbapi-examples/ndbapi_simple/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_simple_dual/Makefile => storage/ndb/ndbapi-examples/ndbapi_simple_dual/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_simple_index/Makefile => storage/ndb/ndbapi-examples/ndbapi_simple_index/Makefile.am
modified:
  config/ac-macros/ha_ndbcluster.m4
  storage/ndb/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_blob_ndbrecord/main.cpp
  storage/ndb/ndbapi-examples/Makefile.am
  storage/ndb/ndbapi-examples/mgmapi_logevent/Makefile.am
  storage/ndb/ndbapi-examples/mgmapi_logevent2/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_async/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_async1/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_blob/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_blob_ndbrecord/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_event/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_recattr_vs_record/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_retries/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_s_i_ndbrecord/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_scan/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_simple/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_simple_dual/Makefile.am
  storage/ndb/ndbapi-examples/ndbapi_simple_index/Makefile.am

=== modified file 'config/ac-macros/ha_ndbcluster.m4'
--- a/config/ac-macros/ha_ndbcluster.m4	2008-04-29 07:51:49 +0000
+++ b/config/ac-macros/ha_ndbcluster.m4	2008-06-18 19:42:30 +0000
@@ -376,7 +376,21 @@ AC_DEFUN([MYSQL_SETUP_NDBCLUSTER], [
    storage/ndb/test/run-test/Makefile dnl
    storage/ndb/include/ndb_version.h storage/ndb/include/ndb_global.h dnl
    storage/ndb/include/ndb_types.h dnl
-   storage/ndb/swig/Makefile dnl
+   storage/ndb/ndbapi-examples/Makefile dnl
+   storage/ndb/ndbapi-examples/ndbapi_async/Makefile dnl
+   storage/ndb/ndbapi-examples/ndbapi_async1/Makefile dnl
+   storage/ndb/ndbapi-examples/ndbapi_blob/Makefile dnl
+   storage/ndb/ndbapi-examples/ndbapi_blob_ndbrecord/Makefile dnl
+   storage/ndb/ndbapi-examples/ndbapi_event/Makefile dnl
+   storage/ndb/ndbapi-examples/ndbapi_recattr_vs_record/Makefile dnl
+   storage/ndb/ndbapi-examples/ndbapi_retries/Makefile dnl
+   storage/ndb/ndbapi-examples/ndbapi_scan/Makefile dnl
+   storage/ndb/ndbapi-examples/ndbapi_simple/Makefile dnl
+   storage/ndb/ndbapi-examples/ndbapi_simple_dual/Makefile dnl
+   storage/ndb/ndbapi-examples/ndbapi_simple_index/Makefile dnl
+   storage/ndb/ndbapi-examples/ndbapi_s_i_ndbrecord/Makefile dnl
+   storage/ndb/ndbapi-examples/mgmapi_logevent/Makefile dnl
+   storage/ndb/ndbapi-examples/mgmapi_logevent2/Makefile dnl
   )
 ])
 

=== modified file 'storage/ndb/Makefile.am'
--- a/storage/ndb/Makefile.am	2008-03-11 15:27:35 +0000
+++ b/storage/ndb/Makefile.am	2008-06-18 19:42:30 +0000
@@ -13,8 +13,8 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
 
-SUBDIRS = src tools . include swig @ndb_opt_subdirs@
-DIST_SUBDIRS = src tools include test docs swig
+SUBDIRS = src tools . include ndbapi-examples @ndb_opt_subdirs@
+DIST_SUBDIRS = src tools include test docs ndbapi-examples
 EXTRA_DIST = config ndbapi-examples plug.in
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
 
@@ -22,7 +22,6 @@ include $(top_srcdir)/storage/ndb/config
 
 dist-hook:
 	-rm -rf `find $(distdir) -type d -name SCCS`
-	-rm -rf `find $(distdir)/ndbapi-examples -name '*.o'`
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	  if test "$$subdir" != "." -a "$$subdir" != "include"; then \
 	    files="`find $$subdir -name '*\.h'` `find $$subdir -name '*\.hpp'`"; \

=== renamed file 'storage/ndb/ndbapi-examples/Makefile' => 'storage/ndb/ndbapi-examples/Makefile.am'
--- a/storage/ndb/ndbapi-examples/Makefile	2008-04-01 15:37:28 +0000
+++ b/storage/ndb/ndbapi-examples/Makefile.am	2008-06-18 19:42:30 +0000
@@ -1,31 +1,16 @@
-BIN_DIRS := 	ndbapi_simple \
-	 	ndbapi_async \
-	 	ndbapi_async1 \
-		ndbapi_retries \
-		ndbapi_simple_index \
-		ndbapi_s_i_ndbrecord \
+SUBDIRS =	mgmapi_logevent \
+		mgmapi_logevent2 \
+		ndbapi_async \
+		ndbapi_async1 \
+		ndbapi_blob \
 		ndbapi_event \
+		ndbapi_recattr_vs_record \
+		ndbapi_retries \
 		ndbapi_scan \
-		ndbapi_blob \
-		ndbapi_blob_ndbrecord \
-		mgmapi_logevent \
+		ndbapi_simple \
 		ndbapi_simple_dual \
-		mgmapi_logevent2 \
-		ndbapi_recattr_vs_record
-
-bins: $(patsubst %, _bins_%, $(BIN_DIRS))
-
-$(patsubst %, _bins_%, $(BIN_DIRS)) :
-	$(MAKE) -C $(patsubst _bins_%, %, $@) $(OPTS)
-
-libs:
-
-clean:
-	for f in ${BIN_DIRS}; do \
-		$(MAKE) -C $$f $@;\
-	done
-
-clean_dep: clean
-cleanall: clean
-tidy: clean
-distclean: clean
+		ndbapi_blob_ndbrecord \
+		ndbapi_simple_index \
+		ndbapi_s_i_ndbrecord
+# Don't compile right now
+DIST_SUBDIRS =  ndbapi_blob_ndbrecord 

=== renamed file 'storage/ndb/ndbapi-examples/mgmapi_logevent/Makefile' => 'storage/ndb/ndbapi-examples/mgmapi_logevent/Makefile.am'
--- a/storage/ndb/ndbapi-examples/mgmapi_logevent/Makefile	2007-05-29 21:39:57 +0000
+++ b/storage/ndb/ndbapi-examples/mgmapi_logevent/Makefile.am	2008-06-18 19:42:30 +0000
@@ -1,24 +1,12 @@
-TARGET = mgmapi_logevent
-SRCS = main.cpp
-OBJS = main.o
-CXX = g++
-CFLAGS = -c -Wall -fno-rtti -fno-exceptions
-CXXFLAGS = 
-DEBUG = 
-LFLAGS = -Wall
-TOP_SRCDIR = ../../../..
-INCLUDE_DIR = $(TOP_SRCDIR)/storage/ndb/include
-LIB_DIR = -L$(TOP_SRCDIR)/storage/ndb/src/.libs \
-          -L$(TOP_SRCDIR)/libmysql_r/.libs \
-	  -L$(TOP_SRCDIR)/zlib/.libs \
-          -L$(TOP_SRCDIR)/mysys -L$(TOP_SRCDIR)/strings
-SYS_LIB = 
+noinst_PROGRAMS = mgmapi_logevent
 
-$(TARGET): $(OBJS)
-	$(CXX) $(CXXFLAGS) $(LFLAGS) $(LIB_DIR) $(OBJS) -lndbclient -lmysqlclient_r -lmysys -lmystrings -lz $(SYS_LIB) -o $(TARGET)
+mgmapi_logevent_SOURCES = main.cpp
+mgmapi_logevent_CXXFLAGS = -I$(top_srcdir)/storage/ndb/include/mgmapi \
+                           -I$(top_srcdir)/storage/ndb/include/ndbapi \
+                           -I$(top_srcdir)/storage/ndb/include
 
-$(OBJS): $(SRCS)
-	$(CXX) $(CFLAGS) -I$(TOP_SRCDIR)/include -I$(INCLUDE_DIR) -I$(INCLUDE_DIR)/mgmapi  -I$(INCLUDE_DIR)/ndbapi $(SRCS)
+# Need libmysqlclient_r because we use MySQL client lib, not because
+# of NDB API depends
+mgmapi_logevent_LDADD = ${top_srcdir}/storage/ndb/src/libndbclient.la \
+                        ${top_srcdir}/libmysql_r/libmysqlclient_r.la
 
-clean:
-	rm -f *.o $(TARGET)

=== renamed file 'storage/ndb/ndbapi-examples/mgmapi_logevent2/Makefile' => 'storage/ndb/ndbapi-examples/mgmapi_logevent2/Makefile.am'
--- a/storage/ndb/ndbapi-examples/mgmapi_logevent2/Makefile	2007-05-30 18:29:14 +0000
+++ b/storage/ndb/ndbapi-examples/mgmapi_logevent2/Makefile.am	2008-06-18 19:42:30 +0000
@@ -1,24 +1,12 @@
-TARGET = mgmapi_logevent2
-SRCS = main.cpp
-OBJS = main.o
-CXX = g++
-CFLAGS = -c -Wall -fno-rtti -fno-exceptions
-CXXFLAGS = 
-DEBUG = 
-LFLAGS = -Wall
-TOP_SRCDIR = ../../../..
-INCLUDE_DIR = $(TOP_SRCDIR)/storage/ndb/include
-LIB_DIR = -L$(TOP_SRCDIR)/storage/ndb/src/.libs \
-          -L$(TOP_SRCDIR)/libmysql_r/.libs \
-	  -L$(TOP_SRCDIR)/zlib/.libs \
-          -L$(TOP_SRCDIR)/mysys -L$(TOP_SRCDIR)/strings
-SYS_LIB = 
+noinst_PROGRAMS = mgmapi_logevent2
 
-$(TARGET): $(OBJS)
-	$(CXX) $(CXXFLAGS) $(LFLAGS) $(LIB_DIR) $(OBJS) -lndbclient -lmysqlclient_r -lmysys -lmystrings -lz $(SYS_LIB) -o $(TARGET)
+mgmapi_logevent2_SOURCES = main.cpp
+mgmapi_logevent2_CXXFLAGS = -I$(top_srcdir)/storage/ndb/include/mgmapi \
+                            -I$(top_srcdir)/storage/ndb/include/ndbapi \
+                            -I$(top_srcdir)/storage/ndb/include
 
-$(OBJS): $(SRCS)
-	$(CXX) $(CFLAGS) -I$(TOP_SRCDIR)/include -I$(INCLUDE_DIR) -I$(INCLUDE_DIR)/mgmapi  -I$(INCLUDE_DIR)/ndbapi $(SRCS)
-
-clean:
-	rm -f *.o $(TARGET)
+# Need libmysqlclient_r because we use MySQL client lib, not because
+# of NDB API depends
+mgmapi_logevent2_LDADD = ${top_srcdir}/storage/ndb/src/libndbclient.la \
+                         ${top_srcdir}/libmysql_r/libmysqlclient_r.la
+ 

=== renamed file 'storage/ndb/ndbapi-examples/ndbapi_async/Makefile' => 'storage/ndb/ndbapi-examples/ndbapi_async/Makefile.am'
--- a/storage/ndb/ndbapi-examples/ndbapi_async/Makefile	2006-09-01 13:14:50 +0000
+++ b/storage/ndb/ndbapi-examples/ndbapi_async/Makefile.am	2008-06-18 19:42:30 +0000
@@ -1,24 +1,11 @@
-TARGET = ndbapi_async
-SRCS = $(TARGET).cpp
-OBJS = $(TARGET).o
-CXX = g++
-CFLAGS = -g -c -Wall -fno-rtti -fno-exceptions
-CXXFLAGS = -g
-DEBUG = 
-LFLAGS = -Wall
-TOP_SRCDIR = ../../../..
-INCLUDE_DIR = $(TOP_SRCDIR)
-LIB_DIR = -L$(TOP_SRCDIR)/storage/ndb/src/.libs \
-          -L$(TOP_SRCDIR)/libmysql_r/.libs \
-          -L$(TOP_SRCDIR)/zlib/.libs \
-          -L$(TOP_SRCDIR)/mysys -L$(TOP_SRCDIR)/strings
-SYS_LIB = 
+noinst_PROGRAMS = ndbapi_async
 
-$(TARGET): $(OBJS)
-	$(CXX) $(CXXFLAGS) $(LFLAGS) $(LIB_DIR) $(OBJS) -lndbclient -lmysqlclient_r -lmysys -lmystrings -lz $(SYS_LIB) -o $(TARGET)
+ndbapi_async_SOURCES = ndbapi_async.cpp
+ndbapi_async_CXXFLAGS = -I$(top_srcdir)/storage/ndb/include/ndbapi \
+                        -I$(top_srcdir)/storage/ndb/include
 
-$(TARGET).o: $(SRCS)
-	$(CXX) $(CFLAGS) -I$(INCLUDE_DIR)/include -I$(INCLUDE_DIR)/extra -I$(INCLUDE_DIR)/storage/ndb/include -I$(INCLUDE_DIR)/storage/ndb/include/ndbapi $(SRCS)
+# Need libmysqlclient_r because we use MySQL client lib, not because
+# of NDB API depends
+ndbapi_async_LDADD = ${top_srcdir}/storage/ndb/src/libndbclient.la \
+                     ${top_srcdir}/libmysql_r/libmysqlclient_r.la
 
-clean:
-	rm -f *.o $(TARGET)

=== renamed file 'storage/ndb/ndbapi-examples/ndbapi_async1/Makefile' => 'storage/ndb/ndbapi-examples/ndbapi_async1/Makefile.am'
--- a/storage/ndb/ndbapi-examples/ndbapi_async1/Makefile	2006-09-01 13:14:50 +0000
+++ b/storage/ndb/ndbapi-examples/ndbapi_async1/Makefile.am	2008-06-18 19:42:30 +0000
@@ -1,23 +1,11 @@
-TARGET = ndbapi_async1
-SRCS = ndbapi_async1.cpp
-OBJS = ndbapi_async1.o
-CXX = g++
-CFLAGS = -c -Wall -fno-rtti -fno-exceptions
-DEBUG = 
-LFLAGS = -Wall
-TOP_SRCDIR = ../../../..
-INCLUDE_DIR = $(TOP_SRCDIR)/storage/ndb/include
-LIB_DIR = -L$(TOP_SRCDIR)/storage/ndb/src/.libs \
-          -L$(TOP_SRCDIR)/libmysql_r/.libs \
-          -L$(TOP_SRCDIR)/zlib/.libs \
-          -L$(TOP_SRCDIR)/mysys -L$(TOP_SRCDIR)/strings
-SYS_LIB = 
+noinst_PROGRAMS = ndbapi_async1
 
-$(TARGET): $(OBJS)
-	$(CXX) $(LFLAGS) $(LIB_DIR) $(OBJS) -lndbclient -lmysqlclient_r -lmysys -lmystrings -lz $(SYS_LIB) -o $(TARGET)
+ndbapi_async1_SOURCES = ndbapi_async1.cpp
+ndbapi_async1_CXXFLAGS = -I$(top_srcdir)/storage/ndb/include/ndbapi \
+                         -I$(top_srcdir)/storage/ndb/include
 
-$(TARGET).o: $(SRCS)
-	$(CXX) $(CFLAGS) -I$(TOP_SRCDIR)/include -I$(INCLUDE_DIR) -I$(INCLUDE_DIR)/ndbapi $(SRCS)
+# Need libmysqlclient_r because we use MySQL client lib, not because
+# of NDB API depends
+ndbapi_async1_LDADD = ${top_srcdir}/storage/ndb/src/libndbclient.la \
+                      ${top_srcdir}/libmysql_r/libmysqlclient_r.la
 
-clean:
-	rm -f *.o $(TARGET)

=== renamed file 'storage/ndb/ndbapi-examples/ndbapi_blob/Makefile' => 'storage/ndb/ndbapi-examples/ndbapi_blob/Makefile.am'
--- a/storage/ndb/ndbapi-examples/ndbapi_blob/Makefile	2007-03-26 08:40:57 +0000
+++ b/storage/ndb/ndbapi-examples/ndbapi_blob/Makefile.am	2008-06-18 19:42:30 +0000
@@ -1,24 +1,11 @@
-TARGET = ndbapi_blob
-SRCS = $(TARGET).cpp
-OBJS = $(TARGET).o
-CXX = g++
-CFLAGS = -g -c -Wall -fno-rtti -fno-exceptions
-CXXFLAGS = -g
-DEBUG = 
-LFLAGS = -Wall
-TOP_SRCDIR = ../../../..
-INCLUDE_DIR = $(TOP_SRCDIR)
-LIB_DIR = -L$(TOP_SRCDIR)/storage/ndb/src/.libs \
-          -L$(TOP_SRCDIR)/libmysql_r/.libs \
-          -L$(TOP_SRCDIR)/zlib/.libs \
-          -L$(TOP_SRCDIR)/mysys -L$(TOP_SRCDIR)/strings
-SYS_LIB = 
+noinst_PROGRAMS = ndbapi_blob
 
-$(TARGET): $(OBJS)
-	$(CXX) $(CXXFLAGS) $(LFLAGS) $(LIB_DIR) $(OBJS) -lndbclient -lmysqlclient_r -lmysys -lmystrings -lz $(SYS_LIB) -o $(TARGET)
+ndbapi_blob_SOURCES = ndbapi_blob.cpp
+ndbapi_blob_CXXFLAGS = -I$(top_srcdir)/storage/ndb/include/ndbapi \
+                       -I$(top_srcdir)/storage/ndb/include
 
-$(TARGET).o: $(SRCS)
-	$(CXX) $(CFLAGS) -I$(INCLUDE_DIR)/include -I$(INCLUDE_DIR)/extra -I$(INCLUDE_DIR)/storage/ndb/include -I$(INCLUDE_DIR)/storage/ndb/include/ndbapi $(SRCS)
+# Need libmysqlclient_r because we use MySQL client lib, not because
+# of NDB API depends
+ndbapi_blob_LDADD = ${top_srcdir}/storage/ndb/src/libndbclient.la \
+                    ${top_srcdir}/libmysql_r/libmysqlclient_r.la
 
-clean:
-	rm -f *.o $(TARGET)

=== renamed file 'storage/ndb/ndbapi-examples/ndbapi_blob_ndbrecord/Makefile' => 'storage/ndb/ndbapi-examples/ndbapi_blob_ndbrecord/Makefile.am'
--- a/storage/ndb/ndbapi-examples/ndbapi_blob_ndbrecord/Makefile	2007-07-04 06:55:19 +0000
+++ b/storage/ndb/ndbapi-examples/ndbapi_blob_ndbrecord/Makefile.am	2008-06-18 19:42:30 +0000
@@ -1,24 +1,11 @@
-TARGET = ndbapi_blob_ndbrecord
-SRCS = main.cpp
-OBJS = main.o
-CXX = g++
-CFLAGS = -g -c -Wall -fno-rtti -fno-exceptions
-CXXFLAGS = -g
-DEBUG = 
-LFLAGS = -Wall
-TOP_SRCDIR = ../../../..
-INCLUDE_DIR = $(TOP_SRCDIR)
-LIB_DIR = -L$(TOP_SRCDIR)/storage/ndb/src/.libs \
-          -L$(TOP_SRCDIR)/libmysql_r/.libs \
-          -L$(TOP_SRCDIR)/zlib/.libs \
-          -L$(TOP_SRCDIR)/mysys -L$(TOP_SRCDIR)/strings
-SYS_LIB = 
+noinst_PROGRAMS = ndbapi_blob_ndbrecord
 
-$(TARGET): $(OBJS)
-	$(CXX) $(CXXFLAGS) $(LFLAGS) $(LIB_DIR) $(OBJS) -lndbclient -lmysqlclient_r -lmysys -lmystrings -lz $(SYS_LIB) -o $(TARGET)
+ndbapi_blob_ndbrecord_SOURCES = main.cpp
+ndbapi_blob_ndbrecord_CXXFLAGS = -I$(top_srcdir)/storage/ndb/include/ndbapi \
+                                 -I$(top_srcdir)/storage/ndb/include 
 
-$(OBJS): $(SRCS)
-	$(CXX) $(CFLAGS) -I$(INCLUDE_DIR)/include -I$(INCLUDE_DIR)/extra -I$(INCLUDE_DIR)/storage/ndb/include -I$(INCLUDE_DIR)/storage/ndb/include/ndbapi $(SRCS)
+# Need libmysqlclient_r because we use MySQL client lib, not because
+# of NDB API depends
+ndbapi_blob_ndbrecord_LDADD = ${top_srcdir}/storage/ndb/src/libndbclient.la \
+                              ${top_srcdir}/libmysql_r/libmysqlclient_r.la
 
-clean:
-	rm -f *.o $(TARGET)

=== modified file 'storage/ndb/ndbapi-examples/ndbapi_blob_ndbrecord/main.cpp'
--- a/storage/ndb/ndbapi-examples/ndbapi_blob_ndbrecord/main.cpp	2008-04-01 15:37:28 +0000
+++ b/storage/ndb/ndbapi-examples/ndbapi_blob_ndbrecord/main.cpp	2008-06-18 19:42:30 +0000
@@ -24,7 +24,6 @@
   read/write methods.
  */
 
-#include <ndb_global.h>
 #include <mysql.h>
 #include <mysqld_error.h>
 #include <NdbApi.hpp>

=== renamed file 'storage/ndb/ndbapi-examples/ndbapi_event/Makefile' => 'storage/ndb/ndbapi-examples/ndbapi_event/Makefile.am'
--- a/storage/ndb/ndbapi-examples/ndbapi_event/Makefile	2006-09-01 13:14:50 +0000
+++ b/storage/ndb/ndbapi-examples/ndbapi_event/Makefile.am	2008-06-18 19:42:30 +0000
@@ -1,24 +1,11 @@
-TARGET = ndbapi_event
-SRCS = ndbapi_event.cpp
-OBJS = ndbapi_event.o
-CXX = g++ -g
-CFLAGS = -c -Wall -fno-rtti -fno-exceptions
-CXXFLAGS = 
-DEBUG =# -DVM_TRACE
-LFLAGS = -Wall
-TOP_SRCDIR = ../../../..
-INCLUDE_DIR = $(TOP_SRCDIR)/storage/ndb/include
-LIB_DIR = -L$(TOP_SRCDIR)/storage/ndb/src/.libs \
-          -L$(TOP_SRCDIR)/libmysql_r/.libs \
-          -L$(TOP_SRCDIR)/zlib/.libs \
-          -L$(TOP_SRCDIR)/mysys -L$(TOP_SRCDIR)/strings
-SYS_LIB = 
+noinst_PROGRAMS = ndbapi_event
 
-$(TARGET): $(OBJS)
-	$(CXX) $(CXXFLAGS) $(LFLAGS) $(LIB_DIR) $(OBJS) -lndbclient -lmysqlclient_r -lmysys -lmystrings -lz $(SYS_LIB) -o $(TARGET)
+ndbapi_event_SOURCES = ndbapi_event.cpp
+ndbapi_event_CXXFLAGS = -I$(top_srcdir)/storage/ndb/include/ndbapi \
+                        -I$(top_srcdir)/storage/ndb/include
 
-$(TARGET).o: $(SRCS) Makefile
-	$(CXX) $(CFLAGS) $(DEBUG) -I$(INCLUDE_DIR) -I$(INCLUDE_DIR)/ndbapi -I$(TOP_SRCDIR)/include $(SRCS)
+# Need libmysqlclient_r because we use MySQL client lib, not because
+# of NDB API depends
+ndbapi_event_LDADD = ${top_srcdir}/storage/ndb/src/libndbclient.la \
+                     ${top_srcdir}/libmysql_r/libmysqlclient_r.la
 
-clean:
-	rm -f *.o $(TARGET)

=== renamed file 'storage/ndb/ndbapi-examples/ndbapi_recattr_vs_record/Makefile' => 'storage/ndb/ndbapi-examples/ndbapi_recattr_vs_record/Makefile.am'
--- a/storage/ndb/ndbapi-examples/ndbapi_recattr_vs_record/Makefile	2008-04-01 15:37:28 +0000
+++ b/storage/ndb/ndbapi-examples/ndbapi_recattr_vs_record/Makefile.am	2008-06-18 19:42:30 +0000
@@ -1,24 +1,11 @@
-TARGET = ndbapi_recattr_vs_record
-SRCS = main.cpp
-OBJS = main.o
-CXX = g++
-CFLAGS = -c -Wall -fno-rtti -fno-exceptions
-CXXFLAGS = 
-DEBUG = 
-LFLAGS = -Wall
-TOP_SRCDIR = ../../../..
-INCLUDE_DIR = $(TOP_SRCDIR)
-LIB_DIR = -L$(TOP_SRCDIR)/storage/ndb/src/.libs \
-          -L$(TOP_SRCDIR)/libmysql_r/.libs \
-          -L$(TOP_SRCDIR)/zlib/.libs \
-          -L$(TOP_SRCDIR)/mysys -L$(TOP_SRCDIR)/strings
-SYS_LIB = 
+noinst_PROGRAMS = ndbapi_recattr_vs_record
 
-$(TARGET): $(OBJS)
-	$(CXX) $(CXXFLAGS) $(LFLAGS) $(LIB_DIR) $(OBJS) -lndbclient -lmysqlclient_r -lmysys -lmystrings -lz $(SYS_LIB) -o $(TARGET)
+ndbapi_recattr_vs_record_SOURCES = main.cpp
+ndbapi_recattr_vs_record_CXXFLAGS = -I$(top_srcdir)/storage/ndb/include/ndbapi \
+                                    -I$(top_srcdir)/storage/ndb/include
 
-$(OBJS): $(SRCS)
-	$(CXX) $(CFLAGS) -I$(INCLUDE_DIR)/include -I$(INCLUDE_DIR)/storage/ndb/include -I$(INCLUDE_DIR)/storage/ndb/include/ndbapi $(SRCS)
+# Need libmysqlclient_r because we use MySQL client lib, not because
+# of NDB API depends
+ndbapi_recattr_vs_record_LDADD = ${top_srcdir}/storage/ndb/src/libndbclient.la \
+                                 ${top_srcdir}/libmysql_r/libmysqlclient_r.la
 
-clean:
-	rm -f *.o $(TARGET)

=== renamed file 'storage/ndb/ndbapi-examples/ndbapi_retries/Makefile' => 'storage/ndb/ndbapi-examples/ndbapi_retries/Makefile.am'
--- a/storage/ndb/ndbapi-examples/ndbapi_retries/Makefile	2006-09-01 13:14:50 +0000
+++ b/storage/ndb/ndbapi-examples/ndbapi_retries/Makefile.am	2008-06-18 19:42:30 +0000
@@ -1,23 +1,11 @@
-TARGET = ndbapi_retries
-SRCS = ndbapi_retries.cpp
-OBJS = ndbapi_retries.o
-CXX = g++
-CFLAGS = -c -Wall -fno-rtti -fno-exceptions
-DEBUG = 
-LFLAGS = -Wall
-TOP_SRCDIR = ../../../..
-INCLUDE_DIR = $(TOP_SRCDIR)/storage/ndb/include
-LIB_DIR = -L$(TOP_SRCDIR)/storage/ndb/src/.libs \
-          -L$(TOP_SRCDIR)/libmysql_r/.libs \
-          -L$(TOP_SRCDIR)/zlib/.libs \
-          -L$(TOP_SRCDIR)/mysys -L$(TOP_SRCDIR)/strings
-SYS_LIB = 
+noinst_PROGRAMS = ndbapi_retries
 
-$(TARGET): $(OBJS)
-	$(CXX) $(LFLAGS) $(LIB_DIR) $(OBJS) -lndbclient -lmysqlclient_r -lmysys -lmystrings -lz $(SYS_LIB) -o $(TARGET)
+ndbapi_retries_SOURCES = ndbapi_retries.cpp
+ndbapi_retries_CXXFLAGS = -I$(top_srcdir)/storage/ndb/include/ndbapi \
+                          -I$(top_srcdir)/storage/ndb/include
 
-$(TARGET).o: $(SRCS)
-	$(CXX) $(CFLAGS)  -I$(TOP_SRCDIR)/include -I$(INCLUDE_DIR) -I$(INCLUDE_DIR)/ndbapi $(SRCS)
+# Need libmysqlclient_r because we use MySQL client lib, not because
+# of NDB API depends
+ndbapi_retries_LDADD = ${top_srcdir}/storage/ndb/src/libndbclient.la \
+                       ${top_srcdir}/libmysql_r/libmysqlclient_r.la
 
-clean:
-	rm -f *.o $(TARGET)

=== renamed file 'storage/ndb/ndbapi-examples/ndbapi_s_i_ndbrecord/Makefile' => 'storage/ndb/ndbapi-examples/ndbapi_s_i_ndbrecord/Makefile.am'
--- a/storage/ndb/ndbapi-examples/ndbapi_s_i_ndbrecord/Makefile	2007-07-04 06:55:19 +0000
+++ b/storage/ndb/ndbapi-examples/ndbapi_s_i_ndbrecord/Makefile.am	2008-06-18 19:42:30 +0000
@@ -1,24 +1,11 @@
-TARGET = ndbapi_simple_index_ndbrecord
-SRCS = main.cpp
-OBJS = main.o
-CXX = g++
-CFLAGS = -c -Wall -fno-rtti -fno-exceptions
-CXXFLAGS = 
-DEBUG = 
-LFLAGS = -Wall
-TOP_SRCDIR = ../../../..
-INCLUDE_DIR = $(TOP_SRCDIR)
-LIB_DIR = -L$(TOP_SRCDIR)/storage/ndb/src/.libs \
-          -L$(TOP_SRCDIR)/libmysql_r/.libs \
-          -L$(TOP_SRCDIR)/zlib/.libs \
-          -L$(TOP_SRCDIR)/mysys -L$(TOP_SRCDIR)/strings
-SYS_LIB = 
+noinst_PROGRAMS = ndbapi_s_i_ndbrecord
 
-$(TARGET): $(OBJS)
-	$(CXX) $(CXXFLAGS) $(LFLAGS) $(LIB_DIR) $(OBJS) -lndbclient -lmysqlclient_r -lmysys -lmystrings -lz $(SYS_LIB) -o $(TARGET)
+ndbapi_s_i_ndbrecord_SOURCES = main.cpp
+ndbapi_s_i_ndbrecord_CXXFLAGS = -I$(top_srcdir)/storage/ndb/include/ndbapi \
+                                -I$(top_srcdir)/storage/ndb/include
 
-$(OBJS): $(SRCS)
-	$(CXX) $(CFLAGS) -I$(INCLUDE_DIR)/include -I$(INCLUDE_DIR)/storage/ndb/include -I$(INCLUDE_DIR)/storage/ndb/include/ndbapi $(SRCS)
+# Need libmysqlclient_r because we use MySQL client lib, not because
+# of NDB API depends
+ndbapi_s_i_ndbrecord_LDADD = ${top_srcdir}/storage/ndb/src/libndbclient.la \
+                             ${top_srcdir}/libmysql_r/libmysqlclient_r.la
 
-clean:
-	rm -f *.o $(TARGET)

=== renamed file 'storage/ndb/ndbapi-examples/ndbapi_scan/Makefile' => 'storage/ndb/ndbapi-examples/ndbapi_scan/Makefile.am'
--- a/storage/ndb/ndbapi-examples/ndbapi_scan/Makefile	2006-09-01 13:14:50 +0000
+++ b/storage/ndb/ndbapi-examples/ndbapi_scan/Makefile.am	2008-06-18 19:42:30 +0000
@@ -1,24 +1,11 @@
-TARGET = ndbapi_scan
-SRCS = $(TARGET).cpp
-OBJS = $(TARGET).o
-CXX = g++
-CFLAGS = -g -c -Wall -fno-rtti -fno-exceptions
-CXXFLAGS = -g
-DEBUG = 
-LFLAGS = -Wall
-TOP_SRCDIR = ../../../..
-INCLUDE_DIR = $(TOP_SRCDIR)
-LIB_DIR = -L$(TOP_SRCDIR)/storage/ndb/src/.libs \
-          -L$(TOP_SRCDIR)/libmysql_r/.libs \
-          -L$(TOP_SRCDIR)/zlib/.libs \
-          -L$(TOP_SRCDIR)/mysys -L$(TOP_SRCDIR)/strings
-SYS_LIB = 
+noinst_PROGRAMS = ndbapi_scan
 
-$(TARGET): $(OBJS)
-	$(CXX) $(CXXFLAGS) $(LFLAGS) $(LIB_DIR) $(OBJS) -lndbclient -lmysqlclient_r -lmysys -lmystrings -lz $(SYS_LIB) -o $(TARGET)
+ndbapi_scan_SOURCES = ndbapi_scan.cpp
+ndbapi_scan_CXXFLAGS = -I$(top_srcdir)/storage/ndb/include/ndbapi \
+                       -I$(top_srcdir)/storage/ndb/include
 
-$(TARGET).o: $(SRCS)
-	$(CXX) $(CFLAGS) -I$(INCLUDE_DIR)/include -I$(INCLUDE_DIR)/extra -I$(INCLUDE_DIR)/storage/ndb/include -I$(INCLUDE_DIR)/storage/ndb/include/ndbapi $(SRCS)
+# Need libmysqlclient_r because we use MySQL client lib, not because
+# of NDB API depends
+ndbapi_scan_LDADD = ${top_srcdir}/storage/ndb/src/libndbclient.la \
+                    ${top_srcdir}/libmysql_r/libmysqlclient_r.la
 
-clean:
-	rm -f *.o $(TARGET)

=== renamed file 'storage/ndb/ndbapi-examples/ndbapi_simple/Makefile' => 'storage/ndb/ndbapi-examples/ndbapi_simple/Makefile.am'
--- a/storage/ndb/ndbapi-examples/ndbapi_simple/Makefile	2006-09-01 13:14:50 +0000
+++ b/storage/ndb/ndbapi-examples/ndbapi_simple/Makefile.am	2008-06-18 19:42:30 +0000
@@ -1,24 +1,10 @@
-TARGET = ndbapi_simple
-SRCS = $(TARGET).cpp
-OBJS = $(TARGET).o
-CXX = g++
-CFLAGS = -c -Wall -fno-rtti -fno-exceptions
-CXXFLAGS = 
-DEBUG = 
-LFLAGS = -Wall
-TOP_SRCDIR = ../../../..
-INCLUDE_DIR = $(TOP_SRCDIR)/storage/ndb/include
-LIB_DIR = -L$(TOP_SRCDIR)/storage/ndb/src/.libs \
-          -L$(TOP_SRCDIR)/libmysql_r/.libs \
-          -L$(TOP_SRCDIR)/zlib/.libs \
-          -L$(TOP_SRCDIR)/mysys -L$(TOP_SRCDIR)/strings
-SYS_LIB = 
+noinst_PROGRAMS = ndbapi_simple
 
-$(TARGET): $(OBJS)
-	$(CXX) $(CXXFLAGS) $(LFLAGS) $(LIB_DIR) $(OBJS) -lndbclient -lmysqlclient_r -lmysys -lmystrings  -lz $(SYS_LIB) -o $(TARGET)
+ndbapi_simple_SOURCES = ndbapi_simple.cpp
+ndbapi_simple_CXXFLAGS = -I$(top_srcdir)/storage/ndb/include/ndbapi \
+                         -I$(top_srcdir)/storage/ndb/include
 
-$(TARGET).o: $(SRCS)
-	$(CXX) $(CFLAGS) -I$(TOP_SRCDIR)/include -I$(INCLUDE_DIR) -I$(INCLUDE_DIR)/ndbapi $(SRCS)
-
-clean:
-	rm -f *.o $(TARGET)
+# Need libmysqlclient_r because we use MySQL client lib, not because
+# of NDB API depends
+ndbapi_simple_LDADD = ${top_srcdir}/storage/ndb/src/libndbclient.la \
+                      ${top_srcdir}/libmysql_r/libmysqlclient_r.la

=== renamed file 'storage/ndb/ndbapi-examples/ndbapi_simple_dual/Makefile' => 'storage/ndb/ndbapi-examples/ndbapi_simple_dual/Makefile.am'
--- a/storage/ndb/ndbapi-examples/ndbapi_simple_dual/Makefile	2007-05-29 21:39:57 +0000
+++ b/storage/ndb/ndbapi-examples/ndbapi_simple_dual/Makefile.am	2008-06-18 19:42:30 +0000
@@ -1,24 +1,11 @@
-TARGET = ndbapi_simple_dual
-SRCS = main.cpp
-OBJS = main.o
-CXX = g++
-CFLAGS = -c -Wall -fno-rtti -fno-exceptions
-CXXFLAGS = 
-DEBUG = 
-LFLAGS = -Wall
-TOP_SRCDIR = ../../../..
-INCLUDE_DIR = $(TOP_SRCDIR)/storage/ndb/include
-LIB_DIR = -L$(TOP_SRCDIR)/storage/ndb/src/.libs \
-          -L$(TOP_SRCDIR)/libmysql_r/.libs \
-          -L$(TOP_SRCDIR)/zlib/.libs \
-          -L$(TOP_SRCDIR)/mysys -L$(TOP_SRCDIR)/strings
-SYS_LIB = 
+noinst_PROGRAMS = ndbapi_simple_dual
 
-$(TARGET): $(OBJS)
-	$(CXX) $(CXXFLAGS) $(LFLAGS) $(LIB_DIR) $(OBJS) -lndbclient -lmysqlclient_r -lmysys -lmystrings  -lz $(SYS_LIB) -o $(TARGET)
+ndbapi_simple_dual_SOURCES = main.cpp
+ndbapi_simple_dual_CXXFLAGS = -I$(top_srcdir)/storage/ndb/include/ndbapi \
+                              -I$(top_srcdir)/storage/ndb/include
 
-$(OBJS): $(SRCS)
-	$(CXX) $(CFLAGS) -I$(TOP_SRCDIR)/include -I$(INCLUDE_DIR) -I$(INCLUDE_DIR)/ndbapi $(SRCS)
+# Need libmysqlclient_r because we use MySQL client lib, not because
+# of NDB API depends
+ndbapi_simple_dual_LDADD = ${top_srcdir}/storage/ndb/src/libndbclient.la \
+                           ${top_srcdir}/libmysql_r/libmysqlclient_r.la
 
-clean:
-	rm -f *.o $(TARGET)

=== renamed file 'storage/ndb/ndbapi-examples/ndbapi_simple_index/Makefile' => 'storage/ndb/ndbapi-examples/ndbapi_simple_index/Makefile.am'
--- a/storage/ndb/ndbapi-examples/ndbapi_simple_index/Makefile	2007-05-29 21:39:57 +0000
+++ b/storage/ndb/ndbapi-examples/ndbapi_simple_index/Makefile.am	2008-06-18 19:42:30 +0000
@@ -1,24 +1,11 @@
-TARGET = ndbapi_simple_index
-SRCS = main.cpp
-OBJS = main.o
-CXX = g++
-CFLAGS = -c -Wall -fno-rtti -fno-exceptions
-CXXFLAGS = 
-DEBUG = 
-LFLAGS = -Wall
-TOP_SRCDIR = ../../../..
-INCLUDE_DIR = $(TOP_SRCDIR)
-LIB_DIR = -L$(TOP_SRCDIR)/storage/ndb/src/.libs \
-          -L$(TOP_SRCDIR)/libmysql_r/.libs \
-          -L$(TOP_SRCDIR)/zlib/.libs \
-          -L$(TOP_SRCDIR)/mysys -L$(TOP_SRCDIR)/strings
-SYS_LIB = 
+noinst_PROGRAMS = ndbapi_simple_index
 
-$(TARGET): $(OBJS)
-	$(CXX) $(CXXFLAGS) $(LFLAGS) $(LIB_DIR) $(OBJS) -lndbclient -lmysqlclient_r -lmysys -lmystrings -lz $(SYS_LIB) -o $(TARGET)
+ndbapi_simple_index_SOURCES = main.cpp
+ndbapi_simple_index_CXXFLAGS = -I$(top_srcdir)/storage/ndb/include/ndbapi \
+                               -I$(top_srcdir)/storage/ndb/include
 
-$(OBJS): $(SRCS)
-	$(CXX) $(CFLAGS) -I$(INCLUDE_DIR)/include -I$(INCLUDE_DIR)/storage/ndb/include -I$(INCLUDE_DIR)/storage/ndb/include/ndbapi $(SRCS)
+# Need libmysqlclient_r because we use MySQL client lib, not because
+# of NDB API depends
+ndbapi_simple_index_LDADD = ${top_srcdir}/storage/ndb/src/libndbclient.la \
+                            ${top_srcdir}/libmysql_r/libmysqlclient_r.la
 
-clean:
-	rm -f *.o $(TARGET)

Thread
bzr commit into mysql-5.1-telco-6.2 branch (monty:2631) Bug#37491Monty Taylor18 Jun