Bug#1002291: bpfcc: Fails to build with libbpf/0.6.1-1

2022-02-26 Thread Sudip Mukherjee
HI Vasudev,

On Wed, Feb 23, 2022 at 11:30 AM Vasudev Kamath  wrote:
>
> Sudip Mukherjee  writes:
>
> > On Tue, Feb 22, 2022 at 4:12 AM Vasudev Kamath  
> > wrote:
> >>
> >> Sudip Mukherjee  writes:
> >>
> >> > You are trying to build 0.24.0+ds and I am rebuilding 0.22.0+ds-2 to 
> >> > test.  :)
> >> >
> >> > Can you rebuild 0.22.0+ds-2 and verify.
> >>
> >> Err yes. It works with 0.22.0. I was preparing 0.23.0 and then 0.24.0.
> >> Both of which fails as of now. Not sure what should be done.
> >
> > I think, since it works with 0.22.0 I will update libbpf in unstable.
> > I am guessing the previous FTBFS was fixed by libbpf in this release.
> > But now bpfcc has messed up something.
> > If you are ok, then I can update libbpf and then you can ping the
> > bpfcc upstream about the FTBFS with latest bpfcc with latest libbpf.
>
> Yes please go ahead. I will wait for the new upload a bit more. If it
> still does not work I will ping the upstream.

Thanks. I have uploaded now.
Also, if you can please push your branch to salsa I can have a look
sometime next week.


-- 
Regards
Sudip



Bug#1002291: bpfcc: Fails to build with libbpf/0.6.1-1

2022-02-23 Thread Vasudev Kamath
Sudip Mukherjee  writes:

> On Tue, Feb 22, 2022 at 4:12 AM Vasudev Kamath  wrote:
>>
>> Sudip Mukherjee  writes:
>>
>> > You are trying to build 0.24.0+ds and I am rebuilding 0.22.0+ds-2 to test. 
>> >  :)
>> >
>> > Can you rebuild 0.22.0+ds-2 and verify.
>>
>> Err yes. It works with 0.22.0. I was preparing 0.23.0 and then 0.24.0.
>> Both of which fails as of now. Not sure what should be done.
>
> I think, since it works with 0.22.0 I will update libbpf in unstable.
> I am guessing the previous FTBFS was fixed by libbpf in this release.
> But now bpfcc has messed up something.
> If you are ok, then I can update libbpf and then you can ping the
> bpfcc upstream about the FTBFS with latest bpfcc with latest libbpf.

Yes please go ahead. I will wait for the new upload a bit more. If it
still does not work I will ping the upstream.

Cheers,
Vasudev



Bug#1002291: bpfcc: Fails to build with libbpf/0.6.1-1

2022-02-23 Thread Sudip Mukherjee
On Tue, Feb 22, 2022 at 4:12 AM Vasudev Kamath  wrote:
>
> Sudip Mukherjee  writes:
>
> > You are trying to build 0.24.0+ds and I am rebuilding 0.22.0+ds-2 to test.  
> > :)
> >
> > Can you rebuild 0.22.0+ds-2 and verify.
>
> Err yes. It works with 0.22.0. I was preparing 0.23.0 and then 0.24.0.
> Both of which fails as of now. Not sure what should be done.

I think, since it works with 0.22.0 I will update libbpf in unstable.
I am guessing the previous FTBFS was fixed by libbpf in this release.
But now bpfcc has messed up something.
If you are ok, then I can update libbpf and then you can ping the
bpfcc upstream about the FTBFS with latest bpfcc with latest libbpf.


-- 
Regards
Sudip



Bug#1002291: bpfcc: Fails to build with libbpf/0.6.1-1

2022-02-21 Thread Vasudev Kamath
Sudip Mukherjee  writes:

> You are trying to build 0.24.0+ds and I am rebuilding 0.22.0+ds-2 to test.  :)
>
> Can you rebuild 0.22.0+ds-2 and verify.

Err yes. It works with 0.22.0. I was preparing 0.23.0 and then 0.24.0.
Both of which fails as of now. Not sure what should be done.

Cheers,
Vasudev



Bug#1002291: bpfcc: Fails to build with libbpf/0.6.1-1

2022-02-21 Thread Sudip Mukherjee
On Mon, Feb 21, 2022 at 6:32 AM Vasudev Kamath  wrote:
>
> Sudip Mukherjee  writes:
>
> > On Sat, Feb 19, 2022 at 5:36 AM Vasudev Kamath  
> > wrote:
> >>
> >> Sudip Mukherjee  writes:
> >>
> >> > I have now uploaded libbpf/0.7.0 to experimental, can you please try
> >> > building bpfcc and let me know if it works for you.
> >> >
> >>
> >> I'm ending up getting different error now related to deprecation.
> >
> > I am not sure why and how you are getting the error. I have tried
> > building bpfcc_0.22.0+ds-2 with sbuild and have also tried building in
> > an unstable VM with dpkg-buildpackage and in both the cases it has
> > built fine with libbpf/0.7.0
>
> Regular build using sbuild + git-buildpackage. Attaching the full log
> and git diff. I tried to build using libbpf 0.7.0 from experimental. But
> it continues to fail.
>
>
> Let me know if you are able to figure out. I'm bit lost and unable to
> really figure out what is happening here.

You are trying to build 0.24.0+ds and I am rebuilding 0.22.0+ds-2 to test.  :)

Can you rebuild 0.22.0+ds-2 and verify.


-- 
Regards
Sudip



Bug#1002291: bpfcc: Fails to build with libbpf/0.6.1-1

2022-02-19 Thread Sudip Mukherjee
On Sat, Feb 19, 2022 at 5:36 AM Vasudev Kamath  wrote:
>
> Sudip Mukherjee  writes:
>
> > I have now uploaded libbpf/0.7.0 to experimental, can you please try
> > building bpfcc and let me know if it works for you.
> >
>
> I'm ending up getting different error now related to deprecation.

I am not sure why and how you are getting the error. I have tried
building bpfcc_0.22.0+ds-2 with sbuild and have also tried building in
an unstable VM with dpkg-buildpackage and in both the cases it has
built fine with libbpf/0.7.0


-- 
Regards
Sudip



Bug#1002291: bpfcc: Fails to build with libbpf/0.6.1-1

2022-02-18 Thread Vasudev Kamath
Sudip Mukherjee  writes:

> I have now uploaded libbpf/0.7.0 to experimental, can you please try
> building bpfcc and let me know if it works for you.
>

I'm ending up getting different error now related to deprecation.

>/<>/src/cc/bcc_btf.cc:178:33: error: invalid application of 
>‘sizeof’ to incomplete type 
>‘btf_ext_vendored::btf_ext_setup_core_relos(btf_ext_vendored::btf_ext*)::bpf_core_relo’
>   178 | .min_rec_size = sizeof(struct bpf_core_relo),
>   | ^~~~
> /<>/src/cc/bcc_btf.cc: In member function ‘int 
> ebpf::BTF::get_map_tids(std::string, unsigned int, unsigned int, unsigned 
> int*, unsigned int*)’:
> /<>/src/cc/bcc_btf.cc:655:30: warning: ‘int 
> btf__get_map_kv_tids(const btf*, const char*, __u32, __u32, __u32*, __u32*)’ 
> is deprecated: libbpf v0.7+: this API is not necessary when BTF-defined maps 
> are used [-Wdeprecated-declarations]
>   655 |   return btf__get_map_kv_tids(btf_, map_name.c_str(),
>   |  ^~~~
>   656 |   expected_ksize, expected_vsize,
>   |   ~~~
>   657 |   key_tid, value_tid);
>   |   ~~~
> In file included from /<>/src/cc/bcc_libbpf_inc.h:5,
>  from /<>/src/cc/bcc_btf.cc:22:
> /usr/include/bpf/btf.h:154:16: note: declared here
>   154 | LIBBPF_API int btf__get_map_kv_tids(const struct btf *btf, const char 
> *map_name,
>   |^~~~
> /<>/src/cc/bcc_btf.cc: In function ‘int 
> btf_ext_vendored::btf_ext_setup_core_relos(btf_ext_vendored::btf_ext*)’:
> /<>/src/cc/bcc_btf.cc:178:33: error: invalid application of 
> ‘sizeof’ to incomplete type 
> ‘btf_ext_vendored::btf_ext_setup_core_relos(btf_ext_vendored::btf_ext*)::bpf_core_relo’
>   178 | .min_rec_size = sizeof(struct bpf_core_relo),
>   | ^~~~
> /<>/src/cc/bcc_btf.cc: In member function ‘int 
> ebpf::BTF::get_map_tids(std::string, unsigned int, unsigned int, unsigned 
> int*, unsigned int*)’:
> /<>/src/cc/bcc_btf.cc:655:30: warning: ‘int 
> btf__get_map_kv_tids(const btf*, const char*, __u32, __u32, __u32*, __u32*)’ 
> is deprecated: libbpf v0.7+: this API is not necessary when BTF-defined maps 
> are used [-Wdeprecated-declarations]
>   655 |   return btf__get_map_kv_tids(btf_, map_name.c_str(),
>   |  ^~~~
>   656 |   expected_ksize, expected_vsize,
>   |   ~~~
>   657 |   key_tid, value_tid);
>   |   ~~~
> In file included from /<>/src/cc/bcc_libbpf_inc.h:5,
>  from /<>/src/cc/bcc_btf.cc:22:
> /usr/include/bpf/btf.h:154:16: note: declared here
>   154 | LIBBPF_API int btf__get_map_kv_tids(const struct btf *btf, const char 
> *map_name,
>   |^~~~
> make[3]: *** [src/cc/CMakeFiles/bcc-shared.dir/build.make:121: 
> src/cc/CMakeFiles/bcc-shared.dir/bcc_btf.cc.o] Error 1
> make[3]: *** Waiting for unfinished jobs
> [ 69%] Building CXX object 
> src/cc/CMakeFiles/bcc-static.dir/bpf_module_rw_engine.cc.o
> cd /<>/obj-x86_64-linux-gnu/src/cc && /usr/bin/c++ -DEXPORT_USDT 
> -DHAVE_EXTERNAL_LIBBPF -I/usr/lib/llvm-13/include/../tools/clang/include 
> -I/<>/src -I/<>/obj-x86_64-linux-gnu/src 
> -I/<>/obj-x86_64-linux-gnu/src/cc -I/<>/src/cc 
> -I/<>/obj-x86_64-linux-gnu/src/cc/frontends/b 
> -I/<>/src/cc/frontends/b 
> -I/<>/src/cc/frontends/clang -I/usr/lib/llvm-13/include -g -O2 
> -ffile-prefix-map=/<>=. -fstack-protector-strong -Wformat 
> -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -DCUSTOM_MACRO=true 
> -Wall  -fno-rtti -fPIC -DBCC_PROG_TAG_DIR='"/var/tmp/bcc"' -Wno-unused-result 
> -DLLVM_MAJOR_VERSION=13 -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS 
> -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -std=gnu++14 -MD -MT 
> src/cc/CMakeFiles/bcc-static.dir/bpf_module_rw_engine.cc.o -MF 
> CMakeFiles/bcc-static.dir/bpf_module_rw_engine.cc.o.d -o 
> CMakeFiles/bcc-static.dir/bpf_module_rw_engine.cc.o -c 
> /<>/src/cc/bpf_module_rw_engine.cc
> [ 69%] Building CXX object 
> src/cc/CMakeFiles/bcc-shared.dir/exported_files.cc.o
> cd /<>/obj-x86_64-linux-gnu/src/cc && /usr/bin/c++ -DEXPORT_USDT 
> -DHAVE_EXTERNAL_LIBBPF -Dbcc_shared_EXPORTS 
> -I/usr/lib/llvm-13/include/../tools/clang/include -I/<>/src 
> -I/<>/obj-x86_64-linux-gnu/src 
> -I/<>/obj-x86_64-linux-gnu/src/cc -I/<>/src/cc 
> -I/<>/obj-x86_64-linux-gnu/src/cc/frontends/b 
> -I/<>/src/cc/frontends/b 
> -I/<>/src/cc/frontends/clang -I/usr/lib/llvm-13/include -g -O2 
> -ffile-prefix-map=/<>=. -fstack-protector-strong -Wformat 
> -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 

Bug#1002291: bpfcc: Fails to build with libbpf/0.6.1-1

2022-02-18 Thread Sudip Mukherjee
Hi Vasudev,

On Wed, Feb 16, 2022 at 7:15 PM Sudip Mukherjee
 wrote:
>
> Hi Vasudev,
>
> On Thu, Dec 23, 2021 at 6:07 PM Sudip Mukherjee
>  wrote:
> >
> > On Wed, Dec 22, 2021 at 10:52 AM Vasudev Kamath  
> > wrote:
> > >



>
> Seems like the FTBFS is not there with libbpf/0.7.0
> I will upload to experimental by Friday so that you can test.

I have now uploaded libbpf/0.7.0 to experimental, can you please try
building bpfcc and let me know if it works for you.


-- 
Regards
Sudip



Bug#1002291: bpfcc: Fails to build with libbpf/0.6.1-1

2022-02-16 Thread Sudip Mukherjee
Hi Vasudev,

On Thu, Dec 23, 2021 at 6:07 PM Sudip Mukherjee
 wrote:
>
> On Wed, Dec 22, 2021 at 10:52 AM Vasudev Kamath  
> wrote:
> >
> > Hi Sudip,
> >
> > Sudip Mukherjee  writes:
> >
> >
> > >
> > > Reported error:
>
> 
>
> > >
> >
> > I tried building bpfcc 0.23.0 with experimental libbpf and it too
> > failed. These versions are released with 0.5.0 libbpf. I see that next
> > release 0.24.0 (not sure when it happens) should work with newer libbpf.
> > Can we hold uploading newer libbpf to unstable till then?.
>
> Sure, just let me know when its ready and I can upload then.

Seems like the FTBFS is not there with libbpf/0.7.0
I will upload to experimental by Friday so that you can test.

-- 
Regards
Sudip



Bug#1002291: bpfcc: Fails to build with libbpf/0.6.1-1

2021-12-23 Thread Sudip Mukherjee
On Wed, Dec 22, 2021 at 10:52 AM Vasudev Kamath  wrote:
>
> Hi Sudip,
>
> Sudip Mukherjee  writes:
>
>
> >
> > Reported error:



> >
>
> I tried building bpfcc 0.23.0 with experimental libbpf and it too
> failed. These versions are released with 0.5.0 libbpf. I see that next
> release 0.24.0 (not sure when it happens) should work with newer libbpf.
> Can we hold uploading newer libbpf to unstable till then?.

Sure, just let me know when its ready and I can upload then.


-- 
Regards
Sudip



Bug#1002291: bpfcc: Fails to build with libbpf/0.6.1-1

2021-12-22 Thread Vasudev Kamath
Hi Sudip,

Sudip Mukherjee  writes:


>
> Reported error:
> In file included from /<>/src/cc/bcc_libbpf_inc.h:5,
>  from 
> /<>/src/cc/frontends/clang/b_frontend_action.cc:37:
> /usr/include/bpf/btf.h: In function ‘bool btf_is_mod(const btf_type*)’:
> /usr/include/bpf/btf.h:463:24: error: ‘BTF_KIND_TYPE_TAG’ was not declared in 
> this scope; did you mean ‘BTF_KIND_TYPEDEF’?
>   463 |kind == BTF_KIND_TYPE_TAG;
>   |^
>   |BTF_KIND_TYPEDEF
> /usr/include/bpf/btf.h: In function ‘bool btf_is_decl_tag(const btf_type*)’:
> /usr/include/bpf/btf.h:493:31: error: ‘BTF_KIND_DECL_TAG’ was not declared in 
> this scope; did you mean ‘BTF_KIND_FLOAT’?
>   493 | return btf_kind(t) == BTF_KIND_DECL_TAG;
>   |   ^
>   |   BTF_KIND_FLOAT
> /usr/include/bpf/btf.h: In function ‘bool btf_is_type_tag(const btf_type*)’:
> /usr/include/bpf/btf.h:498:31: error: ‘BTF_KIND_TYPE_TAG’ was not declared in 
> this scope; did you mean ‘BTF_KIND_TYPEDEF’?
>   498 | return btf_kind(t) == BTF_KIND_TYPE_TAG;
>   |   ^
>   |   BTF_KIND_TYPEDEF
>

I tried building bpfcc 0.23.0 with experimental libbpf and it too
failed. These versions are released with 0.5.0 libbpf. I see that next
release 0.24.0 (not sure when it happens) should work with newer libbpf.
Can we hold uploading newer libbpf to unstable till then?.

Thanks and Regards,
Vasudev



Bug#1002291: bpfcc: Fails to build with libbpf/0.6.1-1

2021-12-21 Thread Sudip Mukherjee
Source: bpfcc
Version: 0.22.0+ds-2
Severity: important
Tags: ftbfs
X-Debbugs-Cc: sudipm.mukher...@gmail.com

Dear Maintainer,

bpfcc is failing to build with the latest release of libbpf.

Reported error:
In file included from /<>/src/cc/bcc_libbpf_inc.h:5,
 from 
/<>/src/cc/frontends/clang/b_frontend_action.cc:37:
/usr/include/bpf/btf.h: In function ‘bool btf_is_mod(const btf_type*)’:
/usr/include/bpf/btf.h:463:24: error: ‘BTF_KIND_TYPE_TAG’ was not declared in 
this scope; did you mean ‘BTF_KIND_TYPEDEF’?
  463 |kind == BTF_KIND_TYPE_TAG;
  |^
  |BTF_KIND_TYPEDEF
/usr/include/bpf/btf.h: In function ‘bool btf_is_decl_tag(const btf_type*)’:
/usr/include/bpf/btf.h:493:31: error: ‘BTF_KIND_DECL_TAG’ was not declared in 
this scope; did you mean ‘BTF_KIND_FLOAT’?
  493 | return btf_kind(t) == BTF_KIND_DECL_TAG;
  |   ^
  |   BTF_KIND_FLOAT
/usr/include/bpf/btf.h: In function ‘bool btf_is_type_tag(const btf_type*)’:
/usr/include/bpf/btf.h:498:31: error: ‘BTF_KIND_TYPE_TAG’ was not declared in 
this scope; did you mean ‘BTF_KIND_TYPEDEF’?
  498 | return btf_kind(t) == BTF_KIND_TYPE_TAG;
  |   ^
  |   BTF_KIND_TYPEDEF


I have uploaded libbpf to experimental for now.


--
Regards
Sudip