g+
g+ Communities
Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  <20122013  2014  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  <20122013  2014 
<== Date ==> <== Thread ==>

Subject: Re: Converting driver of R3.13 Applications to R3.14 problems
From: Andrew Johnson <anj@aps.anl.gov>
To: tech-talk@aps.anl.gov
Cc: Bai Jiaoni <baijn@ihep.ac.cn>
Date: Thu, 8 Mar 2012 18:03:49 -0600
Hello,

On 2012-03-08 Bai Jiaoni wrote:
> When I make in <top>/, it reports error
> 
> ../drvBPEM.c:26:21: vxWorks.h: No such file or directory
> ../drvBPEM.c:27:19: vxLib.h: No such file or directory
> ../drvBPEM.c:28:17: vme.h: No such file or directory
> ../drvBPEM.c:29:23: rebootLib.h: No such file or directory
> ../drvBPEM.c:30:21: taskLib.h: No such file or directory
> ../drvBPEM.c:31:20: sysLib.h: No such file or directory
> ../drvBPEM.c:32:20: logLib.h: No such file or directory
> ../drvBPEM.c:33:20: intLib.h: No such file or directory
> ../drvBPEM.c:34:16: iv.h: No such file or directory

These errors are because it's trying to compile vxWorks-specific code using 
the linux native compiler, which is never going to work since Linux doesn't 
have those header files.

> Besides my host architechture is linux-x86 and cross complier target
>  architecture is vxworks ppc604. I think maybe VALID_BUILDS = Ioc is
>  suitable for vxworks, but there still exits the errors in this case. I
>  don't know why.

You don't need to look at or set VALID_BUILDS at all, take that modification 
out completely.

Assuming your added source files are only meant to be compiled for vxWorks, 
the changes you need to make are that instead of these lines:

example_SRCS += drvBPEM.c
example_SRCS += devBPEM.c
example_SRCS += universe.c
example_SRCS += dmaLib.c

use these instead:

example_SRCS_vxWorks += drvBPEM.c
example_SRCS_vxWorks += devBPEM.c
example_SRCS_vxWorks += universe.c
example_SRCS_vxWorks += dmaLib.c

which tell the build system that these files should only be compiled for the 
vxWorks target architectures.

- Andrew
-- 
Never interrupt your enemy when he is making a mistake.
-- Napoleon Bonaparte

References:
Converting driver of R3.13 Applications to R3.14 problems Bai Jiaoni

Navigate by Date:
Prev: RE: How do you close a CSS BOY window? Chen, Xihui
Next: example_registerRecordDeviceDriver.cpp:238: undefined reference to `pvar_drvet_drvBPEM' error Bai Jiaoni
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  <20122013  2014 
Navigate by Thread:
Prev: Converting driver of R3.13 Applications to R3.14 problems Bai Jiaoni
Next: example_registerRecordDeviceDriver.cpp:238: undefined reference to `pvar_drvet_drvBPEM' error Bai Jiaoni
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  <20122013  2014 
ANJ, 18 Nov 2013 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· EPICSv4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·