fluid directory compile/link issue
When I build my Debug build I get this series of errors at the end, during the link:
It starts here:
audiofile/audiofile.h includes sndfile.h, but it has this error calling a sndfile.h function:
The second to last issue seems to be the culmination of all the lines above it, and that's here in fluid/fluidgui.cpp:
That erroneous line of code points to this bit in synthesizer/synthesizergui.cpp:
fluid/fluidgui.h has this include, so that part should be OK:
#include "synthesizer/synthesizergui.h"
What am I missing? I have installed all the dependencies listed in the compile instructions, including:
libsndfile, ogg, and vorbis, which seem to be the issue here. I just reinstalled the binaries for libsndfile to make sure.
Comments
I just turned off SOUNDFONT3 in my CMake configuration on the Qt Creator Build page. Now I only get one error, the same one in fluid/fluidgui.cpp, what I refer to as the second to last error in my original post.
Here is the Compile Output version of the error:
../fluid/libfluid.a(fluidgui.cpp.obj): In function
ZN8FluidGuiC2EPN2Ms11SynthesizerE':
Ms::SynthesizerGui::SynthesizerGui(Ms::Synthesizer*)'Z:/MuseScore/fluid/fluidgui.cpp:79: undefined reference to
collect2.exe: error: ld returned 1 exit status
You don't have the dependencies right. There is a zip file in the instructions, did you use it ?
In reply to You don't have the… by [DELETED] 5
I did. And I checked the various directories for the files being there. I'll recopy everything out of that zip file and see if maybe one of the files is old. The instructions tell you to get files from the sources and to only use the zip file for specific files, I did get some files from the source websites.
In reply to I did. And I checked the… by sideways
All dependencies but Jack are in the zip file.
I unzipped the Qt-additions.zip file into C:\ and overwrote 19 files of the same name. I downloaded the latest Jack 32 bit installer and installed that over whatever version was installed. No change.
I turned SOUNDFONT3 back on. The additional, original errors returned.
I rebooted. No change
Now I am back where I was at the beginning of this post, with those identical errors. What specific dependency is failing?
In reply to I unzipped the Qt-additions… by sideways
I believe it's libsndfile
In reply to I believe it's libsndfile by [DELETED] 5
Yes, so do I. It was the first thing I reinstalled and copied into those include and lib folders, earlier today.
And it's the .lib file, not any of the source files, because this is the static linking stage.
The file is called: libsndfile-1.dll, and it it is version 1.0.24.0 in my C:\Qt\Tools\mingw530_32\lib folder.
But wait, why are there .dll files in this lib folder? Are they not supposed to be .lib files for statically linking here?
The two files it's trying to link are:
../fluid/libfluid.a(sfont3.cpp.obj)
../fluid/libfluid.a(fluidgui.cpp.obj)
I can eliminate the sfont3.cpp.obj errors by turning off SOUNDFONT3 in the CMake options.
Is there a .lib file I'm missing, or is libsndfile-1.dll all I should need?
It's solved!
I had to delete build.qtc again. After that I cleared my CMake configuration, ran CMake, then built.
And this is with my code integrated. I diff'd and integrated as my first step, which was probably not a good idea either. Better to build straight from the master when upgrading all these moving parts.
I did also add the .lib version of libsndfile-1 to that lib folder, but I assume it made no difference.
Why are you using .dlls for linking statically?
Thanks again to both of you for your responsiveness so late on a Friday.
In reply to It's solved!… by sideways
We don't link external dependencies statically on windows. We use dynamic linking for all of them. That's why you can find the dll in the bin directory of your install.
In reply to We don't link external… by [DELETED] 5
Then why does the CMake use them in the link process? I would think that failure would occur at run time, not at link time, if they are dynamically linked.