Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/1] package/ocrad: fix static build
@ 2022-08-12 21:01 Fabrice Fontaine
  2022-08-14 21:42 ` Yann E. MORIN
  0 siblings, 1 reply; 2+ messages in thread
From: Fabrice Fontaine @ 2022-08-12 21:01 UTC (permalink / raw)
  To: buildroot; +Cc: Gilles Talis, Fabrice Fontaine

Fix the following static build failure raised since bump to version 0.28
in commit 1b677db703dc0b976a707942bbc94ecd3f7b4b4b:

/home/buildroot/autobuild/run/instance-2/output-1/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld: /home/buildroot/autobuild/run/instance-2/output-1/host/arm-buildroot-linux-uclibcgnueabi/sysroot/usr/lib/libpng.a(png.o): in function `png_reset_crc':
png.c:(.text+0x738): undefined reference to `crc32'

Fixes:
 - http://autobuild.buildroot.org/results/97543d8df5c40818e05622490e4aad60b48934a6

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 package/ocrad/ocrad.mk | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/package/ocrad/ocrad.mk b/package/ocrad/ocrad.mk
index 78638b770a..5a68427bfb 100644
--- a/package/ocrad/ocrad.mk
+++ b/package/ocrad/ocrad.mk
@@ -10,12 +10,14 @@ OCRAD_SITE = $(BR2_GNU_MIRROR)/ocrad
 OCRAD_LICENSE = GPL-2.0+
 OCRAD_LICENSE_FILES = COPYING
 OCRAD_INSTALL_STAGING = YES
-OCRAD_DEPENDENCIES = libpng
+OCRAD_DEPENDENCIES = host-pkgconf libpng
+OCRAD_LIBS = `$(PKG_CONFIG_HOST_BINARY) --libs libpng`
 
 # This is not a true autotools package.
 define OCRAD_CONFIGURE_CMDS
 	cd $(@D) && \
-	$(TARGET_MAKE_ENV) ./configure --prefix=/usr --sysconfdir=/etc $(TARGET_CONFIGURE_OPTS)
+	$(TARGET_MAKE_ENV) ./configure --prefix=/usr --sysconfdir=/etc \
+		LIBS="$(OCRAD_LIBS)" $(TARGET_CONFIGURE_OPTS)
 endef
 
 define OCRAD_BUILD_CMDS
-- 
2.35.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/ocrad: fix static build
  2022-08-12 21:01 [Buildroot] [PATCH 1/1] package/ocrad: fix static build Fabrice Fontaine
@ 2022-08-14 21:42 ` Yann E. MORIN
  0 siblings, 0 replies; 2+ messages in thread
From: Yann E. MORIN @ 2022-08-14 21:42 UTC (permalink / raw)
  To: Fabrice Fontaine; +Cc: Gilles Talis, buildroot

Fabrice, All,

On 2022-08-12 23:01 +0200, Fabrice Fontaine spake thusly:
> Fix the following static build failure raised since bump to version 0.28
> in commit 1b677db703dc0b976a707942bbc94ecd3f7b4b4b:
> 
> /home/buildroot/autobuild/run/instance-2/output-1/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld: /home/buildroot/autobuild/run/instance-2/output-1/host/arm-buildroot-linux-uclibcgnueabi/sysroot/usr/lib/libpng.a(png.o): in function `png_reset_crc':
> png.c:(.text+0x738): undefined reference to `crc32'

I've added a blurb how LIBS work, and applied to master, thanks.

Regards,
Yann E. MORIN.

> Fixes:
>  - http://autobuild.buildroot.org/results/97543d8df5c40818e05622490e4aad60b48934a6
> 
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> ---
>  package/ocrad/ocrad.mk | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/package/ocrad/ocrad.mk b/package/ocrad/ocrad.mk
> index 78638b770a..5a68427bfb 100644
> --- a/package/ocrad/ocrad.mk
> +++ b/package/ocrad/ocrad.mk
> @@ -10,12 +10,14 @@ OCRAD_SITE = $(BR2_GNU_MIRROR)/ocrad
>  OCRAD_LICENSE = GPL-2.0+
>  OCRAD_LICENSE_FILES = COPYING
>  OCRAD_INSTALL_STAGING = YES
> -OCRAD_DEPENDENCIES = libpng
> +OCRAD_DEPENDENCIES = host-pkgconf libpng
> +OCRAD_LIBS = `$(PKG_CONFIG_HOST_BINARY) --libs libpng`
>  
>  # This is not a true autotools package.
>  define OCRAD_CONFIGURE_CMDS
>  	cd $(@D) && \
> -	$(TARGET_MAKE_ENV) ./configure --prefix=/usr --sysconfdir=/etc $(TARGET_CONFIGURE_OPTS)
> +	$(TARGET_MAKE_ENV) ./configure --prefix=/usr --sysconfdir=/etc \
> +		LIBS="$(OCRAD_LIBS)" $(TARGET_CONFIGURE_OPTS)
>  endef
>  
>  define OCRAD_BUILD_CMDS
> -- 
> 2.35.1
> 
> _______________________________________________
> 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] 2+ messages in thread

end of thread, other threads:[~2022-08-14 21:42 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-08-12 21:01 [Buildroot] [PATCH 1/1] package/ocrad: fix static build Fabrice Fontaine
2022-08-14 21:42 ` Yann E. MORIN

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox