[tao-users] Windows 10 Entry Point Error

Johnny Willemsen jwillemsen at remedy.nl
Tue Jan 23 05:33:00 CST 2018


Hi,

Thanks for using the PRF form. The problem is how you use the
export_macro commandline argument. When you compile the generated code
within your application this is not needed, when you use a seprate DLL
you have to use an unique export macro as we for example do in
TAO/tests/IDL_Test.

Best regards,


Johnny Willemsen
Remedy IT
Postbus 81 | 6930 AB Westervoort | The Netherlands
http://www.remedy.nl

On 01/23/2018 12:14 PM, maggiari at b-k.it wrote:
> Hello!
>
> Any help on the following would be great. Please let me know if I have to
> provide more details.
>
> ACE+TAO VERSION: 6.4.6
>
> HOST MACHINE and OPERATING SYSTEM: Windows 10 Home x64
>
> COMPILER NAME AND VERSION (AND PATCHLEVEL): Using MS visual studio 2017
> community edition 15.4.0
>
> THE $ACE_ROOT/ace/config.h FILE: #include "ace/config-win32.h"
>
> AREA/CLASS/EXAMPLE AFFECTED: Compilation is clean, linking is clean.
>
> DOES THE PROBLEM AFFECT: EXECUTION?
> Yes.
>
> SYNOPSIS
> Application Run-time failure involves:
>
> The procedure entry point ??shortSequence@@QEAA at AEBV0@@Z could not be
> located in the dynamic link library myexe.exe
>
> The procedure entry point ??getObjectID at ComServer@Sim@@UEAA_NPEBDAEAH at Z
> could not be located in the dynamic link library SimLib.dll
>
> The procedure entry point
> ??getCommandList at ComEntity@Sim@@UEAA_NV?$TAP_Seq_Out_T at VComCommandList@@@@Z
> could not be located in the dynamic link library SimTr.dll
>
> DESCRIPTION
> This is my situation: I come from ACE+TAO 6.0.1 (Win 7) compiled for x64
> arch and this works fine. I'm moved on VS2017 using ACE+TAO 6.4.6. ACE+TAO
> compilation works fine.
> I use and link ACE+TAO libs
> (TAO_PortableServer.lib,TAO_AnyTypeCode.lib,TAO_IORTable.lib,TAO.lib,ACE.lib)
> in some my dynamic libraries (which compile and link fine, all classes
> export symbols with __declspec(dllexport)) and then I link these libraries
> with a my application.
>
> Running this application I got a sequence of run-time failure at dynamic
> library loading time (works fine with older ACE+TAO 6.0.1 under Win 7):
>
> The procedure entry point ??shortSequence@@QEAA at AEBV0@@Z could not be
> located in the dynamic link library myexe.exe
>
> The procedure entry point ??getObjectID at ComServer@Sim@@UEAA_NPEBDAEAH at Z
> could not be located in the dynamic link library SimLib.dll
>
> The procedure entry point
> ??getCommandList at ComEntity@Sim@@UEAA_NV?$TAP_Seq_Out_T at VComCommandList@@@@Z
> could not be located in the dynamic link library SimTr.dll
>
> All entry point errors speaks about some IDL types/interfaces. Looking
> inside libraries (with VS dumpbin) these symbols there are.
>
> I compile the IDL with this command:
>
> tao_idl -Wb,export_macro=__declspec(dllexport) Sim.idl
>
> I attach my IDL at the mail end. I suspect I need to update the IDL
> somehow or use others IDL options to compile.
>
> It's strange because I have to say that under a Linux environment works
> fine with the same ACE+TAO version!
>
> Can you give me some ideas?
>
> Many thanks,
>
> Best Regards
>
> Dario
>
> --------------------------------- IDL ----------------------------
> typedef long IDType;
>
>
> struct vector2f
> {
>   float x;
>   float y;
> };
>
>
> struct vector2d
> {
>   double x;
>   double y;
> };
>
>
> struct vector3f
> {
>   float x;
>   float y;
>   float z;
> };
>
>
> struct vector3d
> {
>   double x;
>   double y;
>   double z;
> };
>
>
> enum DataType
> {
>   DT_BOOLEAN,
>   DT_CHAR,
>   DT_SHORT,
>   DT_USHORT,
>   DT_LONG,
>   DT_ULONG,
>   DT_FLOAT,
>   DT_DOUBLE,
>   DT_VECTOR2F,
>   DT_VECTOR2D,
>   DT_VECTOR3F,
>   DT_VECTOR3D,
>   DT_STRING,
>   DT_BOOLEAN_SEQUENCE,
>   DT_CHAR_SEQUENCE,
>   DT_SHORT_SEQUENCE,
>   DT_USHORT_SEQUENCE,
>   DT_LONG_SEQUENCE,
>   DT_ULONG_SEQUENCE,
>   DT_FLOAT_SEQUENCE,
>   DT_DOUBLE_SEQUENCE,
>   DT_VECTOR2F_SEQUENCE,
>   DT_VECTOR2D_SEQUENCE,
>   DT_VECTOR3F_SEQUENCE,
>   DT_VECTOR3D_SEQUENCE,
>   DT_STRING_SEQUENCE
> };
>
> typedef sequence<boolean>        booleanSequence;
> typedef sequence<char>           charSequence;
> typedef sequence<short>          shortSequence;
> typedef sequence<unsigned short> ushortSequence;
> typedef sequence<long>           longSequence;
> typedef sequence<unsigned long>  ulongSequence;
> typedef sequence<float>          floatSequence;
> typedef sequence<double>         doubleSequence;
> typedef sequence<vector2f>       vector2fSequence;
> typedef sequence<vector2d>       vector2dSequence;
> typedef sequence<vector3f>       vector3fSequence;
> typedef sequence<vector3d>       vector3dSequence;
> typedef sequence<string>         stringSequence;
>
>
> union DataValue switch (DataType)
> {
>   case DT_BOOLEAN:
>     boolean booleanData;
>   case DT_CHAR:
>     char charData;
>   case DT_SHORT:
>     short shortData;
>   case DT_USHORT:
>     unsigned short ushortData;
>   case DT_LONG:
>     long longData;
>   case DT_ULONG:
>     unsigned long ulongData;
>   case DT_FLOAT:
>     float floatData;
>   case DT_DOUBLE:
>     double doubleData;
>   case DT_VECTOR2F:
>     vector2f vector2fData;
>   case DT_VECTOR2D:
>     vector2d vector2dData;
>   case DT_VECTOR3F:
>     vector3f vector3fData;
>   case DT_VECTOR3D:
>     vector3d vector3dData;
>   case DT_STRING:
>     string stringData;
>   case DT_BOOLEAN_SEQUENCE:
>     booleanSequence booleanSequenceData;
>   case DT_CHAR_SEQUENCE:
>     charSequence charSequenceData;
>   case DT_SHORT_SEQUENCE:
>     shortSequence shortSequenceData;
>   case DT_USHORT_SEQUENCE:
>     ushortSequence ushortSequenceData;
>   case DT_LONG_SEQUENCE:
>     longSequence longSequenceData;
>   case DT_ULONG_SEQUENCE:
>     ulongSequence ulongSequenceData;
>   case DT_FLOAT_SEQUENCE:
>     floatSequence floatSequenceData;
>   case DT_DOUBLE_SEQUENCE:
>     doubleSequence doubleSequenceData;
>   case DT_VECTOR2F_SEQUENCE:
>     vector2fSequence vector2fSequenceData;
>   case DT_VECTOR2D_SEQUENCE:
>     vector2dSequence vector2dSequenceData;
>   case DT_VECTOR3F_SEQUENCE:
>     vector3fSequence vector3fSequenceData;
>   case DT_VECTOR3D_SEQUENCE:
>     vector3dSequence vector3dSequenceData;
>   case DT_STRING_SEQUENCE:
>     stringSequence stringSequenceData;
> };
>
>
> struct ComData
> {
>   string    Name;
>   DataValue Value;
> };
>
> typedef sequence<ComData> ComDataList;
>
>
> struct ComCommand
> {
>   string      Name;
>   ComDataList Parameters;
> };
>
> typedef sequence<ComCommand> ComCommandList;
>
>
> struct ComReply
> {
>   string      Name;
>   boolean     Success;
>   ComDataList ReturnValues;
> };
>
>
> module Sim
> {
>   struct ComEntityDescriptor
>   {
>     string Name;
>     string Type;
>   };
>
>   typedef sequence<ComEntityDescriptor> ComEntityDescriptorList;
>
>   interface ComEntity
>   {
>     ComEntityDescriptor getDescriptor();
>
>     boolean getParametersList(out ComDataList p_Parameters);
>
>     boolean getParameter(inout ComData p_Parameter);
>     boolean setParameter(in    ComData p_Parameter);
>
>     boolean getParameters(inout ComDataList p_Parameters);
>     boolean setParameters(in    ComDataList p_Parameters);
>
>     boolean getCommandsList(out ComCommandList p_Commands);
>     ComReply executeCommand(in ComCommand p_Command, in ComEntity
> p_Commander);
>     oneway void invokeCommand(in ComCommand p_Command, in ComEntity
> p_Commander, in boolean p_IsReplyRequested);
>     oneway void replyCallback(in ComReply p_Reply, in ComEntity p_Replier);
>   };
>
>   interface ComClient
>   {
>     string getUniqueID();
>     string getUDPAddress();
>
>     stringSequence getEntitiesAvailableTypesList();
>     boolean createEntity(in ComEntityDescriptor p_ComEntityDescriptor);
>     boolean destroyEntity(in ComEntityDescriptor p_ComEntityDescriptor);
>
>     ComEntityDescriptorList getEntityDescriptorList();
>     ComEntity getEntity(in ComEntityDescriptor p_ComEntityDescriptor);
>
>     oneway void notifyEntityRegistration  (in ComEntityDescriptor
> p_ComEntityDescriptor);
>     oneway void notifyEntityDeregistration(in ComEntityDescriptor
> p_ComEntityDescriptor);
>
>     oneway void setObjectDOF(in double p_Time, in IDType p_ObjectID, in
> IDType p_ComponentID, in vector3d p_Position, in vector3d p_Rotation);
>     oneway void scaleObject (in double p_Time, in IDType p_ObjectID, in
> IDType p_ComponentID, in vector3d p_Scale);
>     oneway void attachObject(in double p_Time, in IDType p_ObjectID, in
> string p_AttachToObject, in string p_AttachToLabel);
>     oneway void detachObject(in double p_Time, in IDType p_ObjectID);
>     oneway void hideObject  (in double p_Time, in IDType p_ObjectID, in
> IDType p_ComponentID);
>     oneway void showObject  (in double p_Time, in IDType p_ObjectID, in
> IDType p_ComponentID);
>   };
>
>   interface ComServer
>   {
>     boolean registerClient  (in Sim::ComClient p_ComClient);
>     boolean unregisterClient(in Sim::ComClient p_ComClient);
>
>     boolean registerEntity  (in ComEntityDescriptor p_ComEntityDescriptor,
> in Sim::ComClient p_ComClient);
>     boolean unregisterEntity(in ComEntityDescriptor p_ComEntityDescriptor,
> in Sim::ComClient p_ComClient);
>
>     stringSequence getClientIDList();
>     string getClientID(in ComEntityDescriptor p_ComEntityDescriptor);
>     ComClient getClient(in string p_ID);
>     ComClient getEntityClient(in ComEntityDescriptor p_ComEntityDescriptor);
>
>     ComEntityDescriptorList getEntityDescriptorList();
>
>     boolean getObjectID(in string p_Name, out IDType p_ID);
>     boolean getMulticastAddress(out string p_MulticastAddress);
>     double  getTime();
>
>     oneway void setObjectDOF(in double p_Time, in IDType p_ObjectID, in
> IDType p_ComponentID, in vector3d p_Position, in vector3d p_Rotation);
>     oneway void scaleObject (in double p_Time, in IDType p_ObjectID, in
> IDType p_ComponentID, in vector3d p_Scale);
>     oneway void attachObject(in double p_Time, in IDType p_ObjectID, in
> string p_AttachToObject, in string p_AttachToLabel);
>     oneway void detachObject(in double p_Time, in IDType p_ObjectID);
>     oneway void hideObject  (in double p_Time, in IDType p_ObjectID, in
> IDType p_ComponentID);
>     oneway void showObject  (in double p_Time, in IDType p_ObjectID, in
> IDType p_ComponentID);
>   };
> };
>
> ------------------------------------ IDL
> ----------------------------------------
>
>
> _______________________________________________
> tao-users mailing list
> tao-users at list.isis.vanderbilt.edu
> http://list.isis.vanderbilt.edu/cgi-bin/mailman/listinfo/tao-users



More information about the tao-users mailing list