This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: "module privilege check" breaks (cross-)compilation due to libelf dependency


Hi,

After making few times the mistake to not check latest code, I ensure now to be on HEAD of master branch ;-)

My feeling is that you had an environment with libelf available but elf_getshdrstrndx() not available.

This is then not sufficient but similar. This solves the issue of unused parameters (this is a warning considered as an error) but not the issue of the use of Elf_Scn type. Systemtap only defines "typedef struct Elf_Scn Elf_Scn;", real definition would come from "elfutils-0.143/libelf/libelfP.h" in my case (but --with-elfutils is not used)



Regards
Fred

Frederic Turgis
OMAP Platform Business Unit - OMAP System Engineering - Platform Enablement - System Multimedia



>
Texas Instruments France SA, 821 Avenue Jack Kilby, 06270 Villeneuve Loubet. 036 420 040 R.C.S Antibes. Capital de EUR 753.920

-----Original Message-----
>From: Mark Wielaard [mailto:mjw@redhat.com]
>Sent: Monday, December 05, 2011 2:58 PM
>To: Turgis, Frederic
>Cc: SystemTap
>Subject: Re: "module privilege check" breaks
>(cross-)compilation due to libelf dependency
>
>On Mon, Dec 05, 2011 at 01:36:01PM +0000, Turgis, Frederic wrote:
>> Commit "bb4470cacb3f7ce5161f9e8a1b7c37a87516a6c3 PR 13128: Implement
>> module privilege check in staprun." has broken my cross-compilation
>> environment to build "staprun" tool for ARM android (I do 4 first
>> steps on host, staprun step on target), see end of mail.
>>
>> Having a deeper look, there is in fact code in staprun_funcs.c that
>> requires libelf like find_section_in_module() and
>> get_module_required_credentials() (Elf_Scn for example) and that is
>> not surrounded by HAVE_LIBELF_H or HAVE_ELF_GETSHDRSTRNDX
>
>I had something similar a few days ago, though I don't
>remember exactly which setup it was on. Does the following
>commit help in your case?
>
>commit fa2418539b4ac2cb1352948f68da08890cec7774
>Author: Mark Wielaard <mjw@redhat.com>
>Date:   Sat Nov 26 02:33:01 2011 +0100
>
>  Fix build error in staprun_funcs.c when
>HAVE_ELF_GETSHDRSTRNDX is not set.
>
>  Mark find_section_in_module arguments unused when
>HAVE_ELF_GETSHDRSTRNDX
>  isn't set.
>
>Or do you need more than that?
>
>Cheers,
>
>Mark
>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]