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 error: OSCNode.cpp:153:28: error: cannot convert 'lo_arg*' to 'lo_blob' {aka 'lo_blob_*'} in initialization #1949

Open
topas-rec opened this issue Mar 27, 2024 · 5 comments · Fixed by #1954

Comments

@topas-rec
Copy link

I get

plugins/osc/OSCNode.cpp: In function 'int ola::plugin::osc::OSCDataHandler(const char*, const char*, lo_arg**, int, void*, void*)':
plugins/osc/OSCNode.cpp:153:28: error: cannot convert 'lo_arg*' to 'lo_blob' {aka 'lo_blob_*'} in initialization
  153 |       lo_blob blob = argv[0];
      |                      ~~~~~~^
      |                            |
      |                            lo_arg*
plugins/osc/OSCNode.cpp: In member function 'bool ola::plugin::osc::OSCNode::Init()':
plugins/osc/OSCNode.cpp:266:50: error: invalid conversion from 'int (*)(const char*, const char*, lo_arg**, int, void*, void*)' to 'lo_method_handler' {aka 'int (*)(const char*, const char*, lo_arg**, int, lo_message_*, void*)'} [-fpermissive]
  266 |   lo_server_add_method(m_osc_server, NULL, NULL, OSCDataHandler, this);
      |                                                  ^~~~~~~~~~~~~~
      |                                                  |
      |                                                  int (*)(const char*, const char*, lo_arg**, int, void*, void*)
In file included from /usr/include/lo/lo.h:32,
                 from ./plugins/osc/OSCNode.h:24:
/usr/include/lo/lo_lowlevel.h:876:72: note:   initializing argument 4 of 'lo_method_* lo_server_add_method(lo_server, const char*, const char*, lo_method_handler, const void*)'
  876 |                                const char *typespec, lo_method_handler h,
      |                                                      ~~~~~~~~~~~~~~~~~~^
make[2]: *** [Makefile:12250: plugins/osc/libolaoscnode_la-OSCNode.lo] Error 1
make[2]: Leaving directory '/home/tobiasb/.cache/rua/build/ola/src/ola-0.10.9'
make[1]: *** [Makefile:16480: all-recursive] Error 1
make[1]: Leaving directory '/home/tobiasb/.cache/rua/build/ola/src/ola-0.10.9'
make: *** [Makefile:7553: all] Error 2
==> ERROR: A failure occurred in build().
    Aborting...

during the build.
Is someone else having this, too?

@kripton
Copy link
Member

kripton commented Mar 27, 2024

Hi, thanks for reporting. Could we please get some more info on your environment? Which version of OLA are you trying to compile? With which version of gcc and libc? Thanks :)

@kripton
Copy link
Member

kripton commented Mar 27, 2024

Alright, I just saw osam-cologne/archlinux-proaudio#396. @cbix, is there something that broke compatibility on liblo that we should consider?

@cbix
Copy link
Contributor

cbix commented Mar 27, 2024

@kripton yes, the liblo 0.32 update (first release in 4 years) apparently includes breaking changes in the header.

@peternewman
Copy link
Member

Generally a config.log helps, but as @kripton says @cbix has found the cause.

If you just need to get going in the short term and don't need OSC, you should be able to just --disable-osc during configure and it will build everything but the OSC plugin.

Specifically it seems to be this commit:
johnty/liblo@2c1ef1c

From what I can see, the library ABI version is still liblo7, so if we need two different codepaths, we'll have to detect the library's numeric version and work from there to work around this behaviour.

@topas-rec
Copy link
Author

topas-rec commented Mar 28, 2024

Config log is here:
config.log

edit: I am checking --disable-osc works around the issue - thanks for that hint.

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

Successfully merging a pull request may close this issue.

4 participants