[meta-oe] php: Fix native build due mistakenly linking against host's iconv

Submitted by Otavio Salvador on Aug. 24, 2014, 7:39 p.m.

Details

Message ID 1408909187-29642-1-git-send-email-otavio@ossystems.com.br
State Accepted, archived
Headers show

Commit Message

Otavio Salvador Aug. 24, 2014, 7:39 p.m.
The configure script has mistakenly choose to enable iconv support,
due host to provide it, adding '/usr/lib' to the linking flags and
failing as:

,----[ Linking error while testing 'fork' support ]
| conftest.c:268: warning: conflicting types for built-in function 'fork'
| .../build/tmp/sysroots/x86_64-linux/usr/lib/libxml2.so:
|     undefined reference to `gzopen64@ZLIB_1.2.3.3'
| collect2: ld returned 1 exit status
`----

This patch disables iconv support for native builds fixing the error.

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
---
 meta-oe/recipes-devtools/php/php.inc |    1 +
 1 file changed, 1 insertion(+)

Patch hide | download patch | download mbox

diff --git a/meta-oe/recipes-devtools/php/php.inc b/meta-oe/recipes-devtools/php/php.inc
index 030c090..6bdae78 100644
--- a/meta-oe/recipes-devtools/php/php.inc
+++ b/meta-oe/recipes-devtools/php/php.inc
@@ -35,6 +35,7 @@  EXTRA_OECONF = "--enable-mbstring \
 "
 EXTRA_OECONF_virtclass-native = " \
                 --with-zlib=${STAGING_LIBDIR_NATIVE}/.. \
+                --without-iconv \
                 ${COMMON_EXTRA_OECONF} \
 "
 

Comments

Otavio Salvador Aug. 24, 2014, 7:45 p.m.
On Sun, Aug 24, 2014 at 4:39 PM, Otavio Salvador
<otavio@ossystems.com.br> wrote:
> The configure script has mistakenly choose to enable iconv support,
> due host to provide it, adding '/usr/lib' to the linking flags and
> failing as:
>
> ,----[ Linking error while testing 'fork' support ]
> | conftest.c:268: warning: conflicting types for built-in function 'fork'
> | .../build/tmp/sysroots/x86_64-linux/usr/lib/libxml2.so:
> |     undefined reference to `gzopen64@ZLIB_1.2.3.3'
> | collect2: ld returned 1 exit status
> `----
>
> This patch disables iconv support for native builds fixing the error.
>
> Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>

Same error exist in Daisy.

I did the rebase here and I can send a patch for it, as it has a minor
conflict due the pkgconfig rework. Martin, do you want me to send the
patch on top of Daisy as well or do you resolve the conflict yourself?
Martin Jansa Aug. 24, 2014, 8:36 p.m.
On Sun, Aug 24, 2014 at 04:45:22PM -0300, Otavio Salvador wrote:
> On Sun, Aug 24, 2014 at 4:39 PM, Otavio Salvador
> <otavio@ossystems.com.br> wrote:
> > The configure script has mistakenly choose to enable iconv support,
> > due host to provide it, adding '/usr/lib' to the linking flags and
> > failing as:
> >
> > ,----[ Linking error while testing 'fork' support ]
> > | conftest.c:268: warning: conflicting types for built-in function 'fork'
> > | .../build/tmp/sysroots/x86_64-linux/usr/lib/libxml2.so:
> > |     undefined reference to `gzopen64@ZLIB_1.2.3.3'
> > | collect2: ld returned 1 exit status
> > `----
> >
> > This patch disables iconv support for native builds fixing the error.
> >
> > Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
> 
> Same error exist in Daisy.
> 
> I did the rebase here and I can send a patch for it, as it has a minor
> conflict due the pkgconfig rework. Martin, do you want me to send the
> patch on top of Daisy as well or do you resolve the conflict yourself?

Please send it.
Armin Kuster Aug. 28, 2014, 2:37 a.m.
Acked-by: Armin Kuster <akuster808@gmail.com>

On 08/24/2014 12:39 PM, Otavio Salvador wrote:
> The configure script has mistakenly choose to enable iconv support,
> due host to provide it, adding '/usr/lib' to the linking flags and
> failing as:
>
> ,----[ Linking error while testing 'fork' support ]
> | conftest.c:268: warning: conflicting types for built-in function 'fork'
> | .../build/tmp/sysroots/x86_64-linux/usr/lib/libxml2.so:
> |     undefined reference to `gzopen64@ZLIB_1.2.3.3'
> | collect2: ld returned 1 exit status
> `----
>
> This patch disables iconv support for native builds fixing the error.
>
> Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
> ---
>   meta-oe/recipes-devtools/php/php.inc |    1 +
>   1 file changed, 1 insertion(+)
>
> diff --git a/meta-oe/recipes-devtools/php/php.inc b/meta-oe/recipes-devtools/php/php.inc
> index 030c090..6bdae78 100644
> --- a/meta-oe/recipes-devtools/php/php.inc
> +++ b/meta-oe/recipes-devtools/php/php.inc
> @@ -35,6 +35,7 @@ EXTRA_OECONF = "--enable-mbstring \
>   "
>   EXTRA_OECONF_virtclass-native = " \
>                   --with-zlib=${STAGING_LIBDIR_NATIVE}/.. \
> +                --without-iconv \
>                   ${COMMON_EXTRA_OECONF} \
>   "
>
>
Martin Jansa Aug. 28, 2014, 9:26 a.m.
On Wed, Aug 27, 2014 at 07:37:59PM -0700, akuster808 wrote:
> 
> Acked-by: Armin Kuster <akuster808@gmail.com>

Is this for "for-daisy" one?

> On 08/24/2014 12:39 PM, Otavio Salvador wrote:
> > The configure script has mistakenly choose to enable iconv support,
> > due host to provide it, adding '/usr/lib' to the linking flags and
> > failing as:
> >
> > ,----[ Linking error while testing 'fork' support ]
> > | conftest.c:268: warning: conflicting types for built-in function 'fork'
> > | .../build/tmp/sysroots/x86_64-linux/usr/lib/libxml2.so:
> > |     undefined reference to `gzopen64@ZLIB_1.2.3.3'
> > | collect2: ld returned 1 exit status
> > `----
> >
> > This patch disables iconv support for native builds fixing the error.
> >
> > Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
> > ---
> >   meta-oe/recipes-devtools/php/php.inc |    1 +
> >   1 file changed, 1 insertion(+)
> >
> > diff --git a/meta-oe/recipes-devtools/php/php.inc b/meta-oe/recipes-devtools/php/php.inc
> > index 030c090..6bdae78 100644
> > --- a/meta-oe/recipes-devtools/php/php.inc
> > +++ b/meta-oe/recipes-devtools/php/php.inc
> > @@ -35,6 +35,7 @@ EXTRA_OECONF = "--enable-mbstring \
> >   "
> >   EXTRA_OECONF_virtclass-native = " \
> >                   --with-zlib=${STAGING_LIBDIR_NATIVE}/.. \
> > +                --without-iconv \
> >                   ${COMMON_EXTRA_OECONF} \
> >   "
> >
> >
> -- 
> _______________________________________________
> Openembedded-devel mailing list
> Openembedded-devel@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-devel