mirror of
https://github.com/aaru-dps/fstester.git
synced 2025-12-16 19:24:39 +00:00
Implement DOS fstester.setter.
This commit is contained in:
966
setter/dos.c
966
setter/dos.c
File diff suppressed because it is too large
Load Diff
65
setter/dos.h
Executable file
65
setter/dos.h
Executable file
@@ -0,0 +1,65 @@
|
|||||||
|
/****************************************************************************
|
||||||
|
The Disc Image Chef
|
||||||
|
-----------------------------------------------------------------------------
|
||||||
|
|
||||||
|
Filename : dos.h
|
||||||
|
Author(s) : Natalia Portillo
|
||||||
|
|
||||||
|
Component : fstester.setter
|
||||||
|
|
||||||
|
--[ Description ] -----------------------------------------------------------
|
||||||
|
|
||||||
|
Contains DOS definitions
|
||||||
|
|
||||||
|
--[ License ] ---------------------------------------------------------------
|
||||||
|
This program is free software: you can redistribute it and/or modify
|
||||||
|
it under the terms of the GNU General Public License as
|
||||||
|
published by the Free Software Foundation, either version 3 of the
|
||||||
|
License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warraty of
|
||||||
|
MERCHANTIBILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
-----------------------------------------------------------------------------
|
||||||
|
Copyright (C) 2011-2018 Natalia Portillo
|
||||||
|
*****************************************************************************/
|
||||||
|
|
||||||
|
#if defined(__DOS__) || defined (MSDOS)
|
||||||
|
|
||||||
|
#ifndef DIC_FSTESTER_SETTER_DOS_H
|
||||||
|
#define DIC_FSTESTER_SETTER_DOS_H
|
||||||
|
|
||||||
|
#pragma pack(__push, 1)
|
||||||
|
|
||||||
|
typedef struct _Fat32FreeSpace
|
||||||
|
{
|
||||||
|
unsigned short size;
|
||||||
|
unsigned short version;
|
||||||
|
unsigned long sectorsPerCluster;
|
||||||
|
unsigned long bytesPerSector;
|
||||||
|
unsigned long freeClusters;
|
||||||
|
unsigned long totalClusters;
|
||||||
|
unsigned long freeSectors;
|
||||||
|
unsigned long totalSectors;
|
||||||
|
unsigned long freeUnits;
|
||||||
|
unsigned long totalUnits;
|
||||||
|
unsigned char reserved[8];
|
||||||
|
} Fat32FreeSpace;
|
||||||
|
|
||||||
|
#pragma pack(__pop)
|
||||||
|
|
||||||
|
#define YEAR(t) (((t & 0xFE00) >> 9) + 1980)
|
||||||
|
#define MONTH(t) ((t & 0x01E0) >> 5)
|
||||||
|
#define DAY(t) (t & 0x001F)
|
||||||
|
#define HOUR(t) ((t & 0xF800) >> 11)
|
||||||
|
#define MINUTE(t) ((t & 0x07E0) >> 5)
|
||||||
|
#define SECOND(t) ((t & 0x001F) << 1)
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
@@ -1,2 +1,2 @@
|
|||||||
FIL common.obj,dos.obj,main.obj
|
FIL dos.obj,main.obj
|
||||||
|
|
||||||
|
|||||||
@@ -1,9 +1,4 @@
|
|||||||
!define BLANK ""
|
!define BLANK ""
|
||||||
C:\dic\common.obj : C:\dic\common.c .AUTODEPEND
|
|
||||||
@C:
|
|
||||||
cd C:\dic
|
|
||||||
*wcc common.c -i="C:\WATCOM/h" -w4 -e25 -zq -od -d2 -bt=dos -fo=.obj -ml
|
|
||||||
|
|
||||||
C:\dic\dos.obj : C:\dic\dos.c .AUTODEPEND
|
C:\dic\dos.obj : C:\dic\dos.c .AUTODEPEND
|
||||||
@C:
|
@C:
|
||||||
cd C:\dic
|
cd C:\dic
|
||||||
@@ -14,11 +9,11 @@ C:\dic\main.obj : C:\dic\main.c .AUTODEPEND
|
|||||||
cd C:\dic
|
cd C:\dic
|
||||||
*wcc main.c -i="C:\WATCOM/h" -w4 -e25 -zq -od -d2 -bt=dos -fo=.obj -ml
|
*wcc main.c -i="C:\WATCOM/h" -w4 -e25 -zq -od -d2 -bt=dos -fo=.obj -ml
|
||||||
|
|
||||||
C:\dic\dos.exe : C:\dic\common.obj C:\dic\dos.obj C:\dic\main.obj C:\dic\con&
|
C:\dic\dos.exe : C:\dic\dos.obj C:\dic\main.obj C:\dic\consts.h C:\dic\defs.&
|
||||||
sts.h C:\dic\defs.h C:\dic\dosos2.h C:\dic\main.h .AUTODEPEND
|
h C:\dic\dos.h C:\dic\dosos2.h C:\dic\main.h .AUTODEPEND
|
||||||
@C:
|
@C:
|
||||||
cd C:\dic
|
cd C:\dic
|
||||||
@%write dos.lk1 FIL common.obj,dos.obj,main.obj
|
@%write dos.lk1 FIL dos.obj,main.obj
|
||||||
@%append dos.lk1
|
@%append dos.lk1
|
||||||
*wlink name dos d all SYS dos op m op maxe=25 op q op symf @dos.lk1
|
*wlink name dos d all sys dos op m op maxe=25 op q op symf @dos.lk1
|
||||||
|
|
||||||
|
|||||||
@@ -63,8 +63,8 @@ WVList
|
|||||||
0
|
0
|
||||||
15
|
15
|
||||||
MItem
|
MItem
|
||||||
8
|
5
|
||||||
common.c
|
dos.c
|
||||||
16
|
16
|
||||||
WString
|
WString
|
||||||
4
|
4
|
||||||
@@ -81,8 +81,8 @@ WVList
|
|||||||
0
|
0
|
||||||
19
|
19
|
||||||
MItem
|
MItem
|
||||||
5
|
6
|
||||||
dos.c
|
main.c
|
||||||
20
|
20
|
||||||
WString
|
WString
|
||||||
4
|
4
|
||||||
@@ -99,26 +99,26 @@ WVList
|
|||||||
0
|
0
|
||||||
23
|
23
|
||||||
MItem
|
MItem
|
||||||
6
|
3
|
||||||
main.c
|
*.h
|
||||||
24
|
24
|
||||||
WString
|
WString
|
||||||
4
|
3
|
||||||
COBJ
|
NIL
|
||||||
25
|
25
|
||||||
WVList
|
WVList
|
||||||
0
|
0
|
||||||
26
|
26
|
||||||
WVList
|
WVList
|
||||||
0
|
0
|
||||||
11
|
-1
|
||||||
1
|
1
|
||||||
1
|
1
|
||||||
0
|
0
|
||||||
27
|
27
|
||||||
MItem
|
MItem
|
||||||
3
|
8
|
||||||
*.h
|
consts.h
|
||||||
28
|
28
|
||||||
WString
|
WString
|
||||||
3
|
3
|
||||||
@@ -129,14 +129,14 @@ WVList
|
|||||||
30
|
30
|
||||||
WVList
|
WVList
|
||||||
0
|
0
|
||||||
-1
|
23
|
||||||
1
|
1
|
||||||
1
|
1
|
||||||
0
|
0
|
||||||
31
|
31
|
||||||
MItem
|
MItem
|
||||||
8
|
6
|
||||||
consts.h
|
defs.h
|
||||||
32
|
32
|
||||||
WString
|
WString
|
||||||
3
|
3
|
||||||
@@ -147,14 +147,14 @@ WVList
|
|||||||
34
|
34
|
||||||
WVList
|
WVList
|
||||||
0
|
0
|
||||||
27
|
23
|
||||||
1
|
1
|
||||||
1
|
1
|
||||||
0
|
0
|
||||||
35
|
35
|
||||||
MItem
|
MItem
|
||||||
6
|
5
|
||||||
defs.h
|
dos.h
|
||||||
36
|
36
|
||||||
WString
|
WString
|
||||||
3
|
3
|
||||||
@@ -165,7 +165,7 @@ WVList
|
|||||||
38
|
38
|
||||||
WVList
|
WVList
|
||||||
0
|
0
|
||||||
27
|
23
|
||||||
1
|
1
|
||||||
1
|
1
|
||||||
0
|
0
|
||||||
@@ -183,7 +183,7 @@ WVList
|
|||||||
42
|
42
|
||||||
WVList
|
WVList
|
||||||
0
|
0
|
||||||
27
|
23
|
||||||
1
|
1
|
||||||
1
|
1
|
||||||
0
|
0
|
||||||
@@ -201,7 +201,7 @@ WVList
|
|||||||
46
|
46
|
||||||
WVList
|
WVList
|
||||||
0
|
0
|
||||||
27
|
23
|
||||||
1
|
1
|
||||||
1
|
1
|
||||||
0
|
0
|
||||||
|
|||||||
@@ -4,8 +4,8 @@ projectIdent
|
|||||||
VpeMain
|
VpeMain
|
||||||
1
|
1
|
||||||
WRect
|
WRect
|
||||||
1504
|
1304
|
||||||
1490
|
460
|
||||||
7680
|
7680
|
||||||
9220
|
9220
|
||||||
2
|
2
|
||||||
@@ -39,5 +39,5 @@ WFileName
|
|||||||
7
|
7
|
||||||
dos.tgt
|
dos.tgt
|
||||||
0
|
0
|
||||||
7
|
1
|
||||||
7
|
7
|
||||||
|
|||||||
Reference in New Issue
Block a user