easy warnings fixed first

e:/vb_share/g/c++/ottd/openttd/src/aaa_template_gui_create.cpp:433:18: warning: unused variable 'mode' [-Wunused-variable]
e:/vb_share/g/c++/ottd/openttd/src/aaa_template_gui_main.cpp:508:17: warning: variable 'cost' set but not used [-Wunused-but-set-variable]
e:/vb_share/g/c++/ottd/openttd/src/aaa_template_gui_main.cpp:510:17: warning: variable 'cost2' set but not used [-Wunused-but-set-variable]
e:/vb_share/g/c++/ottd/openttd/src/aaa_template_gui_main.cpp:518:20: warning: unused variable 'ntv' [-Wunused-variable]
e:/vb_share/g/c++/ottd/openttd/src/aaa_template_vehicle_func.cpp:269:15: warning: variable 'sellc' set but not used [-Wunused-but-set-variable]
e:/vb_share/g/c++/ottd/openttd/src/aaa_template_vehicle_func.cpp:275:15: warning: variable 'sellc' set but not used [-Wunused-but-set-variable]
e:/vb_share/g/c++/ottd/openttd/src/articulated_vehicles.cpp:326:12: warning: unused variable 'eid' [-Wunused-variable]

	modified:   src/aaa_template_gui_create.cpp
	modified:   src/aaa_template_gui_main.cpp
	modified:   src/aaa_template_vehicle_func.cpp
	modified:   src/articulated_vehicles.cpp
more warnings fixed

e:/vb_share/g/c++/ottd/openttd/src/aaa_template_gui_main.cpp:648:42: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
Removed compiler option "-mno-cygwin" from config lib
Removed all instances of

g:/OpenTTD/openttd/src/aaa_template_vehicle_func.h:10:13: warning: 'REPLACEMENT_IN_PROGRESS' defined but not used [-Wunused-variable]
Removed all instances of testfunc()

Was somewhere in the middle of the main gui class and it was doing some template replacement.
But the call to it was in comments.
Fixed data comparison warnings

g:/OpenTTD/openttd/src/aaa_template_gui_replaceall.cpp:173:48: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
g:/OpenTTD/openttd/src/aaa_template_gui_replaceall.cpp:263:50: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
g:/OpenTTD/openttd/src/aaa_template_gui_replaceall.cpp:369:48: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
g:/OpenTTD/openttd/src/aaa_template_gui_replaceall.cpp:384:47: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
g:/OpenTTD/openttd/src/aaa_template_gui_replaceall.cpp:406:48: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
codeblocks project editor-setting
removed build logs from project
Merge commit '8f24075' into warnings
Fixed multiple definition of some command functions
Merge branch 'warnings' into tbtr
Added patch v0.4d

This one includes all changes needed to compile the original v0.4c against the newest trunk and has all warnings from the old code fixed.