Experimental Physics and Industrial Control System
|
Hi Mark,
I see LightField is compiled with /clr and I think this may be leading to the warning. An
epicsThreadId is defined as a pointer to a “struct epicsThreadOSD”
https://github.com/epics-base/epics-base/blob/60fa2d31da2deaaa89636b4a1f5b852efe0b2699/modules/libcom/src/osi/epicsThread.h#L108
and this is returned by epicsThreadCreate() which is used in the lightfield code. The epicsThreadOSD structure is not defined in a
public header on windows, which doesn’t normally matter as the native pointer is not meant to be dereferenced in public code, but as per
https://learn.microsoft.com/en-us/cpp/error-messages/tool-errors/linker-tools-warning-lnk4248?view=msvc-170 I think the linker is unsure whether it could be a CLR type or a native type hence the warning message you see. If you changed the typedef in epicsThread.h
to be:
typedef void *epicsThreadId;
I think that may remove the warning as it has broken the link to the undefined epicsThreadOSD type
Regards,
Freddie
From: Tech-talk <tech-talk-bounces at aps.anl.gov>
On Behalf Of Mark Rivers via Tech-talk
Sent: 30 September 2023 22:05
To: tech-talk at aps.anl.gov
Subject: Re: Warning when building ADLightField for windows-x64 with VS2022
-
LightField.obj : warning LNK4248: unresolved typeref token (01000038) for 'epicsThreadOSD'; image may not run
-
Does anyone know what causes this warning, and if it is serious?
It does not appear to be serious, because the application seems to run fine. But I am still interested to know what might be causing that warning.
Folks,
I am getting a warning for an unresolved typeref in epicsThreadOSD when building ADLightField for windows-x64 with Visual Studio 2022 Community Edition.
link -nologo -subsystem:windows -dll -LTCG -incremental:no -opt:ref -release -MACHINE:X64 -out:LightField.dll -implib:LightField.lib LightField.obj
J:/epics/support/areaDetector-3-12-1/ADCore/lib/windows-x64/ADBase.lib J:/epics/support/asyn-4-44-2/lib/windows-x64/asyn.lib J:/epics/support/areaDetector-3-12-1/ADCore/lib/windows-x64/ntndArrayConverter.lib H:/epics/base-7.0.7/lib/windows-x64/nt.lib H:/epics/base-7.0.7/lib/windows-x64/pvDatabase.lib
H:/epics/base-7.0.7/lib/windows-x64/pvAccess.lib H:/epics/base-7.0.7/lib/windows-x64/pvData.lib J:/epics/support/areaDetector-3-12-1/ADSupport/lib/windows-x64/netCDF.lib J:/epics/support/areaDetector-3-12-1/ADSupport/lib/windows-x64/tiff.lib J:/epics/support/areaDetector-3-12-1/ADSupport/lib/windows-x64/xml2.lib
J:/epics/support/areaDetector-3-12-1/ADSupport/lib/windows-x64/NeXus.lib J:/epics/support/areaDetector-3-12-1/ADSupport/lib/windows-x64/hdf5.lib J:/epics/support/areaDetector-3-12-1/ADSupport/lib/windows-x64/hdf5_hl.lib J:/epics/support/areaDetector-3-12-1/ADSupport/lib/windows-x64/bitshuffle.lib
J:/epics/support/areaDetector-3-12-1/ADSupport/lib/windows-x64/blosc.lib J:/epics/support/areaDetector-3-12-1/ADSupport/lib/windows-x64/szip.lib J:/epics/support/areaDetector-3-12-1/ADSupport/lib/windows-x64/zlib.lib J:/epics/support/areaDetector-3-12-1/ADSupport/lib/windows-x64/jpeg.lib
H:/epics/base-7.0.7/lib/windows-x64/dbRecStd.lib H:/epics/base-7.0.7/lib/windows-x64/dbCore.lib H:/epics/base-7.0.7/lib/windows-x64/ca.lib H:/epics/base-7.0.7/lib/windows-x64/Com.lib gdi32.lib oleaut32.lib
Creating library LightField.lib and object LightField.exp
LightField.obj : warning LNK4248: unresolved typeref token (01000038) for 'epicsThreadOSD'; image may not run
Does anyone know what causes this warning, and if it is serious?
Thanks,
Mark
|
- References:
- Warning when building ADLightField for windows-x64 with VS2022 Mark Rivers via Tech-talk
- Re: Warning when building ADLightField for windows-x64 with VS2022 Mark Rivers via Tech-talk
- Navigate by Date:
- Prev:
Re: Warning when building ADLightField for windows-x64 with VS2022 Mark Rivers via Tech-talk
- Next:
Tech Talk Mailing List Abdalla Ahmad 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
2019
2020
2021
2022
<2023>
2024
- Navigate by Thread:
- Prev:
Re: Warning when building ADLightField for windows-x64 with VS2022 Mark Rivers via Tech-talk
- Next:
Phoebus EDM autoconvert issue with a button widget Lucas Russo 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
2019
2020
2021
2022
<2023>
2024
|
ANJ, 01 Oct 2023 |
·
Home
·
News
·
About
·
Base
·
Modules
·
Extensions
·
Distributions
·
Download
·
·
Search
·
EPICS V4
·
IRMIS
·
Talk
·
Bugs
·
Documents
·
Links
·
Licensing
·
|