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

add missing includes #34

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

arkamar
Copy link

@arkamar arkamar commented Mar 3, 2025

Several includes are missing based on linux man pages:

  • strings.h for strcasecmp
  • alloca.h for alloca
  • stdio.h for fileno

The compilation with GCC 15 fails without those with implicit function declaration error.


It is also worth to say that GCC 15 defaults to -std=c23, where bool is a reserved keyword, thus GCC produces following error:

src/H/bool.h:35:27: error: two or more data types in declaration specifiers
   35 |     typedef unsigned char bool;
      |                           ^~~~

I am using -std=c17 for now.

Several includes are missing based on linux man pages:

- strings.h for strcasecmp
- alloca.h  for alloca
- stdio.h   for fileno

The compilation with GCC 15 fails without those with implicit function
declaration error.
gentoo-bot pushed a commit to gentoo/gentoo that referenced this pull request Mar 3, 2025
- add missing includes and append -D_POSIX_SOURCE cppflag in order to
  resolve implicit function declaration issues
- set -std=c17 because upstream typedefs bool in code base

Upstream-PR: Baron-von-Riedesel/JWasm#34
Closes: https://bugs.gentoo.org/944893
Signed-off-by: Petr Vaněk <[email protected]>
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

Successfully merging this pull request may close these issues.

1 participant