Skip to content

fix(kernel,boot): improve GCC/Clang compatibility across kernel and boot components - #88

Merged
manaskamal merged 1 commit into
manaskamal:gcc-compatfrom
kheersagarpatel:gcc-compat
Aug 1, 2026
Merged

fix(kernel,boot): improve GCC/Clang compatibility across kernel and boot components#88
manaskamal merged 1 commit into
manaskamal:gcc-compatfrom
kheersagarpatel:gcc-compat

Conversation

@kheersagarpatel

Copy link
Copy Markdown
Contributor

Summary

This PR addresses a set of GCC/Clang compatibility issues across the kernel, bootloader, and AArch64 build system while preserving the existing implementation where possible. The changes focus on resolving compiler-specific incompatibilities, correcting build configuration, and improving cross-toolchain portability.

Changes

Kernel

  • Before: Some source files relied on compiler-specific types, contained invalid return statements, or included headers that caused portability issues with GCC/Clang.
  • What: Added compiler and architecture guards where required, replaced compiler-specific variadic types with standard va_list, corrected non-void return paths, and removed an unnecessary host Linux header dependency.
  • Why: Improve compatibility with GCC/Clang while preserving existing behavior.

Bootloader

  • Before: The bootloader contained an incorrect MSVC compiler macro check and required updates for the GCC/Clang toolchain.
  • What: Corrected the _MSC_VER preprocessor check and updated the AArch64 bootloader build configuration.
  • Why: Improve compiler compatibility and maintain consistent build behavior across supported toolchains.

Build System

  • Before: Default build target selection and AArch64 build configuration were not aligned with the intended GCC workflow.
  • What: Updated the AArch64 Makefiles to use the intended default build target and adjusted linker/build configuration where required.
  • Why: Improve build consistency for GCC/Clang-based development.

Compatibility

  • Existing functionality is intended to remain unchanged.
  • MSVC/Windows build verification pending.
  • GCC/Linux build completed successfully.
  • ARM64 runtime validated.

Related

Part of #44

…oot components

- Add compiler and architecture guards for platform-specific headers
- Replace compiler-specific _va_list_ with standard va_list
- Fix invalid return statements in non-void process wait functions
- Correct the _MSC_VER preprocessor check
- Remove an unnecessary host Linux header dependency
- Update AArch64 Makefiles for consistent GCC toolchain builds
@manaskamal
manaskamal merged commit db2bb31 into manaskamal:gcc-compat Aug 1, 2026
2 of 3 checks passed
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.

2 participants