2
0
Эх сурвалжийг харах

* fixed compilation with -dUSE_SYSUTILS

git-svn-id: trunk@486 -
Jonas Maebe 20 жил өмнө
parent
commit
6a8eddb6ce

+ 1 - 3
compiler/comphook.pas

@@ -148,9 +148,7 @@ const
 implementation
 
   uses
-{$IFDEF USE_SYSUTILS}
-    SysUtils,
-{$ELSE USE_SYSUTILS}
+{$IFNDEF USE_SYSUTILS}
    dos,
 {$ENDIF USE_SYSUTILS}
    cutils

+ 0 - 3
compiler/compiler.pas

@@ -235,9 +235,6 @@ function Compile(const cmd:string):longint;
 implementation
 
 uses
-{$IFDEF USE_SYSUTILS}
-  SysUtils,
-{$ENDIF USE_SYSUTILS}
   aasmcpu;
 
 {$ifdef EXTDEBUG}

+ 9 - 1
compiler/globals.pas

@@ -684,7 +684,11 @@ implementation
             PathExists := true;
             exit;
           end;
+{$ifdef USE_SYSUTILS}
+        F := ExpandFileName(F);
+{$else USE_SYSUTILS}
         F := FExpand (F);
+{$endif USE_SYSUTILS}
         I := Pos (DriveSeparator, F);
         if (F [Length (F)] = DirectorySeparator)
                   and (((I = 0) and (Length (F) > 1)) or (I <> Length (F) - 1))
@@ -1150,7 +1154,11 @@ implementation
            currPath:= CurDirRelPath(source_info)
          else
           begin
+{$ifdef USE_SYSUTILS}
+            currPath:=FixPath(ExpandFileName(currpath),false);
+{$else USE_SYSUTILS}
             currPath:=FixPath(FExpand(currPath),false);
+{$endif USE_SYSUTILS}
             if (CurrentDir<>'') and (Copy(currPath,1,length(CurrentDir))=CurrentDir) then
              begin
 {$ifdef AMIGA}
@@ -1185,7 +1193,7 @@ implementation
                         end;
                     end;
                 until findnext(dir) <> 0;
-              end
+              end;
 {$ELSE USE_SYSUTILS}
             findfirst(prefix+'*',directory,dir);
             while doserror=0 do

+ 4 - 0
compiler/options.pas

@@ -1304,7 +1304,11 @@ begin
    Message(option_too_many_cfg_files);
 { open file }
   Message1(option_using_file,filename);
+{$ifdef USE_SYSUTILS}
+  assign(f,ExpandFileName(filename));
+{$else USE_SYSUTILS}
   assign(f,FExpand(filename));
+{$endif USE_SYsUTILS}
   {$I-}
   reset(f);
   {$I+}