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 v4 1/1] package/multipath-tools: new package
Date: Sat, 5 Sep 2020 21:58:37 +0200	[thread overview]
Message-ID: <20200905215837.1851ab18@windsurf.home> (raw)
In-Reply-To: <20200905192015.1346-1-egorenar-dev@posteo.net>

Hello Aleksander,

On Sat,  5 Sep 2020 21:20:15 +0200
Alexander Egorenkov <egorenar-dev@posteo.net> wrote:

> Signed-off-by: Alexander Egorenkov <egorenar-dev@posteo.net>

Thanks for this new iteration. Unfortunately, it still doesn't build
here :-/

I get:

uxsock.c:20:10: fatal error: systemd/sd-daemon.h: No such file or directory
 #include <systemd/sd-daemon.h>
          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.

This is due to how SYSTEMD is detected:

ifndef SYSTEMD
        ifeq ($(shell pkg-config --modversion libsystemd >/dev/null 2>&1 && echo 1), 1)
                SYSTEMD = $(shell pkg-config --modversion libsystemd)
        else
                ifeq ($(shell systemctl --version >/dev/null 2>&1 && echo 1), 1)
                        SYSTEMD = $(shell systemctl --version 2> /dev/null | \
                                sed -n 's/systemd \([0-9]*\).*/\1/p')
                endif
        endif
endif

Indeed, if systemd is found using pkg-config, then it falls back to
using systemctl.. and since my Fedora uses systemd, the multipath-tools
build system thinks it should enable systemd support.. but I don't have
systemd enabled in my Buildroot configuration.

And the problem is that there is no way to explicitly disable SYSTEMD
support...

Also, there are two other things that we should pass explicitly. If you
look at the Makefile, it does this:

ifndef LIB
        ifeq ($(shell test -d /lib64 && echo 1),1)
                LIB=lib64
        else
                LIB=lib
        endif
endif

ifndef RUN
        ifeq ($(shell test -L /var/run -o ! -d /var/run && echo 1),1)
                RUN=run
        else
                RUN=var/run
        endif
endif

So for LIB and RUN, it looks at what exists on the build machine...
which doesn't make sense when cross-compiling. So I think we want t
pass LIB=lib and RUN=run explicitly.

Could you have a look at the systemd ? Just build a Buildroot
configuration without systemd, on a build machine that uses systemd,
and you'll get the failure.

Thanks!

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

  reply	other threads:[~2020-09-05 19:58 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-05 19:20 [Buildroot] [PATCH v4 1/1] package/multipath-tools: new package Alexander Egorenkov
2020-09-05 19:58 ` Thomas Petazzoni [this message]
2020-09-05 20:03   ` Alexander Egorenkov
2020-09-05 21:10   ` Alexander Egorenkov
2020-09-06  9:31   ` Alexander Egorenkov

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=20200905215837.1851ab18@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