Closed HpLightcorner closed 3 years ago
It seems that only generated message code is affected. __declspec(dllexport)
seems to be missing such that another program can link to this under windows.
Can be fixed by calling the message compiler with -P
command.
@riebl and @thor - do you think that we have to make the -P
option Windows-specific or shall we introduce this fix as a general solution when generating messages?
INET's src/makefrag
adds -DINET_EXPORT
only for the Win32 platform. Maybe opp_cmake.py
needs to handle the -pINET
argument passed to opp_makemake
in addition? The current implementation just skips this type of argument…
Hmmm, did not take a look at the python file till now...
It seems that for all other symbols (where the source code is not generated) CMake handles the definition of INET_EXPORT
by default. Furthermore, it seems that only OMNeT++ version 6 is affected? The message compiler from version 5 does not have this feature (or I have overseen it).
opp_msgc
of OMNeT++ 5.6.2 also knows the -P
option. I cannot say if something has changed regarding symbol handling, though.
yes, they are the same, just got misled by the flag option for -P
which is pretty-print
.
It seems that there are some symbols missing when building/linking with INET. For example,
inet::DispatchProtocolReq
. However, the corresponding.cc
(ProtocolTag_m.cc
) files seem to be compiled correctly.