package/libv4l: fix typeof related compile failure

In case Qt support is enabled use '-std=gnu++11' instead of '-std=c++11' to
enable c++11 support and gain support of the typeof GNU extension.

Fixes:

  - http://autobuild.buildroot.net/results/2d58906a1eefdf921b42f6c0d9fd680ef2ad6e27

  In file included from v4l2-ctl-streaming.cpp:14:
  ../../utils/common/v4l2-tpg.h: In function 'void tpg_s_hue(tpg_data*, s16)':
  ../../utils/common/v4l2-tpg.h:49:2: error: 'typeof' was not declared in this scope
     49 |  typeof(val) __val = (val);  \
        |  ^~~~~~

Signed-off-by: Peter Seiderer <ps.report@gmx.net>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
This commit is contained in:
Peter Seiderer 2021-11-24 21:12:55 +01:00 committed by Arnout Vandecappelle (Essensium/Mind)
parent 1fd67fcfc8
commit 7b2da3caaf

View file

@ -71,8 +71,8 @@ LIBV4L_CONF_ENV += \
ac_cv_prog_MOC=$(HOST_DIR)/bin/moc \
ac_cv_prog_RCC=$(HOST_DIR)/bin/rcc \
ac_cv_prog_UIC=$(HOST_DIR)/bin/uic
# qt5 needs c++11 (since qt-5.7)
LIBV4L_CONF_ENV += CXXFLAGS="$(TARGET_CXXFLAGS) -std=c++11"
# qt5 needs c++11 (since qt-5.7)/use gnu++11 for typeof support
LIBV4L_CONF_ENV += CXXFLAGS="$(TARGET_CXXFLAGS) -std=gnu++11"
else
LIBV4L_CONF_OPTS += --disable-qv4l2
endif