Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > alt.os.development > #8249
| From | "Rod Pemberton" <boo@fasdfrewar.cdm> |
|---|---|
| Newsgroups | alt.os.development |
| Subject | Re: What form of executable or load module for your OS? |
| Date | 2015-06-24 22:31 -0400 |
| Organization | Aioe.org NNTP Server |
| Message-ID | <op.x0rlbhj1yfako5@localhost> (permalink) |
| References | <mme4i6$a6e$1@dont-email.me> |
On Wed, 24 Jun 2015 07:34:47 -0400, James Harris
<james.harris.1@gmail.com> wrote:
> If you have a working OS what form of executable does it load and
> execute, of if your OS is in development what form of executable are you
> thinking to support?
Are you saying my OS is not working simply because it can't load
and execute other code?
Tsk tsk ..
> First, for me, whatever format is used needs to be a form that can be
> constructed by existing build tools so that I can create modules in that
> form. Presumably you had or have the same issue, unless you made your
> own build tools.
I'm in the long, slow process of the latter ...
> Second, it needs to be a form that can be constructed without the
> toolchain building-in something specific to an existing OS (unless my OS
> is going to support that feature which is unlikely).
Hexdump.
unsigned char bin[]=
{
#include "dump.h"
}
dump.h
0x00,0x01,0x02, ...
0x00,0x01,0x02, ...
...
I'm just joking, but that can be used, although rudimentary.
You could even parse raw text hex if you wanted, e.g., A9143DE ...
If it's already an object, that's what the linker is for.
> I have been thinking of supporting multiple formats, as follows.
>
> Rather than linking at compile time I would prefer to have apps
> distributed as folders of object modules.
Uh. Would that mean you need a database to find them?
Or, do you intend to use/abuse the filesystem for that?
> So with that long explanation done the situation is that I am wondering
> what object formats and executable formats to use for apps.
Whatever works? ...
I.e., why lock-in to a format you might not want?
E.g., DJGPP is stuck with COFF since ELF wasn't a choice at first.
You should only really need one executable format.
> For your OS do you have any of these in mind or already working?
In mind? ...
Working? No.
> If so, just out of curiosity, how did you choose what
> formats to support?
The compiler chose it for me. I.e., DJGPP uses a COFF
variant for executables and objects. My original goal
wasn't an OS, but an environment which would load DJGPP
apps. I now have the start of that too, a non-OS environment
which can load DJGPP apps. The other compiler I was using
for my OS, OpenWatcom, I had no serious intention of
supporting executables from it. It generates code which
isn't relocatable for it's DPMI apps.
Rod Pemberton
--
It's time to put an end to gun violence!
Use a hammer ...
Back to alt.os.development | Previous | Next — Next in thread | Find similar | Unroll thread
Re: What form of executable or load module for your OS? "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-06-24 22:31 -0400
Re: What form of executable or load module for your OS? "James Harris" <james.harris.1@gmail.com> - 2015-07-01 10:33 +0100
Re: What form of executable or load module for your OS? "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-01 16:14 -0400
csiph-web