SELinux Archive on lore.kernel.org
 help / color / Atom feed
From: Nicolas Iooss <nicolas.iooss@m4x.org>
To: "Đoàn Trần Công Danh" <congdanhqx@gmail.com>
Cc: SElinux list <selinux@vger.kernel.org>
Subject: Re: [PATCH] libselinux: utils: link with shared libfts
Date: Fri, 22 May 2020 20:59:43 +0200
Message-ID: <CAJfZ7==OdP23Mh06V=qaktKas3wOkz12=ZELj5vOHsDN1t_5vw@mail.gmail.com> (raw)
In-Reply-To: <20200522074648.24538-1-congdanhqx@gmail.com>

On Fri, May 22, 2020 at 9:46 AM Đoàn Trần Công Danh
<congdanhqx@gmail.com> wrote:
>
> On Linux with musl libc, libfts isn't shipped with libc.
> Hence, we link with $(FTS_LIBS) in src.
>
> Some (most) musl-based distribution choose to ship libfts as
> a standalone shared object because their libfts is licensed under either
> very permissive license or that implementation of libfts requires
> attribution in every usage.
>
> Always link with $(FTS_LIBS) in utils to prevent undefined reference
> problem on those platforms.
>
> Signed-off-by: Đoàn Trần Công Danh <congdanhqx@gmail.com>
> ---
>  libselinux/utils/Makefile | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/libselinux/utils/Makefile b/libselinux/utils/Makefile
> index aa2d3e1b..1a7da223 100644
> --- a/libselinux/utils/Makefile
> +++ b/libselinux/utils/Makefile
> @@ -45,6 +45,8 @@ override CFLAGS += -I../include -D_GNU_SOURCE $(DISABLE_FLAGS) $(PCRE_CFLAGS)
>  override LDFLAGS += -L../src
>  override LDLIBS += -lselinux $(FTS_LDLIBS)
>  PCRE_LDLIBS ?= -lpcre
> +FTS_LDLIBS ?=
> +override LDLIBS += $(FTS_LDLIBS)

Hello,
A few lines above there already is "override LDLIBS += -lselinux
$(FTS_LDLIBS)". Why do you need to add $(FTS_LDLIBS) to LDLIBS again?

Thanks,
Nicolas


  reply index

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-22  7:46 Đoàn Trần Công Danh
2020-05-22 18:59 ` Nicolas Iooss [this message]
2020-05-23  1:23   ` Đoàn Trần Công Danh

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='CAJfZ7==OdP23Mh06V=qaktKas3wOkz12=ZELj5vOHsDN1t_5vw@mail.gmail.com' \
    --to=nicolas.iooss@m4x.org \
    --cc=congdanhqx@gmail.com \
    --cc=selinux@vger.kernel.org \
    /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

SELinux Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/selinux/0 selinux/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 selinux selinux/ https://lore.kernel.org/selinux \
		selinux@vger.kernel.org
	public-inbox-index selinux

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.selinux


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git