wireguard.lists.zx2c4.com archive mirror
 help / color / mirror / Atom feed
From: Phil Sutter <phil@nwl.cc>
To: Hangbin Liu <liuhangbin@gmail.com>
Cc: "Jason A. Donenfeld" <Jason@zx2c4.com>,
	netdev@vger.kernel.org, Jakub Kicinski <kuba@kernel.org>,
	Shuah Khan <shuah@kernel.org>,
	"David S. Miller" <davem@davemloft.net>,
	Simon Horman <horms@kernel.org>, Florian Westphal <fw@strlen.de>,
	Petr Mladek <pmladek@suse.com>,
	Yoann Congal <yoann.congal@smile.fr>,
	wireguard@lists.zx2c4.com, bpf@vger.kernel.org,
	linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCHv4 RESEND net-next 2/2] selftests: wireguard: update to using nft for qemu test
Date: Fri, 21 Mar 2025 15:40:20 +0100	[thread overview]
Message-ID: <Z916VMSCEtinZl54@orbyte.nwl.cc> (raw)
In-Reply-To: <Z91fXURX3BQFDaq9@fedora>

On Fri, Mar 21, 2025 at 12:45:17PM +0000, Hangbin Liu wrote:
> On Fri, Mar 21, 2025 at 12:42:42PM +0100, Phil Sutter wrote:
> > Hi Hangbin,
> > 
> > On Fri, Mar 21, 2025 at 10:40:25AM +0000, Hangbin Liu wrote:
> > > Hi Jason, Phil,
> > > On Wed, Mar 19, 2025 at 05:15:41PM +0100, Jason A. Donenfeld wrote:
> > > > On Mon, Jan 06, 2025 at 08:10:43AM +0000, Hangbin Liu wrote:
> > > > > +	echo "file /bin/nft $(NFTABLES_PATH)/src/nft 755 0 0" >> $@
> > > > > +	echo "file /lib/libmnl.so.0 $(TOOLCHAIN_PATH)/lib/libmnl.so.0 755 0 0" >> $@
> > > > > +	echo "file /lib/libnftnl.so.11 $(TOOLCHAIN_PATH)/lib/libnftnl.so.11 755 0 0" >> $@
> > > > 
> > > > Can't these be statically linked into the nft binary?
> > > 
> > > If I omit these, I will got error like
> > > 
> > > mnl_attr_put: symbol not found
> > > 
> > > Even though I set `--enable-static` in nft build.
> > > 
> > > Do you know what's the reason?
> > 
> > I was able to have nft linked statically against built libmnl and
> > libnftnl by passing '--disable-shared --enable-static' to configure
> > calls of all three build systems. With --enable-shared in library
> > configure calls, nftables build preferred to link against the DSOs and I
> > did not find a way to change this.
> 
> The patch is using
> "./configure --prefix=/ $(CROSS_COMPILE_FLAG) --enable-static \
> --disable-shared --disable-debug --disable-man-doc --with-mini-gmp --without-cli"
> to build nft.

Do you pass that to the configure calls for libnftnl and libmnl, too? I
didn't find a way to force static linking in nftables build system, so I
disabled building of shared libmnl/libnftnl libraries.

Cheers, Phil

  parent reply	other threads:[~2025-05-21  9:18 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-06  8:10 [PATCHv4 RESEND net-next 0/2] selftests: wireguards: use nftables for testing Hangbin Liu
2025-01-06  8:10 ` [PATCHv4 RESEND net-next 1/2] selftests: wireguards: convert iptables to nft Hangbin Liu
2025-01-06  8:10 ` [PATCHv4 RESEND net-next 2/2] selftests: wireguard: update to using nft for qemu test Hangbin Liu
2025-03-19 16:15   ` Jason A. Donenfeld
     [not found]     ` <Z91CGRP9QLdZONiZ@fedora>
2025-03-21 11:42       ` Phil Sutter
2025-03-21 12:45         ` Hangbin Liu
2025-03-21 12:51           ` Jason A. Donenfeld
2025-03-21 14:40           ` Phil Sutter [this message]
2025-03-22  9:25             ` Hangbin Liu
2025-03-18 10:24 ` [PATCHv4 RESEND net-next 0/2] selftests: wireguards: use nftables for testing Hangbin Liu
     [not found]   ` <Z9rso2MXYBFGnJYl@zx2c4.com>
2025-03-20  7:40     ` Hangbin Liu

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=Z916VMSCEtinZl54@orbyte.nwl.cc \
    --to=phil@nwl.cc \
    --cc=Jason@zx2c4.com \
    --cc=bpf@vger.kernel.org \
    --cc=davem@davemloft.net \
    --cc=fw@strlen.de \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=liuhangbin@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=pmladek@suse.com \
    --cc=shuah@kernel.org \
    --cc=wireguard@lists.zx2c4.com \
    --cc=yoann.congal@smile.fr \
    /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;
as well as URLs for NNTP newsgroup(s).