diff options
author | tv <tv@pkgsrc.org> | 1998-07-20 14:49:51 +0000 |
---|---|---|
committer | tv <tv@pkgsrc.org> | 1998-07-20 14:49:51 +0000 |
commit | c71f299e88f3eabe824c436fdf54041d5ecfe347 (patch) | |
tree | 76098822057e8a832ca1e5e544d92fb692d1cce3 | |
parent | 32bb272e3c7c4a8f1c56ca2be168b45f70d22e5a (diff) | |
download | pkgsrc-c71f299e88f3eabe824c436fdf54041d5ecfe347.tar.gz |
Update to use libtool to build the clients' shared library.
Add support for client-only setups on all architectures other than those
the server's threads support (i386 and alpha).
-rw-r--r-- | databases/mysql/Makefile | 26 | ||||
-rw-r--r-- | databases/mysql/patches/patch-aa | 132 | ||||
-rw-r--r-- | databases/mysql/patches/patch-ad | 11 | ||||
-rw-r--r-- | databases/mysql/patches/patch-ae | 11 | ||||
-rw-r--r-- | databases/mysql/pkg/PLIST-client | 35 | ||||
-rw-r--r-- | databases/mysql/pkg/PLIST-server (renamed from databases/mysql/pkg/PLIST) | 104 |
6 files changed, 171 insertions, 148 deletions
diff --git a/databases/mysql/Makefile b/databases/mysql/Makefile index df7eccb1036..de3764cde4d 100644 --- a/databases/mysql/Makefile +++ b/databases/mysql/Makefile @@ -1,6 +1,7 @@ -# $NetBSD: Makefile,v 1.6 1998/07/20 12:21:14 frueauf Exp $ +# $NetBSD: Makefile,v 1.7 1998/07/20 14:49:51 tv Exp $ # +# note: if updated, update shlib version number in patch-aa DISTNAME= mysql-3.21.33 CATEGORIES= databases MASTER_SITES= ftp://ftp.digex.net/pub/database/mysql/Downloads/MySQL-3.21/ \ @@ -8,7 +9,7 @@ MASTER_SITES= ftp://ftp.digex.net/pub/database/mysql/Downloads/MySQL-3.21/ \ MAINTAINER= tsarna@endicor.com -ONLY_FOR_ARCHS= i386 alpha +BUILD_DEPENDS= ${PREFIX}/bin/libtool:../../devel/libtool CONFLICTS= mysql-3.21.31 mysql-3.21.32a @@ -17,18 +18,35 @@ NO_CDROM= "Restrictive license." MYSQL_DATADIR?= /var/mysql GNU_CONFIGURE= yes -CONFIGURE_ARGS+=--enable-shared --localstatedir=${MYSQL_DATADIR} \ +CONFIGURE_ARGS+=--localstatedir=${MYSQL_DATADIR} \ --without-perl --without-debug +CONFIGURE_ENV= INSTALL_PROGRAM="${INSTALL_PROGRAM}" \ + INSTALL_DATA="${INSTALL_DATA}" \ + INSTALL_SCRIPT="${INSTALL_SCRIPT}" +MAKE_ENV= LIBTOOL=${PREFIX}/bin/libtool USE_GMAKE= yes USE_PERL5= yes +PLIST_SRC= ${WRKSRC}/.PLIST_SRC + INFO_FILES= mysql.info pre-install: ${INSTALL_DATA} ${WRKSRC}/Docs/mysql.info ${PREFIX}/info - + @${CP} ${PKGDIR}/PLIST-client ${PLIST_SRC} + +.if (${MACHINE_ARCH} != "i386") && (${MACHINE_ARCH} != "alpha") +CONFIGURE_ARGS+=--without-server +pre-configure: + @${ECHO} '########## Client-only support! ##########' + @${ECHO} 'MySQL does not support pthreads on ${MACHINE_ARCH}, so only the client' + @${ECHO} 'support library and clients will be built.' + @${ECHO} '##########################################' +.else post-install: (cd ${WRKSRC}; ./scripts/mysql_install_db) + @${CAT} ${PKGDIR}/PLIST-server >>${PLIST_SRC} +.endif .include "../../mk/bsd.pkg.mk" diff --git a/databases/mysql/patches/patch-aa b/databases/mysql/patches/patch-aa index 08591c4f94d..b611dada94c 100644 --- a/databases/mysql/patches/patch-aa +++ b/databases/mysql/patches/patch-aa @@ -1,53 +1,81 @@ ---- client/Makefile.in.orig Sun May 10 17:25:18 1998 -+++ client/Makefile.in Sun Jun 14 20:15:50 1998 -@@ -149,16 +149,18 @@ - libmysqlclient_a_LIBADD = $(mysysobjects) $(mystringsobjects) $(dbugobjects) - - # Dirty hack to generate names for shared objects (requires GNUmake) --SHLIBOBJS = ${libmysqlclient_a_SOURCES:.c=.o} ${libmysqlclient_a_LIBADD} -+SHLIBOBJS = ${libmysqlclient_a_SOURCES:.c=.so} ${libmysqlclient_a_LIBADD:.o=.so} -+ -+SHVERSION = 321.30 - - CLEANFILES = $(libmysqlclient_a_LIBADD) $(SHLIBOBJS) \ -- libmysqlclient.so libmysqlclient.so.@VERSION@ -+ libmysqlclient.so libmysqlclient.so.${SHVERSION} - - DEFS = -DUNDEF_THREADS_HACK - mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs - CONFIG_HEADER = ../config.h - CONFIG_CLEAN_FILES = --LIBRARIES = $(pkglib_LIBRARIES) -+LIBRARIES = $(pkglib_LIBRARIES) libmysqlclient.so - - CPPFLAGS = @CPPFLAGS@ - LDFLAGS = @LDFLAGS@ -@@ -540,18 +542,22 @@ - - shlib: libmysqlclient.so - --libmysqlclient.so: libmysqlclient.so.@VERSION@ -+libmysqlclient.so: libmysqlclient.so.${SHVERSION} - -rm -f $@ - ln -s $< $@ - --libmysqlclient.so.@VERSION@: $(SHLIBOBJS) -- $(CC) -shared -Wl,-h,libmysqlclient.so.@SHARED_LIB_VERSION@ -o $@ \ -- $(SHLIBOBJS) $(LIBS) -+libmysqlclient.so.${SHVERSION}: libmysqlclient_pic.a -+ $(LD) -x -Bshareable -Bforcearchive libmysqlclient_pic.a -o $@ $(LIBS) -+ -+libmysqlclient_pic.a: $(SHLIBOBJS) -+ ${AR} cru $@ $(SHLIBOBJS) -+ ${RANLIB} $@ - - install_shlib: libmysqlclient.so -- $(INSTALL) libmysqlclient.so.@VERSION@ $(libdir) -+ $(INSTALL) libmysqlclient_pic.a $(libdir) -+ $(INSTALL) libmysqlclient.so.${SHVERSION} $(libdir) - -rm -f $(libdir)/libmysqlclient.so -- ln -s libmysqlclient.so.@VERSION@ $(libdir)/libmysqlclient.so -+ ln -s libmysqlclient.so.${SHVERSION} $(libdir)/libmysqlclient.so - @echo "ensure $(libdir) is in your LD_LIBRARY_PATH" - @echo "and run ldconfig" +--- client/Makefile.in.orig Tue Jun 30 08:14:37 1998 ++++ client/Makefile.in Fri Jul 17 12:20:34 1998 +@@ -42,8 +42,8 @@ + AUTOHEADER = @AUTOHEADER@ + + INSTALL = @INSTALL@ +-INSTALL_PROGRAM = @INSTALL_PROGRAM@ +-INSTALL_DATA = @INSTALL_DATA@ ++INSTALL_PROGRAM = $(LIBTOOL) --mode=install @INSTALL_PROGRAM@ ++INSTALL_DATA = $(LIBTOOL) --mode=install @INSTALL_DATA@ + INSTALL_SCRIPT = @INSTALL_SCRIPT@ + transform = @program_transform_name@ + +@@ -115,21 +115,21 @@ + mystrings_charset = @mystrings_charset@ + perl_dirs = @perl_dirs@ + readline_dir = @readline_dir@ +-readline_link = @readline_link@ ++readline_link = ../readline/libreadline.a + server_scripts = @server_scripts@ + sql_server_dirs = @sql_server_dirs@ + + INCLUDES = -I$(srcdir)/../include -I../include \ + -I$(srcdir)/.. -I$(top_srcdir) -I.. + LIBS = @CLIENT_LIBS@ +-LDADD = -L. -lmysqlclient +-pkglib_LIBRARIES = libmysqlclient.a +-LIBFILES = libmysqlclient.a @shlib@ ++LDADD = libmysqlclient.la ++pkglib_LIBRARIES = libmysqlclient.la ++LIBFILES = libmysqlclient.la + bin_PROGRAMS = mysql mysqladmin mysqlshow mysqldump mysqlimport + noinst_PROGRAMS = insert_test select_test + noinst_HEADERS = sql_string.h completion_hash.h + mysql_SOURCES = mysql.cc readline.cc sql_string.cc completion_hash.cc +-mysql_LDADD = @readline_link@ @TERMCAP_LIB@ $(LDADD) ++mysql_LDADD = $(readline_link) @TERMCAP_LIB@ $(LDADD) + mysql_DEPENDENCIES= $(LIBRARIES) + mysqladmin_DEPENDENCIES= $(LIBRARIES) + mysqlshow_DEPENDENCIES= $(LIBRARIES) +@@ -218,10 +218,10 @@ + select_test_LDFLAGS = + CXXFLAGS = @CXXFLAGS@ + CXXCOMPILE = $(CXX) $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CXXFLAGS) +-CXXLINK = $(CXX) $(CXXFLAGS) $(LDFLAGS) -o $@ ++CXXLINK = $(LIBTOOL) --mode=link $(CXX) $(CXXFLAGS) $(LDFLAGS) -o $@ + CFLAGS = @CFLAGS@ +-COMPILE = $(CC) $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) +-LINK = $(CC) $(CFLAGS) $(LDFLAGS) -o $@ ++COMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) ++LINK = $(LIBTOOL) --mode=link $(CC) $(CFLAGS) $(LDFLAGS) -o $@ + HEADERS = $(noinst_HEADERS) + + DIST_COMMON = Makefile.am Makefile.in +@@ -265,12 +265,6 @@ + else :; fi; \ + done + @$(POST_INSTALL) +- @list='$(pkglib_LIBRARIES)'; for p in $$list; do \ +- if test -f $$p; then \ +- echo " $(RANLIB) $(pkglibdir)/$$p"; \ +- $(RANLIB) $(pkglibdir)/$$p; \ +- else :; fi; \ +- done + + uninstall-pkglibLIBRARIES: + $(NORMAL_UNINSTALL) +@@ -291,10 +285,9 @@ + + maintainer-clean-compile: + +-libmysqlclient.a: $(libmysqlclient_a_OBJECTS) $(libmysqlclient_a_DEPENDENCIES) +- rm -f libmysqlclient.a +- $(AR) cru libmysqlclient.a $(libmysqlclient_a_OBJECTS) $(libmysqlclient_a_LIBADD) +- $(RANLIB) libmysqlclient.a ++libmysqlclient.la: $(libmysqlclient_a_OBJECTS) $(libmysqlclient_a_DEPENDENCIES) ++ $(LIBTOOL) --mode=link $(CC) -o libmysqlclient.la $(libmysqlclient_a_OBJECTS:.o=.lo) $(libmysqlclient_a_LIBADD:.o=.lo) \ ++ -rpath $(prefix)/lib -version-info 321:33 + + mostlyclean-binPROGRAMS: diff --git a/databases/mysql/patches/patch-ad b/databases/mysql/patches/patch-ad deleted file mode 100644 index a638afe3f40..00000000000 --- a/databases/mysql/patches/patch-ad +++ /dev/null @@ -1,11 +0,0 @@ ---- scripts/Makefile.in.orig Sun Jun 14 21:15:12 1998 -+++ scripts/Makefile.in Sun Jun 14 21:13:41 1998 -@@ -40,7 +40,7 @@ - INSTALL = @INSTALL@ - INSTALL_PROGRAM = @INSTALL_PROGRAM@ - INSTALL_DATA = @INSTALL_DATA@ --INSTALL_SCRIPT = @INSTALL_SCRIPT@ -+INSTALL_SCRIPT = install -c -o root -g wheel -m 555 - transform = @program_transform_name@ - - NORMAL_INSTALL = true diff --git a/databases/mysql/patches/patch-ae b/databases/mysql/patches/patch-ae deleted file mode 100644 index fe4f26a8238..00000000000 --- a/databases/mysql/patches/patch-ae +++ /dev/null @@ -1,11 +0,0 @@ ---- bench/Makefile.in.orig Sun Jun 14 21:34:14 1998 -+++ bench/Makefile.in Sun Jun 14 21:34:45 1998 -@@ -40,7 +40,7 @@ - INSTALL = @INSTALL@ - INSTALL_PROGRAM = @INSTALL_PROGRAM@ - INSTALL_DATA = @INSTALL_DATA@ --INSTALL_SCRIPT = @INSTALL_SCRIPT@ -+INSTALL_SCRIPT = install -c -o root -g wheel -m 555 - transform = @program_transform_name@ - - NORMAL_INSTALL = true diff --git a/databases/mysql/pkg/PLIST-client b/databases/mysql/pkg/PLIST-client new file mode 100644 index 00000000000..e376a999273 --- /dev/null +++ b/databases/mysql/pkg/PLIST-client @@ -0,0 +1,35 @@ +@comment $NetBSD: PLIST-client,v 1.1 1998/07/20 14:49:51 tv Exp $ +bin/add_file_priv +bin/add_func_table +bin/add_long_password +bin/make_binary_distribution +bin/msql2mysql +bin/mysql +bin/mysqlaccess +bin/mysqladmin +bin/mysqlbug +bin/mysqldump +bin/mysqlimport +bin/mysqlshow +bin/which1 +bin/zap +include/mysql/chardefs.h +include/mysql/dbug.h +include/mysql/errmsg.h +include/mysql/history.h +include/mysql/keymaps.h +include/mysql/m_ctype.h.in +include/mysql/m_string.h +include/mysql/my_sys.h +include/mysql/mysql.h +include/mysql/mysql_com.h +include/mysql/mysql_version.h +include/mysql/readline.h +include/mysql/tilde.h +@unexec %D/bin/install-info --delete %D/info/mysql.info %D/info/dir +info/mysql.info +@exec %D/bin/install-info %D/info/mysql.info %D/info/dir +lib/libmysqlclient.a +lib/libmysqlclient.so.321.32 +man/man1/mysql.1 +@dirrm include/mysql diff --git a/databases/mysql/pkg/PLIST b/databases/mysql/pkg/PLIST-server index 6b1095709ab..6575381136b 100644 --- a/databases/mysql/pkg/PLIST +++ b/databases/mysql/pkg/PLIST-server @@ -1,94 +1,58 @@ -@comment $NetBSD: PLIST,v 1.2 1998/07/15 11:39:47 agc Exp $ -include/mysql/readline.h -include/mysql/chardefs.h -include/mysql/keymaps.h -include/mysql/history.h -include/mysql/tilde.h -include/mysql/dbug.h -include/mysql/m_string.h -include/mysql/m_ctype.h.in -include/mysql/my_sys.h -include/mysql/mysql.h -include/mysql/mysql_com.h -include/mysql/errmsg.h -include/mysql/mysql_version.h -lib/mysql/libmysqlclient.a -lib/mysql/libmystrings.a -lib/mysql/libdbug.a -lib/mysql/libmysys.a -lib/mysql/libnisam.a -lib/mysql/libheap.a -lib/mysql/libmerge.a -lib/libmysqlclient_pic.a -lib/libmysqlclient.so.321.30 -lib/libmysqlclient.so -bin/mysql -bin/mysqladmin -bin/mysqlshow -bin/mysqldump -bin/mysqlimport -bin/replace +@comment $NetBSD: PLIST-server,v 1.1 1998/07/20 14:49:52 tv Exp $ bin/comp_err -bin/perror bin/isamchk bin/isamlog -bin/add_file_priv -bin/add_long_password -bin/add_func_table -bin/make_binary_distribution -bin/msql2mysql -bin/mysqlaccess -bin/mysqlbug bin/mysql.server -bin/safe_mysqld bin/mysql_install_db -bin/zap -bin/which1 +bin/perror +bin/replace +bin/safe_mysqld +lib/mysql/libdbug.a +lib/mysql/libheap.a +lib/mysql/libmerge.a +lib/mysql/libmystrings.a +lib/mysql/libmysys.a +lib/mysql/libnisam.a +libexec/mysqld +share/mysql/czech/errmsg.sys +share/mysql/czech/errmsg.txt +share/mysql/dutch/errmsg.sys +share/mysql/dutch/errmsg.txt share/mysql/english/errmsg.sys share/mysql/english/errmsg.txt -share/mysql/swedish/errmsg.sys -share/mysql/swedish/errmsg.txt -share/mysql/german/errmsg.sys -share/mysql/german/errmsg.txt share/mysql/french/errmsg.sys share/mysql/french/errmsg.txt -share/mysql/czech/errmsg.sys -share/mysql/czech/errmsg.txt -share/mysql/polish/errmsg.sys -share/mysql/polish/errmsg.txt -share/mysql/spanish/errmsg.sys -share/mysql/spanish/errmsg.txt -share/mysql/norwegian/errmsg.sys -share/mysql/norwegian/errmsg.txt +share/mysql/german/errmsg.sys +share/mysql/german/errmsg.txt +share/mysql/italian/errmsg.sys +share/mysql/italian/errmsg.txt share/mysql/norwegian-ny/errmsg.sys share/mysql/norwegian-ny/errmsg.txt +share/mysql/norwegian/errmsg.sys +share/mysql/norwegian/errmsg.txt +share/mysql/polish/errmsg.sys +share/mysql/polish/errmsg.txt share/mysql/portuguese/errmsg.sys share/mysql/portuguese/errmsg.txt -share/mysql/dutch/errmsg.sys -share/mysql/dutch/errmsg.txt share/mysql/russian/errmsg.sys share/mysql/russian/errmsg.txt -share/mysql/italian/errmsg.sys -share/mysql/italian/errmsg.txt -libexec/mysqld -man/man1/mysql.1 -@unexec %D/bin/install-info --delete %D/info/mysql.info %D/info/dir -info/mysql.info -@exec %D/bin/install-info %D/info/mysql.info %D/info/dir +share/mysql/spanish/errmsg.sys +share/mysql/spanish/errmsg.txt +share/mysql/swedish/errmsg.sys +share/mysql/swedish/errmsg.txt @exec %D/bin/mysql_install_db -@dirrm include/mysql @dirrm lib/mysql +@dirrm share/mysql/czech +@dirrm share/mysql/dutch @dirrm share/mysql/english -@dirrm share/mysql/swedish -@dirrm share/mysql/german @dirrm share/mysql/french -@dirrm share/mysql/czech -@dirrm share/mysql/polish -@dirrm share/mysql/spanish +@dirrm share/mysql/german +@dirrm share/mysql/italian @dirrm share/mysql/norwegian @dirrm share/mysql/norwegian-ny +@dirrm share/mysql/polish @dirrm share/mysql/portuguese -@dirrm share/mysql/dutch @dirrm share/mysql/russian -@dirrm share/mysql/italian +@dirrm share/mysql/spanish +@dirrm share/mysql/swedish @dirrm share/mysql |