Re: xdp2 on ubuntu-24.04.3-live-server-amd64?
dave seddon <[email protected]> Sat, 27 Sep 2025 07:33:48 -0700
| Newsgroups | dev.linux.lists.xdp2 |
|---|---|
| Message-ID | <CANypexTJF8ET9JkhSh3y_cEwhGU5oV+Rw14_u4SKGm_BqbmftQ@mail.gmail.com> |
Oh. And then "make" needs scapy, so you need to do "sudo apt install python3-scapy". Maybe configure should check for scapy? On Sat, Sep 27, 2025 at 7:25=E2=80=AFAM dave seddon <[email protected]= om> wrote: > > I added the extra packages "clang-tools libclang-dev llvm-dev " > > The full set of packages is now "build-essential gcc-multilib > pkg-config bison flex libboost-all-dev libpcap-dev graphviz libelf-dev > clang clang-tools libclang-dev llvm llvm-dev libbpf-dev > linux-tools-$(uname -r)" > > das@ubuntu2404:~/xdp2/src$ ./configure > > > Platform is default > Architecture is x86_64 > Architecture includes for x86_64 not found, using generic > Target Architecture is > COMPILER is gcc > XDP2_CLANG_VERSION=3D18.1.3 > XDP2_C_INCLUDE_PATH=3D/usr/lib/llvm-18/lib/clang/18/include > XDP2_CLANG_RESOURCE_PATH=3D/usr/lib/llvm-18/lib/clang/18 > > das@ubuntu2404:~/xdp2/src$ > > On Fri, Sep 26, 2025 at 5:53=E2=80=AFPM Tom Herbert <[email protected]>= wrote: > > > > On Fri, Sep 26, 2025 at 5:47=E2=80=AFPM dave seddon <dave.seddon.ca@gma= il.com> wrote: > > > > > > Ha! Indeed. I have a version of configure that has significantly more= output. ( I removed all the pipes to null, which allowed me to get miles p= ast this in my nix version. ) > > > > > > > > > > > > das@ubuntu2404:~/xdp2/src$ cp configure old.configure > > > > > > das@ubuntu2404:~/xdp2/src$ diff -u ./configure ./old.configure > > > --- ./configure 2025-09-27 00:40:29.837033843 +0000 > > > +++ ./old.configure 2025-09-27 00:38:51.186921865 +0000 > > > @@ -163,7 +163,7 @@ > > > } > > > EOF > > > $HOST_CXX -o $TMPDIR/clang_lib $TMPDIR/clang_lib.cpp \ > > > - `$HOST_LLVM_CONFIG --ldflags --cxxflags` -lc= lang -lLLVM -lclang-cpp > > > + `$HOST_LLVM_CONFIG --ldflags --cxxflags` -lc= lang -lLLVM -lclang-cpp > /dev/null 2>&1 > > > case $? in > > > 0) ;; > > > *) echo Clang library missing or broken\! 1>&2 > > > das@ubuntu2404:~/xdp2/src$ > > > > > > das@ubuntu2404:~/xdp2/src$ ./configure > > > > > > > > > Platform is default > > > Architecture is x86_64 > > > Architecture includes for x86_64 not found, using generic > > > Target Architecture is > > > COMPILER is gcc > > > config.SNTIAl/clang_lib.cpp:1:10: fatal error: clang/Frontend/Compile= rInstance.h: No such file or directory > > > 1 | #include <clang/Frontend/CompilerInstance.h> > > > | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > > > compilation terminated. > > > Clang library missing or broken! > > > das@ubuntu2404:~/xdp2/src$ > > > > > > > > > I'm just using a little kvm VM with the base ubuntu LTS installed. Y= ou guys must be developing on another distro? I'm really just looking to u= nderstand the versions of things that work, so I can nix-ify this. > > > > Did you Google it? Here's what I got: > > https://stackoverflow.com/questions/20363082/working-with-clang-in-c > > > > Tom > > > > > > > > On Fri, Sep 26, 2025, 17:26 Tom Herbert <[email protected]> wrote: > > >> > > >> On Fri, Sep 26, 2025 at 5:08=E2=80=AFPM dave seddon <dave.seddon.ca@= gmail.com> wrote: > > >> > > > >> > I hope I'm not doing something silly > > >> > > > >> > das@ubuntu2404:/usr/lib/llvm-18/lib$ ls -la | grep libclang > > >> > lrwxrwxrwx 1 root root 40 May 27 2024 libclang-18.so.1 -> > > >> > ../../x86_64-linux-gnu/libclang-18.so.18 > > >> > lrwxrwxrwx 1 root root 40 May 27 2024 libclang-18.so.18 -> > > >> > ../../x86_64-linux-gnu/libclang-18.so.18 > > >> > -rw-r--r-- 1 root root 64796088 May 27 2024 libclang-cpp.so.18.1 > > >> > lrwxrwxrwx 1 root root 17 May 27 2024 libclang.so.1 -> lib= clang-18.so.18 > > >> > > > >> > das@ubuntu2404:/usr/lib/llvm-18/lib$ sudo ln -s libclang-cpp.so.18= .1 > > >> > libclang-cpp.so > > >> > > > >> > das@ubuntu2404:/usr/lib/llvm-18/lib$ ls -la | grep libclang > > >> > lrwxrwxrwx 1 root root 40 May 27 2024 libclang-18.so.1 -> > > >> > ../../x86_64-linux-gnu/libclang-18.so.18 > > >> > lrwxrwxrwx 1 root root 40 May 27 2024 libclang-18.so.18 -> > > >> > ../../x86_64-linux-gnu/libclang-18.so.18 > > >> > lrwxrwxrwx 1 root root 20 Sep 27 00:01 libclang-cpp.so -> > > >> > libclang-cpp.so.18.1 > > >> > -rw-r--r-- 1 root root 64796088 May 27 2024 libclang-cpp.so.18.1 > > >> > lrwxrwxrwx 1 root root 17 May 27 2024 libclang.so.1 -> lib= clang-18.so.18 > > >> > das@ubuntu2404:/usr/lib/llvm-18/lib$ > > >> > > > >> > das@ubuntu2404:~$ cd xdp2/src/ > > >> > das@ubuntu2404:~/xdp2/src$ ./configure > > >> > > > >> > > > >> > Platform is default > > >> > Architecture is x86_64 > > >> > Architecture includes for x86_64 not found, using generic > > >> > Target Architecture is > > >> > COMPILER is gcc > > >> > Clang library missing or broken! > > >> > > >> Unfortunately, we've done too good of a job hiding output from the > > >> user :-(. Can you edit configure script and the build line under > > >> check_clang_lib: > > >> > > >> $HOST_CXX -o $TMPDIR/clang_lib $TMPDIR/clang_lib.cpp \ > > >> `$HOST_LLVM_CONFIG --ldflags --cxxflags` -lclang -lLLVM -lclang-cpp = > > > >> /dev/null 2>&1 > > >> > > >> to > > >> > > >> $HOST_CXX -o $TMPDIR/clang_lib $TMPDIR/clang_lib.cpp \ > > >> `$HOST_LLVM_CONFIG --ldflags --cxxflags` -lclang -lLLVM -lclang-cpp > > >> > > >> That should give the error causing the failure > > >> > > >> Tom > > >> > > >> > > >> > das@ubuntu2404:~/xdp2/src$ > > >> > > > >> > > > >> > Also tried this, although I'm not sure the full path makes much di= fference > > >> > > > >> > das@ubuntu2404:/usr/lib/llvm-18/lib$ sudo ln -s > > >> > /usr/lib/llvm-18/lib/libclang-cpp.so.18.1 > > >> > /usr/lib/llvm-18/lib/libclang-cpp.so > > >> > > > >> > das@ubuntu2404:~/xdp2/src$ ls -la /usr/lib/llvm-18/lib/ | grep cla= ng > > >> > drwxr-xr-x 3 root root 4096 Sep 26 23:59 clang > > >> > lrwxrwxrwx 1 root root 40 May 27 2024 libclang-18.so.1 -> > > >> > ../../x86_64-linux-gnu/libclang-18.so.18 > > >> > lrwxrwxrwx 1 root root 40 May 27 2024 libclang-18.so.18 -> > > >> > ../../x86_64-linux-gnu/libclang-18.so.18 > > >> > lrwxrwxrwx 1 root root 41 Sep 27 00:06 libclang-cpp.so -> > > >> > /usr/lib/llvm-18/lib/libclang-cpp.so.18.1 > > >> > -rw-r--r-- 1 root root 64796088 May 27 2024 libclang-cpp.so.18.1 > > >> > lrwxrwxrwx 1 root root 17 May 27 2024 libclang.so.1 -> lib= clang-18.so.18 > > > > -- > Regards, > Dave Seddon > +1 415 857 5102 --=20 Regards, Dave Seddon +1 415 857 5102