This fixes the build with -Werror-implicit-function-declaration. --- tests/timer/timer_test.c | 1 + utils/osmo-auc-gen.c | 1 + 2 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/tests/timer/timer_test.c b/tests/timer/timer_test.c index 61079bd..ba3127d 100644 --- a/tests/timer/timer_test.c +++ b/tests/timer/timer_test.c @@ -26,6 +26,7 @@ #include <stdlib.h> #include <signal.h> #include <getopt.h> +#include <unistd.h> #include <osmocom/core/talloc.h> #include <osmocom/core/timer.h> diff --git a/utils/osmo-auc-gen.c b/utils/osmo-auc-gen.c index 266d0d6..1a78477 100644 --- a/utils/osmo-auc-gen.c +++ b/utils/osmo-auc-gen.c @@ -26,6 +26,7 @@ #include <errno.h> #include <string.h> #include <getopt.h> +#include <time.h> #include <osmocom/crypt/auth.h> #include <osmocom/core/utils.h>
Hi Christopher,
On Thu, Aug 02, 2012 at 02:01:49AM +0200, Chí-Thanh Christopher Nguyễn wrote:
This fixes the build with -Werror-implicit-function-declaration.
thanks for your patch. I wanted to apply it, but it was seriously broken/malformatted. For some reason, the empty lines of the source files had been removed from your patch, causing it to be malformed and rejected both by patch itself, as well as by 'git am'.
I've manually added the #include to the two files now.
Please never copy+paste patches into regular mail user agents, they often break formatting (whitespace) and break lines into multiple lines, causing patches to fail.
It's best to use 'git send-email' directly to avoid this problem.
Regards, Harald
On Thu, Aug 02, 2012 at 02:01:49AM +0200, Chí-Thanh Christopher Nguyễn wrote:
This fixes the build with -Werror-implicit-function-declaration.
Hi,
from the OBS build I am seeing the following other issues. You might have the time to look into the other -Werror warnings?
[ 78s] I: Program is using implicit definitions of functions getting [ 78s] pointers or implemented by macros. These functions need to use their [ 78s] correct prototypes to allow correct argument passing on e.g. x86_64 . [ 78s] - Implicit memory/string functions need #include <string.h>. [ 78s] - Implicit *printf functions need #include <stdio.h>. [ 78s] - Implicit *printf functions need #include <stdio.h>. [ 78s] - Implicit *read* functions need #include <unistd.h>. [ 78s] - Implicit *recv* functions need #include <sys/socket.h>. [ 78s] W: libosmocore implicit-pointer-decl osmo-auc-gen.c:215 [ 78s] [ 78s] I: Program is likely to break with new gcc. Try -fno-strict-aliasing. [ 78s] W: libosmocore strict-aliasing-punning gprs_bssgp.c:109, 110, 128, 129, 152, 153, 176, 177, 198, 199, 238, 295, 303, 312, 320, 321, 333, 341, 349, 357, 358, 366, 369, 371, 376, 382, 383, 389, 401, 422, 431, 433, 443, 466, 476, 479, 508, 538, 539, 547, 555, 626, 629, 716, 717, 721, 730, 733, 738, 741, 751, 772, 773, 842, 868, 869 [ 78s] W: libosmocore strict-aliasing-punning gprs_bssgp_bss.c:53, 54, 76, 77, 101, 102, 123, 124, 199, 200, 225, 226, 249, 250, 269, 270, 289, 290, 329, 330, 343, 350 [ 78s] W: libosmocore strict-aliasing-punning gprs_bssgp_util.c:85, 86, 104, 105, 114 [ 78s] W: libosmocore strict-aliasing-punning gprs_ns.c:558, 560, 562, 610, 611, 809 [ 78s] W: libosmocore strict-aliasing-punning osmo-auc-gen.c:216, 217, 218, 219 [ 78s] E: libosmocore 64bit-portability-issue gprs_bssgp.c:470