-
Notifications
You must be signed in to change notification settings - Fork 2.1k
make: clang is more pedantic than gcc #4560
Copy link
Copy link
Closed
Labels
Area: build systemArea: Build systemArea: Build systemPlatform: nativePlatform: This PR/issue effects the native platformPlatform: This PR/issue effects the native platformType: bugThe issue reports a bug / The PR fixes a bug (including spelling errors)The issue reports a bug / The PR fixes a bug (including spelling errors)
Description
Activity
Metadata
Metadata
Assignees
Labels
Area: build systemArea: Build systemArea: Build systemPlatform: nativePlatform: This PR/issue effects the native platformPlatform: This PR/issue effects the native platformType: bugThe issue reports a bug / The PR fixes a bug (including spelling errors)The issue reports a bug / The PR fixes a bug (including spelling errors)
Using
-pedanticflag with clang compiler, it considers language extensions as errors. Buildingtests/fault_handlerfor native fails withRIOT/tests/fault_handler/main.c:48:22: error: extension used [-Werror,-Wlanguage-extension-token] puts(PRINT_MACRO(INVALID_INSTRUCTION)); ^ RIOT/tests/fault_handler/main.c:30:29: note: expanded from macro 'INVALID_INSTRUCTION' #define INVALID_INSTRUCTION asm (".short 0xdead, 0xbeef, 0xcafe, 0xbabe\n") ^ RIOT/tests/fault_handler/main.c:49:5: error: extension used [-Werror,-Wlanguage-extension-token] INVALID_INSTRUCTION; ^ RIOT/tests/fault_handler/main.c:30:29: note: expanded from macro 'INVALID_INSTRUCTION' #define INVALID_INSTRUCTION asm (".short 0xdead, 0xbeef, 0xcafe, 0xbabe\n")