Skip to content

[devkitPPC] ::aligned_alloc is available, but not std::aligned_alloc #4

@dkosmari

Description

@dkosmari

I'm reporting this here, since the gcc repo doesn't allow submitting issues.

In devkitPPC/powerpc-eabi/include/c++/13.2.0/powerpc-eabi/bits/c++config.h, the _GLIBCXX_HAVE_ALIGNED_ALLOC macro is not defined, and that prevents the C function aligned_alloc() to be imported into the std namespace for C++ (in cstdlib).

This code compiles:

#include <stdlib.h>
// ...
buffer = ::aligned_alloc(256, size);

but this doesn't:

#include <cstdlib>
// ...
buffer = std::aligned_alloc(256, size);

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions