Re: [evlog-dev] evlog compiling error on linux
James Keniston <[email protected]> Mon, 29 Jan 2007 12:20:13 -0800
| Newsgroups | gmane.linux.kernel.event-logging |
|---|---|
| Message-ID | <OF05E8BFE0.F6DB6A9D-ON88257272.006E07F5-88257272.006FB72A@us.ibm.com> |
--===============1649442109== Content-type: multipart/alternative; Boundary="0__=07BBF8E1DFFD81658f9e8a93df938690918c07BBF8E1DFFD8165" Content-Disposition: inline --0__=07BBF8E1DFFD81658f9e8a93df938690918c07BBF8E1DFFD8165 Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: quoted-printable [email protected] wrote on 01/28/2007 11:3= 9:36 AM: > Hello, > > I am trying to compile evlog-1.6.1 from source code tar ball on > Rehhat enterprise linux 4 (64bit) on intel x86_64 server. > However I got many errors: > > > syslogatArray.c: In function `main': > syslogatArray.c:73: warning: initialization makes integer from > pointer without a cast > syslogatArray.c:73: error: initializer element is not computable at l= oad time > syslogatArray.c :73: error: (near initialization for `___.pos.function[0]') > syslogatArray.c:87: warning: initialization makes integer from > pointer without a cast > syslogatArray.c:87: error: initializer element is not computable at l= oad time > syslogatArray.c:87: error: (near initialization for `___.pos.function[0]') > syslogatArray.c:101: warning: initialization makes integer from > pointer without a cast > syslogatArray.c:101: error: initializer element is not computable atl= oad time > syslogatArray.c:101: error: (near initialization for `___.pos.function[0]') > syslogatArray.c:108: warning: initialization makes integer from > pointer without a cast > syslogatArray.c:108: error: initializer element is not computable atl= oad time > syslogatArray.c:108: error: (near initialization for `___.pos.function[0]') > .... > > I am wondering does that mean I can't compile evlog on 64bit Linux OS= ? evlog is definitely intended to work on both 32-bit and 64-bit Linux, including x86_64. I think the problem here might be that the syslogat macro uses __FUNCTI= ON__ as an initializer value. This worked when gcc implemented __FUNCTION__= as a string literal. But a while ago, I think, new versions of gcc starte= d treating __FUNCTION__ as a variable, which can't serve as an initialize= r value. > What should change to enable it? If you want to use syslogat(), I think you may be out of luck. One of = my coworkers has agreed to look into this in a week or so, and he should b= e able to give you a clearer answer. If all you want to do is make the test suite pass, then you can deconfi= gure the syslogat tests by commenting out the "$TESTDIR/syslogatTest.sh" lin= e in runtests.sh. > > If I just go ahead to use existing i386 rpm for 64bit OS, syslog > forward function won't work. > Any suggestion from the experts will be appreicated! > > Thanks. > > EF---------------------------------------------------------------------= ---- Jim Keniston IBM LTC-RAS= --0__=07BBF8E1DFFD81658f9e8a93df938690918c07BBF8E1DFFD8165 Content-type: text/html; charset=US-ASCII Content-Disposition: inline Content-transfer-encoding: quoted-printable <html><body> <p><tt>[email protected] wrote on 01/28/20= 07 11:39:36 AM:<br> <br> > Hello,</tt><br> <tt>> </tt><br> <tt>> I am trying to compile evlog-1.6.1 from source code tar ball o= n <br> > Rehhat enterprise linux 4 (64bit) on intel x86_64 server.</tt><br>= <tt>> However I got many errors:</tt><br> <tt>> </tt><br> <tt>> </tt><br> <tt>> syslogatArray.c: In function `main':<br> > syslogatArray.c:73: warning: initialization makes integer from <br= > > pointer without a cast<br> > syslogatArray.c:73: error: initializer element is not computable a= t load time<br> > syslogatArray.c :73: error: (near initialization for `___.pos.func= tion[0]')<br> > syslogatArray.c:87: warning: initialization makes integer from <br= > > pointer without a cast<br> > syslogatArray.c:87: error: initializer element is not computable a= t load time <br> > syslogatArray.c:87: error: (near initialization for `___.pos.funct= ion[0]')<br> > syslogatArray.c:101: warning: initialization makes integer from <b= r> > pointer without a cast<br> > syslogatArray.c:101: error: initializer element is not computable = atload time <br> > syslogatArray.c:101: error: (near initialization for `___.pos.func= tion[0]')<br> > syslogatArray.c:108: warning: initialization makes integer from <b= r> > pointer without a cast<br> > syslogatArray.c:108: error: initializer element is not computable = atload time <br> > syslogatArray.c:108: error: (near initialization for `___.pos.func= tion[0]')<br> > ....</tt><br> <tt>> </tt><br> <tt>> I am wondering does that mean I can't compile evlog on 64bit L= inux OS?</tt><br> <br> <tt>evlog is definitely intended to work on both 32-bit and 64-bit Linu= x, including x86_64.</tt><br> <br> <tt>I think the problem here might be that the syslogat macro uses __FU= NCTION__ as an initializer value. This worked when gcc implemente= d __FUNCTION__ as a string literal. But a while ago, I think, new= versions of gcc started treating __FUNCTION__ as a variable, which can= 't serve as an initializer value.</tt><br> <br> <tt>> What should change to enable it?</tt><br> <br> <tt>If you want to use syslogat(), I think you may be out of luck. &nbs= p;One of my coworkers has agreed to look into this in a week or so, and= he should be able to give you a clearer answer.</tt><br> <br> <tt>If all you want to do is make the test suite pass, then you can dec= onfigure the syslogat tests by commenting out the "$TESTDIR/syslog= atTest.sh" line in runtests.sh.</tt><br> <br> <tt>> </tt><br> <tt>> If I just go ahead to use existing i386 rpm for 64bit OS, &nbs= p;syslog <br> > forward function won't work.</tt><br> <tt>> Any suggestion from the experts will be appreicated!</tt><br> <tt>> </tt><br> <tt>> Thanks.</tt><br> <tt>> </tt><br> <tt>> EF------------------------------------------------------------= -------------<br> </tt><br> <tt>Jim Keniston</tt><br> <tt>IBM LTC-RAS</tt></body></html>= --0__=07BBF8E1DFFD81658f9e8a93df938690918c07BBF8E1DFFD8165-- --===============1649442109== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV --===============1649442109== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ evlog-developers mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/evlog-developers --===============1649442109==--