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 C++ compilation #1158

Merged
merged 1 commit into from
May 20, 2024
Merged

Conversation

pguyot
Copy link
Collaborator

@pguyot pguyot commented May 15, 2024

With ESP-IDF 5.2, some headers do not tolerate being included from an extern "C" block. To avoid any similar issue, all includes are moved outside of these blocks, thus fixing compilation of C++ code including our headers.

These changes are made under both the "Apache 2.0" and the "GNU Lesser General
Public License 2.1 or later" license terms (dual license).

SPDX-License-Identifier: Apache-2.0 OR LGPL-2.1-or-later

@bettio
Copy link
Collaborator

bettio commented May 19, 2024

Makes sense, let's target release-0.6

With ESP-IDF 5.2, some headers do not tolerate being included from an
extern "C" block. To avoid any similar issue, all includes are moved outside
of these blocks, thus fixing compilation of C++ code including our headers.

Signed-off-by: Paul Guyot <[email protected]>
@pguyot pguyot changed the base branch from main to release-0.6 May 20, 2024 04:03
@pguyot
Copy link
Collaborator Author

pguyot commented May 20, 2024

Makes sense, let's target release-0.6

ets headers also need the same change, I'll create another PR for it on main branch.

@bettio bettio merged commit edf2b12 into atomvm:release-0.6 May 20, 2024
85 of 90 checks passed
@pguyot pguyot deleted the w20/fix-cpp-compilation branch May 21, 2024 04:41
bettio added a commit that referenced this pull request Jun 4, 2024
Fix C++ compilation for ets headers

This PR depends on #1158.

These changes are made under both the "Apache 2.0" and the "GNU Lesser General
Public License 2.1 or later" license terms (dual license).

SPDX-License-Identifier: Apache-2.0 OR LGPL-2.1-or-later
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