fix incompatible pointer type compile errors
v2 cover fix incompatible pointer type compile errors
From: Kai Kang <[email protected]>
v2:
* update Upstream-Status with Inactive-Upstream for daq and uw-imap
Kai Kang (4):
xscreensaver: drop removal for CONFIGUREOPTS
uw-imap: fix incompatible pointer type errors
recipes: disable gcc option -Wincompatible-pointer-types
daq: fix incompatible pointer type error
.../recipes-connectivity/daq/daq_2.0.7.bb | 1 + ...-fix-incompatible-pointer-type-error.patch | 31 ++ .../perl/libdbd-mysql-perl_4.050.bb | 2 + ...-imap-fix-incompatible-pointer-types.patch | 355 ++++++++++++++++++ .../recipes-devtools/uw-imap/uw-imap_2007f.bb | 1 + .../recipes-extended/rrdtool/rrdtool_1.8.0.bb | 2 +- .../xscreensaver/xscreensaver_6.04.bb | 1 - 7 files changed, 391 insertions(+), 2 deletions(-) create mode 100644 meta-networking/recipes-connectivity/daq/files/daq-fix-incompatible-pointer-type-error.patch create mode 100644 meta-oe/recipes-devtools/uw-imap/uw-imap/uw-imap-fix-incompatible-pointer-types.patch
Signature · 1 line
2.34.1
PATCH v2 1/4 xscreensaver: drop removal for CONFIGUREOPTS
From: Kai Kang <[email protected]>
The options in removal for CONFIGUREOPTS have been handled in oe-core so they are not needed any more.
--- meta-oe/recipes-graphics/xscreensaver/xscreensaver_6.04.bb | 1 - 1 file changed, 1 deletion(-)
meta-oe/recipes-graphics/xscreensaver/xscreensaver_6.04.bb +0 -1
@@ -34,7 +34,6 @@ PACKAGECONFIG = "png ${@bb.utils.contains('DISTRO_FEATURES','systemd','systemd', PACKAGECONFIG[systemd] = "--with-systemd=yes,--with-systemd=no,systemd" PACKAGECONFIG[png] = "--with-png=yes,--with-png=no,libpng" -CONFIGUREOPTS:remove = "--disable-silent-rules --disable-dependency-tracking ${@append_libtool_sysroot(d)}" EXTRA_OECONF:remove = "--disable-static" do_install:append() {
Signature · 1 line
2.34.1
PATCH v2 2/4 uw-imap: fix incompatible pointer type errors
From: Kai Kang <[email protected]>
Fix compile errors when gcc option '-Wincompatible-pointer-types' set:
mx.c: In function 'mx_setdate':
mx.c:1286:15: error: passing argument 2 of 'utime' from incompatible pointer type [-Wincompatible-pointer-types]
1286 | utime (file,tp); /* set the times */
| ^~
| |
| time_t * {aka long int *}--- ...-imap-fix-incompatible-pointer-types.patch | 355 ++++++++++++++++++ .../recipes-devtools/uw-imap/uw-imap_2007f.bb | 1 + 2 files changed, 356 insertions(+) create mode 100644 meta-oe/recipes-devtools/uw-imap/uw-imap/uw-imap-fix-incompatible-pointer-types.patch
meta-oe/recipes-devtools/uw-imap/uw-imap/uw-imap-fix-incompatible-pointer-types.patch new file +355 -0
@@ -0,0 +1,355 @@ +Fix compile errors when gcc option '-Wincompatible-pointer-types' set: + +mx.c: In function 'mx_setdate': +mx.c:1286:15: error: passing argument 2 of 'utime' from incompatible pointer type [-Wincompatible-pointer-types] + 1286 | utime (file,tp); /* set the times */ + | ^~ + | | + | time_t * {aka long int *} + +Upstream-Status: Inactive-Upstream [lastrelease: 2011] + +[1]: https://en.wikipedia.org/wiki/UW_IMAP + +Signed-off-by: Kai Kang <[email protected]> + +--- + src/osdep/unix/mbx.c | 12 ++++++------ + src/osdep/unix/mh.c | 2 +- + src/osdep/unix/mmdf.c | 10 +++++----- + src/osdep/unix/mtx.c | 16 ++++++++-------- + src/osdep/unix/mx.c | 2 +- + src/osdep/unix/tenex.c | 16 ++++++++-------- + src/osdep/unix/unix.c | 10 +++++----- + 7 files changed, 34 insertions(+), 34 deletions(-) + +diff --git a/src/osdep/unix/mbx.c b/src/osdep/unix/mbx.c +index c8a45a5..0a587fe 100644 +--- a/src/osdep/unix/mbx.c ++++ b/src/osdep/unix/mbx.c +@@ -302,7 +302,7 @@ int mbx_isvalid (MAILSTREAM **stream,char *name,char *tmp,int *ld,char *lock, + if (sbuf.st_ctime > sbuf.st_atime) { + tp[0] = sbuf.st_atime; /* preserve atime and mtime */ + tp[1] = sbuf.st_mtime; +- utime (tmp,tp); /* set the times */ ++ utime (tmp, (const struct utimbuf *)tp); /* set the times */ + } + } + /* in case INBOX but not mbx format */ +@@ -776,7 +776,7 @@ void mbx_flag (MAILSTREAM *stream,char *sequence,char *flag,long flags) + stream->user_flags[LOCAL->ffuserflag]) || (oldpid != LOCAL->lastpid)) + mbx_update_header (stream); + tp[0] = time (0); /* make sure read comes after all that */ +- utime (stream->mailbox,tp); ++ utime (stream->mailbox, (const struct utimbuf *)tp); + } + if (LOCAL->ld >= 0) { /* unlock now */ + unlockfd (LOCAL->ld,LOCAL->lock); +@@ -1075,7 +1075,7 @@ long mbx_copy (MAILSTREAM *stream,char *sequence,char *mailbox,long options) + /* else preserve \Marked status */ + else tp[0] = (sbuf.st_ctime > sbuf.st_atime) ? sbuf.st_atime : time(0); + tp[1] = sbuf.st_mtime; /* preserve mtime */ +- utime (file,tp); /* set the times */ ++ utime (file, (const struct utimbuf *)tp); /* set the times */ + close (fd); /* close the file */ + MM_NOCRITICAL (stream); /* release critical */ + unlockfd (ld,lock); /* release exclusive parse/append permission */ +@@ -1213,7 +1213,7 @@ long mbx_append (MAILSTREAM *stream,char *mailbox,append_t af,void *data) + /* else preserve \Marked status */ + else tp[0] = (sbuf.st_ctime > sbuf.st_atime) ? sbuf.st_atime : time(0); + tp[1] = sbuf.st_mtime; /* preserve mtime */ +- utime (file,tp); /* set the times */ ++ utime (file, (const struct utimbuf *)tp); /* set the times */ + fclose (df); /* close the file */ + MM_NOCRITICAL (dstream); /* release critical */ + } +@@ -1446,7 +1446,7 @@ long mbx_parse (MAILSTREAM *stream) + time_t tp[2]; + tp[0] = time (0); + tp[1] = LOCAL->filetime; +- utime (stream->mailbox,tp); ++ utime (stream->mailbox, (const struct utimbuf *)tp); + } + stream->silent = silent; /* can pass up events now */ + mail_exists (stream,nmsgs); /* notify upper level of new mailbox size */ +@@ -1814,7 +1814,7 @@ unsigned long mbx_rewrite (MAILSTREAM *stream,unsigned long *reclaimed, + fstat (LOCAL->fd,&sbuf); /* get new write time */ + tp[1] = LOCAL->filetime = sbuf.st_mtime; + tp[0] = time (0); /* reset atime to now */ +- utime (stream->mailbox,tp); ++ utime (stream->mailbox, (const struct utimbuf *)tp); + unlockfd (ld,lock); /* release exclusive parse/append permission */ + /* notify upper level of new mailbox size */ + mail_exists (stream,stream->nmsgs); +diff --git a/src/osdep/unix/mh.c b/src/osdep/unix/mh.c +index 9264624..26f3539 100644 +--- a/src/osdep/unix/mh.c ++++ b/src/osdep/unix/mh.c +@@ -1279,5 +1279,5 @@ void mh_setdate (char *file,MESSAGECACHE *elt) + time_t tp[2]; + tp[0] = time (0); /* atime is now */ + tp[1] = mail_longdate (elt); /* modification time */ +- utime (file,tp); /* set the times */ ++ utime (file, (const struct utimbuf *)tp); /* set the times */ + } +diff --git a/src/osdep/unix/mmdf.c b/src/osdep/unix/mmdf.c +index e962434..c0adbee 100644 +--- a/src/osdep/unix/mmdf.c ++++ b/src/osdep/unix/mmdf.c +@@ -379,7 +379,7 @@ long mmdf_isvalid (char *name,char *tmp) + if ((sbuf.st_ctime > sbuf.st_atime) || (sbuf.st_mtime > sbuf.st_atime)) { + tp[0] = sbuf.st_atime; /* preserve atime and mtime */ + tp[1] = sbuf.st_mtime; +- utime (file,tp); /* set the times */ ++ utime (file, (const struct utimbuf *)tp); /* set the times */ + } + } + } +@@ -1131,7 +1131,7 @@ long mmdf_copy (MAILSTREAM *stream,char *sequence,char *mailbox,long options) + else tp[0] = /* else preserve \Marked status */ + ((sbuf.st_ctime > sbuf.st_atime) || (sbuf.st_mtime > sbuf.st_atime)) ? + sbuf.st_atime : tp[1]; +- utime (file,tp); /* set the times */ ++ utime (file, (const struct utimbuf *)tp); /* set the times */ + mmdf_unlock (fd,NIL,&lock); /* unlock and close mailbox */ + if (tstream) { /* update last UID if we can */ + MMDFLOCAL *local = (MMDFLOCAL *) tstream->local; +@@ -1292,7 +1292,7 @@ long mmdf_append (MAILSTREAM *stream,char *mailbox,append_t af,void *data) + ret = NIL; /* return error */ + } + else tp[0] = tp[1] - 1; /* set atime to now-1 if successful copy */ +- utime (file,tp); /* set the times */ ++ utime (file, (const struct utimbuf *)tp); /* set the times */ + fclose (sf); /* done with scratch file */ + /* force UIDVALIDITY assignment now */ + if (tstream && !tstream->uid_validity) tstream->uid_validity = time (0); +@@ -1550,7 +1550,7 @@ void mmdf_unlock (int fd,MAILSTREAM *stream,DOTLOCK *lock) + } + else now = 0; /* no time change needed */ + /* set the times, note change */ +- if (now && !utime (stream->mailbox,tp)) LOCAL->filetime = tp[1]; ++ if (now && !utime (stream->mailbox, (const struct utimbuf *)tp)) LOCAL->filetime = tp[1]; + } + flock (fd,LOCK_UN); /* release flock'ers */ + if (!stream) close (fd); /* close the file if no stream */ +@@ -2393,7 +2393,7 @@ long mmdf_rewrite (MAILSTREAM *stream,unsigned long *nexp,DOTLOCK *lock, + /* set atime to now, mtime a second earlier */ + tp[1] = (tp[0] = time (0)) - 1; + /* set the times, note change */ +- if (!utime (stream->mailbox,tp)) LOCAL->filetime = tp[1]; ++ if (!utime (stream->mailbox, (const struct utimbuf *)tp)) LOCAL->filetime = tp[1]; + close (LOCAL->fd); /* close and reopen file */ + if ((LOCAL->fd = open (stream->mailbox,O_RDWR, + (long) mail_parameters (NIL,GET_MBXPROTECTION,NIL))) +diff --git a/src/osdep/unix/mtx.c b/src/osdep/unix/mtx.c +index 8e6f76e..f64142b 100644 +--- a/src/osdep/unix/mtx.c ++++ b/src/osdep/unix/mtx.c +@@ -196,7 +196,7 @@ int mtx_isvalid (char *name,char *tmp) + if (sbuf.st_ctime > sbuf.st_atime) { + tp[0] = sbuf.st_atime; /* preserve atime and mtime */ + tp[1] = sbuf.st_mtime; +- utime (file,tp); /* set the times */ ++ utime (file, (const struct utimbuf *)tp); /* set the times */ + } + } + } +@@ -565,7 +565,7 @@ void mtx_flag (MAILSTREAM *stream,char *sequence,char *flag,long flags) + fstat (LOCAL->fd,&sbuf); /* get current write time */ + tp[1] = LOCAL->filetime = sbuf.st_mtime; + tp[0] = time (0); /* make sure read comes after all that */ +- utime (stream->mailbox,tp); ++ utime (stream->mailbox, (const struct utimbuf *)tp); + } + } + +@@ -834,7 +834,7 @@ long mtx_expunge (MAILSTREAM *stream,char *sequence,long options) + fstat (LOCAL->fd,&sbuf); /* get new write time */ + tp[1] = LOCAL->filetime = sbuf.st_mtime; + tp[0] = time (0); /* reset atime to now */ +- utime (stream->mailbox,tp); ++ utime (stream->mailbox, (const struct utimbuf *)tp); + MM_NOCRITICAL (stream); /* release critical */ + /* notify upper level of new mailbox size */ + mail_exists (stream,stream->nmsgs); +@@ -929,7 +929,7 @@ long mtx_copy (MAILSTREAM *stream,char *sequence,char *mailbox,long options) + /* else preserve \Marked status */ + else tp[0] = (sbuf.st_ctime > sbuf.st_atime) ? sbuf.st_atime : time(0); + tp[1] = sbuf.st_mtime; /* preserve mtime */ +- utime (file,tp); /* set the times */ ++ utime (file, (const struct utimbuf *)tp); /* set the times */ + close (fd); /* close the file */ + unlockfd (ld,lock); /* release exclusive parse/append permission */ + MM_NOCRITICAL (stream); /* release critical */ +@@ -946,7 +946,7 @@ long mtx_copy (MAILSTREAM *stream,char *sequence,char *mailbox,long options) + fstat (LOCAL->fd,&sbuf); /* get current write time */ + tp[1] = LOCAL->filetime = sbuf.st_mtime; + tp[0] = time (0); /* make sure atime remains greater */ +- utime (stream->mailbox,tp); ++ utime (stream->mailbox, (const struct utimbuf *)tp); + } + } + if (ret && mail_parameters (NIL,GET_COPYUID,NIL)) +@@ -1062,7 +1062,7 @@ long mtx_append (MAILSTREAM *stream,char *mailbox,append_t af,void *data) + /* else preserve \Marked status */ + else tp[0] = (sbuf.st_ctime > sbuf.st_atime) ? sbuf.st_atime : time(0); + tp[1] = sbuf.st_mtime; /* preserve mtime */ +- utime (file,tp); /* set the times */ ++ utime (file, (const struct utimbuf *)tp); /* set the times */ + fclose (df); /* close the file */ + unlockfd (ld,lock); /* release exclusive parse/append permission */ + MM_NOCRITICAL (stream); /* release critical */ +@@ -1212,7 +1212,7 @@ long mtx_parse (MAILSTREAM *stream) + time_t tp[2]; + tp[0] = time (0); + tp[1] = LOCAL->filetime; +- utime (stream->mailbox,tp); ++ utime (stream->mailbox, (const struct utimbuf *)tp); + } + stream->silent = silent; /* can pass up events now */ + mail_exists (stream,nmsgs); /* notify upper level of new mailbox size */ +@@ -1312,7 +1312,7 @@ void mtx_update_status (MAILSTREAM *stream,unsigned long msgno,long syncflag) + fstat (LOCAL->fd,&sbuf); /* get new write time */ + tp[1] = LOCAL->filetime = sbuf.st_mtime; + tp[0] = time (0); /* make sure read is later */ +- utime (stream->mailbox,tp); ++ utime (stream->mailbox, (const struct utimbuf *)tp); + } + } + } +diff --git a/src/osdep/unix/mx.c b/src/osdep/unix/mx.c +index b5c5adf..4146409 100644 +--- a/src/osdep/unix/mx.c ++++ b/src/osdep/unix/mx.c +@@ -1283,5 +1283,5 @@ void mx_setdate (char *file,MESSAGECACHE *elt) + time_t tp[2]; + tp[0] = time (0); /* atime is now */ + tp[1] = mail_longdate (elt); /* modification time */ +- utime (file,tp); /* set the times */ ++ utime (file, (const struct utimbuf *)tp); /* set the times */ + } +diff --git a/src/osdep/unix/tenex.c b/src/osdep/unix/tenex.c +index eee61fb..622da61 100644 +--- a/src/osdep/unix/tenex.c ++++ b/src/osdep/unix/tenex.c +@@ -203,7 +203,7 @@ int tenex_isvalid (char *name,char *tmp) + if (sbuf.st_ctime > sbuf.st_atime) { + tp[0] = sbuf.st_atime; /* preserve atime and mtime */ + tp[1] = sbuf.st_mtime; +- utime (file,tp); /* set the times */ ++ utime (file, (const struct utimbuf *)tp); /* set the times */ + } + } + } +@@ -654,7 +654,7 @@ void tenex_flag (MAILSTREAM *stream,char *sequence,char *flag,long flags) + fstat (LOCAL->fd,&sbuf); /* get current write time */ + tp[1] = LOCAL->filetime = sbuf.st_mtime; + tp[0] = time (0); /* make sure read comes after all that */ +- utime (stream->mailbox,tp); ++ utime (stream->mailbox, (const struct utimbuf *)tp); + } + } + +@@ -924,7 +924,7 @@ long tenex_expunge (MAILSTREAM *stream,char *sequence,long options) + fstat (LOCAL->fd,&sbuf); /* get new write time */ + tp[1] = LOCAL->filetime = sbuf.st_mtime; + tp[0] = time (0); /* reset atime to now */ +- utime (stream->mailbox,tp); ++ utime (stream->mailbox, (const struct utimbuf *)tp); + MM_NOCRITICAL (stream); /* release critical */ + /* notify upper level of new mailbox size */ + mail_exists (stream,stream->nmsgs); +@@ -1019,7 +1019,7 @@ long tenex_copy (MAILSTREAM *stream,char *sequence,char *mailbox,long options) + /* else preserve \Marked status */ + else tp[0] = (sbuf.st_ctime > sbuf.st_atime) ? sbuf.st_atime : time(0); + tp[1] = sbuf.st_mtime; /* preserve mtime */ +- utime (file,tp); /* set the times */ ++ utime (file, (const struct utimbuf *)tp); /* set the times */ + close (fd); /* close the file */ + unlockfd (ld,lock); /* release exclusive parse/append permission */ + MM_NOCRITICAL (stream); /* release critical */ +@@ -1036,7 +1036,7 @@ long tenex_copy (MAILSTREAM *stream,char *sequence,char *mailbox,long options) + fstat (LOCAL->fd,&sbuf); /* get current write time */ + tp[1] = LOCAL->filetime = sbuf.st_mtime; + tp[0] = time (0); /* make sure atime remains greater */ +- utime (stream->mailbox,tp); ++ utime (stream->mailbox, (const struct utimbuf *)tp); + } + } + if (ret && mail_parameters (NIL,GET_COPYUID,NIL)) +@@ -1159,7 +1159,7 @@ long tenex_append (MAILSTREAM *stream,char *mailbox,append_t af,void *data) + /* else preserve \Marked status */ + else tp[0] = (sbuf.st_ctime > sbuf.st_atime) ? sbuf.st_atime : time(0); + tp[1] = sbuf.st_mtime; /* preserve mtime */ +- utime (file,tp); /* set the times */ ++ utime (file, (const struct utimbuf *)tp); /* set the times */ + fclose (df); /* close the file */ + unlockfd (ld,lock); /* release exclusive parse/append permission */ + MM_NOCRITICAL (stream); /* release critical */ +@@ -1324,7 +1324,7 @@ long tenex_parse (MAILSTREAM *stream) + time_t tp[2]; + tp[0] = time (0); + tp[1] = LOCAL->filetime; +- utime (stream->mailbox,tp); ++ utime (stream->mailbox, (const struct utimbuf *)tp); + } + stream->silent = silent; /* can pass up events now */ + mail_exists (stream,nmsgs); /* notify upper level of new mailbox size */ +@@ -1424,7 +1424,7 @@ void tenex_update_status (MAILSTREAM *stream,unsigned long msgno,long syncflag) + fstat (LOCAL->fd,&sbuf); /* get new write time */ + tp[1] = LOCAL->filetime = sbuf.st_mtime; + tp[0] = time (0); /* make sure read is later */ +- utime (stream->mailbox,tp); ++ utime (stream->mailbox, (const struct utimbuf *)tp); + } + } + } +diff --git a/src/osdep/unix/unix.c b/src/osdep/unix/unix.c +index 86be3f9..012dc83 100644 +--- a/src/osdep/unix/unix.c ++++ b/src/osdep/unix/unix.c +@@ -232,7 +232,7 @@ DRIVER *unix_valid (char *name) + if ((sbuf.st_ctime > sbuf.st_atime) || (sbuf.st_mtime > sbuf.st_atime)) { + tp[0] = sbuf.st_atime; /* yes, preserve atime and mtime */ + tp[1] = sbuf.st_mtime; +- utime (file,tp); /* set the times */ ++ utime (file, (const struct utimbuf *)tp); /* set the times */ + } + } + } +@@ -999,7 +999,7 @@ long unix_copy (MAILSTREAM *stream,char *sequence,char *mailbox,long options) + else tp[0] = /* else preserve \Marked status */ + ((sbuf.st_ctime > sbuf.st_atime) || (sbuf.st_mtime > sbuf.st_atime)) ? + sbuf.st_atime : tp[1]; +- utime (file,tp); /* set the times */ ++ utime (file, (const struct utimbuf *)tp); /* set the times */ + unix_unlock (fd,NIL,&lock); /* unlock and close mailbox */ + if (tstream) { /* update last UID if we can */ + UNIXLOCAL *local = (UNIXLOCAL *) tstream->local; +@@ -1160,7 +1160,7 @@ long unix_append (MAILSTREAM *stream,char *mailbox,append_t af,void *data) + ret = NIL; /* return error */ + } + else tp[0] = tp[1] - 1; /* set atime to now-1 if successful copy */ +- utime (file,tp); /* set the times */ ++ utime (file, (const struct utimbuf *)tp); /* set the times */ + fclose (sf); /* done with scratch file */ + /* force UIDVALIDITY assignment now */ + if (tstream && !tstream->uid_validity) tstream->uid_validity = time (0); +@@ -1425,7 +1425,7 @@ void unix_unlock (int fd,MAILSTREAM *stream,DOTLOCK *lock) + } + else now = 0; /* no time change needed */ + /* set the times, note change */ +- if (now && !utime (stream->mailbox,tp)) LOCAL->filetime = tp[1]; ++ if (now && !utime (stream->mailbox, (const struct utimbuf *)tp)) LOCAL->filetime = tp[1]; + } + flock (fd,LOCK_UN); /* release flock'ers */ + if (!stream) close (fd); /* close the file if no stream */ +@@ -2251,7 +2251,7 @@ long unix_rewrite (MAILSTREAM *stream,unsigned long *nexp,DOTLOCK *lock, + /* set atime to now, mtime a second earlier */ + tp[1] = (tp[0] = time (0)) - 1; + /* set the times, note change */ +- if (!utime (stream->mailbox,tp)) LOCAL->filetime = tp[1]; ++ if (!utime (stream->mailbox, (const struct utimbuf *)tp)) LOCAL->filetime = tp[1]; + close (LOCAL->fd); /* close and reopen file */ + if ((LOCAL->fd = open (stream->mailbox,O_RDWR, + (long) mail_parameters (NIL,GET_MBXPROTECTION,NIL)))
meta-oe/recipes-devtools/uw-imap/uw-imap_2007f.bb +1 -0
@@ -16,6 +16,7 @@ SRC_URI = "https://fossies.org/linux/misc/old/imap-${PV}.tar.gz \ file://0002-tmail-Include-ctype.h-for-isdigit.patch \ file://0001-Fix-Wincompatible-function-pointer-types.patch \ file://uw-imap-newer-tls.patch \ + file://uw-imap-fix-incompatible-pointer-types.patch \ " SRC_URI[md5sum] = "2126fd125ea26b73b20f01fcd5940369"
Signature · 1 line
2.34.1
PATCH v2 3/4 recipes: disable gcc option -Wincompatible-pointer-types
In reply to [email protected]From: Kai Kang <[email protected]>
It fails to run do_compile tasks for libdbd-mysql-perl and rrdtool with gcc option -Wincompatible-pointer-types enabled by default. Disable it as workaround.
--- meta-oe/recipes-devtools/perl/libdbd-mysql-perl_4.050.bb | 2 ++ meta-oe/recipes-extended/rrdtool/rrdtool_1.8.0.bb | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-)
meta-oe/recipes-devtools/perl/libdbd-mysql-perl_4.050.bb +2 -0
@@ -20,3 +20,5 @@ SRC_URI = "git://github.com/perl5-dbi/DBD-mysql.git;protocol=https;branch=master S = "${WORKDIR}/git" inherit cpan + +EXTRA_OEMAKE = ' CC="${CC} -Wno-incompatible-pointer-types"'
meta-oe/recipes-extended/rrdtool/rrdtool_1.8.0.bb +1 -1
@@ -59,7 +59,7 @@ export STAGING_LIBDIR export STAGING_INCDIR # emulate cpan_do_configure -EXTRA_OEMAKE = ' PERL5LIB="${PERL_ARCHLIB}" ' +EXTRA_OEMAKE = ' CC="${CC} -Wno-incompatible-pointer-types" PERL5LIB="${PERL_ARCHLIB}" ' # Avoid do_configure error on some hosts do_configure() {
Signature · 1 line
2.34.1
PATCH v2 4/4 daq: fix incompatible pointer type error
In reply to [email protected]From: Kai Kang <[email protected]>
Fix incompatible pointer type error for daq:
| ../../daq-2.0.7/os-daq-modules/daq_nfq.c: In function 'SetPktHdr':
| ../../daq-2.0.7/os-daq-modules/daq_nfq.c:394:37: error: passing argument 2
of 'nfq_get_payload' from incompatible pointer type [-Wincompatible-pointer-types]
| 394 | int len = nfq_get_payload(nfad, (char**)pkt); | | ^~~~~~~~~~~ | | | | | char **
--- .../recipes-connectivity/daq/daq_2.0.7.bb | 1 + ...-fix-incompatible-pointer-type-error.patch | 31 +++++++++++++++++++ 2 files changed, 32 insertions(+) create mode 100644 meta-networking/recipes-connectivity/daq/files/daq-fix-incompatible-pointer-type-error.patch
meta-networking/recipes-connectivity/daq/daq_2.0.7.bb +1 -0
@@ -11,6 +11,7 @@ DEPENDS = "libpcap libpcre libdnet bison-native libnetfilter-queue" SRC_URI = "http://fossies.org/linux/misc/daq-${PV}.tar.gz \ file://disable-run-test-program-while-cross-compiling.patch \ file://0001-correct-the-location-of-unistd.h.patch \ + file://daq-fix-incompatible-pointer-type-error.patch \ " SRC_URI[sha256sum] = "bdc4e5a24d1ea492c39ee213a63c55466a2e8114b6a9abed609927ae13a7705e" # these 2 create undeclared dependency on libdnet and libnetfilter-queue from meta-networking
meta-networking/recipes-connectivity/daq/files/daq-fix-incompatible-pointer-type-error.patch new file +31 -0
@@ -0,0 +1,31 @@ +Fix daq incompatible pointer type error when gcc option +'-Wincompatible-pointer-types is set: + +| ../../daq-2.0.7/os-daq-modules/daq_nfq.c: In function 'SetPktHdr': +| ../../daq-2.0.7/os-daq-modules/daq_nfq.c:394:37: error: passing argument 2 + of 'nfq_get_payload' from incompatible pointer type [-Wincompatible-pointer-types] +| 394 | int len = nfq_get_payload(nfad, (char**)pkt); +| | ^~~~~~~~~~~ +| | | +| | char ** + +Upstream-Status: Inactive-Upstream [lastrelease: 2019-03-09] + +Signed-off-by: Kai Kang <[email protected]> +--- + os-daq-modules/daq_nfq.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/os-daq-modules/daq_nfq.c b/os-daq-modules/daq_nfq.c +index 4de94b6..a6de2f3 100644 +--- a/os-daq-modules/daq_nfq.c ++++ b/os-daq-modules/daq_nfq.c +@@ -391,7 +391,7 @@ static inline int SetPktHdr ( + DAQ_PktHdr_t* hdr, + uint8_t** pkt + ) { +- int len = nfq_get_payload(nfad, (char**)pkt); ++ int len = nfq_get_payload(nfad, (unsigned char**)pkt); + + if ( len <= 0 ) + return -1;
Signature · 1 line
2.34.1