diff options
author | Khem Raj <raj.khem@gmail.com> | 2022-08-31 19:04:44 -0700 |
---|---|---|
committer | Khem Raj <raj.khem@gmail.com> | 2022-09-05 22:49:34 -0700 |
commit | a3fe8e3e0378a3b85d014c092c4c6bb483ac076e (patch) | |
tree | 85c9114f3e4deeca3951ec41da119c3bdb7a39d3 | |
parent | dcf06b291d3fb0174c9a49bcb97ac7788f80a1c2 (diff) | |
download | meta-openembedded-a3fe8e3e0378a3b85d014c092c4c6bb483ac076e.tar.gz |
ckermit: Fix build with clang
Signed-off-by: Khem Raj <raj.khem@gmail.com>
-rw-r--r-- | meta-oe/recipes-support/ckermit/ckermit/0001-Fix-function-prototype-errors.patch | 106 | ||||
-rw-r--r-- | meta-oe/recipes-support/ckermit/ckermit_302.bb | 4 |
2 files changed, 109 insertions, 1 deletions
diff --git a/meta-oe/recipes-support/ckermit/ckermit/0001-Fix-function-prototype-errors.patch b/meta-oe/recipes-support/ckermit/ckermit/0001-Fix-function-prototype-errors.patch new file mode 100644 index 000000000..306a2ee52 --- /dev/null +++ b/meta-oe/recipes-support/ckermit/ckermit/0001-Fix-function-prototype-errors.patch | |||
@@ -0,0 +1,106 @@ | |||
1 | From f73eade85b7a1b93f7b9ef6ca9ead9d2441f8f84 Mon Sep 17 00:00:00 2001 | ||
2 | From: Khem Raj <raj.khem@gmail.com> | ||
3 | Date: Wed, 31 Aug 2022 19:01:38 -0700 | ||
4 | Subject: [PATCH] Fix function prototype errors | ||
5 | |||
6 | Clang 15 is strict, therefore ensure that right headers are pulled in | ||
7 | and also right function prototypes are used. | ||
8 | |||
9 | Upstream-Status: Pending | ||
10 | |||
11 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
12 | --- | ||
13 | ckcmai.c | 4 ++++ | ||
14 | ckucmd.c | 2 +- | ||
15 | ckucmd.h | 2 -- | ||
16 | ckucon.c | 2 +- | ||
17 | ckufio.c | 2 +- | ||
18 | ckuusx.c | 2 +- | ||
19 | 6 files changed, 8 insertions(+), 6 deletions(-) | ||
20 | |||
21 | diff --git a/ckcmai.c b/ckcmai.c | ||
22 | index a5640e5..a4e322d 100644 | ||
23 | --- a/ckcmai.c | ||
24 | +++ b/ckcmai.c | ||
25 | @@ -561,6 +561,10 @@ ACKNOWLEDGMENTS: | ||
26 | #include "ckntap.h" | ||
27 | #endif /* NT */ | ||
28 | |||
29 | +#ifndef VMS | ||
30 | +#include <time.h> /* time() */ | ||
31 | +#endif | ||
32 | + | ||
33 | #ifndef NOSERVER | ||
34 | /* Text message definitions.. each should be 256 chars long, or less. */ | ||
35 | #ifdef MINIX | ||
36 | diff --git a/ckucmd.c b/ckucmd.c | ||
37 | index 274dc2d..730f20d 100644 | ||
38 | --- a/ckucmd.c | ||
39 | +++ b/ckucmd.c | ||
40 | @@ -7356,7 +7356,7 @@ cmdgetc(timelimit) int timelimit; { /* Get a character from the tty. */ | ||
41 | Returns 0 or greater always. | ||
42 | */ | ||
43 | int | ||
44 | -cmdconchk() { | ||
45 | +cmdconchk(void) { | ||
46 | int x = 0, y; | ||
47 | y = pushc ? 1 : 0; /* Have command character pushed? */ | ||
48 | #ifdef OS2 | ||
49 | diff --git a/ckucmd.h b/ckucmd.h | ||
50 | index 7cd4ced..5c43cc4 100644 | ||
51 | --- a/ckucmd.h | ||
52 | +++ b/ckucmd.h | ||
53 | @@ -280,9 +280,7 @@ _PROTOTYP( int cmdsquo, (int) ); | ||
54 | _PROTOTYP( int cmdgquo, (void) ); | ||
55 | _PROTOTYP( char * ckcvtdate, (char *, int) ); | ||
56 | _PROTOTYP( int cmdgetc, (int)); | ||
57 | -#ifndef NOARROWKEYS | ||
58 | _PROTOTYP( int cmdconchk, (void) ); | ||
59 | -#endif /* NOARROWKEYS */ | ||
60 | |||
61 | #ifdef CK_RECALL | ||
62 | _PROTOTYP( char * cmgetcmd, (char *) ); | ||
63 | diff --git a/ckucon.c b/ckucon.c | ||
64 | index 50ceb7e..954719e 100644 | ||
65 | --- a/ckucon.c | ||
66 | +++ b/ckucon.c | ||
67 | @@ -39,8 +39,8 @@ _PROTOTYP( static VOID concld, (void) ); | ||
68 | |||
69 | #ifdef NEXT | ||
70 | #undef NSIG | ||
71 | -#include <sys/wait.h> /* For wait() */ | ||
72 | #endif /* NEXT */ | ||
73 | +#include <sys/wait.h> /* For wait() */ | ||
74 | |||
75 | #include <signal.h> /* Signals */ | ||
76 | |||
77 | diff --git a/ckufio.c b/ckufio.c | ||
78 | index b5bfaae..2a8d4e5 100644 | ||
79 | --- a/ckufio.c | ||
80 | +++ b/ckufio.c | ||
81 | @@ -142,8 +142,8 @@ _PROTOTYP( int parser, ( int ) ); | ||
82 | |||
83 | #ifdef UNIX /* Pointer arg to wait() allowed */ | ||
84 | #define CK_CHILD /* Assume this is safe in all UNIX */ | ||
85 | +#include <sys/wait.h> /* wait() API */ | ||
86 | #endif /* UNIX */ | ||
87 | - | ||
88 | extern int binary, recursive, stathack; | ||
89 | #ifdef CK_CTRLZ | ||
90 | extern int eofmethod; | ||
91 | diff --git a/ckuusx.c b/ckuusx.c | ||
92 | index d332bed..253f992 100644 | ||
93 | --- a/ckuusx.c | ||
94 | +++ b/ckuusx.c | ||
95 | @@ -9144,7 +9144,7 @@ char *s; /* a string */ | ||
96 | #ifndef CK_CURPOS | ||
97 | /* Dummies for when cursor control is not supported */ | ||
98 | int | ||
99 | -ck_curpos(row, col) { | ||
100 | +ck_curpos(int row, int col) { | ||
101 | return(-1); | ||
102 | } | ||
103 | |||
104 | -- | ||
105 | 2.37.3 | ||
106 | |||
diff --git a/meta-oe/recipes-support/ckermit/ckermit_302.bb b/meta-oe/recipes-support/ckermit/ckermit_302.bb index abeeeccd1..53f2b9d2c 100644 --- a/meta-oe/recipes-support/ckermit/ckermit_302.bb +++ b/meta-oe/recipes-support/ckermit/ckermit_302.bb | |||
@@ -8,7 +8,9 @@ SECTION = "console/network" | |||
8 | LICENSE = "BSD-3-Clause" | 8 | LICENSE = "BSD-3-Clause" |
9 | LIC_FILES_CHKSUM = "file://COPYING.TXT;md5=932ca542d6c6cb8a59a0bcd76ab67cc3" | 9 | LIC_FILES_CHKSUM = "file://COPYING.TXT;md5=932ca542d6c6cb8a59a0bcd76ab67cc3" |
10 | 10 | ||
11 | SRC_URI = "http://www.kermitproject.org/ftp/kermit/archives/cku${PV}.tar.gz;subdir=${BPN}-${PV}" | 11 | SRC_URI = "http://www.kermitproject.org/ftp/kermit/archives/cku${PV}.tar.gz;subdir=${BPN}-${PV} \ |
12 | file://0001-Fix-function-prototype-errors.patch \ | ||
13 | " | ||
12 | SRC_URI[md5sum] = "eac4dbf18b45775e4cdee5a7c74762b0" | 14 | SRC_URI[md5sum] = "eac4dbf18b45775e4cdee5a7c74762b0" |
13 | SRC_URI[sha256sum] = "0d5f2cd12bdab9401b4c836854ebbf241675051875557783c332a6a40dac0711" | 15 | SRC_URI[sha256sum] = "0d5f2cd12bdab9401b4c836854ebbf241675051875557783c332a6a40dac0711" |
14 | 16 | ||