* [Buildroot] [PATCH 1/1] package/avro-c: fix build with gcc 14
@ 2024-06-15 20:28 Fabrice Fontaine
2024-06-16 8:58 ` Yann E. MORIN
2024-07-05 19:23 ` Peter Korsgaard
0 siblings, 2 replies; 3+ messages in thread
From: Fabrice Fontaine @ 2024-06-15 20:28 UTC (permalink / raw)
To: buildroot; +Cc: Titouan Christophe, Fabrice Fontaine
Fix the following build failure with gcc 14:
In file included from /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/src/avro/legacy.h:33,
from /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/src/avro/io.h:31,
from /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/src/avro/consumer.h:30,
from /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/src/avro.h:28,
from /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/examples/quickstop.c:18:
/home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/examples/quickstop.c: In function 'print_person':
/home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/examples/quickstop.c:123:61: error: passing argument 3 of 'first_value.iface->get_string' from incompatible pointer type [-Wincompatible-pointer-types]
123 | avro_value_get_string(&first_value, &p, &size);
| ^~
| |
| int32_t ** {aka int **}
Fixes:
- http://autobuild.buildroot.org/results/fdbc6a888ba8bb51f4e076a450919477d1378eb3
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
...-Fix-typos-in-docs-and-examples-2795.patch | 59 +++++++++++++++++++
1 file changed, 59 insertions(+)
create mode 100644 package/avro-c/0001-AVRO-3957-Fix-typos-in-docs-and-examples-2795.patch
diff --git a/package/avro-c/0001-AVRO-3957-Fix-typos-in-docs-and-examples-2795.patch b/package/avro-c/0001-AVRO-3957-Fix-typos-in-docs-and-examples-2795.patch
new file mode 100644
index 0000000000..72faaa0abe
--- /dev/null
+++ b/package/avro-c/0001-AVRO-3957-Fix-typos-in-docs-and-examples-2795.patch
@@ -0,0 +1,59 @@
+From 52f051dbeefad0b7e73187becad6c33747b047d3 Mon Sep 17 00:00:00 2001
+From: Sahil Kang <sahil.kang@asilaycomputing.com>
+Date: Mon, 11 Mar 2024 03:01:21 -0700
+Subject: [PATCH] AVRO-3957: [C] Fix typos in docs and examples (#2795)
+
+* AVRO-3957: [C] Fix misformatted type in docs
+
+Signed-off-by: Sahil Kang <sahil.kang@asilaycomputing.com>
+Signed-off-by: Sahil Kang <sahilkang@google.com>
+
+* AVRO-3957: [C] Fix type in quickstop example
+
+This removes the following warning:
+
+ avro/lang/c/examples/quickstop.c:123:40: warning: incompatible pointer types passing 'int32_t **' (aka 'int **') to parameter of type
+ 'const char **' [-Wincompatible-pointer-types]
+ avro_value_get_string(&first_value, &p, &size);
+
+Signed-off-by: Sahil Kang <sahil.kang@asilaycomputing.com>
+Signed-off-by: Sahil Kang <sahilkang@google.com>
+
+---------
+
+Signed-off-by: Sahil Kang <sahil.kang@asilaycomputing.com>
+Signed-off-by: Sahil Kang <sahilkang@google.com>
+
+Upstream: https://github.com/apache/avro/commit/52f051dbeefad0b7e73187becad6c33747b047d3
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+---
+ lang/c/docs/index.txt | 2 +-
+ lang/c/examples/quickstop.c | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/docs/index.txt b/docs/index.txt
+index a439a052631..df16f9d9678 100644
+--- a/docs/index.txt
++++ b/docs/index.txt
+@@ -178,7 +178,7 @@ different versions of the Avro library. That means that it's really
+ only safe to use these hash values internally within the context of a
+ single execution of a single application.
+
+-The +reset+ method “clears out” an +avro_value_t instance, making sure
++The +reset+ method “clears out” an +avro_value_t+ instance, making sure
+ that it's ready to accept the contents of a new value. For scalars,
+ this is usually a no-op, since the new value will just overwrite the old
+ one. For arrays and maps, this removes any existing elements from the
+diff --git a/examples/quickstop.c b/examples/quickstop.c
+index ff9e9700590..b26dad10c04 100644
+--- a/examples/quickstop.c
++++ b/examples/quickstop.c
+@@ -107,7 +107,7 @@ int print_person(avro_file_reader_t db, avro_schema_t reader_schema)
+ if (rval == 0) {
+ int64_t id;
+ int32_t age;
+- int32_t *p;
++ const char *p;
+ size_t size;
+ avro_value_t id_value;
+ avro_value_t first_value;
--
2.43.0
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [Buildroot] [PATCH 1/1] package/avro-c: fix build with gcc 14
2024-06-15 20:28 [Buildroot] [PATCH 1/1] package/avro-c: fix build with gcc 14 Fabrice Fontaine
@ 2024-06-16 8:58 ` Yann E. MORIN
2024-07-05 19:23 ` Peter Korsgaard
1 sibling, 0 replies; 3+ messages in thread
From: Yann E. MORIN @ 2024-06-16 8:58 UTC (permalink / raw)
To: Fabrice Fontaine; +Cc: Titouan Christophe, buildroot
Fabrice, All,
On 2024-06-15 22:28 +0200, Fabrice Fontaine spake thusly:
> Fix the following build failure with gcc 14:
>
> In file included from /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/src/avro/legacy.h:33,
> from /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/src/avro/io.h:31,
> from /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/src/avro/consumer.h:30,
> from /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/src/avro.h:28,
> from /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/examples/quickstop.c:18:
> /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/examples/quickstop.c: In function 'print_person':
> /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/examples/quickstop.c:123:61: error: passing argument 3 of 'first_value.iface->get_string' from incompatible pointer type [-Wincompatible-pointer-types]
> 123 | avro_value_get_string(&first_value, &p, &size);
> | ^~
> | |
> | int32_t ** {aka int **}
>
> Fixes:
> - http://autobuild.buildroot.org/results/fdbc6a888ba8bb51f4e076a450919477d1378eb3
>
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Applied to master, thanks.
Regards,
Yann E. MORIN.
> ---
> ...-Fix-typos-in-docs-and-examples-2795.patch | 59 +++++++++++++++++++
> 1 file changed, 59 insertions(+)
> create mode 100644 package/avro-c/0001-AVRO-3957-Fix-typos-in-docs-and-examples-2795.patch
>
> diff --git a/package/avro-c/0001-AVRO-3957-Fix-typos-in-docs-and-examples-2795.patch b/package/avro-c/0001-AVRO-3957-Fix-typos-in-docs-and-examples-2795.patch
> new file mode 100644
> index 0000000000..72faaa0abe
> --- /dev/null
> +++ b/package/avro-c/0001-AVRO-3957-Fix-typos-in-docs-and-examples-2795.patch
> @@ -0,0 +1,59 @@
> +From 52f051dbeefad0b7e73187becad6c33747b047d3 Mon Sep 17 00:00:00 2001
> +From: Sahil Kang <sahil.kang@asilaycomputing.com>
> +Date: Mon, 11 Mar 2024 03:01:21 -0700
> +Subject: [PATCH] AVRO-3957: [C] Fix typos in docs and examples (#2795)
> +
> +* AVRO-3957: [C] Fix misformatted type in docs
> +
> +Signed-off-by: Sahil Kang <sahil.kang@asilaycomputing.com>
> +Signed-off-by: Sahil Kang <sahilkang@google.com>
> +
> +* AVRO-3957: [C] Fix type in quickstop example
> +
> +This removes the following warning:
> +
> + avro/lang/c/examples/quickstop.c:123:40: warning: incompatible pointer types passing 'int32_t **' (aka 'int **') to parameter of type
> + 'const char **' [-Wincompatible-pointer-types]
> + avro_value_get_string(&first_value, &p, &size);
> +
> +Signed-off-by: Sahil Kang <sahil.kang@asilaycomputing.com>
> +Signed-off-by: Sahil Kang <sahilkang@google.com>
> +
> +---------
> +
> +Signed-off-by: Sahil Kang <sahil.kang@asilaycomputing.com>
> +Signed-off-by: Sahil Kang <sahilkang@google.com>
> +
> +Upstream: https://github.com/apache/avro/commit/52f051dbeefad0b7e73187becad6c33747b047d3
> +Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> +---
> + lang/c/docs/index.txt | 2 +-
> + lang/c/examples/quickstop.c | 2 +-
> + 2 files changed, 2 insertions(+), 2 deletions(-)
> +
> +diff --git a/docs/index.txt b/docs/index.txt
> +index a439a052631..df16f9d9678 100644
> +--- a/docs/index.txt
> ++++ b/docs/index.txt
> +@@ -178,7 +178,7 @@ different versions of the Avro library. That means that it's really
> + only safe to use these hash values internally within the context of a
> + single execution of a single application.
> +
> +-The +reset+ method “clears out” an +avro_value_t instance, making sure
> ++The +reset+ method “clears out” an +avro_value_t+ instance, making sure
> + that it's ready to accept the contents of a new value. For scalars,
> + this is usually a no-op, since the new value will just overwrite the old
> + one. For arrays and maps, this removes any existing elements from the
> +diff --git a/examples/quickstop.c b/examples/quickstop.c
> +index ff9e9700590..b26dad10c04 100644
> +--- a/examples/quickstop.c
> ++++ b/examples/quickstop.c
> +@@ -107,7 +107,7 @@ int print_person(avro_file_reader_t db, avro_schema_t reader_schema)
> + if (rval == 0) {
> + int64_t id;
> + int32_t age;
> +- int32_t *p;
> ++ const char *p;
> + size_t size;
> + avro_value_t id_value;
> + avro_value_t first_value;
> --
> 2.43.0
>
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 561 099 427 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Buildroot] [PATCH 1/1] package/avro-c: fix build with gcc 14
2024-06-15 20:28 [Buildroot] [PATCH 1/1] package/avro-c: fix build with gcc 14 Fabrice Fontaine
2024-06-16 8:58 ` Yann E. MORIN
@ 2024-07-05 19:23 ` Peter Korsgaard
1 sibling, 0 replies; 3+ messages in thread
From: Peter Korsgaard @ 2024-07-05 19:23 UTC (permalink / raw)
To: Fabrice Fontaine; +Cc: Titouan Christophe, buildroot
>>>>> "Fabrice" == Fabrice Fontaine <fontaine.fabrice@gmail.com> writes:
> Fix the following build failure with gcc 14:
> In file included from /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/src/avro/legacy.h:33,
> from /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/src/avro/io.h:31,
> from /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/src/avro/consumer.h:30,
> from /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/src/avro.h:28,
> from /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/examples/quickstop.c:18:
> /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/examples/quickstop.c: In function 'print_person':
> /home/autobuild/autobuild/instance-6/output-1/build/avro-c-1.11.3/examples/quickstop.c:123:61: error: passing argument 3 of 'first_value.iface->get_string' from incompatible pointer type [-Wincompatible-pointer-types]
> 123 | avro_value_get_string(&first_value, &p, &size);
> | ^~
> | |
> | int32_t ** {aka int **}
> Fixes:
> - http://autobuild.buildroot.org/results/fdbc6a888ba8bb51f4e076a450919477d1378eb3
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Committed to 2024.05.x, thanks.
--
Bye, Peter Korsgaard
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-07-05 19:23 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-06-15 20:28 [Buildroot] [PATCH 1/1] package/avro-c: fix build with gcc 14 Fabrice Fontaine
2024-06-16 8:58 ` Yann E. MORIN
2024-07-05 19:23 ` Peter Korsgaard
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox