* [PROBLEM] all warnings being treated as errors when I try to compile ext4 subtree
@ 2024-09-14 12:53 Max
0 siblings, 0 replies; only message in thread
From: Max @ 2024-09-14 12:53 UTC (permalink / raw)
To: linux-ext4
I have cloned the ext4 subtree: git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4.git
Then I tried to build it, first by making a .config file, and then running make.
The make won't finish beacuse I am getting this "all warnings being treated as errors":
In file included from help.c:12:
subcmd-util.h: In function ‘xrealloc’:
subcmd-util.h:58:31: error: pointer ‘ptr’ may be used after ‘realloc’ [-Werror=use-after-free]
58 | ret = realloc(ptr, 1);
| ^~~~~~~~~~~~~~~
subcmd-util.h:52:21: note: call to ‘realloc’ here
52 | void *ret = realloc(ptr, size);
| ^~~~~~~~~~~~~~~~~~
subcmd-util.h:56:23: error: pointer ‘ptr’ may be used after ‘realloc’ [-Werror=use-after-free]
56 | ret = realloc(ptr, size);
| ^~~~~~~~~~~~~~~~~~
subcmd-util.h:52:21: note: call to ‘realloc’ here
52 | void *ret = realloc(ptr, size);
| ^~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make[5]: *** [/home/max/kernels/ext4/tools/build/Makefile.build:97: /home/max/kernels/build_ext4/tools/objtool/help.o] Error 1
Worth mentioning that trying to 'make' the mainline tree works fine.
I have tried adding the -Wno-error flag but it didnt work and anyway I think I shouldn't attempt changing it at all in order to build.
I would appreciate any help, I am a newbie, and I'd like to help fixing some bugs.
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2024-09-14 12:53 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-14 12:53 [PROBLEM] all warnings being treated as errors when I try to compile ext4 subtree Max
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox