安装TDM-GCC-64,编译wxWidgets 3.1失败
按照Building wxWidgets for wondows的方法
Debug
•open CMD.EXE, cd to \Path\To\wxWidgets\Sources\build\msw and type:
mingw32-make -f makefile.gcc setup_h
•Next, open the file: \path\to\wxwidgets\lib\gcc_dll\mswud\wx\setup.h and change line 784 (ish) to:
# define wxUSE_GRAPHICS_CONTEXT 1
•Start the build
mingw32-make -j8 -f Makefile.gcc SHARED=1 UNICODE=1 BUILD=debug VENDOR=cl CXXFLAGS="-fno-keep-inline-dllexport -std=c++11" MONOLITHIC=1
错误代码如下:
Code: Select all
Makefile.gcc:6741: recipe for target 'gcc_mswuddll\monodll_tarstrm.o' failed
mingw32-make: *** [gcc_mswuddll\monodll_tarstrm.o] Error 1
Makefile.gcc:6735: recipe for target 'gcc_mswuddll\monodll_strvararg.o' failed
mingw32-make: *** [gcc_mswuddll\monodll_strvararg.o] Error 1
Makefile.gcc:6756: recipe for target 'gcc_mswuddll\monodll_timercmn.o' failed
mingw32-make: *** [gcc_mswuddll\monodll_timercmn.o] Error 1
Code: Select all
C:\Users\Administrator>gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=C:/myFile/TDM-GCC-64/bin/../libexec/gcc/x86_64-w64-mingw32/5
.1.0/lto-wrapper.exe
Target: x86_64-w64-mingw32
Configured with: ../../../src/gcc-5.1.0/configure --build=x86_64-w64-mingw32 --e
nable-targets=all --enable-languages=ada,c,c++,fortran,lto,objc,obj-c++ --enable
-libgomp --enable-lto --enable-graphite --enable-cxx-flags=-DWINPTHREAD_STATIC -
-disable-build-with-cxx --disable-build-poststage1-with-cxx --enable-libstdcxx-d
ebug --enable-threads=posix --enable-version-specific-runtime-libs --enable-full
y-dynamic-string --enable-libstdcxx-threads --enable-libstdcxx-time --with-gnu-l
d --disable-werror --disable-nls --disable-win32-registry --prefix=/mingw64tdm -
-with-local-prefix=/mingw64tdm --with-pkgversion=tdm64-1 --with-bugurl=http://td
m-gcc.tdragon.net/bugs
Thread model: posix
gcc version 5.1.0 (tdm64-1)
Code: Select all
C:\Users\Administrator>wx-config --version
3.0.0
C:\Users\Administrator>wx-config --cxxflags
-mthreads -DHAVE_W32API_H -D__WXMSW__ -DNDEBUG -D_UNICODE -IC:/myFile/wxWidgets/
lib/gcc_dll/mswu -IC:/myFile/wxWidgets/include -DWXUSINGDLL -Wno-ctor-dtor-priva
cy -pipe -fmessage-length=0 -fno-keep-inline-dllexport
C:\Users\Administrator>wx-config --libs
-mthreads -LC:/myFile/wxWidgets/lib/gcc_dll -lwxmsw30u_xrc -lwxmsw30u_aui -lwxm
sw30u_html -lwxmsw30u_adv -lwxmsw30u_core -lwxbase30u_xml -lwxbase30u_net -lwxms
w30u_richtext -lwxbase30u -lwxtiff -lwxjpeg -lwxpng -lwxzlib -lwxregexu -lwxexpa
t -lkernel32 -luser32 -lgdi32 -lcomdlg32 -lwxregexu -lwinspool -lwinmm -lshell32
-lcomctl32 -lole32 -loleaut32 -luuid -lrpcrt4 -ladvapi32 -lwsock32