|
Boost Users : |
Subject: [Boost-users] [Locale] MinGW + ICU + cross compiling = wchar errors?
From: Jookia (166291_at_[hidden])
Date: 2012-10-29 06:07:49
Hello!
I'm trying to compile Boost.Locale 1.51.0 with ICU 1.50 support in
x86_64 MinGW-w64 4.7.2.
So to start off, I have a structure of all my libs, includes and whatnot
at /home/jookia/Programming/mingw64.
I've built ICU using this command and installed it:
CXXFLAGS=-fpermissive ../configure
--prefix=/home/jookia/Programming/mingw64/ --host x86_64-w64-mingw32
--with-cross-build=/home/jookia/Programming/local/icu/source/build
--enable-static --enable-shared --with-data-packaging=archive
--with-library-bits=64
Building Boost uses this user-config:
using gcc : 4.7 : x86_64-w64-mingw32-g++
:
<rc>x86_64-w64-mingw32-windres
<archiver>x86_64-w64-mingw32-ar
<compileflags>-I/home/jookia/Programming/mingw64/include/
<linkflags>-L/home/jookia/Programming/mingw64/lib/
;
and this command:
bjam threadapi=win32 target-os=windows variant=release threading=multi
link=shared runtime-link=shared
--prefix=/home/jookia/Programming/mingw64 --user-config=user-config.jam
--without-python --without-mpi --layout=tagged -sNO_BZIP=1 -sNO_ZLIB=1
install
In order to try and build Boost.Locale I've patched its Jamfile to
remove the shared libstdc++ stuff as MinGW doesn't seem to support it,
and also rename all of the searched-lib <name>s to their MSVC
equivalents so I can find those.
The command it used to build is this (stuff omitted to save space):
"x86_64-w64-mingw32-g++"
"-Wl,--out-implib,bin.v2/libs/locale/build/.../libboost_locale-mt.dll.a"
-o "bin.v2/libs/locale/build/.../libboost_locale-mt.dll" -Wl,-h
-Wl,libboost_locale-mt.dll -shared -Wl,--start-group ... -Wl,-Bstatic
-Wl,-Bdynamic -licuuc -licuin -licudt -liconv -Wl,--end-group
-L/home/jookia/Programming/mingw64/lib/ -mthreads
Compiling works fine up until linking, where it gives a few errors like
this (paths and mangled names omitted to save sapce):
bin.v2/.../formatter.o:formatter.cpp:(... undefined reference to
`icu_50::UnicodeString::UnicodeString(wchar_t const*, int)'
Is there any solution to this or is this something to do with MinGW's
lack of support for wchars?
Thanks,
Jookia.
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net