Closed
Description
This is the error we get doing a simple compile, using these options with kernel 3.8 kernel headers:
-DENABLE_SQLITE3=ON \
-DENABLE_RPM=OFF \
-DENABLE_IMAGEMAGICK6=OFF \
-DENABLE_IMAGEMAGICK7=OFF \
-DENABLE_SYSTEM_YYJSON=ON
with this config output:
-- The C compiler identification is GNU 14.2.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/local/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
-- Check if compiler accepts -pthread
-- Check if compiler accepts -pthread - yes
-- Found Threads: TRUE
-- Found PkgConfig: /usr/local/bin/pkg-config (found version "0.29.2")
-- Build type: Release
-- Threads type: pthread
-- The CXX compiler identification is GNU 14.2.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/local/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Enabling LTO
-- Target dirs: ROOT="" USR="/usr" HOME="/home" ETC="/etc"
fatal: No names found, cannot describe anything.
-- Found Python: /usr/local/bin/python3.12 (found version "3.12.6") found components: Interpreter
-- Enabling DirectX headers for WSL
-- Looking for wcwidth
-- Looking for wcwidth - found
-- Looking for statx
-- Looking for statx - not found
-- System provided yyjson is used
-- Library: missing: VULKAN
-- Library: missing: WAYLAND
-- Library: missing: XCB_RANDR
-- Library: missing: XCB
-- Library: missing: XRANDR
-- Library: missing: X11
-- Library: missing: DRM
-- Library: found GIO
-- Library: missing: DCONF
-- Library: missing: DBUS
-- Library: missing: XFCONF
-- Library: found SQLITE3
-- Library: missing: EGL
-- Library: missing: GLX
-- Library: missing: OSMESA
-- Library: missing: OPENCL
-- Library: missing: PULSE
-- Library: missing: DDCUTIL
-- Library: found ELF
-- Library: missing: DIRECTX_HEADERS
-- Looking for linux/wireless.h
-- Looking for linux/wireless.h - not found
-- Looking for utmpx.h
-- Looking for utmpx.h - found
-- Looking for wordexp.h
-- Looking for wordexp.h - found
-- Looking for pthread_np.h
-- Looking for pthread_np.h - not found
-- Looking for pthread_timedjoin_np
-- Looking for pthread_timedjoin_np - found
-- Configuring done (13.0s)
-- Generating done (0.1s)
-- Build files have been written to: /usr/local/tmp/crew/fastfetch.20240916013038.dir/builddir
... and then the failure.
/usr/local/bin/cc -DFF_HAVE_ELF=1 -DFF_HAVE_GIO=1 -DFF_HAVE_LIBZFS=1 -DFF_HAVE_LINUX_VIDEODEV2=1 -DFF_HAVE_SQLITE3=1 -DFF_HAVE_THREADS -DFF_HAVE_TIMEDJOIN_NP=1 -DFF_HAVE_UTMPX=1 -DFF_HAVE_WCWIDTH -DFF_HAVE_WORDEXP=1 -DFF_USE_SYSTEM_YYJSON -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE -D_XOPEN_SOURCE -D__STDC_WANT_LIB_EXT1__=1 -I/usr/local/include/libmount -I/usr/local/include/blkid -I/usr/local/include/glib-2.0 -I/usr/local/lib/glib-2.0/include -I/usr/local/tmp/crew/fastfetch.20240916011904.dir/builddir -I/usr/local/tmp/crew/fastfetch.20240916011904.dir/src -O2 -pipe -ffat-lto-objects -fPIC -flto=auto -Wall -Wextra -Wconversion -Werror=uninitialized -Werror=return-type -Werror=incompatible-pointer-types -Werror=implicit-function-declaration -Werror=int-conversion -O3 -DNDEBUG -std=gnu11 -flto=auto -fno-fat-lto-objects -pthread -MD -MT CMakeFiles/libfastfetch.dir/src/detection/camera/camera_linux.c.o -MF CMakeFiles/libfastfetch.dir/src/detection/camera/camera_linux.c.o.d -o CMakeFiles/libfastfetch.dir/src/detection/camera/camera_linux.c.o -c /usr/local/tmp/crew/fastfetch.20240916011904.dir/src/detection/camera/camera_linux.c
/usr/local/tmp/crew/fastfetch.20240916011904.dir/src/detection/camera/camera_linux.c: In function ‘ffDetectCamera’:
/usr/local/tmp/crew/fastfetch.20240916011904.dir/src/detection/camera/camera_linux.c:46:14: error: ‘V4L2_COLORSPACE_OPRGB’ undeclared (first use in this function); did you mean ‘V4L2_COLORSPACE_SRGB’?
46 | case V4L2_COLORSPACE_OPRGB: ffStrbufInitStatic(&camera->colorspace, "Adobe RGB"); break;
| ^~~~~~~~~~~~~~~~~~~~~
| V4L2_COLORSPACE_SRGB
/usr/local/tmp/crew/fastfetch.20240916011904.dir/src/detection/camera/camera_linux.c:46:14: note: each undeclared identifier is reported only once for each function it appears in
/usr/local/tmp/crew/fastfetch.20240916011904.dir/src/detection/camera/camera_linux.c:47:14: error: ‘V4L2_COLORSPACE_BT2020’ undeclared (first use in this function); did you mean ‘V4L2_COLORSPACE_BT878’?
47 | case V4L2_COLORSPACE_BT2020: ffStrbufInitStatic(&camera->colorspace, "BT.2020"); break;
| ^~~~~~~~~~~~~~~~~~~~~~
| V4L2_COLORSPACE_BT878
/usr/local/tmp/crew/fastfetch.20240916011904.dir/src/detection/camera/camera_linux.c:48:14: error: ‘V4L2_COLORSPACE_RAW’ undeclared (first use in this function); did you mean ‘V4L2_COLORSPACE_SRGB’?
48 | case V4L2_COLORSPACE_RAW: ffStrbufInitStatic(&camera->colorspace, "RAW"); break;
| ^~~~~~~~~~~~~~~~~~~
| V4L2_COLORSPACE_SRGB
/usr/local/tmp/crew/fastfetch.20240916011904.dir/src/detection/camera/camera_linux.c:49:14: error: ‘V4L2_COLORSPACE_DCI_P3’ undeclared (first use in this function); did you mean ‘V4L2_COLORSPACE_SRGB’?
49 | case V4L2_COLORSPACE_DCI_P3: ffStrbufInitStatic(&camera->colorspace, "DCI-P3"); break;
| ^~~~~~~~~~~~~~~~~~~~~~
| V4L2_COLORSPACE_SRGB
ninja: build stopped: subcommand failed.
We worked around the issue by adding this to the cmake build options: -DHAVE_LINUX_VIDEODEV2=false