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

Fix platform-specific preprocessor directive for Linux #8

Merged
merged 4 commits into from
Mar 13, 2025

Conversation

vitimiti
Copy link
Contributor

@vitimiti vitimiti commented Mar 13, 2025

Replaced _LINUX with __linux__ to align with standard platform macros.

This ensures proper compilation and debugging functionality on Linux systems.

No other logic or functionality was affected.

    Replaced `_LINUX` with `__linux__` to align with standard platform
    macros.

    This ensures proper compilation and debugging functionality on Linux
    systems.

    No other logic or functionality was affected.

Signed-off-by: Victor Matia <[email protected]>
Replaced multiple Linux compiler checks with a unified `_LINUX` define.

This improves consistency and reduces redundancy in platform-specific
code handling.

This also ensures the code compiles in more distributions and versions
of Linux systems.

Signed-off-by: Victor Matia <[email protected]>
@vitimiti
Copy link
Contributor Author

I added better standardization for the Linux macro defines as discussed privately to support all expected macros under the previously used macro.

Fixed the way the macro `_LINUX` is checked for to prevent UB in some
compilers.

Signed-off-by: Victor Matia <[email protected]>
Updated the Linux platform detection logic to include the 'linux' macro,
ensuring broader compatibility.

Referenced cpredef documentation for clarity and standardized coverage.

Signed-off-by: Victor Matia <[email protected]>
@OmniBlade OmniBlade merged commit 87d9c11 into TheAssemblyArmada:master Mar 13, 2025
@vitimiti vitimiti deleted the fix-linux-build branch March 13, 2025 20:15
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