https://www.cnblogs.com/cway/p/12793740.html 在sublime text3中编译汇编并高亮显示 https://blog.csdn.net/sinat_34260423/article/details/64133043 配置Sublime Text3编译汇编并高亮代码 https://blog.csdn.net/m0_49448277/article/details/116772403 汇编语言编辑器:Sublime text3 https://blog.csdn.net/duke56/article/details/9076279 我的第一个MASM32程序(MASM32环境配置) https://www.bbsmax.com/A/rV573b3E5P/ [原]Sublime Text3 搭建16位汇编环境(windows) https://www.cnblogs.com/tishion/archive/2010/09/09/1822438.html 简单OS开发前奏<一>EDITPLUS+MASM32搭建汇编开发环境(16位+32位)
- 首先安装masm32和sublime并配置好sublime插件x86 and x86 Assembly(masm32安装年代过于久远,不记得是否配置环境变量)
- 重点步骤,在masm32的bin文件下配置asm.bat,把路径改为自己安装的名称
@echo off
D:\masm32\bin\ml.exe /c %1.asm
D:\masm32\bin\link16.exe %1.obj %1,,,,,
D:\DOSBox-0.74\DOSBox.exe %1.exe
- sublime3下新建新的编译环境,然后按ctrl+b选择run_asm,博客园作者写得还是相对靠谱的,用得都是绝对路径,csdn的那篇配置文章没看见build.bat的定义(作个记录,具体配置语法细节我也不懂)
{
"cmd": ["D:\\masm32\\bin\\asm.bat", "$file_base_name"],
"file_regex": "^[ ]*File \"(...*?)\", line ([0-9]*)",
"selector": "source.asm",
"encoding":"cp936",
"variants":
[
{
"name": "Run_ASM",
"cmd": ["D:\\masm32\\bin\\asm.bat", "$file_base_name"],
"shell":true
}
]
}
- 编译过后自动会生成exe文件并调用dosbox
- 但我之前dosbox是配置过的,直接建议手动定位到文件夹里执行程序
{
"shell_cmd": "build.bat \"${file_path}/${file_base_name}\"",
"file_regex": "^(..[^:]*):([0-9]+):?([0-9]+)?:? (.*)$",
"selector": "source.asm,source.ASM",
"working_dir": "${file_path}",
"encoding": "gbk",
"variants":
[
{
"name": "Run",
"shell_cmd": "build.bat \"${file_path}/${file_base_name}\" && \"${file_path}/${file_base_name}\""
}
]
}
————————————————
版权声明:本文为CSDN博主「ToringZZZ」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/sinat_34260423/article/details/64133043
{
"cmd": ["D:\\DOSBox-0.74\\DOSBox","dos.bat"],
}
|