[Freewx-maint] Bug#875827: wx-config does not work when --host is passed

Helmut Grohne helmut at subdivi.de
Thu Sep 14 21:03:08 UTC 2017


Package: libwxgtk3.0-dev
Version: 3.0.3.1+dfsg-1
Tags: upstream
Forwarded: https://trac.wxwidgets.org/ticket/12698
User: helmutg at debian.org
Usertags: rebootstrap
Control: affects -1 + src:mediainfo

I figured that mediainfo fails to cross build from source, because it
does not find wxWidgets. It invokes wx-config as:

    wx-config --host=$DEB_HOST_GNU_TYPE --unicode=yes --static=no base --version

That fails whereas it works after dropping --host:

| $ WXDEBUG=1 wx-config --host=powerpc64le-linux-gnu --unicode=yes --static=no base --version
| 
|   input parameters          = base
|   libs parameters           = 
|   optional-libs parameters  = 
|   input options     = host
|     host = powerpc64le-linux-gnu
|   yes/no options    = unicode static
|     unicode = yes
|     static = no
|   flag options      = 
|   output options    = version
|     version = yes
|   query options     = 
| 
|   prefix       = '/usr'
|   exec_prefix  = '/usr'
|   wxconfdir    = '/usr/lib/powerpc64le-linux-gnu/wx/config'
|   m_host       = 'powerpc64le-linux-gnu-?'
|   m_toolkit    = '[^-]+'
|   m_widgetset  = '(univ)?'
|   m_chartype   = 'unicode'
|   m_debugtype  = '(debug|release)'
|   m_flavour    = '(-[^-]+)?'
|   m_version    = '[0-9]+\.[0-9]+'
|   m_linkage    = ''
|   configmask   = '^powerpc64le-linux-gnu-?-[^-]+(univ)?-unicode-[0-9]+\.[0-9]+(-[^-]+)?$'
|   this config  = 'gtk2-unicode-3.0'
| 
|   must delegate to an alternate config
|   potential delegates (0):
| 
|           Warning: No config found to match: ^powerpc64le-linux-gnu-?-[^-]+(univ)?-unicode-[0-9]+\.[0-9]+(-[^-]+)?$
|                    in /usr/lib/powerpc64le-linux-gnu/wx/config
|           If you require this configuration, please install the desired
|           library build.  If this is part of an automated configuration
|           test and no other errors occur, you may safely ignore it.
|           You may use wx-config --list to see all configs available in
|           the default prefix.
| 
| $ WXDEBUG=1 wx-config  --unicode=yes --static=no base --version
| 
|   input parameters          = base
|   libs parameters           = 
|   optional-libs parameters  = 
|   input options     = 
|   yes/no options    = unicode static
|     unicode = yes
|     static = no
|   flag options      = 
|   output options    = version
|     version = yes
|   query options     = 
| 
|   prefix       = '/usr'
|   exec_prefix  = '/usr'
|   wxconfdir    = '/usr/lib/powerpc64le-linux-gnu/wx/config'
|   m_host       = ''
|   m_toolkit    = '[^-]+'
|   m_widgetset  = '(univ)?'
|   m_chartype   = 'unicode'
|   m_debugtype  = '(debug|release)'
|   m_flavour    = '(-[^-]+)?'
|   m_version    = '[0-9]+\.[0-9]+'
|   m_linkage    = ''
|   configmask   = '^[^-]+(univ)?-unicode-[0-9]+\.[0-9]+(-[^-]+)?$'
|   this config  = 'gtk2-unicode-3.0'
| 
|   using this config
| 3.0.3
|   user supplied libs: ''
|   fetching lib flags for: ''
|   retrieved: ldflags = 
|              wxlibs  = 
|              alllibs = 
| 
|   using libs: ' '
|   using_gui = yes
| 
| $

I believe that mediainfo's use of --host is reasonable and wx-config
should handle the native --host just fine.

In an IRC discussion Olly Betts figured the matching upstream bug (set
as forwarded above).

In testing this, I found a workaround that makes --host work. If you
copy /usr/lib/powerpc64le-linux-gnu/wx/config/gtk2-unicode-3.0 to
/usr/lib/powerpc64le-linux-gnu/wx/config/powerpc64le-linux-gnu-gtk2-unicode-3.0
and sed 's/^this_host=".*"/this_host="powerpc64le-linux-gnu"/' the new
file, then wx-config works with that --host.

I'm not sure whether that workaround breaks something, but if it
doesn't, I think the packaging could do that and thus unbreak --host.
I'm not convinced enough to set the patch tag though. %-)

Helmut



More information about the Freewx-maint mailing list