diff options
| author | Michael S. Tsirkin <mst@redhat.com> | 2025-12-04 12:22:43 -0500 |
|---|---|---|
| committer | Michael S. Tsirkin <mst@redhat.com> | 2025-12-24 08:02:56 -0500 |
| commit | 4e949e77fa5e335ff32f177fd37d3e469fd396f9 (patch) | |
| tree | 7178dbd3e6dc5968b552bec8fb4a74fa0ce1d47c | |
| parent | b6600eff0559ef69479cf6b7dccafddf451c6842 (diff) | |
tools/virtio: pass KCFLAGS to module build
Update the mod target to pass KCFLAGS with the in-tree vhost driver
include path. This way vhost_test can find vhost headers.
Created using Cursor CLI.
Message-ID: <5473e5a5dfd2fcd261a778f2017cac669c031f23.1764873799.git.mst@redhat.com>
Acked-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
| -rw-r--r-- | tools/virtio/Makefile | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/virtio/Makefile b/tools/virtio/Makefile index e25e99c1c3b7..a60316211df6 100644 --- a/tools/virtio/Makefile +++ b/tools/virtio/Makefile @@ -20,8 +20,9 @@ CFLAGS += -g -O2 -Werror -Wno-maybe-uninitialized -Wall -I. -I../include/ -I ../ CFLAGS += -pthread LDFLAGS += -pthread vpath %.c ../../drivers/virtio ../../drivers/vhost +BUILD=KCFLAGS="-I "`pwd`/../../drivers/vhost ${MAKE} -C `pwd`/../.. V=${V} mod: - ${MAKE} -C `pwd`/../.. M=`pwd`/vhost_test V=${V} + ${BUILD} M=`pwd`/vhost_test #oot: build vhost as an out of tree module for a distro kernel #no effort is taken to make it actually build or work, but tends to mostly work |
