From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH] mysql server and client 5.1.x and 5.5.x
Date: Sat, 4 Jun 2011 10:52:04 +0200 [thread overview]
Message-ID: <20110604105204.543ebf70@surf> (raw)
In-Reply-To: <383b905e1557b0da1bc0cdb5b9e5bab7dbace620.1306605163.git.smiley73@users.sourceforge.net>
Hello Heiko!
Thanks for taking care of the MySQL package. I have a few comments
below, but first, is there a good reason to support both MySQL 5.1 and
MySQL 5.5 ? Wouldn't supporting MySQL 5.5 be enough ?
On Sat, 28 May 2011 12:56:20 -0500
heiko at zuerker.org wrote:
> diff --git a/package/mysql/Config.in b/package/mysql/Config.in
> new file mode 100644
> index 0000000..3c44ec3
> --- /dev/null
> +++ b/package/mysql/Config.in
> @@ -0,0 +1,91 @@
> +config BR2_PACKAGE_MYSQL
> + bool "MySQL"
> + depends on BR2_INSTALL_LIBSTDCPP
> + select BR2_PACKAGE_NCURSES
> + select BR2_PACKAGE_READLINE
> + help
> + MySQL client and optional server
> +
> +menu "MySQL options"
> +depends on BR2_PACKAGE_MYSQL
> +
> +choice
> + prompt "MySQL Version"
> + default BR2_PACKAGE_MYSQL_51
> + help
> + The version of MySQL
> +
> +config BR2_PACKAGE_MYSQL_51
> + bool "5.1.x"
> + select BR2_TARGET_SYSLINUX
> +
> +config BR2_PACKAGE_MYSQL_55
> + bool "5.5.x"
> +
> +endchoice
> +
> +config BR2_PACKAGE_MYSQL_SERVER
> + bool "Build the MySQL Server"
> + depends on BR2_INSTALL_LIBSTDCPP && BR2_PACKAGE_MYSQL
> + select BR2_PACKAGE_NCURSES
> + select BR2_PACKAGE_READLINE
Since this depends on BR2_PACKAGE_MYSQL, which already selects ncurses
and readline, do we really need those selects again ?
> diff --git a/package/mysql/mysql-5.5.12/mysql-5.5.11-tool-path.patch b/package/mysql/mysql-5.5.12/mysql-5.5.11-tool-path.patch
> new file mode 100644
> index 0000000..03de86d
> --- /dev/null
> +++ b/package/mysql/mysql-5.5.12/mysql-5.5.11-tool-path.patch
This patch needs a description + Signed-off-by line.
> --- /dev/null
> +++ b/package/mysql/mysql.mk
> @@ -0,0 +1,143 @@
> +#############################################################
> +#
> +# MySQL Server & Client
> +#
> +#############################################################
> +
> +ifeq ($(BR2_PACKAGE_MYSQL_51),y)
> + MYSQL_MAIN_VERSION = 5.1
> + MYSQL_VERSION = $(MYSQL_MAIN_VERSION).57
> +endif
> +
> +ifeq ($(BR2_PACKAGE_MYSQL_55),y)
> + MYSQL_MAIN_VERSION = 5.5
> + MYSQL_VERSION = $(MYSQL_MAIN_VERSION).12
> +endif
> +
> +MYSQL_SOURCE = mysql-$(MYSQL_VERSION).tar.gz
> +MYSQL_SITE = http://mirror.services.wisc.edu/mysql/Downloads/MySQL-$(MYSQL_MAIN_VERSION)
> +MYSQL_INSTALL_TARGET = YES
> +MYSQL_INSTALL_STAGING = YES
> +MYSQL_DEPENDENCIES = readline ncurses host-mysql
Could you detail why host-mysql is needed as a dependency ? (For
example by adding a comment).
> + -DMYSQL_DATADIR=/var/mysql
What about using the configuration option for the data directory ?
> +# Generic section
> +define MYSQL_REMOVE_TEST_PROGS
> + rm -rf $(TARGET_DIR)/usr/mysql-test $(TARGET_DIR)/usr/sql-bench
> +endef
> +
> +define MYSQL_ADD_MYSQL_LIB_PATH
> + echo "/usr/lib/mysql" >> $(TARGET_DIR)/etc/ld.so.conf
> +endef
> +
> +ifeq ($(BR2_PACKAGE_MYSQL_REMOVE_TEST_PROGS),y)
> + MYSQL_POST_INSTALL_TARGET_HOOKS += MYSQL_REMOVE_TEST_PROGS
> +endif
> +
> +MYSQL_POST_INSTALL_TARGET_HOOKS += MYSQL_ADD_MYSQL_LIB_PATH
> +
> +MYSQL_POST_CONFIGURE_HOOKS += MYSQL_COPY_HOST_BINARIES
> +
> +define MYSQL_COPY_HOST_BINARIES
> + cp $(@D)/../host-mysql-$(MYSQL_VERSION)/sql/gen_lex_hash $(@D)/sql/
> + cp $(@D)/../host-mysql-$(MYSQL_VERSION)/scripts/comp_sql $(@D)/scripts/
> + cp $(@D)/../host-mysql-$(MYSQL_VERSION)/extra/comp_err $(@D)/extra/
> + # set the file dates far into the future to prevent recompilation
> + touch -t "203012120101" $(@D)/sql/gen_lex_hash
> + touch -t "203012120101" $(@D)/scripts/comp_sql
> + touch -t "203012120101" $(@D)/extra/comp_err
> +endef
> +
> +define HOST_MYSQL_BUILD_CMDS
> + make -C $(@D)/vio
> + make -C $(@D)/mysys
> + make -C $(@D)/strings
> + make -C $(@D)/dbug
> + make -C $(@D)/regex
> + make -C $(@D)/sql gen_lex_hash
> + make -C $(@D)/scripts comp_sql
> + make -C $(@D)/extra comp_err
> +endef
> +
> +define HOST_MYSQL_INSTALL_CMDS
> + # no need to really install this
> + exit 0
Really ?
> +endef
Normally, all those definitions should be before the
AUTOTARGETS/CMAKETARGETS calls.
Regards,
Thomas
--
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
next prev parent reply other threads:[~2011-06-04 8:52 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-28 17:56 [Buildroot] [PATCH] mysql server and client 5.1.x and 5.5.x heiko at zuerker.org
2011-06-04 8:52 ` Thomas Petazzoni [this message]
2011-06-04 13:48 ` Heiko Zuerker
2011-07-09 13:19 ` Heiko Zuerker
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20110604105204.543ebf70@surf \
--to=thomas.petazzoni@free-electrons.com \
--cc=buildroot@busybox.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox