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

Zephyr 3.6 support #52

Merged
merged 6 commits into from
Sep 24, 2024
Merged

Zephyr 3.6 support #52

merged 6 commits into from
Sep 24, 2024

Conversation

tylerwhall
Copy link
Owner

No description provided.

@tylerwhall tylerwhall changed the title Zephyr 3.6 support WIP: Zephyr 3.6 support Jul 1, 2024
Zephyr 3.5 switches to picolibc by default and can use a binary from the
SDK or build from source. Clang, invoked by zephyr-bindgen from
zephyr-sys's build.rs, cannot find the SDK's picolibc include path,
resulting in this error:

> zephyr/include/zephyr/posix/time.h:55:12: fatal error: 'sys/timespec.h' file not found

This is because when using the SDK version, it picks up the include path
from a spec file.

    if(NOT CONFIG_PICOLIBC_USE_MODULE)
    zephyr_compile_options(--specs=picolibc.specs)

We don't pass zephyr_compile_options for bindgen because it contains
many GCC-specific options that fail under clang, and in this case the
spec file won't work with clang anyway.

Build from source so the include path is added in the normal way.
Add newly supported versions and remove intermediate 2.x versions to
lighten the build load.
The SYS_INIT function signature changed again.
9f1e4fa86c98ca5a80008080045bdc3b61efd5b9 broke including
<zephyr/posix/time.h>.

It was fixed in 6cf557d64a61d30352b6c50dbeab1dae4f3a67c1 which was only
backported to 3.7-branch as fe0b5ab37b1a1959e4457fee6e0ff0964176adee,
which doesn't currently have a point release.

Should be able to turn native_posix on for 3.7 if I can build from the
branch instead of the released 3.7.0 tag.

zephyr/include/zephyr/posix/posix_types.h:51:21: error: ‘pthread_attr_t’ undeclared here (not in a function); did you mean ‘pthread_attr’?
@tylerwhall tylerwhall changed the title WIP: Zephyr 3.6 support Zephyr 3.6 support Sep 24, 2024
@tylerwhall tylerwhall merged commit d92ba89 into master Sep 24, 2024
80 of 84 checks passed
@tylerwhall tylerwhall deleted the 3.6-support branch September 24, 2024 23:58
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