Skip to content
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 fails with waveform.c:690:18: error: ‘ddb_waveformat_t’ has no member named ‘is_bigendian’ (GCC 13.2.1) #33

Open
dreirund opened this issue Sep 22, 2023 · 2 comments

Comments

@dreirund
Copy link

dreirund commented Sep 22, 2023

Ahoj,

I try to build this software according to ↗ this recipe.

Build of the GTK2 variant fails for me with
waveform.c:690:18: error: ‘ddb_waveformat_t’ has no member named ‘is_bigendian’:

waveform.c: In function ‘waveform_generate_wavedata’:
waveform.c:690:18: error: ‘ddb_waveformat_t’ has no member named ‘is_bigendian’
  690 |                 .is_bigendian = 0
      |                  ^~~~~~~~~~~~
waveform.c: At top level:
waveform.c:1405:18: warning: initialization of ‘int (*)(struct DB_plugin_action_s *, ddb_action_context_t)’ {aka ‘int (*)(struct DB_plugin_action_s *, enum ddb_action_context_e)’} from incompatible pointer type ‘int (*)(DB_plugin_action_t *, int)’ {aka ‘int (*)(struct DB_plugin_action_s *, int)’} [-Wincompatible-pointer-types]
 1405 |     .callback2 = waveform_action_lookup,
      |                  ^~~~~~~~~~~~~~~~~~~~~~
waveform.c:1405:18: note: (near initialization for ‘lookup_action.callback2’)
make: *** [Makefile:96: gtk2/waveform.o] Error 1

GCC version: 13.2.1,
GTK2 version 2.24.33,
on Artix GNU/Linux (rolling release).

Regards!

@cbirchinger
Copy link

As a workaround you can add -DDDB_API_LEVEL=15 to CFLAGS
The reason is deadbeef.h added this define:

#if (DDB_API_LEVEL >= 17)
    uint32_t flags;
#else
    int is_bigendian;
#endif

@dreirund
Copy link
Author

As a workaround you can add -DDDB_API_LEVEL=15 to CFLAGS The reason is deadbeef.h added this define:

I can confirm that this workaround works.

I leave this issue open since it is only a workaround, and ddb_waveform_seekbar should be adapted to fit the new DDB_API_LEVEL.

Regards!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants