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 compilation with define __fallthrough__ #4563

Closed
wants to merge 1 commit into from

Conversation

muvarov
Copy link

@muvarov muvarov commented Nov 11, 2021

Fix compilation under OE (aarch64 gcc 11.2). The original error:
|/usr/include/optee/export-user_ta/include/compiler.h:259:21: error: expected ')' before 'attribute'
| 259 | #define fallthrough attribute((fallthrough))
| | ^~~~~~~~~~~~~
| ./lib/wolf/wolf_symlink/wolfssl/wolfcrypt/types.h:184:50: note: in expansion of macro 'fallthrough'
| 184 | #define FALL_THROUGH attribute ((fallthrough));
| | ^~~~~~~~~~~
| lib/wolf/wolf_symlink/wolfcrypt/src/ecc.c:2980:13: note: in expansion of macro 'FALL_THROUGH'
| 2980 | FALL_THROUGH;
| | ^~~~~~~~~~~~
| In file included from ./lib/wolf/wolf_symlink/wolfssl/wolfcrypt/ecc.h:26,
| from lib/wolf/wolf_symlink/wolfcrypt/src/ecc.c:106:
| ./lib/wolf/wolf_symlink/wolfssl/wolfcrypt/types.h:184:62: error: expected identifier or '(' before ')' token
| 184 | #define FALL_THROUGH attribute ((fallthrough));
| | ^
| lib/wolf/wolf_symlink/wolfcrypt/src/ecc.c:2980:13: note: in expansion of macro 'FALL_THROUGH'
| 2980 | FALL_THROUGH;

Signed-off-by: Maxim Uvarov maxim.uvarov@linaro.org

Fix compilation under OE (aarch64 gcc 11.2). The original error:
|/usr/include/optee/export-user_ta/include/compiler.h:259:21: error: expected ')' before '__attribute__'
|   259 | #define fallthrough __attribute__((__fallthrough__))
|       |                     ^~~~~~~~~~~~~
| ./lib/wolf/wolf_symlink/wolfssl/wolfcrypt/types.h:184:50: note: in expansion of macro 'fallthrough'
|   184 |             #define FALL_THROUGH __attribute__ ((fallthrough));
|       |                                                  ^~~~~~~~~~~
| lib/wolf/wolf_symlink/wolfcrypt/src/ecc.c:2980:13: note: in expansion of macro 'FALL_THROUGH'
|  2980 |             FALL_THROUGH;
|       |             ^~~~~~~~~~~~
| In file included from ./lib/wolf/wolf_symlink/wolfssl/wolfcrypt/ecc.h:26,
|                  from lib/wolf/wolf_symlink/wolfcrypt/src/ecc.c:106:
| ./lib/wolf/wolf_symlink/wolfssl/wolfcrypt/types.h:184:62: error: expected identifier or '(' before ')' token
|   184 |             #define FALL_THROUGH __attribute__ ((fallthrough));
|       |                                                              ^
| lib/wolf/wolf_symlink/wolfcrypt/src/ecc.c:2980:13: note: in expansion of macro 'FALL_THROUGH'
|  2980 |             FALL_THROUGH;

Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
@wolfSSL-Bot
Copy link

Can one of the wolfSSL admins verify this patch?

@embhorn
Copy link
Member

embhorn commented Nov 14, 2021

Hello @muvarov

Thanks for submitting this fix! We do not typically accept one-line changes from contributors. Would you consider opening a GH issue?
https://github.com/wolfSSL/wolfssl/issues/new/choose

Kind regards,
Eric @ wolfSSL Support

@dgarske
Copy link
Contributor

dgarske commented Nov 15, 2021

Closing and treating as bug report. See #4568.

@dgarske dgarske closed this Nov 15, 2021
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.

None yet

4 participants