RTEMS | test_cat type mismatch with LTO (#5739)
Joel Sherrill (@joel)
gitlab at rtems.org
Wed Sep 2 14:32:12 UTC 2026
Issue created by Joel Sherrill: https://gitlab.rtems.org/rtems/rtos/rtems/-/work_items/5739
## Summary
<!--
Please provide as much information as possible such as error messages or attaching logs
-->
@chris asked me to look into this. The patch to a solution is not clear. More below the output.
```
../../../testsuites/libtests/tar02/init.c:110:6: warning: type of 'test_cat' does not match original declaration [-Wlto-type-mismatch]
110 | void test_cat( const char *file, int offset_arg, int length );
| ^
../../../testsuites/psxtests/psxfile01/test_cat.c:61:6: note: type mismatch in parameter 3
61 | void test_cat( char *file, int offset_arg, size_t length )
| ^
../../../testsuites/psxtests/psxfile01/test_cat.c:61:6: note: type 'size_t' should match type 'int'
../../../testsuites/psxtests/psxfile01/test_cat.c:61:6: note: 'test_cat' was previously declared here
../../../testsuites/psxtests/psxfile01/test_cat.c:61:6: note: code may be misoptimized unless '-fno-strict-aliasing' is used
```
test_cat.c is in psxfile01 and included as "sources" in the yaml.
But tar02, psxftw01, psxftw02 are "scripts" in yaml. Those three reference test_cat.c in a custom script fragment.
## Steps to reproduce
@chris Beyond enabling LTO, what else?
<!-- Pre-set options
- milestone
-->
--
View it on GitLab: https://gitlab.rtems.org/rtems/rtos/rtems/-/work_items/5739
You're receiving this email because of your account on gitlab.rtems.org. Unsubscribe from this thread: https://gitlab.rtems.org/-/sent_notifications/5-2ocus609es8arkvyhblqu0ej9-1d/unsubscribe | Manage all notifications: https://gitlab.rtems.org/-/profile/notifications | Help: https://gitlab.rtems.org/help
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/bugs/attachments/20260902/b0e059d9/attachment-0001.htm>
More information about the bugs
mailing list