Thanks. I don't use windows, so I'll have to try crosscompiling in Code::Blocks as a project.
SvarDOS fan :: artificial "intelligence" bots - not a fan at all :: say NO to systemd :: is freeware a lie, when human freedom is a fundamental lie? :: f00ck €u!
cookertronwrote on 2026-03-12, 17:21:I've been using Microsoft Visual Studio Community 2026. This is the contents of the batch file I use to build Agent86: […] Show full quote
aVdwrote on 2026-03-12, 13:00:Hi, @cookertron,
How do you compile "agent86" v.0.19.3? This time it throws me a bunch of errors, while trying […] Show full quote
Hi, @cookertron,
How do you compile "agent86" v.0.19.3? This time it throws me a bunch of errors, while trying
1Microsoft (R) C/C++ Optimizing Compiler Version 19.50.35726 for x64 2Copyright (C) Microsoft Corporation. All rights reserved. 3 4main.cpp 5lexer.cpp 6symtab.cpp 7expr.cpp 8asm.cpp 9encoder.cpp 10decoder.cpp 11emitter.cpp 12jit.cpp 13dos.cpp 14kbd.cpp 15Generating Code... 16Microsoft (R) Incremental Linker Version 14.50.35726.0 17Copyright (C) Microsoft Corporation. All rights reserved. 18 19/out:agent86.exe 20main.obj 21lexer.obj 22symtab.obj 23expr.obj 24asm.obj 25encoder.obj 26decoder.obj 27emitter.obj 28jit.obj 29dos.obj 30kbd.obj
your build.bat deleted in repo actually works, and I can use v141_xp (i.e. v14.16) to build and it even works in XP.
(just jit.cpp needs to include intrin.h for building in older MSVC)
Hi, guys,
Finally compiled latest Agent86 by using Mingw-w64 and Code::Blocks's project with all the cpp-files added like in @cookertron's bat-file.
Also, as @roytam1 I had to add "#include <intrin.h>" line in "jit.cpp" file, due to error preventing normal compilation.
Now I have 32 and 64bit Agent86 windows executabels. Thank you!
SvarDOS fan :: artificial "intelligence" bots - not a fan at all :: say NO to systemd :: is freeware a lie, when human freedom is a fundamental lie? :: f00ck €u!
cookertronwrote on 2026-03-10, 23:53:DOS Notepad V1.1.0 broke because Claude Opus 4.6 couldn't get the 'unlimited' file size feature to work given the level of compl […] Show full quote
DOS Notepad V1.1.0 broke because Claude Opus 4.6 couldn't get the 'unlimited' file size feature to work given the level of complexity it was at that time. The emulator built into Agent86 was an interpreter which was painfully slow when taking into consideration all the instructions to just render the screen, so that system was scrapped. After Agent86's emulator was transformed into a JIT, the code executed in real-time, saving 2-3 minutes per execution. Even after that speed increase, V1.1.0 of DOS Notepad and many, many tokens, Notepad still refused to integrate the new system - Notepad V1.1.0 was laid to rest.
On to new beginnings. How was I supposed to have this massive feature if it was seemingly impossible to implement? I had the idea of starting with the feature and building round it. TEXTREAD (https://github.com/cookertron/TEXTREAD) was born, a text file reader for MS-DOS that could read files up to 32MB big! It works really well and is a standalone program if you care to try it - I couldn't stop there though. I wanted the text editor! Over the next two days myself and Claude built a working real piece table append-only add buffer text editor built on top of TEXTREAD. TEXTEDIT (https://github.com/cookertron/textedit) emerged like a butterfly from a cocoon 🤣. A fairly stark TUI with two shortcut keys, save and exit, and you could only open a file from the command line.
Built on top of the foundation. TEXTEDIT was a solid proof of concept Claude and I needed to move forward - the architecture was there, it just needed moving into the early 90s with a jazzy TUI wrapper. That was the easy part, but I soon started getting greedy. I wanted multi-document support. We built it but realised that the memory constraints of real-mode address space meant that only 3 documents could be open at once and no clipboard and no undo/redo. Was it worth it, just to have two extra documents open? I didn't think so - I'd rather have a single document, feature-rich text editor with large file support capable of running on an 8086 system.
So that's pretty much where we are. The multi-document monstrosity needs stripping back to when it was wrapped in the TUI so we can start adding in the features from DOS Notepad V1.1.0:
Tab support
Search with direction, selection, case sensitivity
Replace
Insert key support
Menu shortcuts
Copy & paste
Undo/Redo
and all the other little bits that made it
I wonder if there is "direct viewing mode" to view file in any size that DOS/file system supports?
aVdwrote on 2026-03-13, 06:34:Hi, guys,
Finally compiled latest Agent86 by using Mingw-w64 and Code::Blocks's project with all the cpp-files added like in @co […] Show full quote
Hi, guys,
Finally compiled latest Agent86 by using Mingw-w64 and Code::Blocks's project with all the cpp-files added like in @cookertron's bat-file.
Also, as @roytam1 I had to add "#include <intrin.h>" line in "jit.cpp" file, due to error preventing normal compilation.
Now I have 32 and 64bit Agent86 windows executabels. Thank you!
Excellent, well done!
I was going to try and compile it for Linux myself tonight as I have Ubuntu installed on a partition. If successful I'll include the Linux build strategy in Agent86 readme.
Asus P5A v1.06, Gigabyte GA-6BXDS, Soyo SY-5EMA (faulty), Viglen 486, Asus SP97-V
aVdwrote on 2026-03-13, 06:34:Hi, guys,
Finally compiled latest Agent86 by using Mingw-w64 and Code::Blocks's project with all the cpp-files added like in @co […] Show full quote
Hi, guys,
Finally compiled latest Agent86 by using Mingw-w64 and Code::Blocks's project with all the cpp-files added like in @cookertron's bat-file.
Also, as @roytam1 I had to add "#include <intrin.h>" line in "jit.cpp" file, due to error preventing normal compilation.
Now I have 32 and 64bit Agent86 windows executabels. Thank you!
for mingw-w64 (I'm using strawberry perl x64 here, comes with gcc-8.3.0), following command line generates working x64 agent86.exe without linking to libgcc/libstdc++/libwinpthread DLL:
I can't compile Agent86 executable for Linux without modifications to the code in "asm.cpp" file. In "canonicalizePath" function "_MAX_PATH" constant and "_fullpath" function are windows specific, so I have to replace "_MAX_PATH" with "PATH_MAX" from "limits.h", but I don't know suitable alternative for "_fullpath()" (possibly "realpath()" ?). Tried g++ and Clang compilers, and both throws errors due to these windows specific function and constant.
SvarDOS fan :: artificial "intelligence" bots - not a fan at all :: say NO to systemd :: is freeware a lie, when human freedom is a fundamental lie? :: f00ck €u!
I can't compile Agent86 executable for Linux without modifications to the code in "asm.cpp" file. In "canonicalizePath" function "_MAX_PATH" constant and "_fullpath" function are windows specific, so I have to replace "_MAX_PATH" with "PATH_MAX" from "limits.h", but I don't know suitable alternative for "_fullpath()" (possibly "realpath()" ?). Tried g++ and Clang compilers, and both throws errors due to these windows specific function and constant.
There's also an issue with the JIT and DOS calls, specifically FindFirst/FindNext which are handle with very Windows specific routines. In the Linux Agent86 those DOS calls are stubbed and will simply return "no more files". This means testing a file dialog box using the JIT will return an empty file list. Not good!
I'll create pure Linux source code, that'll be the best thing to do.
roytam1wrote on 2026-03-13, 12:00:for mingw-w64 (I'm using strawberry perl x64 here, comes with gcc-8.3.0), following command line generates working x64 agent86.e […] Show full quote
aVdwrote on 2026-03-13, 06:34:Hi, guys,
Finally compiled latest Agent86 by using Mingw-w64 and Code::Blocks's project with all the cpp-files added like in @co […] Show full quote
Hi, guys,
Finally compiled latest Agent86 by using Mingw-w64 and Code::Blocks's project with all the cpp-files added like in @cookertron's bat-file.
Also, as @roytam1 I had to add "#include <intrin.h>" line in "jit.cpp" file, due to error preventing normal compilation.
Now I have 32 and 64bit Agent86 windows executabels. Thank you!
for mingw-w64 (I'm using strawberry perl x64 here, comes with gcc-8.3.0), following command line generates working x64 agent86.exe without linking to libgcc/libstdc++/libwinpthread DLL:
cookertronwrote on 2026-03-13, 21:07:There's also an issue with the JIT and DOS calls, specifically FindFirst/FindNext which are handle with very Windows specific r […] Show full quote
I can't compile Agent86 executable for Linux without modifications to the code in "asm.cpp" file. In "canonicalizePath" function "_MAX_PATH" constant and "_fullpath" function are windows specific, so I have to replace "_MAX_PATH" with "PATH_MAX" from "limits.h", but I don't know suitable alternative for "_fullpath()" (possibly "realpath()" ?). Tried g++ and Clang compilers, and both throws errors due to these windows specific function and constant.
There's also an issue with the JIT and DOS calls, specifically FindFirst/FindNext which are handle with very Windows specific routines. In the Linux Agent86 those DOS calls are stubbed and will simply return "no more files". This means testing a file dialog box using the JIT will return an empty file list. Not good!
I'll create pure Linux source code, that'll be the best thing to do.
roytam1wrote on 2026-03-13, 12:00:for mingw-w64 (I'm using strawberry perl x64 here, comes with gcc-8.3.0), following command line generates working x64 agent86.e […] Show full quote
aVdwrote on 2026-03-13, 06:34:Hi, guys,
Finally compiled latest Agent86 by using Mingw-w64 and Code::Blocks's project with all the cpp-files added like in @co […] Show full quote
Hi, guys,
Finally compiled latest Agent86 by using Mingw-w64 and Code::Blocks's project with all the cpp-files added like in @cookertron's bat-file.
Also, as @roytam1 I had to add "#include <intrin.h>" line in "jit.cpp" file, due to error preventing normal compilation.
Now I have 32 and 64bit Agent86 windows executabels. Thank you!
for mingw-w64 (I'm using strawberry perl x64 here, comes with gcc-8.3.0), following command line generates working x64 agent86.exe without linking to libgcc/libstdc++/libwinpthread DLL:
Agent86 Linux executable added to repo (github:cookertron/Agent86)
Hi, @cookertron,
Just tried the prebuild 64bit Linux executable from your github repo and it gives me these errors:
1./agent86: /lib/x86_64-linux-gnu/libstdc++.so.6: version `GLIBCXX_3.4.32' not found (required by ./agent86) 2./agent86: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.38' not found (required by ./agent86)
I think this happens due to dynamically (non-statically) linked libraries.
SvarDOS fan :: artificial "intelligence" bots - not a fan at all :: say NO to systemd :: is freeware a lie, when human freedom is a fundamental lie? :: f00ck €u!
aVdwrote on 2026-03-14, 05:40:Hi, @cookertron,
Just tried the prebuild 64bit Linux executable from your github repo and it gives me these errors: […] Show full quote
Agent86 Linux executable added to repo (github:cookertron/Agent86)
Hi, @cookertron,
Just tried the prebuild 64bit Linux executable from your github repo and it gives me these errors:
1./agent86: /lib/x86_64-linux-gnu/libstdc++.so.6: version `GLIBCXX_3.4.32' not found (required by ./agent86) 2./agent86: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.38' not found (required by ./agent86)
I think this happens due to dynamically (non-statically) linked libraries.
Pure Linux source code in Github repo, including binary . DOS calls and dependencies issues fixed 😀
Asus P5A v1.06, Gigabyte GA-6BXDS, Soyo SY-5EMA (faulty), Viglen 486, Asus SP97-V
roytam1wrote on 2026-03-13, 12:00:for mingw-w64 (I'm using strawberry perl x64 here, comes with gcc-8.3.0), following command line generates working x64 agent86.e […] Show full quote
aVdwrote on 2026-03-13, 06:34:Hi, guys,
Finally compiled latest Agent86 by using Mingw-w64 and Code::Blocks's project with all the cpp-files added like in @co […] Show full quote
Hi, guys,
Finally compiled latest Agent86 by using Mingw-w64 and Code::Blocks's project with all the cpp-files added like in @cookertron's bat-file.
Also, as @roytam1 I had to add "#include <intrin.h>" line in "jit.cpp" file, due to error preventing normal compilation.
Now I have 32 and 64bit Agent86 windows executabels. Thank you!
for mingw-w64 (I'm using strawberry perl x64 here, comes with gcc-8.3.0), following command line generates working x64 agent86.exe without linking to libgcc/libstdc++/libwinpthread DLL:
Now I have to test the new Linux Agent86 compiler...
EDIT: Formating the post.
Last edited by aVd on 2026-03-14, 12:31. Edited 1 time in total.
SvarDOS fan :: artificial "intelligence" bots - not a fan at all :: say NO to systemd :: is freeware a lie, when human freedom is a fundamental lie? :: f00ck €u!
and extra: gcc-x86 compiled agent86 can work under real DOS when HX-DOS is loaded and run with `DPMILD32 agent86 ...`
Hi, @roytam1,
Nice find. I'll definitely try this trick in DOS.
Thanks!
SvarDOS fan :: artificial "intelligence" bots - not a fan at all :: say NO to systemd :: is freeware a lie, when human freedom is a fundamental lie? :: f00ck €u!
ALT-X for quit is not working (was mentioned earlier as well).
The left/right keys are not working in in the confirm boxes (Yes/No)
The replace function does only work from the cursor position. Not for the whole file (when selecting replace all)
Think it would be nice to do some extra menus. The Edit menu option should at least be split up in a Edit and Search. Also some extra lines in the menu could make it a bit nicer/cleaner.
You're not going to add an option to edit multiple files? If so it's unfortunately not usable for me as I really want the option to compare and copy/paste between files.
ALT-X for quit is not working (was mentioned earlier as well).
The left/right keys are not working in in the confirm boxes (Yes/No)
The replace function does only work from the cursor position. Not for the whole file (when selecting replace all)
Think it would be nice to do some extra menus. The Edit menu option should at least be split up in a Edit and Search. Also some extra lines in the menu could make it a bit nicer/cleaner.
You're not going to add an option to edit multiple files? If so it's unfortunately not usable for me as I really want the option to compare and copy/paste between files.
Unfortunately the conventional memory address space is too small to have multiple files as well as large document support, undo/redo, cut, copy and paste especially if there are other TSR programs running too. I wouldn't mind creating a 32-bit version with a DOS extender like DOS/4GW to add multiple documents but I'd like to get the get this real-mode version to a place I can say it's done before I move on.
I'll look into those other points you mentioned. Thank you for the feedback 😀
EDIT: Quit shortcut is ALT+Q not ALT-X. Is ALT-X the standard for applications?
Asus P5A v1.06, Gigabyte GA-6BXDS, Soyo SY-5EMA (faulty), Viglen 486, Asus SP97-V
Hi, @cookertron!
Nice to see there's a new improved version (with a new name).
I just wanted a modified version with default tab = 4 (8 seems like a "too much waste of space"), so I started over with compiling Agents86. Everything from this post is still valid and I managed to compile Agent86 with success.
Now I have TEDIT.COM (ver. 0.53) with default tab = 4 😀 I wish it has a side scrollbar.
I'll post later, if I find something wrong, that was not mentioned by @Yoghoo. Did <Left> and <Right> keys ever worked in dialog boxes?
P.S. I like the 16-bit real mode one file edit version. For me this is just a modern and better EDIT replacement.
SvarDOS fan :: artificial "intelligence" bots - not a fan at all :: say NO to systemd :: is freeware a lie, when human freedom is a fundamental lie? :: f00ck €u!
aVdwrote on 2026-03-25, 16:15:Hi, @cookertron!
Nice to see there's a new improved version (with a new name). […] Show full quote
Hi, @cookertron!
Nice to see there's a new improved version (with a new name).
I just wanted a modified version with default tab = 4 (8 seems like a "too much waste of space"), so I started over with compiling Agents86. Everything from this post is still valid and I managed to compile Agent86 with success.
Now I have TEDIT.COM (ver. 0.53) with default tab = 4 😀 I wish it has a side scrollbar.
I'll post later, if I find something wrong, that was not mentioned by @Yoghoo. Did <Left> and <Right> keys ever worked in dialog boxes?
P.S. I like the 16-bit real mode one file edit version. For me this is just a modern and better EDIT replacement.
The left-right to select YES|NO|CANCEL etc is fixed.
Replace All scans entire document now.
Now I have TEDIT.COM (ver. 0.53) with default tab = 4 😀
That's the beauty of open source 😀
Scrollbar I'll look into next. Thanks for the feedback 😀
EDIT: Scrollbars implemented
Last edited by cookertron on 2026-03-25, 17:25. Edited 1 time in total.
Asus P5A v1.06, Gigabyte GA-6BXDS, Soyo SY-5EMA (faulty), Viglen 486, Asus SP97-V