Description:
Compiling latest BK source make_win_src_distribution:
1- Fatal errors
1.1
--------------------Configuration: mysqld - Win32 Debug--------------------
Build : warning : failed to (or don't know how to) build
'E:\mysql-5.0.2-alpha\sql\message.rc'
Compiling resources...
RC : fatal error RC1110 : could not open E:\mysql-5.0.2-alpha\sql\message.rc
Error executing rc.exe.
Suggestion Fix: On mysqld.dsp do the below custom build:
Right click message.mc -> settings
Edit Text box Command:
mc.exe "$(InputDir)\$(InputName).mc"
Edit Text box Output:
$(InputDir)\$(InputName).rc
$(InputDir)\$(InputName).h
1.2
E:\mysql-5.0.2-alpha\sql\sql_base.cpp(3168) : error C2362: initialization of 'table'
is skipped by 'goto err_no_arena'
E:\mysql-5.0.2-alpha\sql\sql_base.cpp(2996) : see declaration of 'table'
Suggestion Fix:
Remove from the below "for loop" the declaration and initialization of
TABLE_LIST *table= tables and to do before goto err_no_arena.
/* Check if we are using outer joins */
for (TABLE_LIST *table= tables; table; table= table->next_local)
{
1.3
E:\mysql-5.0.2-alpha\sql\opt_range.cpp(7943) : error C2664: 'key_cmp' : cannot convert parameter 2 from 'char *' to 'const unsigned char *'
Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
E:\mysql-5.0.2-alpha\sql\opt_range.cpp(8069) : error C2664: 'key_cmp' : cannot convert parameter 2 from 'char *' to 'const unsigned char *'
Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
Suggestion Fix: to cast 2nd paremeter with (byte*)
1.4
sql_base.obj : error LNK2001: unresolved external symbol "public: __thiscall Table_triggers_list::~Table_triggers_list(void)THD@@PBD1PAUst_table@@@Z)
sql_parse.obj : error LNK2001: unresolved external symbol "int __cdecl mysql_create_or_drop_trigger(class THD *,struct st_table_list *,int)"
Suggestion Fix. To add the file .\sql_trigger.cpp to the project mysqld.dsp
2- Warnings of non-used variables:
E:\mysql-5.0.2-alpha\sql\field.cpp(1766) : warning C4244: '-=' : conversion from '__int64' to 'unsigned int', possible loss of data
E:\mysql-5.0.2-alpha\sql\field.cpp(2052) : warning C4101: 'warning_given' : unreferenced local variable
E:\mysql-5.0.2-alpha\sql\sql_db.cpp(740) : warning C4101: 'copy_of_path' : unreferenced local variable
E:\mysql-5.0.2-alpha\sql\sql_db.cpp(841) : warning C4101: 'tmp2_path' : unreferenced local variable
E:\mysql-5.0.2-alpha\sql\ha_innodb.cpp(2199) : warning C4101: 'skip_auto_inc_decr' : unreferenced local variable
Suggestion fix: just remove those variables.
3- Conflict of type:
E:\mysql-5.0.2-alpha\sql\sp_pcontext.h(53) : warning C4099: 'sp_pcontext' : type name first seen using 'class' now seen using 'struct'
E:\mysql-5.0.2-alpha\sql\sql_lex.h(27) : see declaration of 'sp_pcontext'
sp_pcontext.cpp
E:\mysql-5.0.2-alpha\sql\sp_pcontext.h(53) : warning C4099: 'sp_pcontext' : type name first seen using 'class' now seen using 'struct'
E:\mysql-5.0.2-alpha\sql\sql_lex.h(27) : see declaration of 'sp_pcontext'
sp_rcontext.cpp
E:\mysql-5.0.2-alpha\sql\sp_pcontext.h(53) : warning C4099: 'sp_pcontext' : type name first seen using 'class' now seen using 'struct'
E:\mysql-5.0.2-alpha\sql\sql_lex.h(27) : see declaration of 'sp_pcontext'
4- Warnings for loss of data:
E:\mysql-5.0.2-alpha\sql\sql_view.cpp(738) : warning C4244: '=' : conversion from 'unsigned __int64' to 'unsigned char', possible loss of data
How to repeat:
Create the source distribution for Windows 5.0 BK and compile it with VC++.
Suggested fix:
see description