Hi,
On 2011-11-16 [email protected] wrote:
> cd topbin
> value = 0 = 0x0
> #load epics 3.14.12.1 core
> ld 0,0, "rapp.munch"
> Undefined symbol: devReadProbe (binding 1 type 0)
> Undefined symbol: devRegisterAddress (binding 1 type 0)
> ld error: Module contains undefined symbol(s) and may be unusable.
> value = 0 = 0x0
I think this is an indication that you're linking the libraries into your IOC
binary in the wrong order; your device support is the only code that needs the
devLib routines to be present, so you must link libCom *after* your code that
calls devLib. The issue is subtle though, see below...
> After searching tech-talk for reference to solve the problems, I used
> nmppc and arppc extract devLibVME.o from libCom.a and loaded it before
> iocCore, but I got more undefined symbol hint. I guess I must have
> configured some error somewhere, but I can’t find a way yet to solve the
> problem. Is there any one who can give me some advice? Any comment will be
> much appreciated.
Doing that won't help, we need to fix this in the Makefile, which you very
helpfully posted.
> There it is the Makefile of app:
...
> # Add all the support libraries needed by this IOC
> rapp_LIBS_vxWorks += vxStats
> rapp_LIBS_vxWorks += CaenV812
^^^ These are causing the problem.
...
> # Finally link to the EPICS Base libraries
> rapp_LIBS += $(EPICS_BASE_IOC_LIBS)
Libraries that appear in the target-specific rapp_LIBS_vxWorks variable get
linked *after* libraries from the general rapp_LIBS variable, which contains
libCom and hence the devLib routines that your libCaenV812.a needs.
To fix your problem, change the two lines above that I marked to add those
libraries to the rapp_LIBS variable instead. You probably used the _vxWorks
variable because those libraries aren't available for your host architecture,
but the correct way to resolve that is to only build the IOC on vxWorks, so
change the line setting PROD_IOC to set PROD_IOC_vxWorks instead.
Alternatively you could link to libCom a second time by adding the line
rapp_LIBS_vxWorks += Com
anywhere after the other two settings above. However I would recommend my
other solution as it may prevent other similar problems in the future.
HTH,
- Andrew
--
Optimization is the process of taking something that works and
replacing it with something that almost works, but costs less.
-- Roger Needham
- References:
- Undefined symbol of devReadProbe and devRegisterAddress housg
- Navigate by Date:
- Prev:
RE: TEMPE_VEAT Exception Szalata, Zenon M.
- Next:
Re: EPICS stackoverflow site Andrew Johnson
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
<2011>
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
- Navigate by Thread:
- Prev:
Undefined symbol of devReadProbe and devRegisterAddress housg
- Next:
Re: Undefined symbol of devReadProbe and devRegisterAddress housg
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
<2011>
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
|