From: "Serge E. Hallyn" <serue@us.ibm.com>
To: Mitani <mitani@ryobi.co.jp>
Cc: ltp-list@lists.sourceforge.net
Subject: Re: [LTP] cap_bset_inh_bounds.c build failure
Date: Wed, 7 Apr 2010 08:39:18 -0500 [thread overview]
Message-ID: <20100407133918.GA20569@us.ibm.com> (raw)
In-Reply-To: <000901cad613$7d894030$789bc090$@co.jp>
Quoting Mitani (mitani@ryobi.co.jp):
> Hi,
>
> > -----Original Message-----
> > From: Serge E. Hallyn [mailto:serue@us.ibm.com]
> > Sent: Monday, April 05, 2010 10:22 PM
> > To: Mitani
> > Cc: ltp-list@lists.sourceforge.net
> > Subject: Re: [LTP] cap_bset_inh_bounds.c build failure
> >
> > Quoting Mitani (mitani@ryobi.co.jp):
> > > Hi,
> > >
> > > I tried to build by using yesterday's git in my system (RHEL4.8 x86).
> > > (ltp-dev-4837fee8a7c2de6a83c8927a574c792ca6dabe4e.tar.gz)
> > > But build failed in "cap_bset_inh_bounds.c" with following message.
> > > This is different from "cap_bounds_r.c"'s problem (another thread),
> > I think
> > >
> > > ------------
> > > gcc -g -O2 -g -O2 -fno-strict-aliasing -pipe -Wall
> > > -I/home/LTP/ltp-dev-20100401-3/testcases/kernel/include
> > > -I../../../../include -I../../../../include -L../../../../lib
> > > cap_bset_inh_bounds.c -lltp -lcap -o cap_bset_inh_bounds
> > > cap_bset_inh_bounds.c:124: error: syntax error before numeric
> > constant
> > > cap_bset_inh_bounds.c:124: warning: type defaults to `int' in
> > declaration of
> > > `tst_resm'
> > > cap_bset_inh_bounds.c:124: error: conflicting types for 'tst_resm'
> > > ../../../../include/test.h:192: error: previous declaration of
> > 'tst_resm'
> > > was here
> > > cap_bset_inh_bounds.c:124: error: conflicting types for 'tst_resm'
> > > ../../../../include/test.h:192: error: previous declaration of
> > 'tst_resm'
> > > was here
> > > cap_bset_inh_bounds.c:124: warning: data definition has no type or
> > storage
> > > class
> > > cap_bset_inh_bounds.c:129: warning: type defaults to `int' in
> > declaration of
> > > `tst_exit'
> > > cap_bset_inh_bounds.c:129: error: conflicting types for 'tst_exit'
> > > ../../../../include/test.h:203: error: previous declaration of
> > 'tst_exit'
> > > was here
> > > cap_bset_inh_bounds.c:129: error: conflicting types for 'tst_exit'
> > > ../../../../include/test.h:203: error: previous declaration of
> > 'tst_exit'
> > > was here
> > > cap_bset_inh_bounds.c:129: warning: data definition has no type or
> > storage
> > > class
> > > cap_bset_inh_bounds.c:130: error: syntax error before '}' token
> > > ------------
> > >
> > > In this source, the pair of "ifdef" start/end and the pair of
> > > main() function's "parenthesis" are alternate, I think.
> > >
> > >
> > > How about following patch?
> > >
> > > Signed-off-by : Tomonori Mitani <mitani@ryobi.co.jp>
> >
> > Yup - although really the #ifdef HAVE_LIBCAP should be redundant as
> > the testcases/kernel/security/cap_bound/Makefile shouldn't compile
> > cap_bounds at all if HAVE_LIBCAP is not defined.
> >
>
> Yes. - In my system, this source is not problem. Your indication is
> right. :-)
> But, I manually had updated "libcap2" once. And after "./configure",
> HAVE_LIBCAP is defined. Therefore, I noticed this error.
>
> The system which updated to "libcap2" will need solution of this
> problem, I think.
Agreed, since this is LTP it's not right to expect "sane"
userspace-kernel combos. So we need to check both. Unfortunately
I won't have time to work with that this week.
Even if I did, I'd have a guidance question for Garrett: Do we
want to assume that people will change kernels, but not libraries,
between compile/install and run of ltp? If so, then we can stick
with the autoconf checks for libraries+includes, and add a check
at runtime (as I believe was there originally) for the requisite
kernel support - file capabilities, bounding sets, and 64-bit
capabilities.
OTOH if you're ok with assuming kernel is same at ltp configure
and run, then we can do a test in autoconf which makes for a cleaner
run.
thanks,
-serge
------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list
next prev parent reply other threads:[~2010-04-07 13:39 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-02 3:50 [LTP] cap_bset_inh_bounds.c build failure Mitani
2010-04-05 13:21 ` Serge E. Hallyn
2010-04-07 5:30 ` Mitani
2010-04-07 13:39 ` Serge E. Hallyn [this message]
2010-04-07 16:47 ` Garrett Cooper
2010-04-15 2:55 ` Mitani
2010-04-15 6:56 ` Rishikesh K Rajak
2010-04-15 8:44 ` Garrett Cooper
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20100407133918.GA20569@us.ibm.com \
--to=serue@us.ibm.com \
--cc=ltp-list@lists.sourceforge.net \
--cc=mitani@ryobi.co.jp \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox