jarcode-foss / glava

GLava - OpenGL audio spectrum visualizer
GNU General Public License v3.0
1.18k stars 59 forks source link

compilation error #228

Open vaynefox opened 2 years ago

vaynefox commented 2 years ago

Screenshot_2022-04-19_01-26-45 This always appear whenever I try to compile it.

LightningV1p3r commented 2 years ago

Same here, tried it on two different machines with the new ubuntu 22.04 release.

LightningV1p3r commented 2 years ago

I also tested it on a ubuntu 21.10 install where glava is already installed. Same error:

ninja -C build
ninja: Entering directory `build' [2/19] Compiling C object glava.p/glava-cli_cli.c.o cc1: warning: command-line option ‘-std=c++11’ is valid for C++/ObjC++ but not for C [3/19] Compiling C object libglava.so.p/glava_fifo.c.o ../glava/fifo.c: In function ‘entry’: ../glava/fifo.c:81:17: warning: ignoring return value of ‘read’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 81 | read(fd, buf, sizeof(buf)); | ^~~~~~ [9/19] Compiling C++ object libglfft.a.p/glfft_glfft_gl_interface.cpp.o FAILED: libglfft.a.p/glfft_glfft_gl_interface.cpp.o c++ -Ilibglfft.a.p -I. -I.. -fdiagnostics-color=always -pipe -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wnon-virtual-dtor -O2 -DGLAVA_UNIX -DGLAVA_GLX '-DGLAVA_VERSION="v1.6.3-90-g6fc0e32"' '-DSHADER_INSTALL_PATH="/etc/xdg/glava"' '-DGLAVA_RESOURCE_PATH="/usr/share/glava/resources"' -fPIC -MD -MQ libglfft.a.p/glfft_glfft_gl_interface.cpp.o -MF libglfft.a.p/glfft_glfft_gl_interface.cpp.o.d -o libglfft.a.p/glfft_glfft_gl_interface.cpp.o -c ../glfft/glfft_gl_interface.cpp In file included from ../glfft/glfft_gl_interface.cpp:19: ../glfft/glfft_gl_interface.hpp: In function ‘void glfft_log(const char, ...)’: ../glfft/glfft_gl_interface.hpp:43:14: error: ‘stdout’ was not declared in this scope 43 | vfprintf(stdout, fmt, l); | ^~ ../glfft/glfft_gl_interface.hpp:33:1: note: ‘stdout’ is defined in header ‘’; did you forget to ‘#include ’? 32 | #include +++ |+#include 33 | } ../glfft/glfft_gl_interface.hpp:43:5: error: ‘vfprintf’ was not declared in this scope; did you mean ‘vwprintf’? 43 | vfprintf(stdout, fmt, l); | ^~~~ | vwprintf ../glfft/glfft_gl_interface.hpp: In function ‘double glfft_time()’: ../glfft/glfft_gl_interface.hpp:54:17: error: ‘stderr’ was not declared in this scope 54 | fprintf(stderr, "clock_gettime(CLOCK_REALTIME, ...): %s\n", strerror(errno)); | ^~ ../glfft/glfft_gl_interface.hpp:54:17: note: ‘stderr’ is defined in header ‘’; did you forget to ‘#include ’? ../glfft/glfft_gl_interface.hpp:54:78: error: ‘errno’ was not declared in this scope 54 | fprintf(stderr, "clock_gettime(CLOCK_REALTIME, ...): %s\n", strerror(errno)); | ^~~~~ ../glfft/glfft_gl_interface.hpp:33:1: note: ‘errno’ is defined in header ‘’; did you forget to ‘#include ’? 32 | #include +++ |+#include 33 | } ../glfft/glfft_gl_interface.hpp:54:9: error: ‘fprintf’ was not declared in this scope; did you mean ‘wprintf’? 54 | fprintf(stderr, "clock_gettime(CLOCK_REALTIME, ...): %s\n", strerror(errno)); | ^~~ | wprintf ../glfft/glfft_gl_interface.cpp: In member function ‘virtual void GLFFT::GLContext::log(const char, ...)’: ../glfft/glfft_gl_interface.cpp:201:5: error: ‘vsnprintf’ was not declared in this scope; did you mean ‘vswprintf’? 201 | vsnprintf(buffer, sizeof(buffer), fmt, va); | ^~~~~ | vswprintf [12/19] Compiling C++ object libglfft.a.p/glfft_glfft_wisdom.cpp.o FAILED: libglfft.a.p/glfft_glfft_wisdom.cpp.o c++ -Ilibglfft.a.p -I. -I.. -fdiagnostics-color=always -pipe -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wnon-virtual-dtor -O2 -DGLAVA_UNIX -DGLAVA_GLX '-DGLAVA_VERSION="v1.6.3-90-g6fc0e32"' '-DSHADER_INSTALL_PATH="/etc/xdg/glava"' '-DGLAVA_RESOURCE_PATH="/usr/share/glava/resources"' -fPIC -MD -MQ libglfft.a.p/glfft_glfft_wisdom.cpp.o -MF libglfft.a.p/glfft_glfft_wisdom.cpp.o.d -o libglfft.a.p/glfft_glfft_wisdom.cpp.o -c ../glfft/glfft_wisdom.cpp ../glfft/glfft_wisdom.cpp: In member function ‘std::pair<double, GLFFT::FFTOptions::Performance> GLFFT::FFTWisdom::study(GLFFT::Context*, const GLFFT::WisdomPass&, GLFFT::FFTOptions::Type) const’: ../glfft/glfft_wisdom.cpp:273:23: error: ‘logic_error’ was not declared in this scope 273 | throw logic_error("Invalid input mode.\n"); | ^~~ ../glfft/glfft_wisdom.cpp:307:23: error: ‘logic_error’ was not declared in this scope 307 | throw logic_error("Invalid output mode.\n"); | ^~~ [14/19] Compiling C++ object libglfft.a.p/glfft_glfft.cpp.o ninja: build stopped: subcommand failed.

PixelMelt commented 2 years ago

try https://github.com/jarcode-foss/glava/issues/218 ?

ElGamerNovato commented 2 years ago

I'm having the same error :c

shreyasSarve commented 1 year ago

any fix ?

shreyasSarve commented 1 year ago

i gave up and just used https://github.com/karlstav/cava use #185