[virt-tools-list] Linking error trying to cross compile virt-viewer for windows using mingw32 on Fedora 20
cyber python
cyberpython at gmail.com
Sat Jun 21 17:36:45 UTC 2014
Hello everyone,
I am trying to build virt-viewer for MS Windows on Fedora 20.
I have installed:
mingw32-* pkgconfig intltool icoutils dos2unix msitools gtk2-devel
libxml2-devel
(link to text file with full list of installed packages
<https://dl.dropboxusercontent.com/u/599926/fedora_20_installed_packages.txt>
)
I also have cloned the virt-viewer repository from:
https://git.fedorahosted.org/git/virt-viewer.git to ~/projects/virt-viewer.
The current git commit id is 687b9e0bfa679b8ba7576025fbf34517b0d65e21.
Initially, I tried building virt-viewer with:
./autobuild.sh
but this fails while executing ./configure (which is expected since I am
missing the dependencies to build the Linux binaries).
Then, I tried to build with:
./autogen.sh --help
rm -rf build-mingw
mkdir build-mingw
cd build-mingw
../configure
PKG_CONFIG_LIBDIR="/usr/i686-w64-mingw32/sys-root/mingw/lib/pkgconfig:/usr/i686-w64-mingw32/sys-root/mingw/share/pkgconfig"
PKG_CONFIG_PATH="$HOME/builder/i686-w64-mingw32/sys-root/mingw/lib/pkgconfig"
CC="i686-w64-mingw32-gcc" --build=$(uname -m)-w64-linux
--host=i686-w64-mingw32
--prefix="$HOME/builder/i686-w64-mingw32/sys-root/mingw" --with-gtk=2.0
--without-gtk-vnc
make
This time build configuration was successful, but linking failed with the
linker complaining about undefined references regarding symbols in glib,
gtk-2.0, libxml2 etc.
I also tried setting GTK_CFLAGS, GTK_LIBS, GLIB2_CFLAGS, GLIB2_LIBS with
the values generated by mingw32-pkg-config:
../configure
PKG_CONFIG_LIBDIR="/usr/i686-w64-mingw32/sys-root/mingw/lib/pkgconfig:/usr/i686-w64-mingw32/sys-root/mingw/share/pkgconfig"
PKG_CONFIG_PATH="$HOME/builder/i686-w64-mingw32/sys-root/mingw/lib/pkgconfig"
CC="i686-w64-mingw32-gcc" GTK_CFLAGS="-mms-bitfields
-I/usr/i686-w64-mingw32/sys-root/mingw/include/gtk-2.0
-I/usr/i686-w64-mingw32/sys-root/mingw/lib/gtk-2.0/include
-I/usr/i686-w64-mingw32/sys-root/mingw/include/pango-1.0
-I/usr/i686-w64-mingw32/sys-root/mingw/include/harfbuzz
-I/usr/i686-w64-mingw32/sys-root/mingw/include/pango-1.0
-I/usr/i686-w64-mingw32/sys-root/mingw/include/cairo
-I/usr/i686-w64-mingw32/sys-root/mingw/include/atk-1.0
-I/usr/i686-w64-mingw32/sys-root/mingw/include/cairo
-I/usr/i686-w64-mingw32/sys-root/mingw/include/pixman-1
-I/usr/i686-w64-mingw32/sys-root/mingw/include
-I/usr/i686-w64-mingw32/sys-root/mingw/include/freetype2
-I/usr/i686-w64-mingw32/sys-root/mingw/include
-I/usr/i686-w64-mingw32/sys-root/mingw/include/freetype2
-I/usr/i686-w64-mingw32/sys-root/mingw/include
-I/usr/i686-w64-mingw32/sys-root/mingw/include/libpng16
-I/usr/i686-w64-mingw32/sys-root/mingw/include/gdk-pixbuf-2.0
-I/usr/i686-w64-mingw32/sys-root/mingw/include/libpng16
-I/usr/i686-w64-mingw32/sys-root/mingw/include/glib-2.0
-I/usr/i686-w64-mingw32/sys-root/mingw/lib/glib-2.0/include"
GTK_LIBS="-L/usr/i686-w64-mingw32/sys-root/mingw/lib -lgtk-win32-2.0
-lgdk-win32-2.0 -lgdi32 -limm32 -lshell32 -lole32 -Wl,-luuid
-lpangocairo-1.0 -lpangoft2-1.0 -lfontconfig -lfreetype -lpangowin32-1.0
-lgdi32 -lpango-1.0 -lm -latk-1.0 -lcairo -lgdk_pixbuf-2.0 -lgio-2.0
-lgobject-2.0 -lglib-2.0 -lintl" GLIB2_CFLAGS="-mms-bitfields
-I/usr/i686-w64-mingw32/sys-root/mingw/include/glib-2.0
-I/usr/i686-w64-mingw32/sys-root/mingw/lib/glib-2.0/include"
GLIB2_LIBS="-L/usr/i686-w64-mingw32/sys-root/mingw/lib -lglib-2.0 -lintl"
--build=$(uname -m)-w64-linux --host=i686-w64-mingw32
--prefix="$HOME/builder/i686-w64-mingw32/sys-root/mingw" --with-gtk=2.0
--without-gtk-vnc
but the linker keeps complaining about undefined references.
Could someone please tell me what am I doing wrong?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/virt-tools-list/attachments/20140621/da4ad076/attachment.htm>
More information about the virt-tools-list
mailing list