diff --git a/api/virtio/virtio.hpp b/api/virtio/virtio.hpp index e913c51b4..7bf257e83 100644 --- a/api/virtio/virtio.hpp +++ b/api/virtio/virtio.hpp @@ -34,10 +34,13 @@ #include "../hw/pci_device.hpp" #include +#include #include #include -#define PAGE_SIZE 4096 +#if ! defined(PAGE_SIZE) +#error "PAGE_SIZE not defined. Expected it to be defined by musl's limits.h" +#endif #define VIRTIO_F_NOTIFY_ON_EMPTY 24 #define VIRTIO_F_ANY_LAYOUT 27 diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index d212b22a2..572f3e38d 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -46,7 +46,7 @@ if (DEBUG_INFO) set(NO_DEBUG "") endif() -set(CMAKE_CXX_FLAGS "-g -O0 -std=c++20 -Wall -Wextra -Wno-frame-address -Wno-unused-function -Wno-int-to-pointer-cast -D__id_t_defined -DUNITTESTS -DURI_THROW_ON_ERROR ${NO_INFO} ${NO_DEBUG} -DGSL_THROW_ON_CONTRACT_VIOLATION -Dlest_FEATURE_AUTO_REGISTER=1 -DHAVE_LEST_MAIN") +set(CMAKE_CXX_FLAGS "-g -O0 -std=c++20 -Wall -Wextra -Wno-frame-address -Wno-unused-function -Wno-int-to-pointer-cast -D__id_t_defined -DUNITTESTS -DURI_THROW_ON_ERROR ${NO_INFO} ${NO_DEBUG} -DGSL_THROW_ON_CONTRACT_VIOLATION -Dlest_FEATURE_AUTO_REGISTER=1 -DHAVE_LEST_MAIN -DPAGE_SIZE=4096") set(TEST ${CMAKE_CURRENT_SOURCE_DIR})