libcamera: Fix compilation with uClibc and uClibc-ng

Neither uClibc nor uClibc-ng support O_TMPFILE. Define it in utils.h if
not defined.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
This commit is contained in:
Laurent Pinchart
2019-10-29 02:58:44 +02:00
parent 97a5855f37
commit b465ecb3e3

View File

@@ -16,6 +16,15 @@
#define ARRAY_SIZE(a) (sizeof(a) / sizeof(a[0]))
#ifndef __DOXYGEN__
/* uClibc and uClibc-ng don't provide O_TMPFILE */
#ifndef O_TMPFILE
#define O_TMPFILE (020000000 | O_DIRECTORY)
#endif
#endif
namespace libcamera {
namespace utils {