我花了几个小时在 Visual Studio 2012 中使用 Windows 7 x64 构建我的第一个 Allegro 5 应用程序。
我已按照本教程的所有步骤进行操作: http ://wiki.allegro.cc/index.php?title=Windows,_Visual_Studio_2010_and_Allegro_5#Download 这意味着 Allegro 目录位于 c:/allegro/ 中,并且所有库都已添加在调试和发布配置中。
我还将我的子系统更改为 Windows,所以现在它显示“Windows (/SUBSYSTEM:WINDOWS)”
1>------ Build started: Project: AllegroTesting, Configuration: Debug Win32 ------
1>main.obj : error LNK2019: unresolved external symbol __imp__al_install_system referenced in function _main
1>main.obj : error LNK2019: unresolved external symbol __imp__al_rest referenced in function _main
1>main.obj : error LNK2019: unresolved external symbol __imp__al_map_rgb referenced in function _main
1>main.obj : error LNK2019: unresolved external symbol __imp__al_create_display referenced in function _main
1>main.obj : error LNK2019: unresolved external symbol __imp__al_destroy_display referenced in function _main
1>main.obj : error LNK2019: unresolved external symbol __imp__al_flip_display referenced in function _main
1>main.obj : error LNK2019: unresolved external symbol __imp__al_clear_to_color referenced in function _main
1>c:\users\skypower\documents\visual studio 2012\Projects\AllegroTesting\Debug\AllegroTesting.exe : fatal error LNK1120: 7 unresolved externals
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========