-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Build error on Arch Linux GCC14 #26
Comments
same error on GCC-11 with setup command |
Try to use
It seems the error was occurred in #define _GL_VERIFY_TYPE(R, DIAGNOSTIC) { } |
If you're not using virtio-vgpu, which emulates an OpenGL-compatible GPU within the guest operating system, you should remove the flag |
I get the same error without vgpu and setup command EDIT: this makes it build however runtime gives me an assertion error |
diff --git a/.gitignore b/.gitignore
index 25b5caf..0c10f7e 100644
--- a/.gitignore
+++ b/.gitignore
@@ -8,4 +8,3 @@ config/default.yaml
.clang-format
.vscode/
.DS_Store
-.cache/
diff --git a/devices/display/qxl/canvas/lz_common.h b/devices/display/qxl/canvas/lz_common.h
index a99ede0..9b3905f 100644
--- a/devices/display/qxl/canvas/lz_common.h
+++ b/devices/display/qxl/canvas/lz_common.h
@@ -24,7 +24,7 @@
#define H_SPICE_COMMON_LZ_COMMON
#include <spice/macros.h>
-// #include "verify.h"
+#include "verify.h"
SPICE_BEGIN_DECLS
@@ -56,10 +56,10 @@ static const int IS_IMAGE_TYPE_RGB[] = {0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1};
static const int PLT_PIXELS_PER_BYTE[] = {0, 8, 8, 2, 2, 1};
static const int RGB_BYTES_PER_PIXEL[] = {0, 1, 1, 1, 1, 1, 2, 3, 4, 4, 4, 1};
-// verify(SPICE_N_ELEMENTS(IS_IMAGE_TYPE_PLT) == (LZ_IMAGE_TYPE_A8 + 1));
-// verify(SPICE_N_ELEMENTS(IS_IMAGE_TYPE_RGB) == (LZ_IMAGE_TYPE_A8 + 1));
-// verify(SPICE_N_ELEMENTS(PLT_PIXELS_PER_BYTE) == (LZ_IMAGE_TYPE_PLT8 + 1));
-// verify(SPICE_N_ELEMENTS(RGB_BYTES_PER_PIXEL) == (LZ_IMAGE_TYPE_A8 + 1));
+verify(SPICE_N_ELEMENTS(IS_IMAGE_TYPE_PLT) == (LZ_IMAGE_TYPE_A8 + 1));
+verify(SPICE_N_ELEMENTS(IS_IMAGE_TYPE_RGB) == (LZ_IMAGE_TYPE_A8 + 1));
+verify(SPICE_N_ELEMENTS(PLT_PIXELS_PER_BYTE) == (LZ_IMAGE_TYPE_PLT8 + 1));
+verify(SPICE_N_ELEMENTS(RGB_BYTES_PER_PIXEL) == (LZ_IMAGE_TYPE_A8 + 1));
/* ASCII "LZ " */
#define LZ_MAGIC 0x20205a4c
diff --git a/devices/display/qxl/canvas/macros.h b/devices/display/qxl/canvas/macros.h
index 7338238..01765ab 100644
--- a/devices/display/qxl/canvas/macros.h
+++ b/devices/display/qxl/canvas/macros.h
@@ -19,7 +19,7 @@
#ifndef H_SPICE_COMMON_MACROS
#define H_SPICE_COMMON_MACROS
-// #include "verify.h"
+#include "verify.h"
#ifdef __GNUC__
#define SPICE_CONSTRUCTOR_FUNC(func_name) \
@@ -43,7 +43,7 @@
#error Please implement SPICE_CONSTRUCTOR_FUNC and SPICE_DESTRUCTOR_FUNC for this compiler
#endif
-// #define SPICE_VERIFY(cond) verify_expr(cond, (void)1)
+#define SPICE_VERIFY(cond) verify_expr(cond, (void)1)
#if __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 5)
#define SPICE_UNREACHABLE __builtin_unreachable()
diff --git a/devices/display/qxl/canvas/quic.c b/devices/display/qxl/canvas/quic.c
index 468de70..22c17aa 100644
--- a/devices/display/qxl/canvas/quic.c
+++ b/devices/display/qxl/canvas/quic.c
@@ -214,8 +214,8 @@ static const unsigned int tabrand_chaos[TABRAND_TABSIZE] = {
static unsigned int stabrand(void)
{
- // SPICE_VERIFY( !(TABRAND_SEEDMASK & TABRAND_TABSIZE));
- // SPICE_VERIFY( TABRAND_SEEDMASK + 1 == TABRAND_TABSIZE );
+ SPICE_VERIFY( !(TABRAND_SEEDMASK & TABRAND_TABSIZE));
+ SPICE_VERIFY( TABRAND_SEEDMASK + 1 == TABRAND_TABSIZE );
return TABRAND_SEEDMASK;
}
@@ -240,7 +240,7 @@ static void set_wm_trigger(CommonState *state)
wm = 10;
}
- // SPICE_VERIFY(DEFevol < 6);
+ SPICE_VERIFY(DEFevol < 6);
state->wm_trigger = besttrigtab[DEFevol / 2][wm];
@@ -705,7 +705,7 @@ static void find_model_params(Encoder *encoder,
/* The only valid values are 1, 3 and 5.
0, 2 and 4 are obsolete and the rest of the
values are considered out of the range. */
- // SPICE_VERIFY(DEFevol == 1 || DEFevol == 3 || DEFevol == 5);
+ SPICE_VERIFY(DEFevol == 1 || DEFevol == 3 || DEFevol == 5);
spice_assert(bpc <= 8 && bpc > 0);
*ncounters = 8;
diff --git a/devices/display/qxl/canvas/quic_family_tmpl.c b/devices/display/qxl/canvas/quic_family_tmpl.c
index 0977c0f..6a05fb6 100644
--- a/devices/display/qxl/canvas/quic_family_tmpl.c
+++ b/devices/display/qxl/canvas/quic_family_tmpl.c
@@ -67,7 +67,7 @@ static unsigned int FNAME(golomb_decoding)(const unsigned int l, const unsigned
static void FNAME(update_model)(CommonState *state, s_bucket * const bucket,
const BYTE curval)
{
- // SPICE_VERIFY(BPC >= 1);
+ SPICE_VERIFY(BPC >= 1);
spice_return_if_fail (bucket != NULL);
const unsigned int bpp = BPC; this patch seems to work for archlinux, it just removes all usage of verify.h |
This header file |
it seem the same error in void linux when bulid.
|
@youfun The verify.h file has been deleted, and the code has been merged into the master branch. You can try again. |
|
It seems you have configured virtio-vgpu before. |
Hello, I am trying to build this project on arch linux, I have the dependencies installed and the build setup succeeds with the commandline
meson setup build -Dsdl=true -Dvgpu=true
however the build command fails as followsThe text was updated successfully, but these errors were encountered: