Intended audience:Students at the East University Computer college senior are designing the Operating System Course (other students should pass low-altitude)
Operating System Course Design Kernel compilation and WinDbg running batch files, Help you work better!
DownloadFileBefore, Please carefully read the following instructions
Purpose:1. Kernel compilation command line integration; 2. Command Line integration started by WinDbg (you do not need to knock so many command lines every time ~~)
Before running:1. Install the Virtual Machine and port configuration OK. 2. Install WinDbg. 3. Complete WRK source code deployment.
Source code:
Run!
: Author
: Time: 2010.9.1
: Mail: Kingpro@live.cn
: Website: http://kingpro.cnblogs.com
: Copyright: Free Copy
: This batch of processing files is mainly used for wrk compilation and windbg startup of the host machine in this operating system experiment.
: These two operations are complex, so they are made into batch files for simple calls.
: Modify the following basic parameters to suit your environment
@ Echo off
: Parameter Modification starts.
: Modify the root directory of WRK according to the actual directory
Set wrk = D: \ ftp \ binary \ OS \ wrk
: The operating system architecture is changed based on your system architecture [x86 | amd64]
Set arch = x86
: The environment variables do not need to be modified.
Set path = % wrk % \ tools \ % arch %; % path %
: The root directory of WinDebug is modified according to the actual directory.
Set wdbg = C: \ WinDDK \ 7600.16385.1 \ Debuggers
: Do not modify the WinDebug startup parameters.
Set windbgargs =-k com: pipe, port =\\. \ PIPE \ debug, resets = 0, reconnect
: You do not need to modify system environment parameters.
Set _ nt_symbol_path = % wrk % \ base \ ntos \ build \ exe; % wrk % \ ws03sp1hals \ x86 \ halacpim
: Parameter Modification ended
Color F1
Echo Author: pee fragment drunk (kingpro@live.cn)
Echo free copy \ (^ o ^)/2010.9.1
Echo -------------------------------------------------------------------------------
Echo base parameters:
Echo source code and tools path: % wrk %
Echo System Generator TOR: % arch %
Echo windebug path: % wdbg %
Echo windebug ARGs: % windbgargs %
Echo -------------------------------------------------------------------------------
Echo if all the parameters above are correct
Echo Press Y to continue
Echo else press n to close and edit this bat file
: Check
Set/p cho = [Y, N]
If % cho % equ N goto End
If % cho % equ n goto End
If % cho % equ Y goto Choices
If % cho % equ y goto Choices
Echo Error Choice
Goto Check
: Choices
Echo -------------------------------------------------------------------------------
Set/p cho = Build Kernel, Press B; Run WinDbg, Press R; Exit, Press E [B, R, E]?
If % cho % equ E goto End
If % cho % equ e goto End
If % cho % equ R goto WinDbg
If % cho % equ r goto WinDbg
If % cho % equ B goto BuildKernel
If % cho % equ B goto BuildKernel
Echo Error Choice
Goto Choices
: BuildKernel
Cd % wrk % \ base \ ntos
Echo Building Kernel...
Nmake-nologo % arch % =
Echo Build Complete
Goto Choices
: WinDbg
% Wdbg % \ windbg.exe % windbgargs %
Goto Choices
: End
After downloading to the batch file, right-click bat and modify the variable settings in the first few rows. the variables that need to be set include:
1. wrk source code root directory
2. arch system architecture, generally x86, unless you are an AMD64-bit System
3. installation directory of wdbg WinDbg
Save the modification. Double-click to run the task. If any problem occurs, try to solve the problem or contact me.
Download: Run.rar