Skip to contentSkip to conversation

bpftool: Build failure due to opensslv.h

BUG Namhyung Kim 3 participants 13 messages Oct 27, 2025 – Nov 27, 2025 BPF

lore
Share & tools
lore
#0 lore raw

Hello,

I'm seeing a build failure like below in Fedora 40 and others. I'm not sure if it's reported already but it failed to build perf tools due to errors in the bootstrap bpftool.

CC /build/util/bpf_skel/.tmp/bootstrap/sign.o
sign.c:16:10: fatal error: openssl/opensslv.h: No such file or directory
16 | #include <openssl/opensslv.h>
| ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[3]: *** [Makefile:256: /build/util/bpf_skel/.tmp/bootstrap/sign.o] Error 1 make[3]: *** Waiting for unfinished jobs....
make[2]: *** [Makefile.perf:1213: /build/util/bpf_skel/.tmp/bootstrap/bpftool] Error 2 make[1]: *** [Makefile.perf:289: sub-make] Error 2
make: *** [Makefile:76: all] Error 2

I think it's from the recent signing change. I'm not familiar with openssl but I guess there's a proper feature check for it. Is this a known issue?

Thanks,
Namhyung

#1 lore raw

2025-10-26 21:01 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 17 lines

Hello,

I'm seeing a build failure like below in Fedora 40 and others. I'm not sure if it's reported already but it failed to build perf tools due to errors in the bootstrap bpftool.

CC /build/util/bpf_skel/.tmp/bootstrap/sign.o
sign.c:16:10: fatal error: openssl/opensslv.h: No such file or directory
16 | #include <openssl/opensslv.h>
| ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[3]: *** [Makefile:256: /build/util/bpf_skel/.tmp/bootstrap/sign.o] Error 1 make[3]: *** Waiting for unfinished jobs....
make[2]: *** [Makefile.perf:1213: /build/util/bpf_skel/.tmp/bootstrap/bpftool] Error 2 make[1]: *** [Makefile.perf:289: sub-make] Error 2
make: *** [Makefile:76: all] Error 2

Quoted 3 lines

I think it's from the recent signing change. I'm not familiar with openssl but I guess there's a proper feature check for it. Is this a known issue?

Hi Namhyung,

This looks related to the program signing change indeed, commit 40863f4d6ef2 ("bpftool: Add support for signing BPF programs") introduced a dependency on OpenSSL's development headers for bpftool. It's not gated behind a feature check. On Fedora, I think the headers come with openssl-devel, do you have this package installed?

Best regards,
Quentin

#2 lore raw
Quoted 18 lines · Quentin Monnet

2025-10-26 21:01 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 17 lines

Hello,

I'm seeing a build failure like below in Fedora 40 and others. I'm not sure if it's reported already but it failed to build perf tools due to errors in the bootstrap bpftool.

CC /build/util/bpf_skel/.tmp/bootstrap/sign.o
sign.c:16:10: fatal error: openssl/opensslv.h: No such file or directory
16 | #include <openssl/opensslv.h>
| ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[3]: *** [Makefile:256: /build/util/bpf_skel/.tmp/bootstrap/sign.o] Error 1 make[3]: *** Waiting for unfinished jobs....
make[2]: *** [Makefile.perf:1213: /build/util/bpf_skel/.tmp/bootstrap/bpftool] Error 2 make[1]: *** [Makefile.perf:289: sub-make] Error 2
make: *** [Makefile:76: all] Error 2

Quoted 6 lines
Quoted 3 lines

I think it's from the recent signing change. I'm not familiar with openssl but I guess there's a proper feature check for it. Is this a known issue?

Hi Namhyung,

Hello!

Quoted 6 lines

This looks related to the program signing change indeed, commit 40863f4d6ef2 ("bpftool: Add support for signing BPF programs") introduced a dependency on OpenSSL's development headers for bpftool. It's not gated behind a feature check. On Fedora, I think the headers come with openssl-devel, do you have this package installed?

No I don't, but I guess it should be able to build on such systems. Or is it required for bpftool? Anyway I feel like it should have a feature check and appropriate error messages.

Thanks,
Namhyung

#3 lore raw

2025-10-27 11:27 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 35 lines · Quentin Monnet
Quoted 18 lines

2025-10-26 21:01 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 17 lines

Hello,

I'm seeing a build failure like below in Fedora 40 and others. I'm not sure if it's reported already but it failed to build perf tools due to errors in the bootstrap bpftool.

CC /build/util/bpf_skel/.tmp/bootstrap/sign.o
sign.c:16:10: fatal error: openssl/opensslv.h: No such file or directory
16 | #include <openssl/opensslv.h>
| ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[3]: *** [Makefile:256: /build/util/bpf_skel/.tmp/bootstrap/sign.o] Error 1 make[3]: *** Waiting for unfinished jobs....
make[2]: *** [Makefile.perf:1213: /build/util/bpf_skel/.tmp/bootstrap/bpftool] Error 2 make[1]: *** [Makefile.perf:289: sub-make] Error 2
make: *** [Makefile:76: all] Error 2

Quoted 6 lines
Quoted 3 lines

I think it's from the recent signing change. I'm not familiar with openssl but I guess there's a proper feature check for it. Is this a known issue?

Hi Namhyung,

Hello!

Quoted 6 lines

This looks related to the program signing change indeed, commit 40863f4d6ef2 ("bpftool: Add support for signing BPF programs") introduced a dependency on OpenSSL's development headers for bpftool. It's not gated behind a feature check. On Fedora, I think the headers come with openssl-devel, do you have this package installed?

Quoted 4 lines

No I don't, but I guess it should be able to build on such systems. Or is it required for bpftool? Anyway I feel like it should have a feature check and appropriate error messages.

+Cc KP

We usually have feature checks when optional features bring in new dependencies for bpftool, but we haven't discussed it this time. My understanding was that program signing is important enough that it should always be present in newer versions of bpftool, making OpenSSL one of the required dependencies going forward.

We don't currently have feature checks to tell when required dependencies are missing for bpftool (it's just the build failing, in that case). I know perf does a great job at it, we could look into it for bpftool, too.

Quentin

#4 lore raw
Quoted 49 lines · Quentin Monnet

2025-10-27 11:27 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 35 lines · Quentin Monnet
Quoted 18 lines

2025-10-26 21:01 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 17 lines

Hello,

I'm seeing a build failure like below in Fedora 40 and others. I'm not sure if it's reported already but it failed to build perf tools due to errors in the bootstrap bpftool.

CC /build/util/bpf_skel/.tmp/bootstrap/sign.o
sign.c:16:10: fatal error: openssl/opensslv.h: No such file or directory
16 | #include <openssl/opensslv.h>
| ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[3]: *** [Makefile:256: /build/util/bpf_skel/.tmp/bootstrap/sign.o] Error 1 make[3]: *** Waiting for unfinished jobs....
make[2]: *** [Makefile.perf:1213: /build/util/bpf_skel/.tmp/bootstrap/bpftool] Error 2 make[1]: *** [Makefile.perf:289: sub-make] Error 2
make: *** [Makefile:76: all] Error 2

Quoted 6 lines
Quoted 3 lines

I think it's from the recent signing change. I'm not familiar with openssl but I guess there's a proper feature check for it. Is this a known issue?

Hi Namhyung,

Hello!

Quoted 6 lines

This looks related to the program signing change indeed, commit 40863f4d6ef2 ("bpftool: Add support for signing BPF programs") introduced a dependency on OpenSSL's development headers for bpftool. It's not gated behind a feature check. On Fedora, I think the headers come with openssl-devel, do you have this package installed?

Quoted 4 lines

No I don't, but I guess it should be able to build on such systems. Or is it required for bpftool? Anyway I feel like it should have a feature check and appropriate error messages.

+Cc KP

We usually have feature checks when optional features bring in new dependencies for bpftool, but we haven't discussed it this time. My understanding was that program signing is important enough that it should always be present in newer versions of bpftool, making OpenSSL one of the required dependencies going forward.

Quoted 5 lines

We don't currently have feature checks to tell when required dependencies are missing for bpftool (it's just the build failing, in that case). I know perf does a great job at it, we could look into it for bpftool, too.

One issue here is that some distros package openssl v3 such that the #include files are in /usr/include/openssl3 and libraries in /usr/lib64/openssl3 so that older versions can co-exist. Maybe we could figure out a feature test that handles that too?

Alan

#12 lore raw
In reply to Quentin Monnet
Quoted 41 lines · Quentin Monnet

2025-10-27 11:27 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 35 lines · Quentin Monnet
Quoted 18 lines

2025-10-26 21:01 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 17 lines

Hello,

I'm seeing a build failure like below in Fedora 40 and others. I'm not sure if it's reported already but it failed to build perf tools due to errors in the bootstrap bpftool.

CC /build/util/bpf_skel/.tmp/bootstrap/sign.o
sign.c:16:10: fatal error: openssl/opensslv.h: No such file or directory
16 | #include <openssl/opensslv.h>
| ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[3]: *** [Makefile:256: /build/util/bpf_skel/.tmp/bootstrap/sign.o] Error 1 make[3]: *** Waiting for unfinished jobs....
make[2]: *** [Makefile.perf:1213: /build/util/bpf_skel/.tmp/bootstrap/bpftool] Error 2 make[1]: *** [Makefile.perf:289: sub-make] Error 2
make: *** [Makefile:76: all] Error 2

Quoted 6 lines
Quoted 3 lines

I think it's from the recent signing change. I'm not familiar with openssl but I guess there's a proper feature check for it. Is this a known issue?

Hi Namhyung,

Hello!

Quoted 6 lines

This looks related to the program signing change indeed, commit 40863f4d6ef2 ("bpftool: Add support for signing BPF programs") introduced a dependency on OpenSSL's development headers for bpftool. It's not gated behind a feature check. On Fedora, I think the headers come with openssl-devel, do you have this package installed?

Quoted 4 lines

No I don't, but I guess it should be able to build on such systems. Or is it required for bpftool? Anyway I feel like it should have a feature check and appropriate error messages.

Quoted 7 lines

+Cc KP

We usually have feature checks when optional features bring in new dependencies for bpftool, but we haven't discussed it this time. My understanding was that program signing is important enough that it should always be present in newer versions of bpftool, making OpenSSL one of the required dependencies going forward.

Yeah, the problem is that it also affects to perf build.

Quoted 5 lines

We don't currently have feature checks to tell when required dependencies are missing for bpftool (it's just the build failing, in that case). I know perf does a great job at it, we could look into it for bpftool, too.

It's in the tools/build directory. :)

Thanks,
Namhyung

#5 lore raw
In reply to Alan Maguire

Hello,

Quoted 56 lines · Alan Maguire
Quoted 49 lines · Quentin Monnet

2025-10-27 11:27 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 35 lines · Quentin Monnet
Quoted 18 lines

2025-10-26 21:01 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 17 lines

Hello,

I'm seeing a build failure like below in Fedora 40 and others. I'm not sure if it's reported already but it failed to build perf tools due to errors in the bootstrap bpftool.

CC /build/util/bpf_skel/.tmp/bootstrap/sign.o
sign.c:16:10: fatal error: openssl/opensslv.h: No such file or directory
16 | #include <openssl/opensslv.h>
| ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[3]: *** [Makefile:256: /build/util/bpf_skel/.tmp/bootstrap/sign.o] Error 1 make[3]: *** Waiting for unfinished jobs....
make[2]: *** [Makefile.perf:1213: /build/util/bpf_skel/.tmp/bootstrap/bpftool] Error 2 make[1]: *** [Makefile.perf:289: sub-make] Error 2
make: *** [Makefile:76: all] Error 2

Quoted 6 lines
Quoted 3 lines

I think it's from the recent signing change. I'm not familiar with openssl but I guess there's a proper feature check for it. Is this a known issue?

Hi Namhyung,

Hello!

Quoted 6 lines

This looks related to the program signing change indeed, commit 40863f4d6ef2 ("bpftool: Add support for signing BPF programs") introduced a dependency on OpenSSL's development headers for bpftool. It's not gated behind a feature check. On Fedora, I think the headers come with openssl-devel, do you have this package installed?

Quoted 4 lines

No I don't, but I guess it should be able to build on such systems. Or is it required for bpftool? Anyway I feel like it should have a feature check and appropriate error messages.

+Cc KP

We usually have feature checks when optional features bring in new dependencies for bpftool, but we haven't discussed it this time. My understanding was that program signing is important enough that it should always be present in newer versions of bpftool, making OpenSSL one of the required dependencies going forward.

Quoted 5 lines

We don't currently have feature checks to tell when required dependencies are missing for bpftool (it's just the build failing, in that case). I know perf does a great job at it, we could look into it for bpftool, too.

Quoted 4 lines

One issue here is that some distros package openssl v3 such that the #include files are in /usr/include/openssl3 and libraries in /usr/lib64/openssl3 so that older versions can co-exist. Maybe we could figure out a feature test that handles that too?

What's the state of this? Is the fix in the bpf tree now?

Thanks,
Namhyung

#6 lore raw

2025-11-19 17:56 UTC-0800 ~ Namhyung Kim <[email protected]>

Quoted 59 lines

Hello,

Quoted 56 lines · Alan Maguire
Quoted 54 lines · Quentin Monnet

2025-10-27 11:27 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 35 lines · Quentin Monnet
Quoted 18 lines

2025-10-26 21:01 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 17 lines

Hello,

I'm seeing a build failure like below in Fedora 40 and others. I'm not sure if it's reported already but it failed to build perf tools due to errors in the bootstrap bpftool.

CC /build/util/bpf_skel/.tmp/bootstrap/sign.o
sign.c:16:10: fatal error: openssl/opensslv.h: No such file or directory
16 | #include <openssl/opensslv.h>
| ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[3]: *** [Makefile:256: /build/util/bpf_skel/.tmp/bootstrap/sign.o] Error 1 make[3]: *** Waiting for unfinished jobs....
make[2]: *** [Makefile.perf:1213: /build/util/bpf_skel/.tmp/bootstrap/bpftool] Error 2 make[1]: *** [Makefile.perf:289: sub-make] Error 2
make: *** [Makefile:76: all] Error 2

Quoted 6 lines
Quoted 3 lines

I think it's from the recent signing change. I'm not familiar with openssl but I guess there's a proper feature check for it. Is this a known issue?

Hi Namhyung,

Hello!

Quoted 6 lines

This looks related to the program signing change indeed, commit 40863f4d6ef2 ("bpftool: Add support for signing BPF programs") introduced a dependency on OpenSSL's development headers for bpftool. It's not gated behind a feature check. On Fedora, I think the headers come with openssl-devel, do you have this package installed?

Quoted 4 lines

No I don't, but I guess it should be able to build on such systems. Or is it required for bpftool? Anyway I feel like it should have a feature check and appropriate error messages.

+Cc KP

We usually have feature checks when optional features bring in new dependencies for bpftool, but we haven't discussed it this time. My understanding was that program signing is important enough that it should always be present in newer versions of bpftool, making OpenSSL one of the required dependencies going forward.

We don't currently have feature checks to tell when required dependencies are missing for bpftool (it's just the build failing, in that case). I know perf does a great job at it, we could look into it for bpftool, too.

Quoted 6 lines
Quoted 4 lines

One issue here is that some distros package openssl v3 such that the #include files are in /usr/include/openssl3 and libraries in /usr/lib64/openssl3 so that older versions can co-exist. Maybe we could figure out a feature test that handles that too?

What's the state of this? Is the fix in the bpf tree now?

Hi Namhyung, Alan just submitted a v2 of his patch (targetting bpf-next), see:

https://lore.kernel.org/all/[email protected]/

Quentin

#7 lore raw
Quoted 65 lines · Quentin Monnet

2025-11-19 17:56 UTC-0800 ~ Namhyung Kim <[email protected]>

Quoted 64 lines

Hello,

Quoted 60 lines · Alan Maguire
Quoted 49 lines · Quentin Monnet

2025-10-27 11:27 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 35 lines · Quentin Monnet
Quoted 18 lines

2025-10-26 21:01 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 17 lines

Hello,

I'm seeing a build failure like below in Fedora 40 and others. I'm not sure if it's reported already but it failed to build perf tools due to errors in the bootstrap bpftool.

CC /build/util/bpf_skel/.tmp/bootstrap/sign.o
sign.c:16:10: fatal error: openssl/opensslv.h: No such file or directory
16 | #include <openssl/opensslv.h>
| ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[3]: *** [Makefile:256: /build/util/bpf_skel/.tmp/bootstrap/sign.o] Error 1 make[3]: *** Waiting for unfinished jobs....
make[2]: *** [Makefile.perf:1213: /build/util/bpf_skel/.tmp/bootstrap/bpftool] Error 2 make[1]: *** [Makefile.perf:289: sub-make] Error 2
make: *** [Makefile:76: all] Error 2

Quoted 6 lines
Quoted 3 lines

I think it's from the recent signing change. I'm not familiar with openssl but I guess there's a proper feature check for it. Is this a known issue?

Hi Namhyung,

Hello!

Quoted 6 lines

This looks related to the program signing change indeed, commit 40863f4d6ef2 ("bpftool: Add support for signing BPF programs") introduced a dependency on OpenSSL's development headers for bpftool. It's not gated behind a feature check. On Fedora, I think the headers come with openssl-devel, do you have this package installed?

Quoted 4 lines

No I don't, but I guess it should be able to build on such systems. Or is it required for bpftool? Anyway I feel like it should have a feature check and appropriate error messages.

+Cc KP

We usually have feature checks when optional features bring in new dependencies for bpftool, but we haven't discussed it this time. My understanding was that program signing is important enough that it should always be present in newer versions of bpftool, making OpenSSL one of the required dependencies going forward.

Quoted 5 lines

We don't currently have feature checks to tell when required dependencies are missing for bpftool (it's just the build failing, in that case). I know perf does a great job at it, we could look into it for bpftool, too.

One issue here is that some distros package openssl v3 such that the #include files are in /usr/include/openssl3 and libraries in /usr/lib64/openssl3 so that older versions can co-exist. Maybe we could figure out a feature test that handles that too?

Quoted 7 lines
Quoted 1 line

What's the state of this? Is the fix in the bpf tree now?

Hi Namhyung, Alan just submitted a v2 of his patch (targetting bpf-next), see:

https://lore.kernel.org/all/[email protected]/

Hello Quentin,

I'm afraid it doesn't fix my issue. It seems to fix another problem about the error API. But I still see the build failure.

Thanks,
Namhyung

#8 lore raw
Quoted 72 lines · Namhyung Kim
Quoted 71 lines · Quentin Monnet

2025-11-19 17:56 UTC-0800 ~ Namhyung Kim <[email protected]>

Quoted 59 lines

Hello,

Quoted 56 lines · Alan Maguire
Quoted 54 lines · Quentin Monnet

2025-10-27 11:27 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 35 lines · Quentin Monnet
Quoted 18 lines

2025-10-26 21:01 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 17 lines

Hello,

I'm seeing a build failure like below in Fedora 40 and others. I'm not sure if it's reported already but it failed to build perf tools due to errors in the bootstrap bpftool.

CC /build/util/bpf_skel/.tmp/bootstrap/sign.o
sign.c:16:10: fatal error: openssl/opensslv.h: No such file or directory
16 | #include <openssl/opensslv.h>
| ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[3]: *** [Makefile:256: /build/util/bpf_skel/.tmp/bootstrap/sign.o] Error 1 make[3]: *** Waiting for unfinished jobs....
make[2]: *** [Makefile.perf:1213: /build/util/bpf_skel/.tmp/bootstrap/bpftool] Error 2 make[1]: *** [Makefile.perf:289: sub-make] Error 2
make: *** [Makefile:76: all] Error 2

Quoted 6 lines
Quoted 3 lines

I think it's from the recent signing change. I'm not familiar with openssl but I guess there's a proper feature check for it. Is this a known issue?

Hi Namhyung,

Hello!

Quoted 6 lines

This looks related to the program signing change indeed, commit 40863f4d6ef2 ("bpftool: Add support for signing BPF programs") introduced a dependency on OpenSSL's development headers for bpftool. It's not gated behind a feature check. On Fedora, I think the headers come with openssl-devel, do you have this package installed?

Quoted 4 lines

No I don't, but I guess it should be able to build on such systems. Or is it required for bpftool? Anyway I feel like it should have a feature check and appropriate error messages.

+Cc KP

We usually have feature checks when optional features bring in new dependencies for bpftool, but we haven't discussed it this time. My understanding was that program signing is important enough that it should always be present in newer versions of bpftool, making OpenSSL one of the required dependencies going forward.

We don't currently have feature checks to tell when required dependencies are missing for bpftool (it's just the build failing, in that case). I know perf does a great job at it, we could look into it for bpftool, too.

Quoted 6 lines
Quoted 4 lines

One issue here is that some distros package openssl v3 such that the #include files are in /usr/include/openssl3 and libraries in /usr/lib64/openssl3 so that older versions can co-exist. Maybe we could figure out a feature test that handles that too?

What's the state of this? Is the fix in the bpf tree now?

Hi Namhyung, Alan just submitted a v2 of his patch (targetting bpf-next), see:

Quoted 7 lines
Quoted 1 line

https://lore.kernel.org/all/[email protected]/

Hello Quentin,

I'm afraid it doesn't fix my issue. It seems to fix another problem about the error API. But I still see the build failure.

This header file is delivered by openssl-devel (could be openssl-dev on some distros). Looking at [1], it seems like that package has been a requirement to build kernels from 4.3 on. Is it missing on your system, installed to an unusual path like /usr/include/opensslv3, or is the package perhaps missing some header files?

Alan

[1] https://docs.kernel.org/process/changes.html

Quoted 4 lines

Thanks,
Namhyung

#9 lore raw

Hello,

Quoted 81 lines · Alan Maguire
Quoted 72 lines · Namhyung Kim
Quoted 71 lines · Quentin Monnet

2025-11-19 17:56 UTC-0800 ~ Namhyung Kim <[email protected]>

Quoted 59 lines

Hello,

Quoted 56 lines · Alan Maguire
Quoted 54 lines · Quentin Monnet

2025-10-27 11:27 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 35 lines · Quentin Monnet
Quoted 18 lines

2025-10-26 21:01 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 17 lines

Hello,

I'm seeing a build failure like below in Fedora 40 and others. I'm not sure if it's reported already but it failed to build perf tools due to errors in the bootstrap bpftool.

CC /build/util/bpf_skel/.tmp/bootstrap/sign.o
sign.c:16:10: fatal error: openssl/opensslv.h: No such file or directory
16 | #include <openssl/opensslv.h>
| ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[3]: *** [Makefile:256: /build/util/bpf_skel/.tmp/bootstrap/sign.o] Error 1 make[3]: *** Waiting for unfinished jobs....
make[2]: *** [Makefile.perf:1213: /build/util/bpf_skel/.tmp/bootstrap/bpftool] Error 2 make[1]: *** [Makefile.perf:289: sub-make] Error 2
make: *** [Makefile:76: all] Error 2

Quoted 6 lines
Quoted 3 lines

I think it's from the recent signing change. I'm not familiar with openssl but I guess there's a proper feature check for it. Is this a known issue?

Hi Namhyung,

Hello!

Quoted 6 lines

This looks related to the program signing change indeed, commit 40863f4d6ef2 ("bpftool: Add support for signing BPF programs") introduced a dependency on OpenSSL's development headers for bpftool. It's not gated behind a feature check. On Fedora, I think the headers come with openssl-devel, do you have this package installed?

Quoted 4 lines

No I don't, but I guess it should be able to build on such systems. Or is it required for bpftool? Anyway I feel like it should have a feature check and appropriate error messages.

+Cc KP

We usually have feature checks when optional features bring in new dependencies for bpftool, but we haven't discussed it this time. My understanding was that program signing is important enough that it should always be present in newer versions of bpftool, making OpenSSL one of the required dependencies going forward.

We don't currently have feature checks to tell when required dependencies are missing for bpftool (it's just the build failing, in that case). I know perf does a great job at it, we could look into it for bpftool, too.

Quoted 6 lines
Quoted 4 lines

One issue here is that some distros package openssl v3 such that the #include files are in /usr/include/openssl3 and libraries in /usr/lib64/openssl3 so that older versions can co-exist. Maybe we could figure out a feature test that handles that too?

What's the state of this? Is the fix in the bpf tree now?

Hi Namhyung, Alan just submitted a v2 of his patch (targetting bpf-next), see:

Quoted 7 lines
Quoted 1 line

https://lore.kernel.org/all/[email protected]/

Hello Quentin,

I'm afraid it doesn't fix my issue. It seems to fix another problem about the error API. But I still see the build failure.

Quoted 5 lines

This header file is delivered by openssl-devel (could be openssl-dev on some distros). Looking at [1], it seems like that package has been a requirement to build kernels from 4.3 on. Is it missing on your system, installed to an unusual path like /usr/include/opensslv3, or is the package perhaps missing some header files?

I think some of my test environments don't have openssl dev packages. I didn't know it was required for kernel builds but it wasn't for perf. If you guys require it for bpftool, maybe I can make perf disable BPF support in case openssl is missing.

Thanks,
Namhyung

Quoted 10 lines

Alan

[1] https://docs.kernel.org/process/changes.html

Quoted 4 lines

Thanks,
Namhyung

#10 lore raw

2025-11-26 10:33 UTC-0800 ~ Namhyung Kim <[email protected]>

Quoted 90 lines

Hello,

Quoted 81 lines · Alan Maguire
Quoted 72 lines · Namhyung Kim
Quoted 71 lines · Quentin Monnet

2025-11-19 17:56 UTC-0800 ~ Namhyung Kim <[email protected]>

Quoted 59 lines

Hello,

Quoted 56 lines · Alan Maguire
Quoted 54 lines · Quentin Monnet

2025-10-27 11:27 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 35 lines · Quentin Monnet
Quoted 18 lines

2025-10-26 21:01 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 17 lines

Hello,

I'm seeing a build failure like below in Fedora 40 and others. I'm not sure if it's reported already but it failed to build perf tools due to errors in the bootstrap bpftool.

CC /build/util/bpf_skel/.tmp/bootstrap/sign.o
sign.c:16:10: fatal error: openssl/opensslv.h: No such file or directory
16 | #include <openssl/opensslv.h>
| ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[3]: *** [Makefile:256: /build/util/bpf_skel/.tmp/bootstrap/sign.o] Error 1 make[3]: *** Waiting for unfinished jobs....
make[2]: *** [Makefile.perf:1213: /build/util/bpf_skel/.tmp/bootstrap/bpftool] Error 2 make[1]: *** [Makefile.perf:289: sub-make] Error 2
make: *** [Makefile:76: all] Error 2

Quoted 6 lines
Quoted 3 lines

I think it's from the recent signing change. I'm not familiar with openssl but I guess there's a proper feature check for it. Is this a known issue?

Hi Namhyung,

Hello!

Quoted 6 lines

This looks related to the program signing change indeed, commit 40863f4d6ef2 ("bpftool: Add support for signing BPF programs") introduced a dependency on OpenSSL's development headers for bpftool. It's not gated behind a feature check. On Fedora, I think the headers come with openssl-devel, do you have this package installed?

Quoted 4 lines

No I don't, but I guess it should be able to build on such systems. Or is it required for bpftool? Anyway I feel like it should have a feature check and appropriate error messages.

+Cc KP

We usually have feature checks when optional features bring in new dependencies for bpftool, but we haven't discussed it this time. My understanding was that program signing is important enough that it should always be present in newer versions of bpftool, making OpenSSL one of the required dependencies going forward.

We don't currently have feature checks to tell when required dependencies are missing for bpftool (it's just the build failing, in that case). I know perf does a great job at it, we could look into it for bpftool, too.

Quoted 6 lines
Quoted 4 lines

One issue here is that some distros package openssl v3 such that the #include files are in /usr/include/openssl3 and libraries in /usr/lib64/openssl3 so that older versions can co-exist. Maybe we could figure out a feature test that handles that too?

What's the state of this? Is the fix in the bpf tree now?

Hi Namhyung, Alan just submitted a v2 of his patch (targetting bpf-next), see:

Quoted 7 lines
Quoted 1 line

https://lore.kernel.org/all/[email protected]/

Hello Quentin,

I'm afraid it doesn't fix my issue. It seems to fix another problem about the error API. But I still see the build failure.

Quoted 5 lines

This header file is delivered by openssl-devel (could be openssl-dev on some distros). Looking at [1], it seems like that package has been a requirement to build kernels from 4.3 on. Is it missing on your system, installed to an unusual path like /usr/include/opensslv3, or is the package perhaps missing some header files?

Quoted 4 lines

I think some of my test environments don't have openssl dev packages. I didn't know it was required for kernel builds but it wasn't for perf. If you guys require it for bpftool, maybe I can make perf disable BPF support in case openssl is missing.

Hi, yes OpenSSL is a required dependency for bpftool going forward, sorry to hear it doesn't work well with your environment. I think there's already an option to turn off BPF skeletons in perf, I'd try running the Makefile with BUILD_BPF_SKEL=0 maybe.

Quentin

#11 lore raw
Quoted 97 lines · Quentin Monnet

2025-11-26 10:33 UTC-0800 ~ Namhyung Kim <[email protected]>

Quoted 90 lines

Hello,

Quoted 81 lines · Alan Maguire
Quoted 72 lines · Namhyung Kim
Quoted 71 lines · Quentin Monnet

2025-11-19 17:56 UTC-0800 ~ Namhyung Kim <[email protected]>

Quoted 59 lines

Hello,

Quoted 56 lines · Alan Maguire
Quoted 54 lines · Quentin Monnet

2025-10-27 11:27 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 35 lines · Quentin Monnet
Quoted 18 lines

2025-10-26 21:01 UTC-0700 ~ Namhyung Kim <[email protected]>

Quoted 17 lines

Hello,

I'm seeing a build failure like below in Fedora 40 and others. I'm not sure if it's reported already but it failed to build perf tools due to errors in the bootstrap bpftool.

CC /build/util/bpf_skel/.tmp/bootstrap/sign.o
sign.c:16:10: fatal error: openssl/opensslv.h: No such file or directory
16 | #include <openssl/opensslv.h>
| ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[3]: *** [Makefile:256: /build/util/bpf_skel/.tmp/bootstrap/sign.o] Error 1 make[3]: *** Waiting for unfinished jobs....
make[2]: *** [Makefile.perf:1213: /build/util/bpf_skel/.tmp/bootstrap/bpftool] Error 2 make[1]: *** [Makefile.perf:289: sub-make] Error 2
make: *** [Makefile:76: all] Error 2

Quoted 6 lines
Quoted 3 lines

I think it's from the recent signing change. I'm not familiar with openssl but I guess there's a proper feature check for it. Is this a known issue?

Hi Namhyung,

Hello!

Quoted 6 lines

This looks related to the program signing change indeed, commit 40863f4d6ef2 ("bpftool: Add support for signing BPF programs") introduced a dependency on OpenSSL's development headers for bpftool. It's not gated behind a feature check. On Fedora, I think the headers come with openssl-devel, do you have this package installed?

Quoted 4 lines

No I don't, but I guess it should be able to build on such systems. Or is it required for bpftool? Anyway I feel like it should have a feature check and appropriate error messages.

+Cc KP

We usually have feature checks when optional features bring in new dependencies for bpftool, but we haven't discussed it this time. My understanding was that program signing is important enough that it should always be present in newer versions of bpftool, making OpenSSL one of the required dependencies going forward.

We don't currently have feature checks to tell when required dependencies are missing for bpftool (it's just the build failing, in that case). I know perf does a great job at it, we could look into it for bpftool, too.

Quoted 6 lines
Quoted 4 lines

One issue here is that some distros package openssl v3 such that the #include files are in /usr/include/openssl3 and libraries in /usr/lib64/openssl3 so that older versions can co-exist. Maybe we could figure out a feature test that handles that too?

What's the state of this? Is the fix in the bpf tree now?

Hi Namhyung, Alan just submitted a v2 of his patch (targetting bpf-next), see:

Quoted 7 lines
Quoted 1 line

https://lore.kernel.org/all/[email protected]/

Hello Quentin,

I'm afraid it doesn't fix my issue. It seems to fix another problem about the error API. But I still see the build failure.

Quoted 5 lines

This header file is delivered by openssl-devel (could be openssl-dev on some distros). Looking at [1], it seems like that package has been a requirement to build kernels from 4.3 on. Is it missing on your system, installed to an unusual path like /usr/include/opensslv3, or is the package perhaps missing some header files?

Quoted 4 lines

I think some of my test environments don't have openssl dev packages. I didn't know it was required for kernel builds but it wasn't for perf. If you guys require it for bpftool, maybe I can make perf disable BPF support in case openssl is missing.

Quoted 4 lines

Hi, yes OpenSSL is a required dependency for bpftool going forward, sorry to hear it doesn't work well with your environment. I think there's already an option to turn off BPF skeletons in perf, I'd try running the Makefile with BUILD_BPF_SKEL=0 maybe.

Yes, we have it. Thanks for confirming.

Namhyung