summaryrefslogtreecommitdiff
path: root/ide
diff options
context:
space:
mode:
authorkaroly <karoly@3ad0048d-3df7-0310-abae-a5850022a9f2>2008-10-24 17:44:04 +0000
committerkaroly <karoly@3ad0048d-3df7-0310-abae-a5850022a9f2>2008-10-24 17:44:04 +0000
commit0e9f7b5170bdc6d53a163975b41f451ae800e5ff (patch)
treecc29e5bccd2610ec55b82ec38cdd1a6d3b07d97f /ide
parent89c6107e1647b4ceb7f66e8c347f757b12323bbd (diff)
downloadfpc-0e9f7b5170bdc6d53a163975b41f451ae800e5ff.tar.gz
+ minor IDE tweaks
* define Amiga and MorphOS as FSCaseInsensitve systems * get EOL and DirSep from System unit, and do not redefine it with tons of $ifdefs * for temp files, use T: on Amiga and MorphOS git-svn-id: http://svn.freepascal.org/svn/fpc/trunk@11971 3ad0048d-3df7-0310-abae-a5850022a9f2
Diffstat (limited to 'ide')
-rw-r--r--ide/globdir.inc8
-rw-r--r--ide/wutils.pas11
2 files changed, 17 insertions, 2 deletions
diff --git a/ide/globdir.inc b/ide/globdir.inc
index c3b060ba36..51e707437b 100644
--- a/ide/globdir.inc
+++ b/ide/globdir.inc
@@ -82,6 +82,14 @@
{$define FSCaseInsensitive}
{$endif}
+{$ifdef Amiga}
+ {$define FSCaseInsensitive}
+{$endif}
+
+{$ifdef MorphOS}
+ {$define FSCaseInsensitive}
+{$endif}
+
{ --- Exclude debugger support --- }
{.$DEFINE NODEBUG}
diff --git a/ide/wutils.pas b/ide/wutils.pas
index 4f492151e2..4999e70fd9 100644
--- a/ide/wutils.pas
+++ b/ide/wutils.pas
@@ -40,7 +40,12 @@ const
TempFirstChar = {$ifndef Unix}'~'{$else}'_'{$endif};
TempExt = '.tmp';
TempNameLen = 8;
- EOL : String[2] = {$ifdef Unix}#10;{$else}#13#10;{$endif}
+
+ { Get DirSep and EOL from System unit, instead of redefining
+ here with tons of $ifdefs (KB) }
+ DirSep : char = System.DirectorySeparator;
+ EOL : String[2] = System.LineEnding;
+
type
PByteArray = ^TByteArray;
@@ -179,7 +184,6 @@ const LastStrToIntResult : integer = 0;
LastHexToIntResult : integer = 0;
LastStrToCardResult : integer = 0;
LastHexToCardResult : integer = 0;
- DirSep : char = {$ifdef Unix}'/'{$else}'\'{$endif};
UseOldBufStreamMethod : boolean = false;
procedure RegisterWUtils;
@@ -1229,6 +1233,9 @@ var Dir: string;
begin
Dir:=GetEnv('TEMP');
if Dir='' then Dir:=GetEnv('TMP');
+{$if defined(morphos) or defined(amiga)}
+ if Dir='' then Dir:='T:';
+{$endif}
if (Dir<>'') then if not ExistsDir(Dir) then Dir:='';
if Dir='' then Dir:=GetCurDir;
repeat