Building qemu screamer on linux

About Qemu-system-ppc, a PPC Mac emulator for Windows, macOS and Linux that can run Mac OS 9.0 up to Mac OS X 10.5

Moderators: Cat_7, Ronald P. Regensburg

Post Reply
tonyrh
Space Cadet
Posts: 9
Joined: Sun Sep 13, 2009 3:16 pm

Building qemu screamer on linux

Post by tonyrh »

Hi,
recently I had to build qemu screamer again because I upgraded my system and reinstalled the OS.
I got the source with:

Code: Select all

git clone --recursive -b screamer https://github.com/mcayland/qemu.git qemu-screamer
and proceeded to configure the building process with:

Code: Select all

./configure --target-list="ppc-softmmu" --enable-sdl --enable-gtk
I got a problem with:

Code: Select all

FAILED: libcommon.fa.p/ebpf_ebpf_rss.c.o 
cc -m64 -mcx16 -Ilibcommon.fa.p -I../common-user/host/x86_64 -I/usr/include/capstone -I/usr/include/pixman-1 -I/usr/include/libpng16 -I/usr/include/p11-kit-1 -I/usr/include/SDL2 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/sysprof-4 -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/gio-unix-2.0 -I/usr/include/slirp -I/usr/include/gtk-3.0 -I/usr/include/pango-1.0 -I/usr/include/harfbuzz -I/usr/include/freetype2 -I/usr/include/fribidi -I/usr/include/cairo -I/usr/include/lzo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/cloudproviders -I/usr/include/atk-1.0 -I/usr/include/at-spi2-atk/2.0 -I/usr/include/at-spi-2.0 -I/usr/include/dbus-1.0 -I/usr/lib/dbus-1.0/include -I/usr/include/vte-2.91 -I/usr/include/virgl -I/usr/include/cacard -I/usr/include/nss -I/usr/include/nspr -I/usr/include/libusb-1.0 -fdiagnostics-color=auto -Wall -Winvalid-pch -Werror -std=gnu11 -O2 -g -isystem /home/antonio/src/qemu-screamer/linux-headers -isystem linux-headers -iquote . -iquote /home/antonio/src/qemu-screamer -iquote /home/antonio/src/qemu-screamer/include -iquote /home/antonio/src/qemu-screamer/disas/libvixl -iquote /home/antonio/src/qemu-screamer/tcg/i386 -pthread -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -Wstrict-prototypes -Wredundant-decls -Wundef -Wwrite-strings -Wmissing-prototypes -fno-strict-aliasing -fno-common -fwrapv -Wold-style-declaration -Wold-style-definition -Wtype-limits -Wformat-security -Wformat-y2k -Winit-self -Wignored-qualifiers -Wempty-body -Wnested-externs -Wendif-labels -Wexpansion-to-defined -Wimplicit-fallthrough=2 -Wno-missing-include-dirs -Wno-shift-negative-value -Wno-psabi -fstack-protector-strong -fPIE -DHWY_SHARED_DEFINE -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=600 -DNCURSES_WIDECHAR=1 -D_REENTRANT -Wno-undef -DSTRUCT_IOVEC_DEFINED -MD -MQ libcommon.fa.p/ebpf_ebpf_rss.c.o -MF libcommon.fa.p/ebpf_ebpf_rss.c.o.d -o libcommon.fa.p/ebpf_ebpf_rss.c.o -c ../ebpf/ebpf_rss.c
../ebpf/ebpf_rss.c: In function ‘ebpf_rss_load’:
../ebpf/ebpf_rss.c:52:5: error: implicit declaration of function ‘bpf_program__set_socket_filter’; did you mean ‘bpf_program__set_log_level’? [-Werror=implicit-function-declaration]
   52 |     bpf_program__set_socket_filter(rss_bpf_ctx->progs.tun_rss_steering_prog);
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |     bpf_program__set_log_level
../ebpf/ebpf_rss.c:52:5: error: nested extern declaration of ‘bpf_program__set_socket_filter’ [-Werror=nested-externs]
cc1: all warnings being treated as errors
I thought of disabling warnings being treated as errors with:

Code: Select all

CFLAGS=-Wno-error ./configure --target-list="ppc-softmmu" --enable-sdl --enable-gtk
but then the linker complains:

Code: Select all

/usr/bin/ld: libcommon.fa.p/ebpf_ebpf_rss.c.o: in function `ebpf_rss_load':
/home/antonio/src/qemu-screamer/build/../ebpf/ebpf_rss.c:52: undefined reference to `bpf_program__set_socket_filter'
collect2: error: ld returned 1 exit status
Googling a bit I found that the bpf_program__set_socket_filter function has been deprecated.
This was patched in qemu https://patchew.org/QEMU/20220527190658 ... chain.org/ but maybe the screamer fork is a bit behind?
Any idea how I could fix this?
User avatar
adespoton
Forum All-Star
Posts: 4226
Joined: Fri Nov 27, 2009 5:11 am
Location: Emaculation.com
Contact:

Re: Building qemu screamer on linux

Post by adespoton »

Probably worth filing an issue against the screamer fork about that.
User avatar
Cat_7
Expert User
Posts: 6145
Joined: Fri Feb 13, 2004 8:59 am
Location: Sittard, The Netherlands

Re: Building qemu screamer on linux

Post by Cat_7 »

I was waiting to ask the developer to rebase the screamer code on qemu 7.2 when it is final, but I guess asking now will also allow us to rebase it ourselves when 7.2 is final.

Best,
Cat_7
Post Reply