[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20201116035515.GF2408@dhcp-12-153.nay.redhat.com>
Date: Mon, 16 Nov 2020 11:55:15 +0800
From: Hangbin Liu <haliu@...hat.com>
To: David Ahern <dsahern@...il.com>
Cc: netdev@...r.kernel.org, bpf@...r.kernel.org
Subject: Re: [PATCHv4 iproute2-next 2/5] lib: rename bpf.c to bpf_legacy.c
On Fri, Nov 13, 2020 at 08:24:41PM -0700, David Ahern wrote:
> On 11/9/20 12:07 AM, Hangbin Liu wrote:
> > diff --git a/lib/bpf_glue.c b/lib/bpf_glue.c
> > new file mode 100644
> > index 00000000..7626a893
> > --- /dev/null
> > +++ b/lib/bpf_glue.c
>
> ...
>
> > +
> > +int bpf_program_load(enum bpf_prog_type type, const struct bpf_insn *insns,
> > + size_t size_insns, const char *license, char *log,
> > + size_t size_log)
> > +{
> > +#ifdef HAVE_LIBBPF
> > + return bpf_load_program(type, insns, size_insns, license, 0, log, size_log);
> > +#else
> > + return bpf_load_load_dev(type, insns, size_insns, license, 0, log, size_log);
> > +#endif
> > +}
> > +
>
> Fails to compile:
>
> $ LIBBPF_FORCE=off ./configure
> $ make
> ...
> /usr/bin/ld: ../lib/libutil.a(bpf_glue.o): in function `bpf_program_load':
> bpf_glue.c:(.text+0x13): undefined reference to `bpf_load_load_dev'
Opps, sorry for the typo...
Powered by blists - more mailing lists