dwarves.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH dwarves 1/2] libbpf: if LIBBPF_EMBEDDED=OFF and libbpf-dev/pkgconfig is not available, fail the build
@ 2021-06-13 13:47 Luca Boccassi
  2021-06-13 13:47 ` [PATCH dwarves 2/2] libbpf: bump dependency to >= 0.4.0 Luca Boccassi
  2021-06-14 18:34 ` [PATCH dwarves 1/2] libbpf: if LIBBPF_EMBEDDED=OFF and libbpf-dev/pkgconfig is not available, fail the build Arnaldo Carvalho de Melo
  0 siblings, 2 replies; 3+ messages in thread
From: Luca Boccassi @ 2021-06-13 13:47 UTC (permalink / raw)
  To: dwarves; +Cc: arnaldo.melo

If using the system library was explicitly requested, ensure it is present
and fail the build if it is not, rather than falling back to the
embedded version (same for pkg-config).

Signed-off-by: Luca Boccassi <bluca@debian.org>
---
 CMakeLists.txt | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 669ea59..0f967d1 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -4,9 +4,9 @@ cmake_policy(SET CMP0005 NEW)
 
 option(LIBBPF_EMBEDDED "Use the embedded version of libbpf instead of searching it via pkg-config" ON)
 if (NOT LIBBPF_EMBEDDED)
-	find_package(PkgConfig)
+	find_package(PkgConfig REQUIRED)
 	if(PKGCONFIG_FOUND)
-		pkg_check_modules(LIBBPF libbpf>=0.3.0)
+		pkg_check_modules(LIBBPF REQUIRED libbpf>=0.3.0)
 	endif()
 endif()
 
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [PATCH dwarves 2/2] libbpf: bump dependency to >= 0.4.0
  2021-06-13 13:47 [PATCH dwarves 1/2] libbpf: if LIBBPF_EMBEDDED=OFF and libbpf-dev/pkgconfig is not available, fail the build Luca Boccassi
@ 2021-06-13 13:47 ` Luca Boccassi
  2021-06-14 18:34 ` [PATCH dwarves 1/2] libbpf: if LIBBPF_EMBEDDED=OFF and libbpf-dev/pkgconfig is not available, fail the build Arnaldo Carvalho de Melo
  1 sibling, 0 replies; 3+ messages in thread
From: Luca Boccassi @ 2021-06-13 13:47 UTC (permalink / raw)
  To: dwarves; +Cc: arnaldo.melo

Required for the new API btf__add_float()

Signed-off-by: Luca Boccassi <bluca@debian.org>
---
 CMakeLists.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 0f967d1..a8c0af8 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -6,7 +6,7 @@ option(LIBBPF_EMBEDDED "Use the embedded version of libbpf instead of searching
 if (NOT LIBBPF_EMBEDDED)
 	find_package(PkgConfig REQUIRED)
 	if(PKGCONFIG_FOUND)
-		pkg_check_modules(LIBBPF REQUIRED libbpf>=0.3.0)
+		pkg_check_modules(LIBBPF REQUIRED libbpf>=0.4.0)
 	endif()
 endif()
 
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH dwarves 1/2] libbpf: if LIBBPF_EMBEDDED=OFF and libbpf-dev/pkgconfig is not available, fail the build
  2021-06-13 13:47 [PATCH dwarves 1/2] libbpf: if LIBBPF_EMBEDDED=OFF and libbpf-dev/pkgconfig is not available, fail the build Luca Boccassi
  2021-06-13 13:47 ` [PATCH dwarves 2/2] libbpf: bump dependency to >= 0.4.0 Luca Boccassi
@ 2021-06-14 18:34 ` Arnaldo Carvalho de Melo
  1 sibling, 0 replies; 3+ messages in thread
From: Arnaldo Carvalho de Melo @ 2021-06-14 18:34 UTC (permalink / raw)
  To: Luca Boccassi; +Cc: dwarves, arnaldo.melo

Em Sun, Jun 13, 2021 at 02:47:05PM +0100, Luca Boccassi escreveu:
> If using the system library was explicitly requested, ensure it is present
> and fail the build if it is not, rather than falling back to the
> embedded version (same for pkg-config).


Thanks, applied and tested both patches,

- Arnaldo
 
> Signed-off-by: Luca Boccassi <bluca@debian.org>
> ---
>  CMakeLists.txt | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/CMakeLists.txt b/CMakeLists.txt
> index 669ea59..0f967d1 100644
> --- a/CMakeLists.txt
> +++ b/CMakeLists.txt
> @@ -4,9 +4,9 @@ cmake_policy(SET CMP0005 NEW)
>  
>  option(LIBBPF_EMBEDDED "Use the embedded version of libbpf instead of searching it via pkg-config" ON)
>  if (NOT LIBBPF_EMBEDDED)
> -	find_package(PkgConfig)
> +	find_package(PkgConfig REQUIRED)
>  	if(PKGCONFIG_FOUND)
> -		pkg_check_modules(LIBBPF libbpf>=0.3.0)
> +		pkg_check_modules(LIBBPF REQUIRED libbpf>=0.3.0)
>  	endif()
>  endif()
>  
> -- 
> 2.30.2
> 

-- 

- Arnaldo

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-06-14 18:34 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-13 13:47 [PATCH dwarves 1/2] libbpf: if LIBBPF_EMBEDDED=OFF and libbpf-dev/pkgconfig is not available, fail the build Luca Boccassi
2021-06-13 13:47 ` [PATCH dwarves 2/2] libbpf: bump dependency to >= 0.4.0 Luca Boccassi
2021-06-14 18:34 ` [PATCH dwarves 1/2] libbpf: if LIBBPF_EMBEDDED=OFF and libbpf-dev/pkgconfig is not available, fail the build Arnaldo Carvalho de Melo

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).