haasn / libplacebo

Official mirror of libplacebo
http://libplacebo.org/
GNU Lesser General Public License v2.1
524 stars 63 forks source link

Demos won't compile on mingw #194

Closed sfan5 closed 10 months ago

sfan5 commented 10 months ago
The Meson build system
Version: 1.2.1
Source dir: /home/stefan/mpv/libplacebo
Build dir: /home/stefan/mpv/libplacebo/builddir
Build type: cross build
Project name: libplacebo
Project version: 6.309.0
C compiler for the host machine: x86_64-w64-mingw32-gcc (gcc 11.4.0 "x86_64-w64-mingw32-gcc (GCC) 11.4.0")
C linker for the host machine: x86_64-w64-mingw32-gcc ld.bfd 2.40
C++ compiler for the host machine: x86_64-w64-mingw32-g++ (gcc 11.4.0 "x86_64-w64-mingw32-g++ (GCC) 11.4.0")
C++ linker for the host machine: x86_64-w64-mingw32-g++ ld.bfd 2.40
C compiler for the build machine: cc (gcc 13.2.1 "cc (GCC) 13.2.1 20230801")
C linker for the build machine: cc ld.bfd 2.41.0
C++ compiler for the build machine: c++ (gcc 13.2.1 "c++ (GCC) 13.2.1 20230801")
C++ linker for the build machine: c++ ld.bfd 2.41.0
Build machine cpu family: x86_64
Build machine cpu: x86_64
Host machine cpu family: x86_64
Host machine cpu: x86_64
Target machine cpu family: x86_64
Target machine cpu: x86_64
Compiler for C supports arguments -Wincompatible-pointer-types: YES 
Compiler for C supports link arguments -Wl,--exclude-libs=ALL: YES 
Configuring libplacebo.rc using configuration
Configuring demos.rc using configuration
Library m found: YES
Program python3 found: YES (/usr/bin/python)
Found pkg-config: /usr/bin/pkg-config (1.8.1)
Found CMake: NO
Run-time dependency libunwind found: NO (tried pkgconfig and cmake)
Library execinfo found: NO
Checking for function "backtrace_symbols" with dependency -lexecinfo: NO 
Check usable header "dbghelp.h" : YES 
Library shlwapi found: YES
Fetching value of define "__MINGW32__" : 1 
Program x86_64-w64-mingw32-dlltool found: YES
Run-time dependency shaderc found: YES 2023.7.0
Message: Skipping `glslang` because `shaderc` is available
Check usable header "d3d11.h" : YES 
Check usable header "d3d11_4.h" : YES 
Check usable header "dxgi1_6.h" : YES 
Run-time dependency spirv-cross-c-shared found: YES 0.57.0
Library version found: YES
Header "dxgidebug.h" has symbol "IID_IDXGIInfoQueue" : NO 
Header "d3d11sdklayers.h" has symbol "DXGI_DEBUG_D3D11" : NO 
Run-time dependency vulkan found: YES 1.3.261
Header "vulkan/vulkan_core.h" has symbol "VK_VERSION_1_3" : YES 
Run-time dependency lcms2 found: NO (tried pkgconfig and cmake)
Run-time dependency dovi found: NO (tried pkgconfig and cmake)
Configuring config.h using configuration
Configuring config_internal.h using configuration
Windows resource compiler: GNU windres (GNU Binutils) 2.40
Run-time dependency glfw3 found: NO (tried pkgconfig and cmake)
sdl2-config found: NO
Run-time dependency sdl2 found: NO (tried pkgconfig, config-tool and cmake)
Run-time dependency sdl2_image found: NO (tried pkgconfig and cmake)
Run-time dependency libavcodec found: YES 60.23.100
Run-time dependency libavformat found: YES 60.10.100
Run-time dependency libavutil found: YES 58.17.100
Has header "nuklear.h" : YES 
Check usable header "EGL/egl.h" : NO 
Configuring config_demos.h using configuration
../demos/meson.build:97: WARNING: Demos enabled but no supported combination of windowing system and graphical APIs was found. Demo programs require either GLFW or SDL and either Vulkan or OpenGL to function.
Build targets in project: 21

libplacebo 6.309.0

  Optional features
    d3d11       : YES
    dovi        : YES
    gl-proc-addr: YES
    glslang     : NO
    lcms        : NO
    libdovi     : NO
    opengl      : YES
    shaderc     : YES
    vk-proc-addr: YES
    vulkan      : YES

  User defined options
    Cross files : /home/stefan/mpv/mingw_prefix/crossfile
    d3d11       : enabled
    opengl      : enabled
    vulkan      : enabled

Found ninja-1.11.1 at /usr/bin/ninja
WARNING: Running the setup command as `meson [options]` instead of `meson setup [options]` is ambiguous and deprecated.
[15/87] Generating src/version.h with a custom command
fatal: No names found, cannot describe anything.
[18/87] Compiling C object demos/video-filtering.exe.p/video-filtering.c.obj
FAILED: demos/video-filtering.exe.p/video-filtering.c.obj 
x86_64-w64-mingw32-gcc -Idemos/video-filtering.exe.p -Idemos -I../demos -Isrc/include -I../src/include -I/home/stefan/mpv/mingw_prefix/usr/include -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -std=c11 -O3 -Wundef -Wshadow -Wparentheses -Wpointer-arith -D_WIN32_WINNT=0x0601 -D_USE_MATH_DEFINES -D_CRT_SECURE_NO_WARNINGS -D_ISOC99_SOURCE -D_ISOC11_SOURCE -D_GNU_SOURCE -D_XOPEN_SOURCE=700 -U__STRICT_ANSI__ -Wmissing-prototypes -Wno-sign-compare -Wno-unused-parameter -Wno-missing-field-initializers -Wno-type-limits -Werror=implicit-function-declaration -Werror=incompatible-pointer-types -D__CRT__NO_INLINE -DCOBJMACROS -O2 -pipe -Wall -D_FORTIFY_SOURCE=2 -O2 -MD -MQ demos/video-filtering.exe.p/video-filtering.c.obj -MF demos/video-filtering.exe.p/video-filtering.c.obj.d -o demos/video-filtering.exe.p/video-filtering.c.obj -c ../demos/video-filtering.c
../demos/video-filtering.c: In function ‘api1_example’:
../demos/video-filtering.c:725:5: error: implicit declaration of function ‘timespec_get’ [-Werror=implicit-function-declaration]
  725 |     timespec_get(&start, TIME_UTC);
      |     ^~~~~~~~~~~~
../demos/video-filtering.c:725:26: error: ‘TIME_UTC’ undeclared (first use in this function)
  725 |     timespec_get(&start, TIME_UTC);
      |                          ^~~~~~~~
../demos/video-filtering.c:725:26: note: each undeclared identifier is reported only once for each function it appears in
../demos/video-filtering.c: In function ‘api2_example’:
../demos/video-filtering.c:792:26: error: ‘TIME_UTC’ undeclared (first use in this function)
  792 |     timespec_get(&start, TIME_UTC);
      |                          ^~~~~~~~
cc1: some warnings being treated as errors

(why is it building them anyway when glfw and sdl are missing?)

haasn commented 10 months ago

Needs to be updated to use pl_clock.h.

Probably, I will just delete this demo - it is old, unmaintained, probably buggy, uninteresting

Edit: Nvm, it's still useful for testing transfer throughput on sdma queues