flat assembler
Message board for the users of flat assembler.
![]() Goto page Previous 1, 2 |
Author |
|
rugxulo
No, we're twins, and "that's all she wrote".
![]() Last edited by rugxulo on 20 Oct 2009, 07:14; edited 1 time in total |
|||
![]() |
|
Pinecone_
Awesome. But what do you mean "That's all she wrote"?
|
|||
![]() |
|
rugxulo
No more kids, i.e. there's only two of us.
Last edited by rugxulo on 20 Oct 2009, 07:14; edited 1 time in total |
|||
![]() |
|
Pinecone_
Major update: Complete rewrite, is now 100% bug free as far as I know.
The core is separated from OS-specific stuff, so sometime I'll give a go at porting it to linux. |
|||
![]() |
|
rugxulo
Cool beans! I was worried you either got swamped at school, lost interest, or were rewriting. Good job!
![]() P.S. Still doesn't work with chess apparently, but seems okay otherwise. (Even works under HX in DOSBox now, which is the main reason I complained about MSVCRT.DLL before. Well, actually, HX might have a bug or two as saluton.bef [never "Hello", only "Saluton"] and serpinsky.bef [hang?] don't work, but other stuff is fine. Those work fine on Vista, though.) Last edited by rugxulo on 20 Oct 2009, 07:14; edited 1 time in total |
|||
![]() |
|
Pinecone_
rugxulo wrote: Cool beans! I was worried you either got swamped at school, lost interest, or were rewriting. Good job! ![]() ![]() rugxulo wrote: P.S. Still doesn't work with chess apparently, but seems okay otherwise. (Even works under HX in DOSBox now, which is the main reason I complained about MSVCRT.DLL before. Well, actually, HX might have a bug or two as saluton.bef [never "Hello", only "Saluton"] and serpinsky.bef [hang?] don't work, but other stuff is fine. Those work fine on Vista, though.) ![]() If anyone looks at the source, any suggestions on how I could more easily make it portable are welcome (this is my first attempt at writing something with the intention of running it on more than windows and I haven't done much/any programming in assembly on other operating systems either, so don't have much of an idea what might've needed to be different) |
|||
![]() |
|
rugxulo
Pinecone_ wrote: If anyone looks at the source, any suggestions on how I could more easily make it portable are welcome (this is my first attempt at writing something with the intention of running it on more than windows and I haven't done much/any programming in assembly on other operating systems either, so don't have much of an idea what might've needed to be different) My only suggestion is to check out the Linux IsForth which uses syscalls (I think). Written in NASM, though but might help. ![]() |
|||
![]() |
|
rugxulo
Code: --- windows.as~ 2009-10-10 00:51:08 +0000 +++ windows.asm 2009-10-25 09:30:06 +0000 @@ -1,4 +1,4 @@ -FORMAT PE CONSOLE +FORMAT PE CONSOLE on 'befi-lfn.com' Entry _Main STD_OUTPUT_HANDLE = -11 Quote:
|
|||
![]() |
|
Pinecone_
What is that code for? I never seen any fasm code like that.
|
|||
![]() |
|
rugxulo
What, you mean the use of "on"? It just embeds a DOS program into the MZ stub of the PE executable. Even (usually OS/2) LE and LX have a DOS stub. Actually, to be honest, I think you can technically have no MZ DOS stub, but 99% of all people and compilers don't do that (not sure if that's due to OS or compiler bugs and limitations or what).
Quote:
Otherwise it just includes by default the useless default message: Quote:
Might as well use that space for something useful, no? ![]() |
|||
![]() |
|
Tomasz Grysztar
rugxulo wrote: Actually, to be honest, I think you can technically have no MZ DOS stub |
|||
![]() |
|
rugxulo
So here's what I should do to get back at all those anti-DOS programmers.
![]() ![]() Code: --- pedemo.asm 2009-02-28 16:33:26 +0000 +++ tony.asm 2009-10-29 10:36:06 +0000 @@ -1,7 +1,7 @@ ; Example of making 32-bit PE program as raw code and data -format PE GUI +format PE GUI on 'befi.com' entry start section '.text' code readable executable @@ -19,8 +19,8 @@ section '.data' data readable writeable - _caption db 'Win32 assembly program',0 - _message db 'Hello World!',0 + _caption db 'http://www.freedos.org',0 + _message db 'This program cannot be run in Win32 mode (try FreeDOS).',0 section '.idata' import data readable writeable Oh well, I thought it was funny. ![]() |
|||
![]() |
|
rugxulo
Tomasz Grysztar wrote:
Good to know although I don't think it would save much space. Then again, it's no less useless than telling you "sorry, we suck, can't run". ![]() Dual .EXEs were never heavily utilized, AFAIR, I only remember seeing a few examples (old old FASM versions [e.g. 1.40 seems to be, also UPX'd, heh], GNUish dual DOS + OS/2 1.x GNU textutils or fileutils, and some old old app that actually ran WIN.COM if started in DOS [ugh, now that was annoying, it didn't even ask!]). EDIT: I guess EMX and RSX/NT apps also utilize it, but they do a lot of other trickery too, so it's not really a self-contained all-in-one app or anything. |
|||
![]() |
|
revolution
rugxulo: "This program cannot be run in Win32 mode (try FreeDOS)."
![]() But ... I can run DOS in my win32 OS. Can you run win32 in your DOS OS? ![]() |
|||
![]() |
|
rugxulo
You can't run DOS in your Win32 unless you're still running Win9x. Everything else is partially emulated (NTVDM -> V86 mode plus heavily modified MS-DOS 5 and BIOS emulation).
As mentioned, the only decent partial Win32 emulation in DOS is HX. (WDOSX works with almost nothing, and DOSWin32 needs "MS-DOS 5" [DR-DOS didn't support it]). Too bad Japheth still never responded to why HX partially doesn't work with Pinecone_'s "new" interpreter. EDIT: Even QEMU or BOCHS or DOSBox under HX or something like GRUB4DOS booting a hard drive image file probably is mostly emulation, but if the host is DOS, I guess you're still technically running Win32 on DOS. |
|||
![]() |
|
Goto page Previous 1, 2 < Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2020, Tomasz Grysztar. Also on GitHub, YouTube, Twitter.
Website powered by rwasa.