2018-02-02 00:14:55 +01:00
|
|
|
# $NetBSD: Makefile.common,v 1.37 2018/02/01 23:14:55 jperkin Exp $
|
2010-03-04 17:27:18 +01:00
|
|
|
#
|
|
|
|
# used by databases/mysql51-client/Makefile
|
|
|
|
# used by databases/mysql51-server/Makefile
|
|
|
|
|
2017-04-13 15:44:49 +02:00
|
|
|
DISTNAME= mysql-5.1.73
|
2011-12-02 15:25:09 +01:00
|
|
|
CATEGORIES= databases
|
|
|
|
MASTER_SITES= ${MASTER_SITE_MYSQL:=MySQL-5.1/}
|
2010-03-04 17:27:18 +01:00
|
|
|
|
2011-12-02 15:25:09 +01:00
|
|
|
MAINTAINER= pkgsrc-users@NetBSD.org
|
2017-09-03 10:53:04 +02:00
|
|
|
HOMEPAGE= https://www.mysql.com/
|
2011-12-02 15:25:09 +01:00
|
|
|
LICENSE= gnu-gpl-v2
|
2010-03-04 17:27:18 +01:00
|
|
|
|
|
|
|
USE_LIBTOOL= yes
|
|
|
|
GNU_CONFIGURE= yes
|
|
|
|
|
|
|
|
.include "../../mk/bsd.prefs.mk"
|
|
|
|
.include "options.mk"
|
|
|
|
|
|
|
|
EXTRACT_USING= bsdtar
|
|
|
|
|
|
|
|
# MYSQL_USER username of the database administrator
|
|
|
|
# MYSQL_GROUP group of the database administrator
|
|
|
|
# MYSQL_DATADIR home directory of the database administrator and
|
|
|
|
# location of the databases
|
2014-04-14 02:02:49 +02:00
|
|
|
# MYSQL_PIDFILE process ID file
|
2010-03-04 17:27:18 +01:00
|
|
|
MYSQL_USER?= mysql
|
|
|
|
MYSQL_GROUP?= mysql
|
|
|
|
MYSQL_DATADIR?= ${VARBASE}/mysql
|
2014-04-14 02:02:49 +02:00
|
|
|
MYSQL_PIDFILE?= ${MYSQL_DATADIR}/${HOST}.pid
|
2010-03-04 17:27:18 +01:00
|
|
|
|
|
|
|
PKG_USERS_VARS+= MYSQL_USER
|
|
|
|
PKG_GROUPS_VARS+= MYSQL_GROUP
|
|
|
|
|
|
|
|
# MYSQL_CHARSET default character set
|
|
|
|
# MYSQL_EXTRA_CHARSET additional character set to be compiled in.
|
|
|
|
MYSQL_CHARSET?= latin1
|
|
|
|
MYSQL_EXTRA_CHARSET?= all
|
|
|
|
|
2010-03-21 15:39:27 +01:00
|
|
|
CONFIGURE_ARGS+= --enable-thread-safe-client
|
Changes 5.1.71:
Functionality Added or Changed
* comp_err now checks to make sure that new errors are not being added to MySQL 5.1 or 5.5 because the set of errors for these series is frozen.
Bugs Fixed
* InnoDB: During an insert buffer merge, InnoDB would invoke lock_rec_restore_from_page_infimum() on a potentially invalid record pointer.
* InnoDB: The page_zip_validate() consistency check would fail after compressing a page, in page_zip_compress(). This problem was caused by page_zip_decompress(), which would fail to set heap_no correctly when a record contained no user data bytes. A record with no user data bytes occurs when, for example, a primary key is an empty string and all secondary index fields are NULL or an empty string.
* InnoDB: The pthread_mutex, commit_threads_m, which was initialized but never used, has been removed from the code base.
* Partitioning: When dropping a partitioned table, the table's .par file was deleted first, before the table definition or data. This meant that, if the server failed during the drop operation, the table could be left in an inconsistent state in which it could neither be accessed nor dropped.
* Shared-compatibility conflict errors occurred for RPM install operations, even if no shared-compatibility RPMs were already installed.
* A user variable referenced during execution of a prepared statement is set to memory that is freed at the end of execution. A second execution of the statement could result in Valgrind warnings when accessing this memory.
* Misoptimization of left expressions in prepared statements could cause a server exit.
* Subsequent to Prepared statement needs to be re-prepared errors, inserts into DECIMAL columns caused a server exit.
* Assigning the result of a subquery to a user variable raised an assertion when the outer query included DISTINCT and GROUP BY.
2013-08-04 12:20:24 +02:00
|
|
|
CONFIGURE_ARGS+= --localstatedir=${MYSQL_DATADIR}
|
2010-03-04 17:27:18 +01:00
|
|
|
CONFIGURE_ARGS+= --without-libwrap
|
|
|
|
CONFIG_SHELL= ${TOOLS_PATH.bash}
|
|
|
|
|
2016-02-25 12:46:20 +01:00
|
|
|
CFLAGS.IRIX+= -DIRIX5 -DNEEDS_BSTRING_H
|
2010-03-04 17:27:18 +01:00
|
|
|
# libgen is incorrectly detected
|
2016-02-25 12:46:20 +01:00
|
|
|
CONFIGURE_ENV.IRIX+= ac_cv_lib_gen_p2open="no"
|
2010-03-04 17:27:18 +01:00
|
|
|
|
|
|
|
BUILD_DEFS+= VARBASE
|
|
|
|
|
|
|
|
# We always use our own readline. Note that these --without-* settings
|
|
|
|
# are confusing, but they just mean "don't use the included readline
|
|
|
|
# or libedit".
|
|
|
|
CONFIGURE_ARGS+= --without-readline
|
|
|
|
CONFIGURE_ARGS+= --without-libedit
|
|
|
|
|
|
|
|
# Speed up production one-time builds; see "./configure --help" for
|
|
|
|
# more information on using or disabling this option.
|
|
|
|
CONFIGURE_ARGS+= --disable-dependency-tracking
|
|
|
|
|
|
|
|
CONFIGURE_ARGS+= --without-debug
|
|
|
|
CONFIGURE_ARGS+= --with-low-memory
|
Changes 5.1.71:
Functionality Added or Changed
* comp_err now checks to make sure that new errors are not being added to MySQL 5.1 or 5.5 because the set of errors for these series is frozen.
Bugs Fixed
* InnoDB: During an insert buffer merge, InnoDB would invoke lock_rec_restore_from_page_infimum() on a potentially invalid record pointer.
* InnoDB: The page_zip_validate() consistency check would fail after compressing a page, in page_zip_compress(). This problem was caused by page_zip_decompress(), which would fail to set heap_no correctly when a record contained no user data bytes. A record with no user data bytes occurs when, for example, a primary key is an empty string and all secondary index fields are NULL or an empty string.
* InnoDB: The pthread_mutex, commit_threads_m, which was initialized but never used, has been removed from the code base.
* Partitioning: When dropping a partitioned table, the table's .par file was deleted first, before the table definition or data. This meant that, if the server failed during the drop operation, the table could be left in an inconsistent state in which it could neither be accessed nor dropped.
* Shared-compatibility conflict errors occurred for RPM install operations, even if no shared-compatibility RPMs were already installed.
* A user variable referenced during execution of a prepared statement is set to memory that is freed at the end of execution. A second execution of the statement could result in Valgrind warnings when accessing this memory.
* Misoptimization of left expressions in prepared statements could cause a server exit.
* Subsequent to Prepared statement needs to be re-prepared errors, inserts into DECIMAL columns caused a server exit.
* Assigning the result of a subquery to a user variable raised an assertion when the outer query included DISTINCT and GROUP BY.
2013-08-04 12:20:24 +02:00
|
|
|
CONFIGURE_ARGS+= --with-zlib-dir=${BUILDLINK_PREFIX.zlib}
|
2010-03-04 17:27:18 +01:00
|
|
|
CONFIGURE_ARGS+= --with-charset=${MYSQL_CHARSET:Q}
|
|
|
|
CONFIGURE_ARGS+= --with-extra-charsets=${MYSQL_EXTRA_CHARSET:Q}
|
|
|
|
|
|
|
|
.if !empty(MACHINE_ARCH:Mi386) && ${OPSYS} != "Interix" && \
|
|
|
|
${OPSYS} != "SunOS" && ${OPSYS} != "Darwin"
|
|
|
|
CONFIGURE_ARGS+= --enable-assembler
|
|
|
|
.endif
|
|
|
|
|
2010-04-08 17:31:55 +02:00
|
|
|
# MySQL 5.1 depends on builtin functions which enabled with i486 and
|
|
|
|
# later with GCC.
|
|
|
|
.if ${OPSYS} == "NetBSD" && !empty(MACHINE_ARCH:Mi386)
|
|
|
|
GNU_ARCH.i386= i486
|
|
|
|
CFLAGS+= -march=i486
|
|
|
|
.endif
|
|
|
|
|
2016-02-25 12:46:20 +01:00
|
|
|
CONFIGURE_ENV.NetBSD+= ac_cv_func_gethostbyname_r="no"
|
2014-05-28 12:16:54 +02:00
|
|
|
|
2010-03-04 17:27:18 +01:00
|
|
|
CONFIGURE_ENV+= mysql_cv_compress="yes"
|
|
|
|
|
|
|
|
CPPFLAGS+= -Dunix
|
|
|
|
CFLAGS+= -DUSE_OLD_FUNCTIONS # 3.23.x compat
|
|
|
|
|
2010-04-30 08:03:36 +02:00
|
|
|
.if ${OPSYS} != "Interix"
|
2010-03-16 20:24:54 +01:00
|
|
|
CFLAGS+= -fPIC -DPIC
|
|
|
|
CXXFLAGS+= -fPIC -DPIC
|
2010-04-30 08:03:36 +02:00
|
|
|
.endif
|
2010-03-16 20:24:54 +01:00
|
|
|
|
2010-03-04 17:27:18 +01:00
|
|
|
# force HAVE_CURSES_H on Solaris since the configure script is broken
|
|
|
|
# and does not properly detect this, breaking the build later on.
|
2016-02-25 12:46:20 +01:00
|
|
|
CFLAGS.SunOS+= -DHAVE_CURSES_H
|
|
|
|
CXXFLAGS.SunOS+= -DHAVE_CURSES_H
|
2010-03-04 17:27:18 +01:00
|
|
|
|
|
|
|
.include "../../mk/pthread.buildlink3.mk"
|
|
|
|
|
|
|
|
.if defined(PTHREAD_TYPE) && (${PTHREAD_TYPE} == "pth")
|
|
|
|
CFLAGS+= -DSIGNALS_DONT_BREAK_READ
|
|
|
|
CXXFLAGS+= -DSIGNALS_DONT_BREAK_READ
|
|
|
|
CONFIGURE_ENV+= ac_cv_func_pthread_setschedparam=no
|
|
|
|
CONFIGURE_ENV+= ac_cv_func_pthread_attr_setschedparam=no
|
|
|
|
.endif
|
|
|
|
|
2018-02-02 00:14:55 +01:00
|
|
|
USE_LANGUAGES= c c++03
|
2010-03-04 17:27:18 +01:00
|
|
|
USE_TOOLS+= autoconf bash autoheader gmake perl:run
|
|
|
|
LDFLAGS+= ${COMPILER_RPATH_FLAG}${PREFIX}/lib/mysql
|
|
|
|
|
2012-03-09 12:55:11 +01:00
|
|
|
# reset the platform diff on SunOS unless it's a GNU diff
|
2013-04-08 13:17:08 +02:00
|
|
|
# which is required by the MySQL build
|
2012-03-09 12:55:11 +01:00
|
|
|
.if ${OPSYS} == "SunOS" && empty(TOOLS_PLATFORM.diff:Mgdiff)
|
|
|
|
TOOLS_PLATFORM.diff= # empty
|
|
|
|
.endif
|
|
|
|
|
Changes 5.1.71:
Functionality Added or Changed
* comp_err now checks to make sure that new errors are not being added to MySQL 5.1 or 5.5 because the set of errors for these series is frozen.
Bugs Fixed
* InnoDB: During an insert buffer merge, InnoDB would invoke lock_rec_restore_from_page_infimum() on a potentially invalid record pointer.
* InnoDB: The page_zip_validate() consistency check would fail after compressing a page, in page_zip_compress(). This problem was caused by page_zip_decompress(), which would fail to set heap_no correctly when a record contained no user data bytes. A record with no user data bytes occurs when, for example, a primary key is an empty string and all secondary index fields are NULL or an empty string.
* InnoDB: The pthread_mutex, commit_threads_m, which was initialized but never used, has been removed from the code base.
* Partitioning: When dropping a partitioned table, the table's .par file was deleted first, before the table definition or data. This meant that, if the server failed during the drop operation, the table could be left in an inconsistent state in which it could neither be accessed nor dropped.
* Shared-compatibility conflict errors occurred for RPM install operations, even if no shared-compatibility RPMs were already installed.
* A user variable referenced during execution of a prepared statement is set to memory that is freed at the end of execution. A second execution of the statement could result in Valgrind warnings when accessing this memory.
* Misoptimization of left expressions in prepared statements could cause a server exit.
* Subsequent to Prepared statement needs to be re-prepared errors, inserts into DECIMAL columns caused a server exit.
* Assigning the result of a subquery to a user variable raised an assertion when the outer query included DISTINCT and GROUP BY.
2013-08-04 12:20:24 +02:00
|
|
|
SUBST_CLASSES+= mk
|
2010-03-04 17:27:18 +01:00
|
|
|
SUBST_STAGE.mk= pre-configure
|
|
|
|
SUBST_FILES.mk= dbug/Makefile.in heap/Makefile.in \
|
|
|
|
mysys/Makefile.in strings/Makefile.in
|
|
|
|
SUBST_SED.mk= -e "/^install-exec:/s/install-pkglibLIBRARIES//"
|
|
|
|
SUBST_MESSAGE.mk= Fixing Makefiles.
|
|
|
|
|
|
|
|
SUBST_CLASSES+= scr
|
|
|
|
SUBST_STAGE.scr= pre-configure
|
|
|
|
SUBST_FILES.scr= scripts/mysql_install_db.sh scripts/mysqld_safe.sh \
|
|
|
|
scripts/mysql_secure_installation.sh \
|
|
|
|
support-files/mysql.server.sh
|
|
|
|
SUBST_SED.scr= -e "s,chown,${CHOWN},g"
|
|
|
|
SUBST_SED.scr+= -e "s,/bin/sh,${RCD_SCRIPTS_SHELL},g"
|
|
|
|
SUBST_MESSAGE.scr= Fixing scripts.
|
|
|
|
|
|
|
|
# Fix broken shared library detection under Mac OS X
|
2016-02-25 12:46:20 +01:00
|
|
|
SUBST_CLASSES.Darwin+= dylib
|
2010-03-04 17:27:18 +01:00
|
|
|
SUBST_STAGE.dylib= pre-configure
|
|
|
|
SUBST_FILES.dylib= configure
|
|
|
|
SUBST_SED.dylib= -e "s|\\\$$shrext_cmds|\\.dylib|g"
|
|
|
|
|
|
|
|
pre-configure:
|
|
|
|
${RM} -f ${WRKSRC}/configure~
|
|
|
|
cd ${WRKSRC} && autoconf && autoheader
|
|
|
|
|
2017-05-05 18:22:28 +02:00
|
|
|
.include "../../mk/curses.buildlink3.mk"
|
2010-03-04 17:27:18 +01:00
|
|
|
.include "../../devel/zlib/buildlink3.mk"
|