[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <b212bec9-27c5-6be0-d33e-e23978a322a2@infradead.org>
Date: Sat, 4 Feb 2023 00:30:16 -0800
From: Randy Dunlap <rdunlap@...radead.org>
To: Christophe Leroy <christophe.leroy@...roup.eu>,
Sathvika Vasireddy <sv@...ux.ibm.com>,
"linuxppc-dev@...ts.ozlabs.org" <linuxppc-dev@...ts.ozlabs.org>
Cc: "jpoimboe@...hat.com" <jpoimboe@...hat.com>,
"peterz@...radead.org" <peterz@...radead.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"aik@...abs.ru" <aik@...abs.ru>,
"mpe@...erman.id.au" <mpe@...erman.id.au>,
"mingo@...hat.com" <mingo@...hat.com>,
"rostedt@...dmis.org" <rostedt@...dmis.org>,
"mbenes@...e.cz" <mbenes@...e.cz>,
"npiggin@...il.com" <npiggin@...il.com>,
"chenzhongjin@...wei.com" <chenzhongjin@...wei.com>,
"naveen.n.rao@...ux.vnet.ibm.com" <naveen.n.rao@...ux.vnet.ibm.com>,
"Elliott, Robert (Servers)" <elliott@....com>
Subject: Re: [PATCH v2 15/16] objtool/powerpc: Enable objtool to be built on
ppc
On 2/4/23 00:21, Randy Dunlap wrote:
>
>
> On 2/4/23 00:19, Randy Dunlap wrote:
>> Hi--
>>
>> On 8/29/22 23:41, Christophe Leroy wrote:
>>>
>>>
>>> Le 29/08/2022 à 07:52, Sathvika Vasireddy a écrit :
>>>> This patch adds [stub] implementations for required
>>>> functions, inorder to enable objtool build on powerpc.
>>>
>>> Not all powerpc it seems, see below
>>>
>>
>> When cross-compiling PPC32 (on x86_64), I get 3600+ of these:
>>
>> /bin/sh: line 1: ./tools/objtool/objtool: No such file or directory
>> /bin/sh: line 1: ./tools/objtool/objtool: No such file or directory
>> /bin/sh: line 1: ./tools/objtool/objtool: No such file or directory
>>
>> Is there some way that objtool should work when cross-compiling?
>>
>
> Oops. Its build failed. I seem to be missing header file(s)
> and possibly a library.
> I'll check on those...
>
It's complaining about libelf.h but I have that, so I don't know where
it is looking other than /usr/include/libelf.h, which exists.
Maybe the tool isn't setup (ready) for cross-compiling?
Here's the build output for objtool:
<stdin>:1:10: fatal error: libelf.h: No such file or directory
compilation terminated.
elf.c: In function ‘read_sections’:
elf.c:273:9: error: ‘elf_getshnum’ is deprecated [-Werror=deprecated-declarations]
273 | if (elf_getshdrnum(elf->elf, §ions_nr)) {
| ^~
In file included from /usr/include/gelf.h:32,
from /work/lnx/next/linux-next-20230203/tools/objtool/include/objtool/elf.h:10,
from elf.c:22:
/usr/include/libelf.h:310:12: note: declared here
310 | extern int elf_getshnum (Elf *__elf, size_t *__dst)
| ^~~~~~~~~~~~
elf.c:278:9: error: ‘elf_getshstrndx’ is deprecated [-Werror=deprecated-declarations]
278 | if (elf_getshdrstrndx(elf->elf, &shstrndx)) {
| ^~
/usr/include/libelf.h:322:12: note: declared here
322 | extern int elf_getshstrndx (Elf *__elf, size_t *__dst)
| ^~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make[4]: *** [/work/lnx/next/linux-next-20230203/tools/build/Makefile.build:96: /work/lnx/next/linux-next-20230203/PPC32/tools/objtool/elf.o] Error 1
make[3]: *** [Makefile:66: /work/lnx/next/linux-next-20230203/PPC32/tools/objtool/objtool-in.o] Error 2
Thanks.
--
~Randy
Powered by blists - more mailing lists