[PATCH v2 mtd-utils 4/4] ubifs-utils: extract_files: Include <linux/limits.h>
Zhihao Cheng
chengzhihao1 at huawei.com
Tue Feb 18 04:01:56 PST 2025
在 2025/2/18 19:31, Fabio Estevam 写道:
> Include <linux/limits.h> to fix the following build error when building
> with musl:
>
> | ../git/ubifs-utils/fsck.ubifs/extract_files.c: In function 'parse_ino_node':
> | ../git/ubifs-utils/fsck.ubifs/extract_files.c:144:47: error: 'XATTR_LIST_MAX' undeclared (first use in this function)
> | 144 | if (ino_node->xnms + ino_node->xcnt > XATTR_LIST_MAX) {
> | | ^~~~~~~~~~~~~~
> | ../git/ubifs-utils/fsck.ubifs/extract_files.c:144:47: note: each undeclared identifier is reported only once for each function it appears in
> | make: *** [Makefile:4374: ubifs-utils/fsck.ubifs/fsck_ubifs-extract_files.o] Error 1
>
> Signed-off-by: Fabio Estevam <festevam at gmail.com>
> ---
> Changes since v1:
> - Include <linux/limits.h>. (Zhihao)
>
> ubifs-utils/fsck.ubifs/extract_files.c | 2 ++
> 1 file changed, 2 insertions(+)
Reviewed-by: Zhihao Cheng <chengzhihao1 at huawei.com>
>
> diff --git a/ubifs-utils/fsck.ubifs/extract_files.c b/ubifs-utils/fsck.ubifs/extract_files.c
> index c83d37749bc0..000ef5d10565 100644
> --- a/ubifs-utils/fsck.ubifs/extract_files.c
> +++ b/ubifs-utils/fsck.ubifs/extract_files.c
> @@ -10,6 +10,8 @@
> #include <getopt.h>
> #include <sys/stat.h>
>
> +#include <linux/limits.h>
> +
> #include "linux_err.h"
> #include "bitops.h"
> #include "kmem.h"
>
More information about the linux-mtd
mailing list