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

Unable to compile on Ubuntu #608

Open
wlcif opened this issue Feb 15, 2025 · 4 comments
Open

Unable to compile on Ubuntu #608

wlcif opened this issue Feb 15, 2025 · 4 comments

Comments

@wlcif
Copy link

wlcif commented Feb 15, 2025

Hello, I'm unable to compile DSDA-Doom on Ubuntu Linux, this is the error log:

[ 91%] Building C object src/CMakeFiles/dsda-doom.dir/MUSIC/flplayer.c.o
/home/lubuntu/dsda/dsda-doom-master/prboom2/src/MUSIC/flplayer.c: In function ‘fl_init’:
/home/lubuntu/dsda/dsda-doom-master/prboom2/src/MUSIC/flplayer.c:177:40: warning: passing argument 2 of ‘fluid_set_log_function’ from incompatible pointer type [-Wincompatible-pointer-types]
  177 |     fluid_set_log_function(FLUID_WARN, fl_null_logger, NULL);
      |                                        ^~~~~~~~~~~~~~
      |                                        |
      |                                        void (*)(int,  const char *, void *)
In file included from /usr/include/fluidsynth.h:101,
                 from /home/lubuntu/dsda/dsda-doom-master/prboom2/src/MUSIC/flplayer.c:68:
/usr/include/fluidsynth/log.h:73:77: note: expected ‘fluid_log_function_t’ {aka ‘void (*)(int,  char *, void *)’} but argument is of type ‘void (*)(int,  const char *, void *)’
   73 | fluid_log_function_t fluid_set_log_function(int level, fluid_log_function_t fun, void* data);
      |                                                        ~~~~~~~~~~~~~~~~~~~~~^~~
/home/lubuntu/dsda/dsda-doom-master/prboom2/src/MUSIC/flplayer.c:296:18: warning: implicit declaration of function ‘new_fluid_defsfloader’; did you mean ‘new_fluid_player’? [-Wimplicit-function-declaration]
  296 |       sfloader = new_fluid_defsfloader(f_set);
      |                  ^~~~~~~~~~~~~~~~~~~~~
      |                  new_fluid_player
/home/lubuntu/dsda/dsda-doom-master/prboom2/src/MUSIC/flplayer.c:296:16: warning: assignment to ‘fluid_sfloader_t *’ {aka ‘struct _fluid_sfloader_t *’} from ‘int’ makes pointer from integer without a cast [-Wint-conversion]
  296 |       sfloader = new_fluid_defsfloader(f_set);
      |                ^
/home/lubuntu/dsda/dsda-doom-master/prboom2/src/MUSIC/flplayer.c:297:7: warning: implicit declaration of function ‘fluid_sfloader_set_callbacks’ [-Wimplicit-function-declaration]
  297 |       fluid_sfloader_set_callbacks(sfloader, fl_sfopen, fl_sfread, fl_sfseek,
      |       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
[ 91%] Building C object src/CMakeFiles/dsda-doom.dir/MUSIC/madplayer.c.o
[ 92%] Building C object src/CMakeFiles/dsda-doom.dir/MUSIC/midifile.c.o
[ 92%] Building C object src/CMakeFiles/dsda-doom.dir/MUSIC/opl.c.o
[ 92%] Building C object src/CMakeFiles/dsda-doom.dir/MUSIC/opl3.c.o
[ 93%] Building C object src/CMakeFiles/dsda-doom.dir/MUSIC/oplplayer.c.o
[ 93%] Building C object src/CMakeFiles/dsda-doom.dir/MUSIC/opl_queue.c.o
[ 94%] Building C object src/CMakeFiles/dsda-doom.dir/MUSIC/portmidiplayer.c.o
[ 94%] Building C object src/CMakeFiles/dsda-doom.dir/MUSIC/vorbisplayer.c.o
[ 94%] Building C object src/CMakeFiles/dsda-doom.dir/gl_clipper.c.o
[ 95%] Building C object src/CMakeFiles/dsda-doom.dir/gl_drawinfo.c.o
[ 95%] Building C object src/CMakeFiles/dsda-doom.dir/gl_fbo.c.o
[ 96%] Building C object src/CMakeFiles/dsda-doom.dir/gl_light.c.o
[ 96%] Building C object src/CMakeFiles/dsda-doom.dir/gl_main.c.o
[ 96%] Building C object src/CMakeFiles/dsda-doom.dir/gl_map.c.o
[ 97%] Building C object src/CMakeFiles/dsda-doom.dir/gl_missingtexture.c.o
[ 97%] Building C object src/CMakeFiles/dsda-doom.dir/gl_opengl.c.o
[ 98%] Building C object src/CMakeFiles/dsda-doom.dir/gl_preprocess.c.o
[ 98%] Building C object src/CMakeFiles/dsda-doom.dir/gl_progress.c.o
[ 98%] Building C object src/CMakeFiles/dsda-doom.dir/gl_shader.c.o
[ 99%] Building C object src/CMakeFiles/dsda-doom.dir/gl_sky.c.o
[ 99%] Building C object src/CMakeFiles/dsda-doom.dir/gl_texture.c.o
[100%] Building C object src/CMakeFiles/dsda-doom.dir/gl_vertex.c.o
[100%] Building C object src/CMakeFiles/dsda-doom.dir/gl_wipe.c.o
[100%] Linking CXX executable ../dsda-doom
CMakeFiles/dsda-doom.dir/MUSIC/flplayer.c.o: In function `fl_init':
flplayer.c:(.text+0x795): undefined reference to `fluid_sfloader_set_callbacks'
collect2: error: ld returned 1 exit status
src/CMakeFiles/dsda-doom.dir/build.make:6375: recipe for target 'dsda-doom' failed
make[2]: *** [dsda-doom] Error 1
CMakeFiles/Makefile2:173: recipe for target 'src/CMakeFiles/dsda-doom.dir/all' failed
make[1]: *** [src/CMakeFiles/dsda-doom.dir/all] Error 2
Makefile:151: recipe for target 'all' failed
make: *** [all] Error 2

I've tried 0.27.5, 0.28.3 and master branches. Always I got the same error. GCC/G++ 10.3.

@fabiangreffrath
Copy link
Collaborator

Well, we do CI on Ubuntu. So, which version of Ubuntu is this and which version of the fluidsynth library?

@wlcif
Copy link
Author

wlcif commented Feb 15, 2025

Ubuntu 18.04 i686, FluidSynth 1.1.9.

@suve
Copy link
Contributor

suve commented Feb 15, 2025

Looking at FluidSynth's repo, it seems to me that new_fluid_defsfloader() is only available since version 2.0.0: FluidSynth/fluidsynth@f55e90a

@ceski-1
Copy link
Contributor

ceski-1 commented Feb 16, 2025

Loading a soundfont from memory (for SNDFONT support) requires at least FluidSynth 2.0.0. If this source port continues to support FluidSynth 1.x.x, I think that requires an #if FLUIDSYNTH_VERSION_MAJOR == 1 block that writes the SNDFONT lump to a temporary file and then loads it.

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

4 participants