netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Daniel Borkmann <daniel@iogearbox.net>
To: Jakub Kicinski <jakub.kicinski@netronome.com>, netdev@vger.kernel.org
Cc: oss-drivers@netronome.com, alexei.starovoitov@gmail.com, acme@redhat.com
Subject: Re: [PATCH net-next v2] bpf: install libbpf headers on 'make install'
Date: Tue, 25 Jul 2017 21:45:28 +0200	[thread overview]
Message-ID: <59779FD8.7070107@iogearbox.net> (raw)
In-Reply-To: <20170725181711.21236-1-jakub.kicinski@netronome.com>

On 07/25/2017 08:17 PM, Jakub Kicinski wrote:
> Add a new target to install the bpf.h header to $(prefix)/include/bpf/
> directory.  This is necessary to build standalone applications using
> libbpf, without the need to clone the kernel sources and point to them.
>
> Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>

Looks good to me, we might do the same for libbpf.h later on as
well, though the naming scheme is a confusing choice (bpf.h and
libbpf.h).

Acked-by: Daniel Borkmann <daniel@iogearbox.net>

> ---
> v2:
>   - make the header installation similar to tools/lib/traceevent (Daniel).
>
> The functional change is that the header will not be installed as part
> of make install, one has to make install_headers, which seems OK.
>
> Out of curiosity - why are only "force elfdep bpfdep" added to the PHONY
> target?  Is there some Makefile magic that makes adding install* targets
> there unnecessary?  Or does the PHONY target just not matter in practice
> so it's not updated?

Arnaldo might know better.

>   tools/lib/bpf/Makefile | 4 ++++
>   1 file changed, 4 insertions(+)
>
> diff --git a/tools/lib/bpf/Makefile b/tools/lib/bpf/Makefile
> index 1f5300e56b44..445289555487 100644
> --- a/tools/lib/bpf/Makefile
> +++ b/tools/lib/bpf/Makefile
> @@ -189,6 +189,10 @@ install_lib: all_cmd
>   	$(call QUIET_INSTALL, $(LIB_FILE)) \
>   		$(call do_install,$(LIB_FILE),$(libdir_SQ))
>
> +install_headers:
> +	$(call QUIET_INSTALL, headers) \
> +		$(call do_install,bpf.h,$(prefix)/include/bpf,644)
> +
>   install: install_lib
>
>   ### Cleaning rules
>

  reply	other threads:[~2017-07-25 19:45 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-24 21:22 [PATCH net-next] bpf: install libbpf headers on 'make install' Jakub Kicinski
2017-07-25 16:51 ` Daniel Borkmann
2017-07-25 18:17 ` [PATCH net-next v2] " Jakub Kicinski
2017-07-25 19:45   ` Daniel Borkmann [this message]
2017-07-26 20:43   ` David Miller

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=59779FD8.7070107@iogearbox.net \
    --to=daniel@iogearbox.net \
    --cc=acme@redhat.com \
    --cc=alexei.starovoitov@gmail.com \
    --cc=jakub.kicinski@netronome.com \
    --cc=netdev@vger.kernel.org \
    --cc=oss-drivers@netronome.com \
    /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).