At 02:36 PM 10/9/2005 +0400, Arkady V.Belousov wrote:
>> And how this should be look? Drivers doesn't return errorlevels,
>>whereas INSTALL= executed after DEVICE=.
MD> Perhaps you could have it conditional on a register return value from an
MD> application,
Even if I introduce new interface, then it will be useful only for new
drivers. It will be useless for all existing drivers.
Wrong. It will be useful for _everything_:
CONFIG.SYS:
; CHECK386 program returns AL nonzero if 386+ level chip found
%IF CHECK386 DEVICE=C:\WHATEVER\PATH\HIMEM.EXE
%IF CHECK386 DEVICE=EMM386
; CHECK286 program returns nonzero if 286-level chip found
%IF CHECK286 DEVICE=FDXMS286
; ISFLASH program detects USB flash driver presence with nonzero return
%IF ISFLASH DEVICE=USBASPI.SYS
%IF ISFLASH DEVICE=DI10000DI.SYS
; ISVIDECD program detects whether CD needs VIDE driver
%IF ISVIDECD DEVICE=VIDE-CDD.SYS
; otherwise try another generic driver
%IFNOT ISVIDECD DEVICE=OAKCDROM.SYS
; if known broken BIOS fails critical operations, load workaround driver
%IF DETFAIL DEVICE=FIXBIOS.SYS
The actual %IF and %IFNOT were arbitrarily chosen as the conditional
commands, of course.
If you want to get fancy, you allow stacking multiple conditionals per
line, e.g. %IFNOT CHECK386 %IFNOT CHECK286 DEVICE=<lame 8086 memory
manager>. As long as you're not spreading out conditionals along multiple
lines with IF/ELSE/ENDIF -- a behavior which seems much more complicated
and nasty to implement -- it could be a simple parse loop added to the
original conditional.
-------------------------------------------------------
This SF.Net email is sponsored by:
Power Architecture Resource Center: Free content, downloads, discussions,
and more. http://solutions.newsforge.com/ibmarch.tmpl
_______________________________________________
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user