-
Notifications
You must be signed in to change notification settings - Fork 33
Open
Description
Hey,
I got various compilation errors on a recent Debian distribution.
GCC Version:
gcc (Debian 10.2.1-6) 10.2.1 20210110
Copyright (C) 2020 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Compilation errors:
In file included from ./src/jtag/jtag.h:15,
from src/openocd.c:20:
./src/flash/nor/core.h: In function ‘report_flash_progress’:
./src/flash/nor/core.h:283:11: error: format ‘%llx’ expects argument of type ‘long long unsigned int’, but argument 7 has type ‘uint64_t’ {aka ‘long unsigned int’} [-Werror=format=]
283 | LOG_INFO("%s:0x%llx|0x%llx|%s", op, region_start, region_end, block_name);
| ^~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~
| |
| uint64_t {aka long unsigned int}
./src/helper/log.h:118:60: note: in definition of macro ‘LOG_INFO’
118 | log_printf_lf(LOG_LVL_INFO, __FILE__, __LINE__, __func__, expr)
| ^~~~
In file included from src/openocd.c:24:
./src/flash/nor/core.h:283:20: note: format string is defined here
283 | LOG_INFO("%s:0x%llx|0x%llx|%s", op, region_start, region_end, block_name);
| ~~~^
| |
| long long unsigned int
| %lx
In file included from ./src/jtag/jtag.h:15,
from src/openocd.c:20:
./src/flash/nor/core.h:283:11: error: format ‘%llx’ expects argument of type ‘long long unsigned int’, but argument 8 has type ‘uint64_t’ {aka ‘long unsigned int’} [-Werror=format=]
283 | LOG_INFO("%s:0x%llx|0x%llx|%s", op, region_start, region_end, block_name);
| ^~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~
| |
| uint64_t {aka long unsigned int}
./src/helper/log.h:118:60: note: in definition of macro ‘LOG_INFO’
118 | log_printf_lf(LOG_LVL_INFO, __FILE__, __LINE__, __func__, expr)
| ^~~~
In file included from src/openocd.c:24:
./src/flash/nor/core.h:283:27: note: format string is defined here
283 | LOG_INFO("%s:0x%llx|0x%llx|%s", op, region_start, region_end, block_name);
| ~~~^
| |
| long long unsigned int
| %lx
In file included from ./src/jtag/jtag.h:15,
from src/openocd.c:20:
src/openocd.c: In function ‘setup_command_handler’:
src/openocd.c:272:24: error: expected ‘)’ before ‘LIBUSB1_COMMIT’
272 | LOG_OUTPUT("libusb1 " LIBUSB1_COMMIT "\n");
| ^~~~~~~~~~~~~~
./src/helper/log.h:133:59: note: in definition of macro ‘LOG_OUTPUT’
133 | log_printf(LOG_LVL_OUTPUT, __FILE__, __LINE__, __func__, expr)
| ^~~~
In file included from src/openocd.c:24:
At top level:
./src/flash/nor/core.h:281:13: error: ‘report_flash_progress’ defined but not used [-Werror=unused-function]
281 | static void report_flash_progress(const char *op, uint64_t region_start, uint64_t region_end, const char *block_name)
| ^~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
Any ideas?
Metadata
Metadata
Assignees
Labels
No labels