wxWidgets Tips: 用 Visual Studio 编译 wxWidgets 的 64 位版本
2015-09-19 21:17
399 查看
用 Visual Studio 2015(通过 nmake)编译 wxWidgets 动态链接库的时候,出现以下错误:
解决办法:
如果 Visual Studio 在安装的时候装了 64 位编译支持包,那么在 Visual Studio Tools 里面就会有 64 位版本的 Command Prompt。
以 Visual Studio 2015 为例,我们打开 VS2015 x64 Native Tools Command Prompt,再来执行 nmake 编译命令,就能编译 64 位版本:
参考:
- #15506: nmake base link error with TARGET_CPU=X64, VS2012
C:\Lib\wxWidgets\v3.0.2\build\msw>nmake /f makefile.vc BUILD=release SHARED=1 TARGET_CPU=X64 Microsoft (R) Program Maintenance Utility Version 14.00.23026.0 Copyright (C) Microsoft Corporation. All rights reserved. link /DLL /NOLOGO /OUT:..\..\lib\vc_x64_dll\wxbase30u_vc_custom.dll /DEBUG /pdb:"..\..\lib\vc_x64_dll\wxbase30u_vc_custom.pdb" /opt:ref /opt:icf /MACHINE:X64 /LIBPATH:..\..\lib\vc_x64_dll @C:\Users\xinyp\AppData\Local\Temp\nm4E86.tmp vc_mswudll_x64\basedll_dummy.obj : fatal error LNK1112: module machine type 'X86' conflicts with target machine type 'x64' NMAKE : fatal error U1077: 'D:\Apps\x86\Microsoft\Visual_Studio\v14.0\VC\BIN\link.EXE' : return code '0x458' Stop. C:\Lib\wxWidgets\v3.0.2\build\msw>
解决办法:
如果 Visual Studio 在安装的时候装了 64 位编译支持包,那么在 Visual Studio Tools 里面就会有 64 位版本的 Command Prompt。
以 Visual Studio 2015 为例,我们打开 VS2015 x64 Native Tools Command Prompt,再来执行 nmake 编译命令,就能编译 64 位版本:
参考:
- #15506: nmake base link error with TARGET_CPU=X64, VS2012
相关文章推荐
- 【笔记】Code::Blocks
- Visual Studio 2010 Service Pack 1多国语言版下载
- wxWidgets不完全系列之--wxDC
- CUDA 4.0 + Visual Studio 开发环境搭建
- Visual Studio 2012/2010/2008 远程调试
- Web.config配置文件详解
- 小白探访WINDOWS下的驱动(五) 第一个HELLO驱动(插曲-调试环境设置HOST&TARGET)
- 无法打开文件“opencv_calib3d240d.lib”
- dcmtk提示无法解析的外部符号(unresolved external symbol)的解决方法
- Visual Studio 2013之Opendv配置【未完】
- Remote debug in windows
- 安装visual studio时遇到的IE限制问题
- Visual Studio 的断点调试技巧
- VC++错误:error C2065: 'SHCreateDirectoryEx' : undeclared identifier
- 在控制台(Console)环境下编译Windows GUI程序
- 在win8.1系统下运行VC++6.0
- 第三次学长授课之C#编写记事本----感想
- [OpenCV] -- Win8.1下配置OpenCV的Qt(MSVC2013编译器)开发环境
- openframawork的下载与安装
- 在WinDOWS X64下 Cuda NVCC 与 Intel C/C++ compiler联合使用的问题