I want to set a breakpoint at 0x7c00 when I run bochsdbg.
I don't want to type these two commands my myself everytime.
b 0x7c00
c
How to do it in bochsrc.txt?
Thank you~
How about using magic breakpoint? Add magic_break: enabled=1 to your bochsrc file, and then add xchg bx, bx to where you wanna set breakpoint in the asm file.
you may create a file in same directory you are running bochs and entries like(brkfile.txt):
pb 0x7c00
lb 0x80100000
once you start bochs you may source file by typing:
source brkfile
Better would be to compile bochs with internal debugger if you working on bootload. Internal debugger would come in handy specifically for bootloader or osdev
You also may write down all the command in rc-file and run Bochs as following
bochs -f .bochsrc.32.obj -dbglog $loghome/$log.log -rc ./debug.rc
The rc-file may contain your debugger commands to execute like loading symbols, setting breakpoints or watching memory locations.
Related
why I am in this trying to figure out what I done wrong mess. As was mentioned before I deleted and started over. This is a fresh install of windows 11 about 4 days now. I did add the folders to my system path. And do not get the program that #1 back up company that starts with an A and ends with an S. When their file goes corrupt and it's like pretty much oh well. Not much. But here we go. Look at the photos. I am going to try and format this again. How the hell do you know what line this thing is bitching about. There is only 6 lines of code in this thing. The rest is my troubleshooting. ~~~
local x = math.pi
local r = 6
local Area2 = (x * r ^ 2)
local Area = Area2-Area2%0.01
print(Area = ..Area.. Oh Yea)
* Executing task in folder MA_scripts: lua54 c:\Users\iSpeedyG\OneDrive\Documents\MA_scripts\LuaUdemy\4_Variables_Expressions\circleArea.lua
Area = 113.09 Oh Yea
* Terminal will be reused by tasks, press any key to close it.
**"DEFAULT COMMAND PROMPT above"** ALL THIS IN VSCODE
------------------------------------------------------------
* Executing task in folder MA_scripts: lua54 c:\Users\iSpeedyG\OneDrive\Documents\MA_scripts\LuaUdemy\4_Variables_Expressions\circleArea.lua
C:\lua\lua54.exe: cannot open c:UsersiSpeedyGOneDriveDocumentsMA_scriptsLuaUdemy4_Variables_ExpressionscircleArea.lua: No such file or directory
* The terminal process C:\Program Files\Git\bin\bash.exe --login, -c, lua54 c:\Users\iSpeedyG\OneDrive\Documents\MA_scripts\LuaUdemy\4_Variables_Expressions\circleArea.lua terminated with exit code: 1.
* Terminal will be reused by tasks, press any key to close it.
**"DEFAULT BASH PROMPT above"**
----------------------------------------------------------------
Next I added a file all the way in my c:\lua called just checking.lua. 1 line of code
1. print(Trying to figure out why i cannot run a lua from cmd line. thinking it has someinthing to do with my docs folder now in one drive.)
* Executing task in folder MA_scripts: lua54 c:\lua\justchecking.lua
C:\lua\lua54.exe: cannot open c:luajustchecking.lua: No such file or directory
* The terminal process C:\Program Files\Git\bin\bash.exe --login, -c, lua54 c:\lua\justchecking.lua terminated with exit code: 1.
* Terminal will be reused by tasks, press any key to close it.
**"DEFAULT BASH PROMPT above"** ```FROM BEFORE DIDNT CHANGE IT```
-----------------------------------------------------------------
* Executing task in folder MA_scripts: lua54 c:\lua\justchecking.lua
```*Trying to figure out why i cannot run a lua from cmd line. thinking it has someinthing to do with my docs folder now on one drive."*```
* Terminal will be reused by tasks, press any key to close it.
**"DEFAULT COMMAND PROMPT above"** ```*"THESE FOUR above WERE WITH CTRL+SHIFT+B -->Terminal Menu--run, build, task"*```
---------------------------------------------------------------------
```"NOW JUST GOING TO TYPE THE COMMAND IN BOTH FROM PROMPT AND THEN LUA54 NOTE EVEN CHANGED DIRECTORY TO WHERE THE FILE IS DEFAULT FOLDER IS ACTUALLY SET TO MA_SCRIPTS SET FROM LOADED WORKSPACE"```
c:\lua>lua54
Lua 5.4.2 Copyright (C) 1994-2020 Lua.org, PUC-Rio
lua justchecking.lua
stdin:1: syntax error near justchecking
justchecking.lua
stdin:1: attempt to index a nil value (global justchecking)
stack traceback:
stdin:1: in main chunk
[C]: in ?
os.exit()
c:\lua>
**"DEFAULT COMMAND PROMPT above"**
-------------------------------------------------------------------
iSpeedyG#iSpeedyG-PC MINGW64 ~/OneDrive/Documents/MA_scripts
$ cd c:lua
iSpeedyG#iSpeedyG-PC MINGW64 /c/lua
$ dir
justchecking.lua lua54.dll lua54.exe luac54.exe wlua54.exe
iSpeedyG#iSpeedyG-PC MINGW64 /c/lua
$ lua justchecking.lua
bash: lua: command not found
iSpeedyG#iSpeedyG-PC MINGW64 /c/lua
$ justchecking.lua
/c/lua/justchecking.lua: line 1: syntax error near unexpected token Trying to figure out why i cannot run a lua from cmd line. thinking it has someinthing to do with my docs folder now in one drive.
/c/lua/justchecking.lua: line 1: print(Trying to figure out why i cannot run a lua from cmd line. thinking it has someinthing to do with my docs folder now in one drive.)
iSpeedyG#iSpeedyG-PC MINGW64 /c/lua
$
**"DEFAULT BASH PROMPT abpve"**
-------------------------------------------------------------------
I have no understanding what happened here. I dont know where I screwed up the path on install. I only created the just checking thing because that was where I placed the Binaries in the beginning right at C:\ but MA_Scripts is in my documents folder and notice when I put it in OneNote it politely just moved the folder to the cloud. Going to see if I can attach a photo of my enviroments. I tried to show as much information as I can. I am running through a course online and tried to do
The run from command line like he does and thats when I found this issue out. I hope it is something simple. I am pretty new to this whole thing and have been on a roller-coaster for a few months hence the reformat and new windows the other day. Thats a longer story. On an added issue at 1st CTRL+L used to select the line. Now it doesnt after I turned sync with github account on. I dont even know where to look. Thanks in advance. There are numbers in front of the code they just dont want to copy for some reason.
[Picture of all of this I have pasted][1]
[picture of my PATH][2]
[1]: https://i.stack.imgur.com/YWgZF.png
[2]: https://i.stack.imgur.com/fztGU.png
I try to use julia-1.6 with VScode, but I cannot find a path to the executable.
When I try to change the working directory via the julia prompt to the executable, I get an error message saying it's not a directory:
julia> cd("/Users/jjdegruijter/bin/julia")
Can anybody tell how to do it properly?
To get the path to your Julia executable, from the REPL, do:
joinpath(Sys.BINDIR, "julia")
You can start a REPL by just running julia from the terminal, or by pressing Alt-J Alt-O in VS Code (you can also instead type Ctrl-Shift-P, then choose Julia: Start REPL from that list).
Or, you can also directly run the above command from the terminal without starting a REPL: julia -e 'println(joinpath(Sys.BINDIR, "julia"))'.
If you just want to change working directory to the directory containing the executable (though I'm not sure why you'd want that here):
cd(Sys.BINDIR)
I'm currently trying to get my hands dirty with Erlang. Also, in the (zsh) shell, I have got accustomed to using vi mode for line editing (set -o vi).
So: Is there a way to make the Erlang interpreter use more vi-like keybindings?
Yes! Just call it as
rlwrap erl -oldshell
NOTE: you may need to install rlwrap (readline wrapper) and adjust your .inputrc (set editing-mode vi)
No!
Well you could write your own line edit module and use that.
I'm looking for a way to write the standard output of my nmake call to a specified file. I tried something like "nmake target > file.log", but this won't work. Moreover I call multiple nmakes from within my MAKEFILE and may use multiple log-files to keep track of the output. I've only found the nmake option to write errors to a file but what's about the standard output.
Is there a simple way to do that (in Windows)?
#Cheeso
I've tried to built simple example and noticed that it doesn't work for me because the MAKEFILE must running in elevated mode. Consider a makefile like this:
default:
REM Test
and a batch-file like this:
cd /d "%~dp0"
nmake output.log
pause
When running the batch-file as administrator it doesn't redirect the stdout to my file and returns an error.
jom is really picky, and it's made based on nmake. Since that's the case, we're probably dealing with the same pickiness.
This works : jom -j 8 >> build.log
While this doesn't work : jom -j 8>>build.log
Add some whitespace, and you should be good to go. This was incredibly annoying for me too with Qt 5.6.1-1. I even tried using Powershell transcripts, but that ended up being a complete bust.
I am running wireshark build on linux. I get a crash,while doing some activities. A core dump is also being generated. But,when i give the following command
gdb ./wireshark core.
It says,file format not recognized. Also,when i do a
cat on "./wireshark",it seems to be some kind of script.
so how to analyze core dumps?
Check the script to see what is the actual wireshark binary being run.
gdb is good for coredump analysis.
when i do a cat on "./wireshark",it seems to be some kind of script.
Probably because you've built Wireshark from source in that directory, in which case it is a script (generated by libtool as a wrapper script).
What you need to do, instead of
gdb ./wireshark core`
is
./libtool --mode=execute gdb ./wireshark core
which will do the right magic to run GDB on the actual executable rather than on the script (and to pass it the right magic to find the shared libraries in your build directory).