* [Buildroot] [PATCH 1/1] package/open-iscsi: fix musl build
@ 2023-09-30 13:28 Fabrice Fontaine
2023-09-30 14:08 ` Thomas Petazzoni via buildroot
2023-11-04 22:08 ` Thomas Petazzoni via buildroot
0 siblings, 2 replies; 4+ messages in thread
From: Fabrice Fontaine @ 2023-09-30 13:28 UTC (permalink / raw)
To: buildroot; +Cc: TIAN Yuanhao, Fabrice Fontaine
Fix the following musl build failure raised since bump to version 2.1.9
in commit 2314928cf828ff02939b9c0041964c3ee2dd907d and
https://github.com/open-iscsi/open-iscsi/commit/7b571d76d6937a78c141630fc38c3c57c532466c:
../usr/idbm.c: In function 'idbm_rec_write_old':
../usr/idbm.c:2230:27: error: 'GLOB_ONLYDIR' undeclared (first use in this function)
2230 | rc = glob(portal, GLOB_ONLYDIR, NULL, &globbuf);
| ^~~~~~~~~~~~
Fixes:
- http://autobuild.buildroot.org/results/14fc1c139f055b5b1eaa6e04e327863c06176a7b
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
.../0001-usr-idbm.c-fix-musl-build.patch | 40 +++++++++++++++++++
1 file changed, 40 insertions(+)
create mode 100644 package/open-iscsi/0001-usr-idbm.c-fix-musl-build.patch
diff --git a/package/open-iscsi/0001-usr-idbm.c-fix-musl-build.patch b/package/open-iscsi/0001-usr-idbm.c-fix-musl-build.patch
new file mode 100644
index 0000000000..2ee0e0cc71
--- /dev/null
+++ b/package/open-iscsi/0001-usr-idbm.c-fix-musl-build.patch
@@ -0,0 +1,40 @@
+From dbe342545b7bee42107e09d0da59bb42c50903cb Mon Sep 17 00:00:00 2001
+From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+Date: Sat, 30 Sep 2023 14:54:15 +0200
+Subject: [PATCH] usr/idbm.c: fix musl build
+
+Fix the following musl build failure raised since version 2.1.9 and
+https://github.com/open-iscsi/open-iscsi/commit/7b571d76d6937a78c141630fc38c3c57c532466c:
+
+../usr/idbm.c: In function 'idbm_rec_write_old':
+../usr/idbm.c:2230:27: error: 'GLOB_ONLYDIR' undeclared (first use in this function)
+ 2230 | rc = glob(portal, GLOB_ONLYDIR, NULL, &globbuf);
+ | ^~~~~~~~~~~~
+
+Fixes:
+ - http://autobuild.buildroot.org/results/14fc1c139f055b5b1eaa6e04e327863c06176a7b
+
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+Upstream: https://github.com/open-iscsi/open-iscsi/pull/426
+---
+ usr/idbm.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/usr/idbm.c b/usr/idbm.c
+index ca4a4ec..fbaa132 100644
+--- a/usr/idbm.c
++++ b/usr/idbm.c
+@@ -45,6 +45,10 @@
+ #include "fw_context.h"
+ #include "iscsi_err.h"
+
++#ifndef GLOB_ONLYDIR
++#define GLOB_ONLYDIR 0x100
++#endif
++
+ #define IDBM_HIDE 0 /* Hide parameter when print. */
+ #define IDBM_SHOW 1 /* Show parameter when print. */
+ #define IDBM_MASKED 2 /* Show "stars" instead of real value when print */
+--
+2.40.1
+
--
2.40.1
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [Buildroot] [PATCH 1/1] package/open-iscsi: fix musl build
2023-09-30 13:28 [Buildroot] [PATCH 1/1] package/open-iscsi: fix musl build Fabrice Fontaine
@ 2023-09-30 14:08 ` Thomas Petazzoni via buildroot
2023-10-02 15:07 ` Fabrice Fontaine
2023-11-04 22:08 ` Thomas Petazzoni via buildroot
1 sibling, 1 reply; 4+ messages in thread
From: Thomas Petazzoni via buildroot @ 2023-09-30 14:08 UTC (permalink / raw)
To: Fabrice Fontaine; +Cc: TIAN Yuanhao, buildroot
On Sat, 30 Sep 2023 15:28:22 +0200
Fabrice Fontaine <fontaine.fabrice@gmail.com> wrote:
> ++#ifndef GLOB_ONLYDIR
> ++#define GLOB_ONLYDIR 0x100
> ++#endif
But musl doesn't support this flag, so isn't that wrong? musl will most
likely ignore it. What is the impact on the application if the glob
also matches files, not just directories? Perhaps it breaks the
application behavior. Are you sure we can just blindly do this
workaround?
Thomas
--
Thomas Petazzoni, co-owner and CEO, Bootlin
Embedded Linux and Kernel engineering and training
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Buildroot] [PATCH 1/1] package/open-iscsi: fix musl build
2023-09-30 14:08 ` Thomas Petazzoni via buildroot
@ 2023-10-02 15:07 ` Fabrice Fontaine
0 siblings, 0 replies; 4+ messages in thread
From: Fabrice Fontaine @ 2023-10-02 15:07 UTC (permalink / raw)
To: Thomas Petazzoni; +Cc: TIAN Yuanhao, buildroot
[-- Attachment #1.1: Type: text/plain, Size: 882 bytes --]
Le sam. 30 sept. 2023 à 16:08, Thomas Petazzoni <
thomas.petazzoni@bootlin.com> a écrit :
> On Sat, 30 Sep 2023 15:28:22 +0200
> Fabrice Fontaine <fontaine.fabrice@gmail.com> wrote:
>
> > ++#ifndef GLOB_ONLYDIR
> > ++#define GLOB_ONLYDIR 0x100
> > ++#endif
>
> But musl doesn't support this flag, so isn't that wrong? musl will most
> likely ignore it. What is the impact on the application if the glob
> also matches files, not just directories? Perhaps it breaks the
> application behavior. Are you sure we can just blindly do this
> workaround?
>
Upstream thinks that the application will not break:
https://github.com/open-iscsi/open-iscsi/pull/426#issuecomment-1743136865
>
> Thomas
> --
> Thomas Petazzoni, co-owner and CEO, Bootlin
> Embedded Linux and Kernel engineering and training
> https://bootlin.com
Best Regards,
Fabrice
[-- Attachment #1.2: Type: text/html, Size: 1671 bytes --]
[-- Attachment #2: Type: text/plain, Size: 150 bytes --]
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Buildroot] [PATCH 1/1] package/open-iscsi: fix musl build
2023-09-30 13:28 [Buildroot] [PATCH 1/1] package/open-iscsi: fix musl build Fabrice Fontaine
2023-09-30 14:08 ` Thomas Petazzoni via buildroot
@ 2023-11-04 22:08 ` Thomas Petazzoni via buildroot
1 sibling, 0 replies; 4+ messages in thread
From: Thomas Petazzoni via buildroot @ 2023-11-04 22:08 UTC (permalink / raw)
To: Fabrice Fontaine; +Cc: TIAN Yuanhao, buildroot
On Sat, 30 Sep 2023 15:28:22 +0200
Fabrice Fontaine <fontaine.fabrice@gmail.com> wrote:
> Fix the following musl build failure raised since bump to version 2.1.9
> in commit 2314928cf828ff02939b9c0041964c3ee2dd907d and
> https://github.com/open-iscsi/open-iscsi/commit/7b571d76d6937a78c141630fc38c3c57c532466c:
>
> ../usr/idbm.c: In function 'idbm_rec_write_old':
> ../usr/idbm.c:2230:27: error: 'GLOB_ONLYDIR' undeclared (first use in this function)
> 2230 | rc = glob(portal, GLOB_ONLYDIR, NULL, &globbuf);
> | ^~~~~~~~~~~~
>
> Fixes:
> - http://autobuild.buildroot.org/results/14fc1c139f055b5b1eaa6e04e327863c06176a7b
>
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> ---
> .../0001-usr-idbm.c-fix-musl-build.patch | 40 +++++++++++++++++++
> 1 file changed, 40 insertions(+)
> create mode 100644 package/open-iscsi/0001-usr-idbm.c-fix-musl-build.patch
Applied to master, after updating the Upstream: tag to point to the
commit that was accepted upstream. Thanks!
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2023-11-04 22:08 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-09-30 13:28 [Buildroot] [PATCH 1/1] package/open-iscsi: fix musl build Fabrice Fontaine
2023-09-30 14:08 ` Thomas Petazzoni via buildroot
2023-10-02 15:07 ` Fabrice Fontaine
2023-11-04 22:08 ` Thomas Petazzoni via buildroot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox