If you compile FreeTDS for Windows and get nmake error that looks like this:
Then again run nmake and finish compiling.
Если вы компилируете FreeTDS для Windows и получаете ошибки nmake примерно такого вида:
После этого снова запускаете nmake и завершаете компиляцию.
Creating library Release_TS\php_dblib.lib and object Release_TS\php_dblib.exp dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tdsdump_log referenced in function _dblib_add_connection dblib.lib(rpc.obj) : error LNK2001: unresolved external symbol _tdsdump_log dblib.lib(dbutil.obj) : error LNK2001: unresolved external symbol _tdsdump_log dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_alloc_context referenced in function _dblib_get_tds_ctx dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_free_context referenced in function _dblib_release_tds_ctx dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_free_results referenced in function _buffer_free_row dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_free_row referenced in function _buffer_free_row dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_alloc_rowreferenced in function _buffer_save_row dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_strlcpy referenced in function _db_env_chg dblib.lib(rpc.obj) : error LNK2001: unresolved external symbol _tds_strlcpy dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_free_login referenced in function _dbloginfree dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_bulk referenced in function _dbsetlbool dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_willconvert referenced in function _dbwillconvert dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_prtype referenced in function _dbprtype dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_vstrbuildreferenced in function _dbperror dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_library referenced in function _dblogin dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_alloc_login referenced in function _dblogin dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_language referenced in function _dbsetlname dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_client_charset referenced in function _dbsetlname dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_app referenced in function _dbsetlname dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_passwd referenced in function _dbsetlname dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_user referenced in function _dbsetlname dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_host referenced in function _dbsetlname dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_packet referenced in function _dbsetllong dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_process_tokens referenced in function __dbresults dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tdsdump_dump_buf referenced in function _dbsetnull dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_convert referenced in function _dbconvert dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_get_size_by_type referenced in function _dbconvert dblib.lib(rpc.obj) : error LNK2001: unresolved external symbol _tds_get_size_by_type dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_get_conversion_type referenced in function _dbbind dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_interfaces_file_loc referenced in function _dbsetifile dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_process_cancel referenced in function _dbcancel dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_send_cancel referenced in function _dbcancel dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_strftime referenced in function _dbspr1row dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_datecrackreferenced in function _dbspr1row dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _asprintf referenced in function _dbsetopt dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_peek referenced in function _dbsqlok dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_flush_packet referenced in function _dbsqlok dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_statereferenced in function _dbmoretext dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_put_n referenced in function _dbmoretext dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_submit_query referenced in function _dbsqlsend dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_free_socket referenced in function _dbclose dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _STD_DATETIME_FMT referenced in function _dbprrow dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_put_int referenced in function _dbwritetext dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_process_simple_query referenced in function _dbwritetext dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_submit_queryf referenced in function _dbwritetext dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_free_connection referenced in function _tdsdbopen dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_connect referenced in function _tdsdbopen dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_read_config_info referenced in function _tdsdbopen dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_parent referenced in function _tdsdbopen dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_alloc_socket referenced in function _tdsdbopen dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_server referenced in function _tdsdbopen dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _vasprintf referenced in function _dbfcmd dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_quote_id referenced in function _dbuse dblib.lib(rpc.obj) : error LNK2019: unresolved external symbol _tds_alloc_param_data referenced in function _param_row_alloc dblib.lib(rpc.obj) : error LNK2019: unresolved external symbol _tds_free_param_results referenced in function _param_info_alloc dblib.lib(rpc.obj) : error LNK2019: unresolved external symbol _tds_set_param_type referenced in function _param_info_alloc dblib.lib(rpc.obj) : error LNK2019: unresolved external symbol _tds_get_null_type referenced in function _param_info_alloc dblib.lib(rpc.obj) : error LNK2019: unresolved external symbol _tds_alloc_param_result referenced in function _param_info_alloc dblib.lib(rpc.obj) : error LNK2019: unresolved external symbol _tds_submit_rpc referenced in function _dbrpcsend dblib.lib(dbutil.obj) : error LNK2019: unresolved external symbol _tds_set_version referenced in function __dblib_setTDS_version Release_TS\php_dblib.dll : fatal error LNK1120: 57 unresolved externals NMAKE : fatal error U1077: '"D:\Program Files\Microsoft Visual Studio 8\VC\BIN\c l.exe"' : return code '0x2' Stop.That means that you need to open Makefile in a text editor, find the line:
LIBS=kernel32.lib ole32.lib user32.lib advapi32.lib shell32.lib ws2_32.lib Dnsapi.libAnd add library libTDS.lib:
LIBS=libTDS.lib kernel32.lib ole32.lib user32.lib advapi32.lib shell32.lib ws2_32.lib Dnsapi.libAlso, the library must be copied to a folder of your libs compiled. The library itself can be found in one of the folders where you copied dblib.lib.
Then again run nmake and finish compiling.
Если вы компилируете FreeTDS для Windows и получаете ошибки nmake примерно такого вида:
Creating library Release_TS\php_dblib.lib and object Release_TS\php_dblib.exp dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tdsdump_log referenced in function _dblib_add_connection dblib.lib(rpc.obj) : error LNK2001: unresolved external symbol _tdsdump_log dblib.lib(dbutil.obj) : error LNK2001: unresolved external symbol _tdsdump_log dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_alloc_context referenced in function _dblib_get_tds_ctx dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_free_context referenced in function _dblib_release_tds_ctx dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_free_results referenced in function _buffer_free_row dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_free_row referenced in function _buffer_free_row dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_alloc_rowreferenced in function _buffer_save_row dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_strlcpy referenced in function _db_env_chg dblib.lib(rpc.obj) : error LNK2001: unresolved external symbol _tds_strlcpy dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_free_login referenced in function _dbloginfree dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_bulk referenced in function _dbsetlbool dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_willconvert referenced in function _dbwillconvert dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_prtype referenced in function _dbprtype dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_vstrbuildreferenced in function _dbperror dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_library referenced in function _dblogin dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_alloc_login referenced in function _dblogin dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_language referenced in function _dbsetlname dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_client_charset referenced in function _dbsetlname dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_app referenced in function _dbsetlname dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_passwd referenced in function _dbsetlname dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_user referenced in function _dbsetlname dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_host referenced in function _dbsetlname dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_packet referenced in function _dbsetllong dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_process_tokens referenced in function __dbresults dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tdsdump_dump_buf referenced in function _dbsetnull dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_convert referenced in function _dbconvert dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_get_size_by_type referenced in function _dbconvert dblib.lib(rpc.obj) : error LNK2001: unresolved external symbol _tds_get_size_by_type dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_get_conversion_type referenced in function _dbbind dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_interfaces_file_loc referenced in function _dbsetifile dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_process_cancel referenced in function _dbcancel dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_send_cancel referenced in function _dbcancel dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_strftime referenced in function _dbspr1row dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_datecrackreferenced in function _dbspr1row dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _asprintf referenced in function _dbsetopt dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_peek referenced in function _dbsqlok dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_flush_packet referenced in function _dbsqlok dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_statereferenced in function _dbmoretext dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_put_n referenced in function _dbmoretext dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_submit_query referenced in function _dbsqlsend dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_free_socket referenced in function _dbclose dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _STD_DATETIME_FMT referenced in function _dbprrow dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_put_int referenced in function _dbwritetext dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_process_simple_query referenced in function _dbwritetext dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_submit_queryf referenced in function _dbwritetext dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_free_connection referenced in function _tdsdbopen dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_connect referenced in function _tdsdbopen dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_read_config_info referenced in function _tdsdbopen dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_parent referenced in function _tdsdbopen dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_alloc_socket referenced in function _tdsdbopen dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_set_server referenced in function _tdsdbopen dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _vasprintf referenced in function _dbfcmd dblib.lib(dblib.obj) : error LNK2019: unresolved external symbol _tds_quote_id referenced in function _dbuse dblib.lib(rpc.obj) : error LNK2019: unresolved external symbol _tds_alloc_param_data referenced in function _param_row_alloc dblib.lib(rpc.obj) : error LNK2019: unresolved external symbol _tds_free_param_results referenced in function _param_info_alloc dblib.lib(rpc.obj) : error LNK2019: unresolved external symbol _tds_set_param_type referenced in function _param_info_alloc dblib.lib(rpc.obj) : error LNK2019: unresolved external symbol _tds_get_null_type referenced in function _param_info_alloc dblib.lib(rpc.obj) : error LNK2019: unresolved external symbol _tds_alloc_param_result referenced in function _param_info_alloc dblib.lib(rpc.obj) : error LNK2019: unresolved external symbol _tds_submit_rpc referenced in function _dbrpcsend dblib.lib(dbutil.obj) : error LNK2019: unresolved external symbol _tds_set_version referenced in function __dblib_setTDS_version Release_TS\php_dblib.dll : fatal error LNK1120: 57 unresolved externals NMAKE : fatal error U1077: '"D:\Program Files\Microsoft Visual Studio 8\VC\BIN\c l.exe"' : return code '0x2' Stop.То это значит, что вам нужно открыть Makefile в текстовом редакторе, найти строку:
LIBS=kernel32.lib ole32.lib user32.lib advapi32.lib shell32.lib ws2_32.lib Dnsapi.libИ добавить библиотеку libTDS.lib:
LIBS=libTDS.lib kernel32.lib ole32.lib user32.lib advapi32.lib shell32.lib ws2_32.lib Dnsapi.libТакже, эту библиотеку нужно скопировать в папку libs вашей компиляции. Саму библиотеку можно найти в одной из папок, там где вы копировали dblib.lib.
После этого снова запускаете nmake и завершаете компиляцию.
Комментариев нет:
Отправить комментарий
Spam, junk and other unused material can be removed without notification.
Спам, мусор и другие неиспользованные материалы могут быть удалены без предварительного уведомления.