Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  <20092010  2011  2012  2013  2014  2015  2016  2017  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  <20092010  2011  2012  2013  2014  2015  2016  2017 
<== Date ==> <== Thread ==>

Subject: RE: error building mca6-11
From: "Mark Rivers" <rivers@cars.uchicago.edu>
To: "Mark Rivers" <rivers@cars.uchicago.edu>, <marco_hair@163.com>, "tech-talk" <tech-talk@aps.anl.gov>
Date: Fri, 20 Nov 2009 08:18:46 -0600
Hi Geyang,
 
I've looked more closely.  First, this definition:
 
typedef uint32_t u_int32_t; 
 
is in libnet-types.h, not libnet-headers.h.  But it only applies for __sun__ && __svr4__, so it is not used in your case.
 
That means it is relying on a system definition for u_int32_t.
 
u_int32_t is defined in sys/types.h, but there is some GNUC_PREREQ #ifdef around it, and it seems to not be defined for GCC 2.7 and later, i.e. only for very early code?
 
So I am confused, I don't know where u_int32_t is being defined on my system, but it must be, because I don't get the error you are getting.
 
Mark

 
________________________________

From: tech-talk-bounces@aps.anl.gov on behalf of Mark Rivers
Sent: Fri 11/20/2009 7:41 AM
To: marco_hair@163.com; tech-talk
Subject: RE: error building mca6-11



Hi Geyang,

I have not seen that problem.

But I can see that the problem is that the type u_int32_t is not defined.  This probably has to do with the version of Linux or the gnu compiler you are using.

The file libnet-headers.h, which is included before libnet-functions.h in libnet.h, contains the following line:

typedef uint32_t u_int32_t;

So the problem must be that the type uint32_t is not defined.

In a search of typedefs for uint32_t on my system I see that it is defined in several files, including /usr/include/stdint.h.

For some reason it is not being defined when you build libnet.  You could try adding:
#include <stdint.h>
before the line
#include <libnet.h>

in nmc_sys_defs.h

and see if that fixes the problem.

Mark



________________________________

From: Silver [mailto:marco_hair@163.com]
Sent: Thu 11/19/2009 11:28 PM
To: tech-talk
Cc: Mark Rivers
Subject: error building mca6-11



hi,

when I tried to compile the mcaR6-11/10, I met following errors:

/usr/bin/gcc-4.2 -c   -D_POSIX_C_SOURCE=199506L -D_POSIX_THREADS -D_XOPEN_SOURCE=500           -D_X86_  -DUNIX  -D_BSD_SOURCE -Dlinux  -D_REENTRANT -ansi   -O3   -Wall     -g `libnet-config --defines`   -m32     -g -fPIC -I. -I../O.Common -I. -I.. -I../../../include/os/Linux -I../../../include  -I/usr/local/epics/r3.14.10/modules/soft/seq/2-0-12/include  -I/usr/local/epics/r3.14.10/modules/soft/calc/2-6-7/include  -I/usr/local/epics/r3.14.10/modules/soft/sscan/2-6-5/include  -I/usr/local/epics/r3.14.10/modules/soft/busy/1-1/include  -I/usr/local/epics/r3.14.10/modules/soft/std/2-6/include    -I/usr/local/epics/r3.14.10/modules/soft/asyn/4-12/include -I/usr/local/epics/r3.14.10/modules/soft/mca/6-11/include/os/Linux -I/usr/local/epics/r3.14.10/modules/soft/mca/6-11/include -I/usr/local/epics/r3.14.10/base/include/os/Linux -I/usr/local/epics/r3.14.10/base/include        ../nmc_comm_subs_1.c
In file included from /usr/include/libnet.h:124,
                 from ../nmc_sys_defs.h:56,
                 from ../nmc_comm_subs_1.c:69:
/usr/include/./libnet/libnet-functions.h:1432: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'u_int32_t'
make[3]: *** [nmc_comm_subs_1.o] Error 1
make[3]: Leaving directory `/usr/local/epics/r3.14.10/modules/soft/mca/6-11/mcaApp/CanberraSrc/O.linux-x86'
make[2]: *** [install.linux-x86] Error 2
make[2]: Leaving directory `/usr/local/epics/r3.14.10/modules/soft/mca/6-11/mcaApp/CanberraSrc'
make[1]: *** [CanberraSrc.install] Error 2
make[1]: Leaving directory `/usr/local/epics/r3.14.10/modules/soft/mca/6-11/mcaApp'
make: *** [mcaApp.install] Error 2
root@cow1:/usr/local/epics/r3.14.10/modules/soft/mca/6-11#
Any suggestion?  thanks a lot.
ps, I use ubuntu, libnet1 with apt-get install ,not from source compilation.

Best regards
Geyang  2009-11-20









References:
error building mca6-11 Silver
RE: error building mca6-11 Mark Rivers

Navigate by Date:
Prev: RE: error building mca6-11 Mark Rivers
Next: RE: error building mca6-11 Davidsaver, Michael
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  <20092010  2011  2012  2013  2014  2015  2016  2017 
Navigate by Thread:
Prev: RE: error building mca6-11 Mark Rivers
Next: Re: RE: RE: error building mca6-11 Silver
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  <20092010  2011  2012  2013  2014  2015  2016  2017 
ANJ, 31 Jan 2014 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·