dmidecode-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [dmidecode] dmidecode for DOS?


From: Jean Delvare
Subject: Re: [dmidecode] dmidecode for DOS?
Date: Sat, 10 Sep 2005 23:18:30 +0200

Hi Ian,

[Ian Anderson]
> This may seem like a strange request in this day and age, but is it
> possible to compile dmidecode so that it will run under DOS?

Compiling it shouldn't be too hard, as I paid much attention to having a
very clean and standard-compliant code. The problem is that running it
will fail because there is no /dev/mem file nor equivalent under DOS.

So, in order to get dmidecode to run on DOS, one would need to rewrite
the mem_chunk() function in util.c to use a different memory access
method. I separated the code in such a way that only this function
should need to be modified. I'd guess this can be done relatively easily
in real mode by just doing a direct access to the memory and copying
data to a buffer. However, I've never written C code for DOS so I don't
really know how to do that, sorry.

> I have a DJGPP enviroment set up and did a quick, unsuccessful
> compile of it.  I am not a C programmer, so I will need help, if this
> is possible at all.

This is certainly possible, modulo my comments above. If you post the
errors you have, maybe we will be able to help you, but this is most
certainly a generic Unix C -> DJGPP issue, so someone with DJGPP
knowledge would probably be more helpful.

-- 
Jean Delvare




reply via email to

[Prev in Thread] Current Thread [Next in Thread]