Skip to content

Commit

Permalink
doc: releases: migration-guide: 3.6: Add note on SOURCE macros
Browse files Browse the repository at this point in the history
Warn users about the SOURCE macros not being defined globally anymore
and them needed to set them if they need them.

Signed-off-by: Alberto Escolar Piedras <[email protected]>
  • Loading branch information
aescolar authored and nashif committed Jan 30, 2024
1 parent 7d1b3bc commit ed2e7ea
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions doc/releases/migration-guide-3.6.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,16 @@ Build System
* The deprecated ``prj_<board>.conf`` Kconfig file support has been removed, projects that use
this should switch to using board Kconfig fragments instead (``boards/<board>.conf``).

* Until now ``_POSIX_C_SOURCE``, ``_XOPEN_SOURCE``, and ``_XOPEN_SOURCE_EXTENDED`` were defined
globally when building for the native (``ARCH_POSIX``) targets, and ``_POSIX_C_SOURCE`` when
building with PicolibC. Since this release, these are set only for the files that need them.
If your library or application needed this, you may start getting an "implicit declaration"
warning for functions whose prototypes are only exposed if one of these is defined.
If so, you can fix it by defining the corresponding macro in your C source file before any
include, or by adding the equivalent of
``target_compile_definitions(app PRIVATE _POSIX_C_SOURCE=200809L)`` to your application
or ``zephyr_library_compile_definitions(_POSIX_C_SOURCE=200809L)`` to your library.

Kernel
======

Expand Down

0 comments on commit ed2e7ea

Please sign in to comment.