Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH 1/1] package/libodb-mysql: fix static build
Date: Tue, 14 Jul 2020 14:46:28 +0200	[thread overview]
Message-ID: <20200714144628.223b7fe5@windsurf.home> (raw)
In-Reply-To: <CAPi7W82G3K_FEJbdSjUJZs8FfKkFjrDoY8jHqKft0hk4ENOLHw@mail.gmail.com>

On Tue, 14 Jul 2020 10:33:37 +0200
Fabrice Fontaine <fontaine.fabrice@gmail.com> wrote:

> I basically copy/pasted the solution that was applied to the open2300
> package 4 years ago:
> https://git.buildroot.net/buildroot/commit/package/open2300?id=382fa60f9c7445e962b290c74779a0e0fd7e310f

Wow, I looked into this, and what I found is not pretty. It turns out
that when there's no zlib available, MySQL builds its own copy, and
installs it in $(STAGING_DIR). We can see during the MySQL configure:

checking for zlib compression library... system-wide zlib not found, using one bundled with MySQL

So to me, it seems like we should fix this, using the following option:

  --with-zlib-dir=no|bundled|DIR
                          Provide MySQL with a custom location of compression
                          library. Given DIR, zlib binary is assumed to be in
                          $DIR/lib and header files in $DIR/include.

I.e probably:

ifeq ($(BR2_PACKAGE_ZLIB),y)
ORACLE_MYSQL_CONF_OPTS += --with-zlib-dir=$(STAGING_DIR)/usr
ORACLE_MYSQL_DEPENDENCIES += zlib
else
ORACLE_MYSQL_CONF_OPTS += --without-zlib-dir
endif

and of course check in the latter case that it really builds without
zlib.

Could you have a look into this ?

Thomas
-- 
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

  reply	other threads:[~2020-07-14 12:46 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-13 21:59 [Buildroot] [PATCH 1/1] package/libodb-mysql: fix static build Fabrice Fontaine
2020-07-14  8:20 ` Thomas Petazzoni
2020-07-14  8:33   ` Fabrice Fontaine
2020-07-14 12:46     ` Thomas Petazzoni [this message]
  -- strict thread matches above, loose matches on Subject: below --
2020-12-14 21:43 Fabrice Fontaine
2020-12-31 16:42 ` Thomas Petazzoni
2021-01-05 21:38 ` Peter Korsgaard

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=20200714144628.223b7fe5@windsurf.home \
    --to=thomas.petazzoni@bootlin.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