Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

io_utils.h uses va_list without previously having included stdarg.h (Solaris derived systems) #166

Open
drboone opened this issue Oct 29, 2024 · 3 comments

Comments

@drboone
Copy link

drboone commented Oct 29, 2024

A number of C files in the common and transport subtrees include subprojects/opensea-common/include/io_utils.h. On Solaris derived systems (in this case, SmartOS, an Illumos distro), since this hasn't included stdargs.h, va_list is undefined. There's a second idential issue in secure_file.h Build log:

va_list.txt

Not sure whether you would prefer to include this in the .h files, or from each of the C modules.

Compiler:

lesmiz 49 $ cc -v
Using built-in specs.
COLLECT_GCC=/opt/local/gcc10/bin/cc
COLLECT_LTO_WRAPPER=/opt/local/gcc10/libexec/gcc/x86_64-sun-solaris2.11/10.4.0/lto-wrapper
Target: x86_64-sun-solaris2.11
Configured with: ../gcc-1f8c6b1d90dd69d36e9de7c1962b42e349561085/configure --with-local-prefix=/opt/local --enable-languages=c,c++,fortran,go,objc,lto --enable-__cxa_atexit --enable-initfini-array --disable-nls --disable-libitm --with-gnu-as --with-as=/opt/local/bin/gas --without-gnu-ld --with-ld=/bin/ld --with-zstd=no --prefix=/opt/local/gcc10 --build=x86_64-sun-solaris2.11 --host=x86_64-sun-solaris2.11 --infodir=/opt/local/gcc10/info --mandir=/opt/local/gcc10/man
Thread model: posix
Supported LTO compression algorithms: zlib
gcc version 10.4.0 (GCC) 
@vonericsen
Copy link
Contributor

Hi @drboone,

Thank you for reporting this and sharing your build output.
I will add that include to the headers to resolve this.

vonericsen added a commit to Seagate/opensea-common that referenced this issue Oct 30, 2024
Adding stdarg.h to io_utils.h and secure_file.h since it was missing.
This causes a build failure on Illumos based distributions.
For some reason Linux, FreeBSD, and Windows do not complain about this.

[Seagate/openSeaChest#166]

Signed-off-by: Tyler Erickson <tyler.erickson@seagate.com>
vonericsen added a commit that referenced this issue Oct 30, 2024
[#165, #166]

Signed-off-by: Tyler Erickson <tyler.erickson@seagate.com>
@vonericsen
Copy link
Contributor

I have pushed a fix for this issue as well as the one the CI identified in opensea-transport when I pushed the fix.
It's on our develop branch currently, but will get pulled into our next release.

@drboone
Copy link
Author

drboone commented Oct 30, 2024

Much appreciated!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants