EPICS Controls 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  <20102011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  <20102011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: Re: Cross compiling EPICS for cris v10
From: Florian Feldbauer <[email protected]>
To: Andrew Johnson <[email protected]>
Cc: Florian Feldbauer <[email protected]>, [email protected]
Date: Fri, 1 Oct 2010 20:06:27 +0200 (CEST)
Here's the makefile:
TOP=../..

include $(TOP)/configure/CONFIG
#----------------------------------------
#  ADD MACRO DEFINITIONS AFTER THIS LINE

#=============================
# Build the IOC support library
LIBRARY_IOC += slowCtrlSupport

PROD_LIBS += stream
PROD_LIBS += asyn
PROD_LIBS += calc
PROD_LIBS += streamSynApps

# xxxRecord.h will be created from xxxRecord.dbd
DBDINC += xxxRecord
# Install devXxxSoft.dbd into <top>/dbd
DBD += xxxSupport.dbd

# Compile and add the code to the support library
slowCtrlSupport_SRCS += xxxRecord.c
slowCtrlSupport_SRCS += devXxxSoft.c

# Link locally-provided code into the support library,
# rather than directly into the IOC application.
slowCtrlSupport_SRCS += dbSubExample.c
slowCtrlSupport_SRCS += slowCtrlHello.c
slowCtrlSupport_SRCS += initTrace.c

slowCtrlSupport_LIBS += $(EPICS_BASE_IOC_LIBS)

#=============================
# Build the IOC application

PROD_IOC = slowCtrl
# slowCtrl.dbd will be created and installed
DBD += slowCtrl.dbd

# slowCtrl.dbd will be made up from these files:
slowCtrl_DBD += base.dbd
slowCtrl_DBD += xxxSupport.dbd
slowCtrl_DBD += dbSubExample.dbd
slowCtrl_DBD += slowCtrlHello.dbd
slowCtrl_DBD += initTrace.dbd
slowCtrl_DBD += slowCtrlInclude.dbd
slowCtrl_DBD += stream.dbd
slowCtrl_DBD += asyn.dbd

# slowCtrl_registerRecordDeviceDriver.cpp derives from slowCtrl.dbd
slowCtrl_SRCS += slowCtrl_registerRecordDeviceDriver.cpp

# Build the main IOC entry point on workstation OSs.
slowCtrl_SRCS_DEFAULT += slowCtrlMain.cpp
slowCtrl_SRCS_vxWorks += -nil-

# Add support from base/src/vxWorks if needed
#slowCtrl_OBJS_vxWorks += $(EPICS_BASE_BIN)/vxComLibrary

# Link in the code from the support library
slowCtrl_LIBS += slowCtrlSupport

# NOTE: To build SNL programs, SNCSEQ must be defined
# in the <top>/configure/RELEASE file

ifneq ($(SNCSEQ),)
    # Build sncExample into slowCtrlSupport
    sncExample_SNCFLAGS += +r
    slowCtrl_DBD += sncExample.dbd
    slowCtrlSupport_SRCS += sncExample.stt
    slowCtrlSupport_LIBS += seq pv
    slowCtrl_LIBS += seq pv

    # Build sncProgram as a standalone program
    PROD_HOST += sncProgram
    sncProgram_SNCFLAGS += +m
    sncProgram_SRCS += sncProgram.st
    sncProgram_LIBS += seq pv
    sncProgram_LIBS += $(EPICS_BASE_HOST_LIBS)
endif

# Finally link to the EPICS Base libraries
slowCtrl_LIBS += $(EPICS_BASE_IOC_LIBS)

#=============================

include $(TOP)/configure/RULES
#----------------------------------------
#  ADD RULES AFTER THIS LINE

and here's the commandline:
/usr/local/cris/bin/cris-axis-linux-gnu-g++ -o slowCtrl -Wl,-Bstatic -static-libgcc -Wl,--strip-all -L/usr/Epics/base-3.14.10/lib/linux-cris_v10 -L/usr/Epics/synApps/synApps_5_5/support/calc-2-8/lib/linux-cris_v10 -L/usr/Epics/slowCtrl_etrax/lib/linux-cris_v10 -L/usr/Epics/synApps/synApps_5_5/support/asyn-4-13/lib/linux-cris_v10 -L/usr/Epics/synApps/synApps_5_5/support/stream-2-4-1/lib/linux-cris_v10 -Wl,-rpath,/usr/Epics/base-3.14.10/lib/linux-cris_v10 -Wl,-rpath,/usr/Epics/synApps/synApps_5_5/support/calc-2-8/lib/linux-cris_v10 -Wl,-rpath,/usr/Epics/slowCtrl_etrax/lib/linux-cris_v10 -Wl,-rpath,/usr/Epics/synApps/synApps_5_5/support/asyn-4-13/lib/linux-cris_v10 -Wl,-rpath,/usr/Epics/synApps/synApps_5_5/support/stream-2-4-1/lib/linux-cris_v10 -L/usr/local/devboard-R2_20//target/cris-axis-linux-gnu/lib -L/usr/local/devboard-R2_20//target/cris-axis-linux-gnu/usr/lib slowCtrl_registerRecordDeviceDriver.o slowCtrlMain.o -lslowCtrlSupport -lrecIoc -lsoftDevIoc -lmiscIoc -lrsrvIoc -ldbtoolsIoc -lasIoc -ldbIoc -lregistryIoc -ldbStaticIoc -lca -lCom -lstream -lasyn -lcalc -lstreamSynApps -lpthread -lm -lrt
/usr/Epics/synApps/synApps_5_5/support/asyn-4-13/lib/linux-cris_v10/libasyn.a(devAsynInt32.o): In function `getIoIntInfo':
epicsTypeClass/../../asyn/devEpics/devAsynInt32.c:288: undefined reference to `epicsRingBytesCreate'
/usr/local/cris/lib/gcc-lib/cris-axis-linux-gnu/3.2.1/../../../../cris-axis-linux-gnu/bin/ld: /usr/Epics/synApps/synApps_5_5/support/asyn-4-13/lib/linux-cris_v10/libasyn.a(devAsynInt32.o): No PLT for relocation R_CRIS_32_GOTPLT against symbol `epicsRingBytesCreate' from .text section
/usr/local/cris/lib/gcc-lib/cris-axis-linux-gnu/3.2.1/../../../../cris-axis-linux-gnu/bin/ld: final link failed: Bad value
collect2: ld returned 1 exit status
make[3]: *** [slowCtrl] Error 1
make[3]: Leaving directory `/usr/Epics/slowCtrl_etrax/slowCtrlApp/src/O.linux-cris_v10'
make[2]: *** [install.linux-cris_v10] Error 2
make[2]: Leaving directory `/usr/Epics/slowCtrl_etrax/slowCtrlApp/src'
make[1]: *** [src.install] Error 2
make[1]: Leaving directory `/usr/Epics/slowCtrl_etrax/slowCtrlApp'
make: *** [slowCtrlApp.install] Error 2


Florian



On Fri, 1 Oct 2010, Andrew Johnson wrote:

On Friday 01 October 2010 07:53:33 Florian Feldbauer wrote:

I've just tested to build the example application using makeBaseApp.pl without changing any files. This works.


But as soon as I add Asyn and Stream I get the error.

Repeating my request of yesterday, please post your IOC's Makefile and the command line of the link command that fails as printed by gnumake. It's sounding more and more like this may be a mistake in your Makefile, that you're not linking all the libraries, or you have them in the wrong order.


- Andrew -- If a man is offered a fact which goes against his instincts, he will scrutinize it closely, and unless the evidence is overwhelming, he will refuse to believe it. If, on the other hand, he is offered something which affords a reason for acting in accordance to his instincts, he will accept it even on the slightest evidence. -- Bertrand Russell


Replies:
RE: Cross compiling EPICS for cris v10 Mark Rivers
References:
Cross compiling EPICS for cris v10 Florian Feldbauer
RE: Cross compiling EPICS for cris v10 Mark Rivers
RE: Cross compiling EPICS for cris v10 Florian Feldbauer
Re: Cross compiling EPICS for cris v10 Andrew Johnson

Navigate by Date:
Prev: Re: Cross compiling EPICS for cris v10 Andrew Johnson
Next: RE: Cross compiling EPICS for cris v10 Mark Rivers
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  <20102011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: Re: Cross compiling EPICS for cris v10 Andrew Johnson
Next: RE: Cross compiling EPICS for cris v10 Mark Rivers
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  <20102011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 01 Oct 2010 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·