我正在尝试在安装了Visual Studio 2017社区的64位Windows 10计算机上构建autoknit。我已经按照自述文件中的说明进行了该项目的操作,包括克隆存储库,但是当我尝试从“ VS 2017的x64本机工具命令提示符”控制台运行jam时,遇到以下错误:
...found 186 target(s)...
...updating 3 target(s)...
Link dist\schedule.exe
objs\ScheduleCost.obj : fatal error LNK1112: module machine type 'x64' conflicts with target machine type 'x86'
link /nologo /nologo /SUBSYSTEM:CONSOLE /LIBPATH:kit-libs-win/out/lib /LIBPATH:kit-libs-win/out/libpng /LIBPATH:kit-libs-win/out/zlib /out:dist\schedule.exe objs\Stitch.obj objs\ScheduleCost.obj objs\schedule.obj objs\embed_DAG.obj objs\plan_transfers.obj objs\plan_transfers-draw_beds.obj objs\plan_transfers-run_transfers.obj objs\plan_transfers-best_collapse.obj objs\plan_transfers-best_shift.obj objs\plan_transfers-best_expand.obj objs\plan_transfers-minimize_winding.obj SDL2main.lib SDL2.lib OpenGL32.lib libpng.lib zlib.lib
...failed Link dist\schedule.exe ...
Link dist\test_flatten.exe
dist\ak-link_chains.obj : fatal error LNK1112: module machine type 'x86' conflicts with target machine type 'x64'
link /nologo /nologo /SUBSYSTEM:CONSOLE /LIBPATH:kit-libs-win/out/lib /LIBPATH:kit-libs-win/out/libpng /LIBPATH:kit-libs-win/out/zlib /out:dist\test_flatten.exe objs\test_flatten.obj dist\ak-link_chains.obj SDL2main.lib SDL2.lib OpenGL32.lib libpng.lib zlib.lib
...failed Link dist\test_flatten.exe ...
Link dist\interface.exe
msvcprt.lib(MSVCP140.dll) : fatal error LNK1112: module machine type 'x64' conflicts with target machine type 'x86'
link /nologo /nologo /SUBSYSTEM:CONSOLE /LIBPATH:kit-libs-win/out/lib /LIBPATH:kit-libs-win/out/libpng /LIBPATH:kit-libs-win/out/zlib /out:dist\interface.exe dist\ak-trace_graph.obj dist\ak-peel_slice-euclidean.obj dist\ak-trim_model.obj dist\ak-embedded_path.obj dist\ak-build_next_active_chains.obj dist\ak-link_chains.obj dist\ak-extract_level_chains.obj dist\ak-find_first_active_chains.obj dist\ak-sample_chain.obj dist\Interface.obj dist\init.obj dist\load_obj.obj dist\ak-load_constraints.obj dist\ak-embed_constraints.obj dist\ak-interpolate_values.obj objs\kit\kit.obj objs\kit\kit-SDL2.obj objs\kit\Button.obj objs\kit\Load.obj objs\kit\MeshBuffer.obj objs\kit\BoneAnimation.obj objs\kit\GLProgram.obj objs\kit\path.obj objs\kit\load_save_png.obj objs\kit\gl_shims.obj objs\Stitch.obj SDL2main.lib SDL2.lib OpenGL32.lib libpng.lib zlib.lib
...failed Link dist\interface.exe ...
...failed updating 3 target(s)...
都说x64机器类型与x86目标类型冲突,并且x86机器类型与x64目标类型冲突。这似乎是不合逻辑的,使编译器似乎检测到x64机器,但代码适用于x86,但也切换到检测具有x64代码的x86机器。我无法对此做出正面或反面的解释,也无法弄清楚如何解决它。这是一个使用jam和VS编译器构建的git存储库;据我所知,这不是一个合适的VS项目。