* [meta-virtualization][PATCH] tini: fix function declaration without a prototype
@ 2022-09-30 11:46 Jose Quaresma
2022-10-04 21:08 ` Bruce Ashfield
0 siblings, 1 reply; 2+ messages in thread
From: Jose Quaresma @ 2022-09-30 11:46 UTC (permalink / raw)
To: meta-virtualization; +Cc: Jose Quaresma
This also fix building with clang 1.15
Signed-off-by: Jose Quaresma <jose.quaresma@foundries.io>
---
...n-declaration-without-a-prototype-is.patch | 74 +++++++++++++++++++
recipes-containers/tini/tini_0.19.0.bb | 1 +
2 files changed, 75 insertions(+)
create mode 100644 recipes-containers/tini/tini/0001-tini.c-a-function-declaration-without-a-prototype-is.patch
diff --git a/recipes-containers/tini/tini/0001-tini.c-a-function-declaration-without-a-prototype-is.patch b/recipes-containers/tini/tini/0001-tini.c-a-function-declaration-without-a-prototype-is.patch
new file mode 100644
index 0000000..96f3625
--- /dev/null
+++ b/recipes-containers/tini/tini/0001-tini.c-a-function-declaration-without-a-prototype-is.patch
@@ -0,0 +1,74 @@
+From 66d0b5fd94fafe1e15bf21a1b73618ca23de078f Mon Sep 17 00:00:00 2001
+From: Jose Quaresma <jose.quaresma@foundries.io>
+Date: Fri, 23 Sep 2022 16:31:33 +0000
+Subject: [PATCH] tini.c: a function declaration without a prototype is
+ deprecated in all versions of C
+
+| /srv/oe/build/tmp-lmp/work/corei7-64-lmp-linux/tini/0.19.0-r0/git/src/tini.c:150:18: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
+| int isolate_child() {
+| ^
+| void
+| /srv/oe/build/tmp-lmp/work/corei7-64-lmp-linux/tini/0.19.0-r0/git/src/tini.c:395:14: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
+| int parse_env() {
+| ^
+| void
+| /srv/oe/build/tmp-lmp/work/corei7-64-lmp-linux/tini/0.19.0-r0/git/src/tini.c:416:24: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
+| int register_subreaper () {
+| ^
+| void
+| /srv/oe/build/tmp-lmp/work/corei7-64-lmp-linux/tini/0.19.0-r0/git/src/tini.c:434:19: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
+| void reaper_check () {
+| ^
+| void
+| 4 errors generated.
+
+:Upstream-Status: Submitted [https://github.com/krallin/tini/pull/198]
+
+Signed-off-by: Jose Quaresma <jose.quaresma@foundries.io>
+---
+ src/tini.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/src/tini.c b/src/tini.c
+index 2c873f9..7914d3a 100644
+--- a/src/tini.c
++++ b/src/tini.c
+@@ -147,7 +147,7 @@ int restore_signals(const signal_configuration_t* const sigconf_ptr) {
+ return 0;
+ }
+
+-int isolate_child() {
++int isolate_child(void) {
+ // Put the child into a new process group.
+ if (setpgid(0, 0) < 0) {
+ PRINT_FATAL("setpgid failed: %s", strerror(errno));
+@@ -392,7 +392,7 @@ int parse_args(const int argc, char* const argv[], char* (**child_args_ptr_ptr)[
+ return 0;
+ }
+
+-int parse_env() {
++int parse_env(void) {
+ #if HAS_SUBREAPER
+ if (getenv(SUBREAPER_ENV_VAR) != NULL) {
+ subreaper++;
+@@ -413,7 +413,7 @@ int parse_env() {
+
+
+ #if HAS_SUBREAPER
+-int register_subreaper () {
++int register_subreaper (void) {
+ if (subreaper > 0) {
+ if (prctl(PR_SET_CHILD_SUBREAPER, 1)) {
+ if (errno == EINVAL) {
+@@ -431,7 +431,7 @@ int register_subreaper () {
+ #endif
+
+
+-void reaper_check () {
++void reaper_check (void) {
+ /* Check that we can properly reap zombies */
+ #if HAS_SUBREAPER
+ int bit = 0;
+--
+2.34.1
+
diff --git a/recipes-containers/tini/tini_0.19.0.bb b/recipes-containers/tini/tini_0.19.0.bb
index 914cffb..fd90f62 100644
--- a/recipes-containers/tini/tini_0.19.0.bb
+++ b/recipes-containers/tini/tini_0.19.0.bb
@@ -8,6 +8,7 @@ SRCREV = "b9f42a0e7bb46efea0c9e3d8610c96ab53b467f8"
SRC_URI = " \
git://github.com/krallin/tini.git;branch=master;protocol=https \
file://0001-Do-not-strip-the-output-binary-allow-yocto-to-do-thi.patch \
+ file://0001-tini.c-a-function-declaration-without-a-prototype-is.patch \
"
LICENSE = "MIT"
--
2.34.1
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [meta-virtualization][PATCH] tini: fix function declaration without a prototype
2022-09-30 11:46 [meta-virtualization][PATCH] tini: fix function declaration without a prototype Jose Quaresma
@ 2022-10-04 21:08 ` Bruce Ashfield
0 siblings, 0 replies; 2+ messages in thread
From: Bruce Ashfield @ 2022-10-04 21:08 UTC (permalink / raw)
To: Jose Quaresma; +Cc: meta-virtualization, Jose Quaresma
merged.
Bruce
In message: [meta-virtualization][PATCH] tini: fix function declaration without a prototype
on 30/09/2022 Jose Quaresma wrote:
> This also fix building with clang 1.15
>
> Signed-off-by: Jose Quaresma <jose.quaresma@foundries.io>
> ---
> ...n-declaration-without-a-prototype-is.patch | 74 +++++++++++++++++++
> recipes-containers/tini/tini_0.19.0.bb | 1 +
> 2 files changed, 75 insertions(+)
> create mode 100644 recipes-containers/tini/tini/0001-tini.c-a-function-declaration-without-a-prototype-is.patch
>
> diff --git a/recipes-containers/tini/tini/0001-tini.c-a-function-declaration-without-a-prototype-is.patch b/recipes-containers/tini/tini/0001-tini.c-a-function-declaration-without-a-prototype-is.patch
> new file mode 100644
> index 0000000..96f3625
> --- /dev/null
> +++ b/recipes-containers/tini/tini/0001-tini.c-a-function-declaration-without-a-prototype-is.patch
> @@ -0,0 +1,74 @@
> +From 66d0b5fd94fafe1e15bf21a1b73618ca23de078f Mon Sep 17 00:00:00 2001
> +From: Jose Quaresma <jose.quaresma@foundries.io>
> +Date: Fri, 23 Sep 2022 16:31:33 +0000
> +Subject: [PATCH] tini.c: a function declaration without a prototype is
> + deprecated in all versions of C
> +
> +| /srv/oe/build/tmp-lmp/work/corei7-64-lmp-linux/tini/0.19.0-r0/git/src/tini.c:150:18: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
> +| int isolate_child() {
> +| ^
> +| void
> +| /srv/oe/build/tmp-lmp/work/corei7-64-lmp-linux/tini/0.19.0-r0/git/src/tini.c:395:14: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
> +| int parse_env() {
> +| ^
> +| void
> +| /srv/oe/build/tmp-lmp/work/corei7-64-lmp-linux/tini/0.19.0-r0/git/src/tini.c:416:24: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
> +| int register_subreaper () {
> +| ^
> +| void
> +| /srv/oe/build/tmp-lmp/work/corei7-64-lmp-linux/tini/0.19.0-r0/git/src/tini.c:434:19: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
> +| void reaper_check () {
> +| ^
> +| void
> +| 4 errors generated.
> +
> +:Upstream-Status: Submitted [https://github.com/krallin/tini/pull/198]
> +
> +Signed-off-by: Jose Quaresma <jose.quaresma@foundries.io>
> +---
> + src/tini.c | 8 ++++----
> + 1 file changed, 4 insertions(+), 4 deletions(-)
> +
> +diff --git a/src/tini.c b/src/tini.c
> +index 2c873f9..7914d3a 100644
> +--- a/src/tini.c
> ++++ b/src/tini.c
> +@@ -147,7 +147,7 @@ int restore_signals(const signal_configuration_t* const sigconf_ptr) {
> + return 0;
> + }
> +
> +-int isolate_child() {
> ++int isolate_child(void) {
> + // Put the child into a new process group.
> + if (setpgid(0, 0) < 0) {
> + PRINT_FATAL("setpgid failed: %s", strerror(errno));
> +@@ -392,7 +392,7 @@ int parse_args(const int argc, char* const argv[], char* (**child_args_ptr_ptr)[
> + return 0;
> + }
> +
> +-int parse_env() {
> ++int parse_env(void) {
> + #if HAS_SUBREAPER
> + if (getenv(SUBREAPER_ENV_VAR) != NULL) {
> + subreaper++;
> +@@ -413,7 +413,7 @@ int parse_env() {
> +
> +
> + #if HAS_SUBREAPER
> +-int register_subreaper () {
> ++int register_subreaper (void) {
> + if (subreaper > 0) {
> + if (prctl(PR_SET_CHILD_SUBREAPER, 1)) {
> + if (errno == EINVAL) {
> +@@ -431,7 +431,7 @@ int register_subreaper () {
> + #endif
> +
> +
> +-void reaper_check () {
> ++void reaper_check (void) {
> + /* Check that we can properly reap zombies */
> + #if HAS_SUBREAPER
> + int bit = 0;
> +--
> +2.34.1
> +
> diff --git a/recipes-containers/tini/tini_0.19.0.bb b/recipes-containers/tini/tini_0.19.0.bb
> index 914cffb..fd90f62 100644
> --- a/recipes-containers/tini/tini_0.19.0.bb
> +++ b/recipes-containers/tini/tini_0.19.0.bb
> @@ -8,6 +8,7 @@ SRCREV = "b9f42a0e7bb46efea0c9e3d8610c96ab53b467f8"
> SRC_URI = " \
> git://github.com/krallin/tini.git;branch=master;protocol=https \
> file://0001-Do-not-strip-the-output-binary-allow-yocto-to-do-thi.patch \
> + file://0001-tini.c-a-function-declaration-without-a-prototype-is.patch \
> "
>
> LICENSE = "MIT"
> --
> 2.34.1
>
>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#7637): https://lists.yoctoproject.org/g/meta-virtualization/message/7637
> Mute This Topic: https://lists.yoctoproject.org/mt/94014454/1050810
> Group Owner: meta-virtualization+owner@lists.yoctoproject.org
> Unsubscribe: https://lists.yoctoproject.org/g/meta-virtualization/unsub [bruce.ashfield@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-10-04 21:08 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-09-30 11:46 [meta-virtualization][PATCH] tini: fix function declaration without a prototype Jose Quaresma
2022-10-04 21:08 ` Bruce Ashfield
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.