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  2012  2013  2014  2015  2016  2017  2018  <20192020  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  <20192020 
<== Date ==> <== Thread ==>

Subject: registerRecordDeviceDriver.obj unresolved external symbols
From: "Thomas, Patrick via Tech-talk" <tech-talk@aps.anl.gov>
To: "tech-talk@aps.anl.gov" <tech-talk@aps.anl.gov>
Date: Wed, 22 May 2019 18:44:28 +0000

Hi,

I was wondering if someone might be able to help me track down the source of these linking errors when compiling an IOC with custom device support. I am using EPICS base 3.14.12.8 and Microsoft Visual Studio Community 2017 on Windows 10 Enterprise 64 bit.

link -nologo   -incremental:no -opt:ref -release  -MACHINE:X64              -out:ads.exe        ads_registerRecordDeviceDriver.obj adsMain.obj     ..\\..\\..\\lib\\windows-x64-static\\adsSupport.lib  C:\\Users\\patrick.thomas\\Desktop\\epics\\base-3.14.12.8\\lib\\windows-x64-static\\recIoc.lib  C:\\Users\\patrick.thomas\\Desktop\\epics\\base-3.14.12.8\\lib\\windows-x64-static\\softDevIoc.lib  C:\\Users\\patrick.thomas\\Desktop\\epics\\base-3.14.12.8\\lib\\windows-x64-static\\miscIoc.lib  C:\\Users\\patrick.thomas\\Desktop\\epics\\base-3.14.12.8\\lib\\windows-x64-static\\rsrvIoc.lib  C:\\Users\\patrick.thomas\\Desktop\\epics\\base-3.14.12.8\\lib\\windows-x64-static\\dbtoolsIoc.lib  C:\\Users\\patrick.thomas\\Desktop\\epics\\base-3.14.12.8\\lib\\windows-x64-static\\asIoc.lib  C:\\Users\\patrick.thomas\\Desktop\\epics\\base-3.14.12.8\\lib\\windows-x64-static\\dbIoc.lib  C:\\Users\\patrick.thomas\\Desktop\\epics\\base-3.14.12.8\\lib\\windows-x64-static\\registryIoc.lib  C:\\Users\\patrick.thomas\\Desktop\\epics\\base-3.14.12.8\\lib\\windows-x64-static\\dbStaticIoc.lib  C:\\Users\\patrick.thomas\\Desktop\\epics\\base-3.14.12.8\\lib\\windows-x64-static\\ca.lib  C:\\Users\\patrick.thomas\\Desktop\\epics\\base-3.14.12.8\\lib\\windows-x64-static\\Com.lib   ws2_32.lib advapi32.lib user32.lib kernel32.lib winmm.lib
ads_registerRecordDeviceDriver.obj : error LNK2019: unresolved external symbol pvar_dset_ai_DevSet referenced in function "void __cdecl `dynamic initializer for 'devsl''(void)" (??__Edevsl@@YAXXZ)
ads_registerRecordDeviceDriver.obj : error LNK2019: unresolved external symbol pvar_dset_ao_DevSet referenced in function "void __cdecl `dynamic initializer for 'devsl''(void)" (??__Edevsl@@YAXXZ)
ads_registerRecordDeviceDriver.obj : error LNK2019: unresolved external symbol pvar_dset_bi_DevSet referenced in function "void __cdecl `dynamic initializer for 'devsl''(void)" (??__Edevsl@@YAXXZ)
ads_registerRecordDeviceDriver.obj : error LNK2019: unresolved external symbol pvar_dset_bo_DevSet referenced in function "void __cdecl `dynamic initializer for 'devsl''(void)" (??__Edevsl@@YAXXZ)
ads_registerRecordDeviceDriver.obj : error LNK2019: unresolved external symbol pvar_dset_longin_DevSet referenced in function "void __cdecl `dynamic initializer for 'devsl''(void)" (??__Edevsl@@YAXXZ)
ads_registerRecordDeviceDriver.obj : error LNK2019: unresolved external symbol pvar_dset_longout_DevSet referenced in function "void __cdecl `dynamic initializer for 'devsl''(void)" (??__Edevsl@@YAXXZ)
ads_registerRecordDeviceDriver.obj : error LNK2019: unresolved external symbol pvar_dset_mbbi_DevSet referenced in function "void __cdecl `dynamic initializer for 'devsl''(void)" (??__Edevsl@@YAXXZ)
ads_registerRecordDeviceDriver.obj : error LNK2019: unresolved external symbol pvar_dset_mbbo_DevSet referenced in function "void __cdecl `dynamic initializer for 'devsl''(void)" (??__Edevsl@@YAXXZ)
ads_registerRecordDeviceDriver.obj : error LNK2019: unresolved external symbol pvar_dset_stringin_DevSet referenced in function "void __cdecl `dynamic initializer for 'devsl''(void)" (??__Edevsl@@YAXXZ)
ads_registerRecordDeviceDriver.obj : error LNK2019: unresolved external symbol pvar_dset_stringout_DevSet referenced in function "void __cdecl `dynamic initializer for 'devsl''(void)" (??__Edevsl@@YAXXZ)
ads_registerRecordDeviceDriver.obj : error LNK2019: unresolved external symbol pvar_func_devADSRegistrar referenced in function ads_registerRecordDeviceDriver
ads_registerRecordDeviceDriver.obj : error LNK2019: unresolved external symbol pvar_func_initTraceRegister referenced in function ads_registerRecordDeviceDriver
ads.exe : fatal error LNK1120: 12 unresolved externals
gmake[3]: *** [C:/Users/patrick.thomas/Desktop/epics/base-3.14.12.8/configure/RULES_BUILD:191: ads.exe] Error 1120
gmake[3]: Leaving directory 'C:/Users/patrick.thomas/Desktop/ads/adsApp/src/O.windows-x64-static'
gmake[2]: *** [C:/Users/patrick.thomas/Desktop/epics/base-3.14.12.8/configure/RULES_ARCHS:61: install.windows-x64-static] Error 2
gmake[2]: Leaving directory 'C:/Users/patrick.thomas/Desktop/ads/adsApp/src'
gmake[1]: *** [C:/Users/patrick.thomas/Desktop/epics/base-3.14.12.8/configure/RULES_DIRS:83: src.install] Error 2
gmake[1]: Leaving directory 'C:/Users/patrick.thomas/Desktop/ads/adsApp'
gmake: *** [C:/Users/patrick.thomas/Desktop/epics/base-3.14.12.8/configure/RULES_DIRS:83: adsApp.install] Error 2

Makefile:

TOP=../..

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

#=============================
# Build the IOC support library

LIBRARY_IOC += adsSupport


# Install devXxxSoft.dbd into <top>/dbd
#DBD += xxxSupport.dbd
DBD += adsSupport.dbd

# Compile and add the code to the support library
adsSupport_SRCS += devADS.cpp

# Link locally-provided code into the support library,
# rather than directly into the IOC application.

USR_CPPFLAGS += /std:c++latest

TcAdsDll_DIR += C:\TwinCAT\AdsApi\TcAdsDll\x64\lib
adsSupport_LIBS += TcAdsDll

adsSupport_LIBS += $(EPICS_BASE_IOC_LIBS)

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

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

# ads.dbd will be made up from these files:
ads_DBD += base.dbd

# Include dbd files from all support applications:
#ads_DBD += xxx.dbd
ads_DBD += adsSupport.dbd

# Add all the support libraries needed by this IOC
#ads_LIBS += xxx
ads_LIBS += adsSupport

# ads_registerRecordDeviceDriver.cpp derives from ads.dbd
ads_SRCS += ads_registerRecordDeviceDriver.cpp

# Build the main IOC entry point on workstation OSs.
ads_SRCS_DEFAULT += adsMain.cpp
ads_SRCS_vxWorks += -nil-

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

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

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

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


Thank you,
Patrick


Replies:
Re: registerRecordDeviceDriver.obj unresolved external symbols Johnson, Andrew N. via Tech-talk
Re: registerRecordDeviceDriver.obj unresolved external symbols Torsten Bögershausen via Tech-talk
Re: registerRecordDeviceDriver.obj unresolved external symbols Thomas, Patrick via Tech-talk

Navigate by Date:
Prev: Re: question about pvAccess/pvData, pvPut Heinz Junkes via Tech-talk
Next: Re: registerRecordDeviceDriver.obj unresolved external symbols Johnson, Andrew N. via Tech-talk
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  <20192020 
Navigate by Thread:
Prev: Re: question about pvAccess/pvData, pvPut Heinz Junkes via Tech-talk
Next: Re: registerRecordDeviceDriver.obj unresolved external symbols Johnson, Andrew N. via Tech-talk
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  <20192020 
ANJ, 23 May 2019 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·