Problem compiling Debug OF library, ofOpenALSoundPlayer culprit

After running the install dependencies and codecs files successfully I tried to run the compileOF script but unfortunately ran into this error. It asked me to report it here so I made an account. I’d really appreciate it if y’all could help, thank you!

Compiling /home/owen/Projects/C++/libraries/OF_0.11.2/libs/openFrameworks/sound/ofOpenALSoundPlayer.cpp
g++ -g3 -DDEBUG -Wall -Werror=return-type -DGCC_HAS_REGEX -DOF_USING_GTK -DOF_USING_GTK -DOF_USING_MPG123 -I/usr/include/cairo -I/usr/include/lzo -
I/usr/include/libpng16 -I/usr/include/freetype2 -I/usr/include/harfbuzz -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/sysprof-
4 -I/usr/include/pixman-1 -I/usr/include/gstreamer-1.0 -I/usr/include/orc-0.4 -I/usr/include/opus -I/usr/include/AL -I/usr/include/rtaudio -D_REENT
RANT -I/usr/include/gtk-3.0 -I/usr/include/pango-1.0 -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/fribidi -I/usr/include/gdk-pixbuf-
2.0 -I/usr/include/gio-unix-2.0 -I/usr/include/cloudproviders -I/usr/include/atk-1.0 -I/usr/include/at-spi2-atk/2.0 -I/usr/include/dbus-1.0 -I/usr/
lib/dbus-1.0/include -I/usr/include/at-spi-2.0 -pthread -I/home/owen/Projects/C++/libraries/OF_0.11.2/libs/fmod/include -I/home/owen/Projects/C++/l
ibraries/OF_0.11.2/libs/glm/include -I/home/owen/Projects/C++/libraries/OF_0.11.2/libs/glm/include/glm -I/home/owen/Projects/C++/libraries/OF_0.11.
2/libs/glm/include/glm/gtx -I/home/owen/Projects/C++/libraries/OF_0.11.2/libs/glm/include/glm/ext -I/home/owen/Projects/C++/libraries/OF_0.11.2/lib
s/glm/include/glm/gtc -I/home/owen/Projects/C++/libraries/OF_0.11.2/libs/glm/include/glm/detail -I/home/owen/Projects/C++/libraries/OF_0.11.2/libs/
glm/include/glm/simd -I/home/owen/Projects/C++/libraries/OF_0.11.2/libs/json/include -I/home/owen/Projects/C++/libraries/OF_0.11.2/libs/kiss/includ
e -I/home/owen/Projects/C++/libraries/OF_0.11.2/libs/pugixml/include -I/home/owen/Projects/C++/libraries/OF_0.11.2/libs/tess2/include -I/home/owen/
Projects/C++/libraries/OF_0.11.2/libs/utf8/include -I/home/owen/Projects/C++/libraries/OF_0.11.2/libs/utf8/include/utf8 -I/home/owen/Projects/C++/l
ibraries/OF_0.11.2/libs/openFrameworks -I/home/owen/Projects/C++/libraries/OF_0.11.2/libs/openFrameworks/communication -I/home/owen/Projects/C++/li
braries/OF_0.11.2/libs/openFrameworks/events -I/home/owen/Projects/C++/libraries/OF_0.11.2/libs/openFrameworks/app -I/home/owen/Projects/C++/librar
ies/OF_0.11.2/libs/openFrameworks/video -I/home/owen/Projects/C++/libraries/OF_0.11.2/libs/openFrameworks/utils -I/home/owen/Projects/C++/libraries
/OF_0.11.2/libs/openFrameworks/types -I/home/owen/Projects/C++/libraries/OF_0.11.2/libs/openFrameworks/sound -I/home/owen/Projects/C++/libraries/OF
_0.11.2/libs/openFrameworks/3d -I/home/owen/Projects/C++/libraries/OF_0.11.2/libs/openFrameworks/gl -I/home/owen/Projects/C++/libraries/OF_0.11.2/l
ibs/openFrameworks/graphics -I/home/owen/Projects/C++/libraries/OF_0.11.2/libs/openFrameworks/math -Wall -Werror=return-type -std=c++14 -DGCC_HAS_R
EGEX -MMD -MP -MF /home/owen/Projects/C++/libraries/OF_0.11.2/libs/openFrameworksCompiled/lib/linux64/obj/Debug/libs/openFrameworks/sound/ofOpenALS
oundPlayer.d -MT/home/owen/Projects/C++/libraries/OF_0.11.2/libs/openFrameworksCompiled/lib/linux64/obj/Debug/libs/openFrameworks/sound/ofOpenALSou
ndPlayer.o -o /home/owen/Projects/C++/libraries/OF_0.11.2/libs/openFrameworksCompiled/lib/linux64/obj/Debug/libs/openFrameworks/sound/ofOpenALSound
Player.o -c /home/owen/Projects/C++/libraries/OF_0.11.2/libs/openFrameworks/sound/ofOpenALSoundPlayer.cpp
In file included from /home/owen/Projects/C++/libraries/OF_0.11.2/libs/openFrameworks/sound/ofOpenALSoundPlayer.cpp:10:
/usr/include/sndfile.h:356:33: error: conflicting declaration 'typedef struct sf_private_tag SNDFILE'
  356 | typedef struct sf_private_tag   SNDFILE ;
      |                                 ^~~~~~~
In file included from /home/owen/Projects/C++/libraries/OF_0.11.2/libs/openFrameworks/sound/ofOpenALSoundPlayer.cpp:1:
/home/owen/Projects/C++/libraries/OF_0.11.2/libs/openFrameworks/sound/ofOpenALSoundPlayer.h:18:33: note: previous declaration as 'typedef struct SN
DFILE_tag SNDFILE'
   18 | typedef struct SNDFILE_tag      SNDFILE ;
      |                                 ^~~~~~~
make[1]: *** [makefileCommon/compile.core.mk:240: /home/owen/Projects/C++/libraries/OF_0.11.2/libs/openFrameworksCompiled/lib/linux64/obj/Debug/lib
s/openFrameworks/sound/ofOpenALSoundPlayer.o] Error 1
make: *** [makefileCommon/compile.core.mk:212: Debug] Error 2
there has been a problem compiling Debug OF library
please report this problem in the forums
1 Like

Same error here on Manjaro; I can’t compile oF for now.

Hey there is a related post here. Maybe try using the nightly build? I think this issue may have been fixed; line 18 of ofOpenALSoundPlayer.hh as changed on the oF GitHub page.

4 Likes

Thanks a lot @TimChi ! Working perfectly fine now :slight_smile: !

Likewise I’m running Manjaro. Thanks @TimChi I was able to compile the nightly build! Although the project generator is complaining now lol, I’ll make it it’s own post if I can’t figure it out. Here’s the tail end of the compilation output:

/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:25:58: warning: 'pugi::xml_parse_result pugi::xml_document::load(const char_t*, unsigned int)' is deprecated [-Wdeprecated-declarations]
   25 |         pugi::xml_parse_result result = filterXmlDoc.load(temp.c_str());
      |                                         ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~
In file included from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/baseProject.h:8,
                 from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.h:7,
                 from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:4:
/home/owen/Projects/C++/libraries/openFrameworks/libs/pugixml/include/pugixml.hpp:1034:53: note: declared here
 1034 |                 PUGIXML_DEPRECATED xml_parse_result load(const char_t* contents, unsigned int options = parse_default);
      |                                                     ^~~~
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:38:26: warning: comparison of integer expressions of different signedness: 'int' and 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   38 |         for(int i = 0; i < relRootWindows.length(); i++) {
      |                        ~~^~~~~~~~~~~~~~~~~~~~~~~~~
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp: In member function 'void visualStudioProject::appendFilter(std::string)':
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:93:71: warning: 'pugi::xpath_node pugi::xml_node::select_single_node(const char_t*, pugi::xpath_variable_set*) const' is deprecated [-Wdeprecated-declarations]
   93 |                  pugi::xml_node node = filterXmlDoc.select_single_node("//ItemGroup[Filter]/Filter").node().parent();
      |                                        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/baseProject.h:8,
                 from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.h:7,
                 from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:4:
/home/owen/Projects/C++/libraries/openFrameworks/libs/pugixml/include/pugixml.hpp:654:47: note: declared here
  654 |                 PUGIXML_DEPRECATED xpath_node select_single_node(const char_t* query, xpath_variable_set* variables = 0) const;
      |                                               ^~~~~~~~~~~~~~~~~~
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp: In member function 'virtual void visualStudioProject::addSrc(std::string, std::string, baseProject::SrcType)':
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:117:27: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<std::__cxx11::basic_string<char> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
  117 |         for (int i = 0; i < folderSubNames.size(); i++){
      |                         ~~^~~~~~~~~~~~~~~~~~~~~~~
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:127:78: warning: 'pugi::xpath_node pugi::xml_node::select_single_node(const char_t*, pugi::xpath_variable_set*) const' is deprecated [-Wdeprecated-declarations]
  127 |                         pugi::xml_node node = filterXmlDoc.select_single_node("//ItemGroup[ClInclude]").node();
      |                                               ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/baseProject.h:8,
                 from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.h:7,
                 from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:4:
/home/owen/Projects/C++/libraries/openFrameworks/libs/pugixml/include/pugixml.hpp:654:47: note: declared here
  654 |                 PUGIXML_DEPRECATED xpath_node select_single_node(const char_t* query, xpath_variable_set* variables = 0) const;
      |                                               ^~~~~~~~~~~~~~~~~~
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:144:85: warning: 'pugi::xpath_node pugi::xml_node::select_single_node(const char_t*, pugi::xpath_variable_set*) const' is deprecated [-Wdeprecated-declarations]
  144 |                         pugi::xml_node nodeFilters = filterXmlDoc.select_single_node("//ItemGroup[ClCompile]").node();
      |                                                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/baseProject.h:8,
                 from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.h:7,
                 from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:4:
/home/owen/Projects/C++/libraries/openFrameworks/libs/pugixml/include/pugixml.hpp:654:47: note: declared here
  654 |                 PUGIXML_DEPRECATED xpath_node select_single_node(const char_t* query, xpath_variable_set* variables = 0) const;
      |                                               ^~~~~~~~~~~~~~~~~~
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:154:85: warning: 'pugi::xpath_node pugi::xml_node::select_single_node(const char_t*, pugi::xpath_variable_set*) const' is deprecated [-Wdeprecated-declarations]
  154 |                         pugi::xml_node nodeFilters = filterXmlDoc.select_single_node("//ItemGroup[ClCompile]").node();
      |                                                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/baseProject.h:8,
                 from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.h:7,
                 from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:4:
/home/owen/Projects/C++/libraries/openFrameworks/libs/pugixml/include/pugixml.hpp:654:47: note: declared here
  654 |                 PUGIXML_DEPRECATED xpath_node select_single_node(const char_t* query, xpath_variable_set* variables = 0) const;
      |                                               ^~~~~~~~~~~~~~~~~~
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:173:85: warning: 'pugi::xpath_node pugi::xml_node::select_single_node(const char_t*, pugi::xpath_variable_set*) const' is deprecated [-Wdeprecated-declarations]
  173 |                         pugi::xml_node nodeFilters = filterXmlDoc.select_single_node("//ItemGroup[ClCompile]").node();
      |                                                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/baseProject.h:8,
                 from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.h:7,
                 from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:4:
/home/owen/Projects/C++/libraries/openFrameworks/libs/pugixml/include/pugixml.hpp:654:47: note: declared here
  654 |                 PUGIXML_DEPRECATED xpath_node select_single_node(const char_t* query, xpath_variable_set* variables = 0) const;
      |                                               ^~~~~~~~~~~~~~~~~~
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:182:78: warning: 'pugi::xpath_node pugi::xml_node::select_single_node(const char_t*, pugi::xpath_variable_set*) const' is deprecated [-Wdeprecated-declarations]
  182 |                         pugi::xml_node node = filterXmlDoc.select_single_node("//ItemGroup[ClInclude]").node();
      |                                               ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/baseProject.h:8,
                 from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.h:7,
                 from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:4:
/home/owen/Projects/C++/libraries/openFrameworks/libs/pugixml/include/pugixml.hpp:654:47: note: declared here
  654 |                 PUGIXML_DEPRECATED xpath_node select_single_node(const char_t* query, xpath_variable_set* variables = 0) const;
      |                                               ^~~~~~~~~~~~~~~~~~
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp: In member function 'void visualStudioProject::addProps(std::string)':
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:270:27: warning: comparison of integer expressions of different signedness: 'int' and 'size_t' {aka 'long unsigned int'} [-Wsign-compare]
  270 |         for (int i = 0; i < items.size(); i++) {
      |                         ~~^~~~~~~~~~~~~~
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp: In member function 'virtual void visualStudioProject::addCFLAG(std::string, baseProject::LibType)':
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:322:22: warning: comparison of integer expressions of different signedness: 'int' and 'size_t' {aka 'long unsigned int'} [-Wsign-compare]
  322 |         for(int i=0;i<items.size();i++){
      |                     ~^~~~~~~~~~~~~
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp: In member function 'virtual void visualStudioProject::addCPPFLAG(std::string, baseProject::LibType)':
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:345:22: warning: comparison of integer expressions of different signedness: 'int' and 'size_t' {aka 'long unsigned int'} [-Wsign-compare]
  345 |         for(int i=0;i<items.size();i++){
      |                     ~^~~~~~~~~~~~~
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp: In member function 'virtual void visualStudioProject::addDefine(std::string, baseProject::LibType)':
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:369:26: warning: comparison of integer expressions of different signedness: 'int' and 'size_t' {aka 'long unsigned int'} [-Wsign-compare]
  369 |         for (int i = 0; i<items.size(); i++) {
      |                         ~^~~~~~~~~~~~~
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp: In member function 'virtual void visualStudioProject::addAddon(ofAddon&)':
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:396:18: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<std::__cxx11::basic_string<char> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
  396 |     for(int i=0;i<addon.dependencies.size();i++){
      |                 ~^~~~~~~~~~~~~~~~~~~~~~~~~~
/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:450:60: error: no matching function for call to 'absolute(__gnu_cxx::__alloc_traits<std::allocator<std::__cxx11::basic_string<char> >, std::__cxx11::basic_string<char> >::value_type&, std::string&)'
  450 |                 std::string dll = std::filesystem::absolute(addon.dllsToCopy[i], addon.addonPath).string();
      |                                   ~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/11.2.0/filesystem:47,
                 from /home/owen/Projects/C++/libraries/openFrameworks/libs/openFrameworks/utils/ofConstants.h:471,
                 from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.h:5,
                 from /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/ofxProjectGenerator/src/projects/visualStudioProject.cpp:4:
/usr/include/c++/11.2.0/bits/fs_ops.h:47:8: note: candidate: 'std::filesystem::__cxx11::path std::filesystem::absolute(const std::filesystem::__cxx11::path&)'
   47 |   path absolute(const path& __p);
      |        ^~~~~~~~
/usr/include/c++/11.2.0/bits/fs_ops.h:47:8: note:   candidate expects 1 argument, 2 provided
/usr/include/c++/11.2.0/bits/fs_ops.h:48:8: note: candidate: 'std::filesystem::__cxx11::path std::filesystem::absolute(const std::filesystem::__cxx11::path&, std::error_code&)'
   48 |   path absolute(const path& __p, error_code& __ec);
      |        ^~~~~~~~
/usr/include/c++/11.2.0/bits/fs_ops.h:48:46: note:   no known conversion for argument 2 from 'std::string' {aka 'std::__cxx11::basic_string<char>'} to 'std::error_code&'
   48 |   path absolute(const path& __p, error_code& __ec);
      |                                  ~~~~~~~~~~~~^~~~
make[1]: *** [/home/owen/Projects/C++/libraries/openFrameworks/libs/openFrameworksCompiled/project/makefileCommon/compile.project.mk:306: /home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/commandLine/obj/linux64/Release/addons/ofxProjectGenerator/src/projects/visualStudioProject.o] Error 1
make[1]: Leaving directory '/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/commandLine'
make: *** [/home/owen/Projects/C++/libraries/openFrameworks/libs/openFrameworksCompiled/project/makefileCommon/compile.project.mk:129: Release] Error 2
make: Leaving directory '/home/owen/Projects/C++/libraries/openFrameworks/apps/projectGenerator/commandLine'
There has been a problem compiling the command line projectGenerator.
Please report this problem in the forums.

Hum… yes probably best to start a new thread for compiling ofxProjectGenerator. Do you just need the PG though? I think there is a precompiled version of it (for linux64gcc6) in the folder /projectGenerator-linux64; look for an executable called projectGenerator.

The compile error is above, so it looks like its lines 47 and 48 of header file fs_ops.h, and also maybe line 450 of visualStudioProject.cpp. The rest of the output looks like compiler warnings to me, which are OK. Also I’m not too familiar with ofxProjectGenerator. I usually use either the PG on macOS, or run the template script for Qt Creator.