Re: [Freedos-devel] FDI 1.2

2015-10-04 Thread Antony Gordon
Hi,

set /p is a Windows NT feature of CMD.EXE. It was not available in MS-DOS or 
Windows 9x. 

I even double checked on my Win98 VM and my Win ME VM before I wrote this. 
(Don’t ask why I have those. Just don’t). I get “Syntax Error” in both Windows 
98 and Windows ME.

It was nice of whomever wrote FreeCOM to include that Windows NT command 
interpreter function. I never tested it, but did they also include Delayed 
Expansion and IF (…) ELSE (…) and stuff like %~dpn0?

If the utilities are small as you say, then building a custom FreeCOM with them 
built in would allow your programs to pass the information without necessarily 
using the environment. 

So assuming your install script always works under FreeCOM, you have guarantees 
that set /p is there. Assuming it is running under Microsoft’s COMMAND.COM 
 on MS-DOS, you won’t have set /p and your script will 
fail at stage 7.


If your installer, still using the same batch file, was spawned in a custom 
command shell, (or FreeCOM), than you can guarantee what you need will be 
there. 

Regarding finding the master environment, in order for FreeDOS to maintain 
compatibility with MS-DOS and the all the abandoned DOS software out there, 
FreeDOS has to implement SysVars, commonly called the List of Lists. This list 
can’t change it’s structure because by doing so, many DOS applications won’t be 
able to run because a lot of them depend on this “undocumented” (by Microsoft) 
structure.

I’m not trying to pick a part your program, just trying to point you to a 
hopefully better implementation. Jim wants a batch file, you have these power 
tools, why not build them into the interpreter as internal commands? You 
implement the same code minus the startup functions and you can probably create 
a “V8” area in DOS memory where the utilities communicate since they are a part 
of the command shell. 

This precludes using the environment as you can create an in memory “structure” 
that they can manipulate.


--
___
Freedos-devel mailing list
Freedos-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-devel


Re: [Freedos-devel] FDI 1.2

2015-10-04 Thread Jerome E. Shidel Jr.

> On Oct 3, 2015, at 10:41 PM, Antony Gordon  wrote:
> 
> Hi,
> 
> What if you implemented V8 tools in a customized version of FreeCOM that 
> starts the setup process?

I sorry, but I think I am failing to understand what you are trying to achieve.

The standard FreeCom (COMMAND.COM) that ships with FreeDOS supports set /p. 
There
is no need for a specialized version. set /p is also supported in MS-DOS (I 
think starting with 7
that ships with Windows) 

Actually, 98% of the V8PT don’t even need DOS. Most of it is either directly 
talking to hardware
or using BIOS function calls. At present, most of it should run fine on the 
original 8086 if it has 
MS-DOS 1.00, EGA graphics and 3K free memory. However, some of the utilities 
(like vinfo) will
require DOS 5.00+ compatibility. 

Even without support for set /p, V8 works fine. You just cannot utilize some of 
it’s advanced 
features. This only causes 1 minor issue in the new installer batch, reading 
the cursor shape 
before hiding it. I say it is minor since using "vcursor small” will make it 
visible again and very
similar to the default cursor on most systems. Also, since after the install, 
you should reboot, 
there are really no real side effects from this issue.

The when the installer starts, it does not need support for set /p. If set /p 
is available, then
it will use it to save the cursor. If it is not, it will just assume it needs 
to use the small cursor
on exit. 

Once there is a partitioned and formatted hard disk drive, it initializes a 
installer temporary 
directory on drive C:. Thereby enabling I/O redirection and support for set /p. 
This is what 
occurs in STAGE006 of the installer. All of the stuff the installer does using 
V8PT in STAGE000 
through STAGE005 can get by just fine without set /p and I/O redirection. 

Things start to get complicated in STAGE007. And, for a working intelligent 
batch file based 
installer, I/O redirection and set /p become mandatory. This is fine since 
STAGE006 insures
that they are now functional.

> 
> The other option is to locate the master environment and write what you need 
> there.

There are 3 reasons why I won’t do it this way. 

First, If there are changes or differences 
in how DOS (FreeDOS, PC-DOS, MS-DOS….) it will cause serious issues. To my 
knowledge, there is no standardized way for a program to set a variable in it’s 
parent
environment under DOS. 

2nd, This would increase the size of many of the utilities in V8PT by 
approximately 1000 bytes.
This may not sound like much, but it would nearly double the size of things 
like vcursor.

Finally, it just isn’t necessary when batch files can utilize the set /p option 
to set data in the
environment.

>> On Oct 2, 2015, at 6:44 PM, Jerome Shidel  wrote:
>> 
>> 
>> On Oct 2, 2015, at 6:26 PM, Antony Gordon  wrote:
>> 
>>> Hey,
>>> 
>>> Couldn't you use 4DOS as the command shell during the installation process?
>>> 
>> Unfortunately, no. 
>> 
>> Some of the things that need to be done require I/O redirection (pipes and 
>> such) and using the output of some process to set the values of environment 
>> variables. This does not work using the 4DOS shell. 
>> 
>> V8Power Tools work fine. However, there is no way to make any use of many of 
>> their advanced features without this capability. 
>> 
>> For example, when using the standard command.com in FreeDOS and with MS-DOS 
>> (I think 7, with XP), you can do smithing like this to hide and restore the 
>> current cursor.
>> 
>> vcursor | set /p OldCursor=
>> vcursor hide
>> rem do stuff with hidden cursor
>> vcursor %OldCursor%
>> set OldCursor=
>> 
>> The cursor would be read, stored, hidden then restored to its original 
>> state. 
>> 
>>> On Oct 2, 2015 1:18 PM, "Jerome E. Shidel Jr."  wrote:
>>> Well, best guess. I’m 70% done with the installer.
>>> 
>>> Just need to port the backup creation code, the system files transfer stuff 
>>> and example package/zip installer portion.
>>> 
>>> But, the readme on using it for the OS release is mostly done. 
>>> 
>>> https://github.com/shidel/FDI/blob/master/README.md
>>> 
>>> FreeDOS 1.2 Installer Prototype
>>> 
>>> This project is for creating the FreeDOS 1.2+ installation kit based on 
>>> V8Power Tools batch file enhancement utilities.
>>> 
>>> File List
>>> 
>>> README.md   - This file.
>>> LICENSE - GNU GPL v2.
>>> mkFDI.bat   - Create the Floppy installation media.
>>> 
>>> Build files in INSFILES\
>>> 
>>> MKBIN.LSTList of files copyied from C:\FDOS\BIN\ to A:\FDSETUP\BIN\
>>> MKHELP.LST   List of files copyied from C:\FDOS\HELP\ to A:\FDSETUP\HELP\
>>> MKV8P.LSTList of files copyied from V8POWER\ to A:\FDSETUP\V8POWER\
>>> MKSETUP.LST  List of files copyied from INSFILES\ to A:\FDSETUP\SETUP\
>>> AUTOEXEC.BAT Copied as-is to A:\
>>> FDCONFIG.SYS Copied as-is to A:\
>>> SETUP.BATCopied as-is to A:\
>>> 
>>> What the installer does.
>>> 
>>> AUTOEXEC.BAT calls SETUP.BAT RECOVERY
>>> 
>>> SETUP.BAT
>>> 
>>> Tests for presence

Re: [Freedos-devel] XFTOOLS - exFAT access a la LTOOLS

2015-10-04 Thread Georg Potthast
If you set the device attribute word in the device driver header (bit 13) to 
flag a non-IBM disk (zero), you can access any disk or tape if the block 
device driver is written to support that. DOS will just specify the logical 
sector numbers it needs and does not care if this is stored in FAT format on 
the disk.

An ext2 driver would need to check the partitions on the disk and if it 
finds one or more ext formatted partitions start reading/writing there.

By the way, Linux now came up with the F2FS file system for flash disks and 
SD-cards. Maybe that is an alternative to exFAT for FreeDOS.

Regards

Georg

>
> Hi Eduardo and Georg,
>
> actually BLOCK drivers are only suitable for making
> FAT partitions on non-BIOS drives (e.g. USB) usable
> by DOS. For other filesystems, you would use other
> interfaces: CDEX / network redirector API, as used
> for ISO9660 CD/DVD and for VMWare in VMSMOUNT :-)
>
> Regards, Eric
>
>
>
>
>
> 


--
___
Freedos-devel mailing list
Freedos-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-devel