OpenDDS / OpenDDS

OpenDDS is an open source C++ implementation of the Object Management Group (OMG) Data Distribution Service (DDS). OpenDDS also supports Java bindings through JNI.
http://www.opendds.org
Other
1.28k stars 463 forks source link

tests/DCPS/MetaStruct/MetaStructTest failes on Yocto #4621

Closed jrw972 closed 1 week ago

jrw972 commented 2 weeks ago

Discussed in https://github.com/OpenDDS/OpenDDS/discussions/4620

Originally posted by **vermaete** May 2, 2024 On a Yocto build with meta-opendds the test 'MetaStructTest' is failing. ``` root@rpi4-opendds:/usr/share/DDS_ROOT/tests/DCPS/MetaStruct# ./run_test.pl run_test_i(Unaligned CDR) ERROR: Serialized type of a.w does not match. expected 1 received 2 run_test_i(XCDR2) ERROR: Serialized type of a.w does not match. expected 1 received 2 run_test_i(Unaligned CDR) ERROR: Serialized type of a.w does not match. expected 1 received 2 run_test_i(XCDR2) ERROR: Serialized type of a.w does not match. expected 1 received 2 run_test_i(Unaligned CDR) ERROR: Serialized type of a.w does not match. expected 1 received 2 run_test_i(XCDR2) ERROR: Serialized type of a.w does not match. expected 1 received 2 ERROR: test returned 1 ``` https://github.com/OpenDDS/OpenDDS/blob/master/tests/DCPS/MetaStruct/MetaStructTest.cpp#L128 https://github.com/OpenDDS/OpenDDS/blob/master/tests/DCPS/MetaStruct/MetaStructTest.cpp#L173 Version of OpenDDS: 3.28.0 Version of gcc: 13.2 ! The same test at Debian with GCC12.2 is passing. I assume it's related to the size of wchar_t? Br,
jrw972 commented 2 weeks ago

Options include:

  1. Change code generator to cast wchar to int. <- selected
  2. Remove wchar from the test, i.e., do not filter on a wchar.
  3. Make wchar a supported type in Value.