[PATCH v4l-utils v1] media-info: add missing sys/stat.h include (for dev_t)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Fixes musl libc compile failure:

  In file included from ../utils/v4l2-tracer/v4l2-tracer-common.h:11,
                   from ../utils/v4l2-tracer/trace.h:9,
                   from ../utils/v4l2-tracer/trace-helper.cpp:6:
  ../utils/common/media-info.h:40:34: error: ‘dev_t’ has not been declared
     40 | int mi_get_dev_t_from_fd(int fd, dev_t *dev);
        |                                  ^~~~~
  ../utils/common/media-info.h:48:39: error: ‘dev_t’ was not declared in this scope; did you mean ‘div_t’?
     48 | std::string mi_get_devpath_from_dev_t(dev_t dev);
        |                                       ^~~~~
        |                                       div_t

Signed-off-by: Peter Seiderer <ps.report@xxxxxxx>
---
 utils/common/media-info.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/utils/common/media-info.h b/utils/common/media-info.h
index a862b70b..c0dd6304 100644
--- a/utils/common/media-info.h
+++ b/utils/common/media-info.h
@@ -6,6 +6,8 @@
 #ifndef _MEDIA_INFO_H
 #define _MEDIA_INFO_H
 
+#include <sys/stat.h>
+
 enum media_type {
 	MEDIA_TYPE_CANT_STAT,
 	MEDIA_TYPE_UNKNOWN,
-- 
2.43.0





[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux