Browse Source

+ typinfo is now also in the makefile for go32v2
+ sysutils.filetruncate for go32v2

florian 26 years ago
parent
commit
befb0f2725
2 changed files with 21 additions and 3 deletions
  1. 6 2
      rtl/go32v2/Makefile
  2. 15 1
      rtl/go32v2/filutil.inc

+ 6 - 2
rtl/go32v2/Makefile

@@ -80,7 +80,7 @@ OBJECTS=strings go32 initc \
 	dpmiexcp profile dxeload emu387 \
 	dos crt objects printer \
         objpas sysutils \
-	cpu mmx msmouse getopts heaptrc graph
+        cpu mmx msmouse getopts heaptrc graph typinfo
 
 LOADERS=prt0 exceptn fpu
 
@@ -260,7 +260,11 @@ include $(CFG)/makefile.def
 
 #
 # $Log$
-# Revision 1.5  1999-01-21 11:54:35  peter
+# Revision 1.6  1999-02-09 17:16:58  florian
+#   + typinfo is now also in the makefile for go32v2
+#   + sysutils.filetruncate for go32v2
+#
+# Revision 1.5  1999/01/21 11:54:35  peter
 #   * renamed mouse->msmouse to resolve conflict with the api mouse unit
 #
 # Revision 1.4  1999/01/15 11:47:16  peter

+ 15 - 1
rtl/go32v2/filutil.inc

@@ -123,7 +123,17 @@ RealIntr($21, Regs);
 end;
 
 Function FileTruncate (Handle,Size: Longint) : boolean;
+var
+  regs : trealregs;
 begin
+  FileSeek(Handle,Size,0);
+  Regs.realecx := 0;
+  Regs.realedx := tb_offset;
+  Regs.ds := tb_segment;
+  Regs.ebx := Handle;
+  Regs.eax:=$4000;
+  RealIntr($21, Regs);
+  FileTruncate:=(regs.realflags and carryflag)=0;
 end;
 
 Function FileAge (Const FileName : String): Longint;
@@ -324,7 +334,11 @@ end;
 
 {
   $Log$
-  Revision 1.2  1999-02-03 11:42:31  michael
+  Revision 1.3  1999-02-09 17:16:59  florian
+    + typinfo is now also in the makefile for go32v2
+    + sysutils.filetruncate for go32v2
+
+  Revision 1.2  1999/02/03 11:42:31  michael
   + Added filetruncate
 
   Revision 1.1  1998/12/21 13:07:02  peter