mysql内核 innodb存储引警(卷1)配书 用VS 2003 编绎 mysql-3.23.49 源代码
作者网址:http://www.innomysql.net/
1.旧版 mysql-3.23.49-win-src.zip 下载 (科学上网络下载配书源代码) 或者 作者网盘 http://pan.baidu.com/s/1bnqK2dx
http://live.dadanini.at/mysql/downloads_html/mysql-3.23.html
相关资料: 何登成 :http://vdisk.weibo.com/u/2216172320
2.打开工程 mysql.sln
error 1:
正在创建临时文件“e:\mysql-3.23.49BAK\strings\debug\BAT000001.bat”,其内容为
[
@echo off
ml /Cx /nologo /DDOS386 /DM_I386 /Zm /coff /c /Fo ".\debug"\"strxmov".obj "e:\mysql-3.23.49BAK\strings\strxmov.asm" if errorlevel goto VCReportError
goto VCEnd
:VCReportError
echo Project : error PRJ0019: 工具从"正在执行自定义生成步骤"
exit
:VCEnd
]
正在创建命令行“"e:\mysql-3.23.49BAK\strings\debug\BAT000001.bat"”
正在创建临时文件“e:\mysql-3.23.49BAK\strings\debug\BAT000002.bat”,其内容为
[
@echo off
ml /Cx /nologo /DDOS386 /DM_I386 /Zm /coff /c /Fo ".\debug"\"strings".obj "e:\mysql-3.23.49BAK\strings\strings.asm" if errorlevel goto VCReportError
goto VCEnd
:VCReportError
echo Project : error PRJ0019: 工具从"正在执行自定义生成步骤"
exit
:VCEnd
]
正在创建命令行“"e:\mysql-3.23.49BAK\strings\debug\BAT000002.bat"”
修改E:\mysql-3.23.49\strings 下的 strings.vcproj
<File
RelativePath="Strxmov.asm">
<FileConfiguration
Name="Release|Win32">
<Tool
Name="VCCustomBuildTool"
CommandLine="ml /Cx /nologo /DDOS386 /DM_I386 /Zm /coff /c /Fo .\debug\Strxmov.obj "$(InputPath)"
"
Outputs="$(OutDir)\$(InputName).obj"/>
</FileConfiguration>
<FileConfiguration
Name="Debug|Win32">
<Tool
Name="VCCustomBuildTool"
CommandLine="ml /Cx /nologo /DDOS386 /DM_I386 /Zm /coff /c /Fo .\debug\Strxmov.obj "$(InputPath)"
"
Outputs="$(OutDir)\$(InputName).obj"/>
</FileConfiguration>
</File>
<File
RelativePath="Strings.asm">
<FileConfiguration
Name="Release|Win32">
<Tool
Name="VCCustomBuildTool"
CommandLine="ml /Cx /nologo /DDOS386 /DM_I386 /Zm /coff /c /Fo .\debug\strings.obj "$(InputPath)"
"
Outputs="$(OutDir)\$(InputName).obj"/>
</FileConfiguration>
<FileConfiguration
Name="Debug|Win32">
<Tool
Name="VCCustomBuildTool"
CommandLine="ml /Cx /nologo /DDOS386 /DM_I386 /Zm /coff /c /Fo .\debug\strings.obj "$(InputPath)"
"
Outputs="$(OutDir)\$(InputName).obj"/>
</FileConfiguration>
</File>
error 2:
正在编译...
cxx_txn.cpp
../bdb\build_win32\db_config.h() : fatal error C1083: 无法打开包含文件:“iostream.h”: No such file or directory
cxx_table.cpp
../bdb\build_win32\db_config.h() : fatal error C1083: 无法打开包含文件:“iostream.h”: No such file or directory
cxx_mpool.cpp
../bdb\build_win32\db_config.h() : fatal error C1083: 无法打开包含文件:“iostream.h”: No such file or directory
cxx_log.cpp
../bdb\build_win32\db_config.h() : fatal error C1083: 无法打开包含文件:“iostream.h”: No such file or directory
cxx_lock.cpp
../bdb\build_win32\db_config.h() : fatal error C1083: 无法打开包含文件:“iostream.h”: No such file or directory
cxx_except.cpp
../bdb\build_win32\db_config.h() : fatal error C1083: 无法打开包含文件:“iostream.h”: No such file or directory
cxx_app.cpp
../bdb\build_win32\db_config.h() : fatal error C1083: 无法打开包含文件:“iostream.h”: No such file or directory
在 E:\mysql-3.23.49\bdb\build_win32\下找到db_config.h
修改db_config.h 第218行 修改为
#include <iostream>
using namespace std;
error 3
cxx_txn.cpp
../bdb\include\db_cxx.h(52) : fatal error C1083: 无法打开包含文件:“iostream.h”: No such file or directory
cxx_table.cpp
../bdb\include\db_cxx.h(52) : fatal error C1083: 无法打开包含文件:“iostream.h”: No such file or directory
cxx_mpool.cpp
../bdb\include\db_cxx.h(52) : fatal error C1083: 无法打开包含文件:“iostream.h”: No such file or directory
cxx_log.cpp
../bdb\include\db_cxx.h(52) : fatal error C1083: 无法打开包含文件:“iostream.h”: No such file or directory
cxx_lock.cpp
../bdb\include\db_cxx.h(52) : fatal error C1083: 无法打开包含文件:“iostream.h”: No such file or directory
cxx_except.cpp
../bdb\include\db_cxx.h(52) : fatal error C1083: 无法打开包含文件:“iostream.h”: No such file or directory
cxx_app.cpp
../bdb\include\db_cxx.h(52) : fatal error C1083: 无法打开包含文件:“iostream.h”: No such file or directory
在E:\mysql-3.23.49\bdb\include下找到 db_cxx.h, 定位到52行修改为
#include <iostream>
using namespace std;
error 4
LINK : fatal error LNK1181: 无法打开输入文件“mysqlclient.lib”
生成日志保存在“file://e:\mysql-3.23.49\client\mysqlcheck___Win32_Release\BuildLog.htm”中 mysqlcheck - 1 错误,0 警告
方法 .在选择 mysqlcheck 项目,右击选择 属性 -》常规-》附加库目录 加入 ..\lib_debug\目录
error 5 库冲突与函数引用
解决方法:
3.调试MYSQL
1.mysqld --debug --standalone --console(CMD 窗口不能关,否则就非正常退去了)
2.打开VS 2003 ,打开mysql.sln
3.在VS 2003中设定想要设定的断点
4.工具->调试->附加到进程->选择 mysqld (本地native)
5.mysql -u root 在这个窗口中 执行SQL命令,VS 2003会在源码中中断到相关细节,进而进行动态调试
6.mysqladmin shutdown -u root //调试完毕后关闭mysqld
mysql 跟踪文件:e:\mysqld.trace
c:\my.cnf
[mysqld] basedir=E:\mysql-3.23.
datadir=E:\mysql-3.23.\data
innodb_data_home_dir=E:\mysql-3.23.\data
innodb_data_file_path=ibdata1:30M
最新文章
- C#获取CPU占用率、内存占用、磁盘占用、进程信息
- 【MySQL】函数IFNULL、设置默认时间
- webmagic 增量爬取
- OC基础--结构体 枚举做类成员属性
- php 执行的目录到新的 directory 目录中
- 查看perl及其模块
- apache在windows上开启gzip的方法
- Android扫码二维码、美女瀑布流、知乎网易音乐、动画源码等
- Go语言极速入门手册
- Python strip()与lstrip()、rstrip()
- jmeter元素
- Remote debugger is in a background tab which may cause apps to perform slowly. Fix this by foregrounding the tab (or opening it in a separate window).
- webpack 非严格模式设置 npm i babel-plugin-transform-remove-strict-mode
- Win10系统的SurfacePro4如何重装系统-1 SurfacePro专用的PE
- 洛谷试炼场-简单数学问题-P1403 [AHOI2005]-因数
- 出于性能考虑,C语言自动地以传地址的方式将数组传递给被调函数 const 编译错误 最小权限原则
- debian 配置linuxptp 软件时间戳
- mysql默认8小时连接断开机制解决
- CSS快速入门-前端布局1(抽屉)
- C# 谁改了我的代码