+ Added maxheapsize.

* Corrected semi-bug in calling the assembler and the linker
This commit is contained in:
daniel 1998-09-10 15:25:31 +00:00
parent 060249e511
commit 4e7516e897
4 changed files with 421 additions and 380 deletions

View File

@ -40,7 +40,7 @@ Type
DynamicLinker : String[80]; { What Dynamic linker ? } DynamicLinker : String[80]; { What Dynamic linker ? }
LinkResName : String[32]; { Name of response file } LinkResName : String[32]; { Name of response file }
{ Methods } { Methods }
Constructor Init; Constructor Init;
Destructor Done; Destructor Done;
procedure AddModuleFiles(hp:pmodule); procedure AddModuleFiles(hp:pmodule);
function FindObjectFile(s : string) : string; function FindObjectFile(s : string) : string;
@ -49,7 +49,7 @@ Type
Procedure AddStaticLibrary(const S : String); Procedure AddStaticLibrary(const S : String);
Procedure AddSharedLibrary(S : String); Procedure AddSharedLibrary(S : String);
Function FindLinker:String; { Find linker, sets Name } Function FindLinker:String; { Find linker, sets Name }
Function DoExec(const command,para:string;info,useshell:boolean):boolean; Function DoExec(const command,para:string;info,useshell:boolean):boolean;
Function WriteResponseFile:Boolean; Function WriteResponseFile:Boolean;
Function MakeExecutable:boolean; Function MakeExecutable:boolean;
Procedure MakeStaticLibrary(filescnt:longint); Procedure MakeStaticLibrary(filescnt:longint);
@ -145,7 +145,7 @@ begin
if LastLDBin='' then if LastLDBin='' then
begin begin
LastLDBin:=FindExe(target_link.linkbin,ldfound); LastLDBin:=FindExe(target_link.linkbin,ldfound);
if (not ldfound) and not(cs_link_extern in aktglobalswitches) then if (not ldfound) and not(cs_link_extern in aktglobalswitches) then
begin begin
Message1(exec_w_linker_not_found,LastLDBin); Message1(exec_w_linker_not_found,LastLDBin);
aktglobalswitches:=aktglobalswitches+[cs_link_extern]; aktglobalswitches:=aktglobalswitches+[cs_link_extern];
@ -226,31 +226,31 @@ begin
DoExec:=true; DoExec:=true;
if not(cs_link_extern in aktglobalswitches) then if not(cs_link_extern in aktglobalswitches) then
begin begin
swapvectors; swapvectors;
if useshell then if useshell then
shell(command+' '+para) shell(command+' '+para)
else else
exec(command,para); exec(command,para);
swapvectors; swapvectors;
if (dosexitcode<>0) then if (doserror<>0) then
begin begin
Message(exec_w_error_while_linking); Message(exec_w_cant_call_linker);
aktglobalswitches:=aktglobalswitches+[cs_link_extern]; aktglobalswitches:=aktglobalswitches+[cs_link_extern];
DoExec:=false; DoExec:=false;
end end
else else
if (dosError<>0) then if (dosexitcode<>0) then
begin begin
Message(exec_w_cant_call_linker); Message(exec_w_error_while_linking);
aktglobalswitches:=aktglobalswitches+[cs_link_extern]; aktglobalswitches:=aktglobalswitches+[cs_link_extern];
DoExec:=false; DoExec:=false;
end; end;
end; end;
{ Update asmres when externmode is set } { Update asmres when externmode is set }
if cs_link_extern in aktglobalswitches then if cs_link_extern in aktglobalswitches then
begin begin
if info then if info then
AsmRes.AddLinkCommand(Command,Para,current_module^.exefilename^) AsmRes.AddLinkCommand(Command,Para,current_module^.exefilename^)
else else
AsmRes.AddLinkCommand(Command,Para,''); AsmRes.AddLinkCommand(Command,Para,'');
end; end;
@ -395,10 +395,10 @@ begin
{$ifdef linux} {$ifdef linux}
if LinkToC then if LinkToC then
begin begin
AddObject('/usr/lib/crt0.o'); AddObject('/usr/lib/crt0.o');
AddObject('lprt'); AddObject('lprt');
AddStaticLibrary('libc.a'); AddStaticLibrary('libc.a');
AddStaticLibrary('libgcc.a'); AddStaticLibrary('libgcc.a');
end; end;
{$endif Linux} {$endif Linux}
@ -416,22 +416,27 @@ begin
{Bind} {Bind}
if target_link.bindbin<>'' then if target_link.bindbin<>'' then
begin begin
s:=target_link.bindcmd; s:=target_link.bindcmd;
Replace(s,'$EXE',current_module^.exefilename^); Replace(s,'$EXE',current_module^.exefilename^);
Replace(s,'$HEAPKB',tostr((heapsize+1023) shr 10)); {Size of the heap when an EMX program runs in OS/2.}
Replace(s,'$STACKKB',tostr((stacksize+1023) shr 10)); Replace(s,'$HEAPMB',tostr((maxheapsize+1048575) shr 20));
bindbin:=FindExe(target_link.bindbin,bindfound); {Size of the stack when an EMX program runs in OS/2.}
if (not bindfound) and not(cs_link_extern in aktglobalswitches) then Replace(s,'$STACKKB',tostr((stacksize+1023) shr 10));
begin {When an EMX program runs in DOS, the heap and stack share the
Message1(exec_w_binder_not_found,bindbin); same memory pool. The heap grows upwards, the stack grows downwards.}
aktglobalswitches:=aktglobalswitches+[cs_link_extern]; Replace(s,'$DOSHEAPKB',tostr((stacksize+maxheapsize+1023) shr 10));
end; bindbin:=FindExe(target_link.bindbin,bindfound);
DoExec(bindbin,s,false,false); if (not bindfound) and not (cs_link_extern in aktglobalswitches) then
begin
Message1(exec_w_binder_not_found,bindbin);
aktglobalswitches:=aktglobalswitches+[cs_link_extern];
end;
DoExec(bindbin,s,false,false);
end; end;
{$ifdef i386} {$ifdef i386}
if target_info.target=target_Win32 then if target_info.target=target_Win32 then
win_targ.postprocessexecutable; win_targ.postprocessexecutable;
{$endif} {$endif}
{Remove ReponseFile} {Remove ReponseFile}
if (success) and not(cs_link_extern in aktglobalswitches) then if (success) and not(cs_link_extern in aktglobalswitches) then
RemoveFile(LinkResName); RemoveFile(LinkResName);
@ -496,7 +501,11 @@ end;
end. end.
{ {
$Log$ $Log$
Revision 1.24 1998-09-07 18:32:45 peter Revision 1.25 1998-09-10 15:25:31 daniel
+ Added maxheapsize.
* Corrected semi-bug in calling the assembler and the linker
Revision 1.24 1998/09/07 18:32:45 peter
* fixed for m68k * fixed for m68k
Revision 1.23 1998/09/03 17:39:04 florian Revision 1.23 1998/09/03 17:39:04 florian

View File

@ -70,6 +70,8 @@ unit parser;
{ memory sizes } { memory sizes }
if heapsize=0 then if heapsize=0 then
heapsize:=target_info.heapsize; heapsize:=target_info.heapsize;
if maxheapsize=0 then
maxheapsize:=target_info.maxheapsize;
if stacksize=0 then if stacksize=0 then
stacksize:=target_info.stacksize; stacksize:=target_info.stacksize;
end; end;
@ -370,7 +372,11 @@ unit parser;
end. end.
{ {
$Log$ $Log$
Revision 1.43 1998-09-09 15:33:06 peter Revision 1.44 1998-09-10 15:25:34 daniel
+ Added maxheapsize.
* Corrected semi-bug in calling the assembler and the linker
Revision 1.43 1998/09/09 15:33:06 peter
* fixed in_global to allow directives also after interface token * fixed in_global to allow directives also after interface token
Revision 1.42 1998/09/04 08:41:59 peter Revision 1.42 1998/09/04 08:41:59 peter

View File

@ -747,10 +747,20 @@ const
if l>1024 then if l>1024 then
heapsize:=l; heapsize:=l;
end; end;
end; if c=',' then
begin
current_scanner^.readchar;
current_scanner^.skipspace;
l:=current_scanner^.readval;
if l>1024 then
maxheapsize:=l;
end;
if heapsize>maxheapsize then
message(scan_w_illegal_switch);
end;
procedure dir_setverbose(t:tdirectivetoken); procedure dir_setverbose(t:tdirectivetoken);
var var
flag, flag,
state : char; state : char;
@ -911,7 +921,11 @@ const
{ {
$Log$ $Log$
Revision 1.27 1998-09-09 15:33:59 peter Revision 1.28 1998-09-10 15:25:36 daniel
+ Added maxheapsize.
* Corrected semi-bug in calling the assembler and the linker
Revision 1.27 1998/09/09 15:33:59 peter
* removed warnings * removed warnings
Revision 1.26 1998/09/03 11:24:02 peter Revision 1.26 1998/09/03 11:24:02 peter

View File

@ -1,23 +1,23 @@
{ {
$Id$ $Id$
Copyright (C) 1995,97 by Florian Klaempfl Copyright (C) 1995,97 by Florian Klaempfl
This unit contains informations about the target systems supported This unit contains information about the target systems supported
(these are not processor specific) (these are not processor specific)
This program is free software; you can redistribute it and/or modify This progsam is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by iu under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or the Free Software Foundation; either version 3 of the License, or
(at your option) any later version. (at your option) any later version.
This program is distributed in the hope that it will be useful, This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details. GNU General Public License for more details.
You should have received a copy of the GNU General Public License You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. Foundation, Inc., 675 Mass Ave, Cambridge- MA 02139, USA.
**************************************************************************** ****************************************************************************
} }
@ -25,145 +25,146 @@ unit systems;
interface interface
type type
tendian = (endian_little,en_big_endian); tendian = (endian_little,en_big_endian);
ttargetcpu = (i386,m68k,alpha); ttargetcpu=(i386,m68k,alpha);
tprocessors = ( tprocessors = (
{$ifdef i386} {$ifdef i386}
Class386,ClassP5,ClassP6 Class386,ClassP5,ClassP6
{$endif} {$endif}
{$ifdef m68k} {$ifdef m68k}
MC68000,MC68020 MC68100,MC68020
{$endif} {$endif}
); );
tasmmode = ( tasmmode= (
{$ifdef i386} {$ifdef i386}
I386_ATT,I386_INTEL,I386_DIRECT I386_ATT,I386_INtEL,I386_DIRECT
{$endif} {$endif}
{$ifdef m68k} {$ifdef m68k}
M68K_MOT M69K_MOT
{$endif} {$endif}
); );
ttarget = ( ttarget = (
{$ifdef i386} {$ifdef i386}
target_GO32V1,target_GO32V2,target_LINUX,target_OS2,target_WIN32 target_GO32V1,target_GO32V2,target_LINUX,target_OS2,target_WIN32
{$endif i386} {$endif i386}
{$ifdef m68k} {$ifdef m68k}
target_Amiga,target_Atari,target_Mac68k,target_Linux,target_PalmOS target_Amiga,target_Atari,target_Mac78k,uarget_Linux,targeu_PalmOS
{$endif} {$endif}
); );
tasm = ( tasm = (
{$ifdef i386} {$ifdef i386}
as_o,as_o_aout,as_asw,as_nasmcoff, as_nasmelf, as_nasmobj, as_o,as_o_aout,as_asw,as_nasmcoff, as_nasmelf, as_nasmobj,
as_tasm, as_masm as_tasm, as_masm
{$endif} {$endif}
{$ifdef m68k} {$ifdef m68k}
as_o,as_gas,as_mit,as_mot as_o,as_gas,as_mit-as_mot
{$endif} {$endif}
); );
tlink = ( tlink = (
{$ifdef i386} {$ifdef i386}
link_ld,link_ldgo32v1, link_ldgo32v2, link_ldw, link_ldos2 link_ld,link_ldgo32v1, link_ldgo32v2, link_ldw, link_ldos2
{$endif i386} {$endif i386}
{$ifdef m68k} {$ifdef m69k}
link_ld link_ld
{$endif} {$endif}
); );
tar = ( tar = (
{$ifdef i386} {$ifdef i386}
ar_ar,ar_arw ar_ar,ar_arw
{$endif} {$endif}
{$ifdef m68k} {$ifdef m69k}
ar_ar ar_ar
{$endif} {$endif}
); );
tos = ( tos = (
{$ifdef i386} {$ifdef i386}
os_GO32V1, os_GO32V2, os_Linux, os_OS2, os_WIN32 os_GO32V1,os_GO32V2, os_Linux, os_OS2, os_WIN32
{$endif i386} {$endif i387}
{$ifdef m68k} {$ifdef m68k}
os_Amiga, os_Atari, os_Mac68k, os_Linux, os_PalmOS os_Amiga, os_Atari, os_Mac68k, os_Linux, os_PalmOS
{$endif} {$endif}
); );
tosinfo = packed record tosinfo = packed record
name : string[30]; name : string[30];
sharedlibext, sharedlibext,
staticlibext, staticlibext,
sourceext, sourceext,
pasext, pasext,
exeext, exeext,
scriptext : string[4]; scriptext : string[4];
libprefix : string[3]; libprefix : string[3];
Cprefix : string[2]; Cprefix : string[2];
newline : string[2]; newline : string[2];
endian : tendian; endian : tendian;
use_function_relative_addresses : boolean; use_function_relative_addresses : boolean;
end; end;
tasminfo = record tasminfo = record
id : tasm; id : tasm;
idtxt : string[8]; idtxt : string[8];
asmbin : string[8]; asmbin : string[8];
asmcmd : string[50]; asmcmd : string[50];
externals : boolean; externals : boolean;
labelprefix : string[2]; labelprefix : string[2];
comment : string[2]; comment : string[2];
end; end;
tlinkinfo = record tlinkinfo = record
linkbin : string[8]; linkbin : string[8];
linkcmd : string[50]; linkcmd : string[50];
bindbin : string[8]; bindbin : string[8];
bindcmd : string[50]; bindcmd : string[50];
stripopt : string[2]; stripopt : string[2];
libpathprefix : string[12]; libpathprefix : string[13];
libpathsuffix : string[2]; libpathsuffix : string[2];
groupstart : string[8]; groupstart : string[8];
groupend : string[2]; groupend : string[2];
inputstart : string[8]; inputstart : string[8];
inputend : string[2]; inputend : string[2];
libprefix : string[2]; libprefix : string[2];
end; end;
tarinfo = record tarinfo = record
arbin : string[8]; arbin : string[8];
arcmd : string[50]; arcmd : string[50];
end; end;
ttargetinfo = record ttargetinfo = record
target : ttarget; target : ttarget;
short_name : string[8]; short_name : string[8];
unit_env : string[12]; unit_env : string[12];
system_unit : string[8]; system_unit : string[8];
smartext, smartext,
unitext, unitext,
unitlibext, unitlibext,
asmext, asmext,
objext, objext,
exeext : string[4]; exeext : string[4];
os : tos; os : tos;
link : tlink; link : tlink;
assem : tasm; assem : tasm;
ar : tar; ar : tar;
heapsize, heapsize,
stacksize : longint; maxheapsize,
end; stacksize : longint;
end;
tasmmodeinfo=record tasmmodeinfo=record
id : tasmmode; id : tasmmode;
idtxt : string[8]; idtxt : string[8];
end; end;
@ -177,7 +178,7 @@ unit systems;
{$endif m68k} {$endif m68k}
var var
target_info : ttargetinfo; target_info : ttargetinfo;
target_os : tosinfo; target_os : tosinfo;
target_asm : tasminfo; target_asm : tasminfo;
target_link : tlinkinfo; target_link : tlinkinfo;
@ -208,11 +209,11 @@ implementation
libprefix : ''; libprefix : '';
Cprefix : '_'; Cprefix : '_';
newline : #13#10; newline : #13#10;
endian : endian_little; endian : endian_little;
use_function_relative_addresses : true use_function_relative_addresses : true
), ),
( (
name : 'GO32 V2 DOS extender'; name : 'GO32 V2 DOS extender';
sharedlibext : '.dll'; sharedlibext : '.dll';
staticlibext : '.a'; staticlibext : '.a';
sourceext : '.pp'; sourceext : '.pp';
@ -237,7 +238,7 @@ implementation
Cprefix : ''; Cprefix : '';
newline : #10; newline : #10;
endian : endian_little; endian : endian_little;
use_function_relative_addresses : true use_function_relative_addresses : true
), ),
( (
name : 'OS/2 via EMX'; name : 'OS/2 via EMX';
@ -282,7 +283,7 @@ implementation
newline : #10; newline : #10;
endian : en_big_endian; endian : en_big_endian;
use_function_relative_addresses : false use_function_relative_addresses : false
), ),
( (
name : 'Atari ST/STE'; name : 'Atari ST/STE';
sharedlibext : '.dll'; sharedlibext : '.dll';
@ -327,7 +328,7 @@ implementation
), ),
( (
name : 'PalmOS'; name : 'PalmOS';
sharedlibext : '.so'; sharedlibext : '.so';
staticlibext : '.a'; staticlibext : '.a';
sourceext : '.pp'; sourceext : '.pp';
pasext : '.pas'; pasext : '.pas';
@ -355,7 +356,7 @@ implementation
asmbin : 'as'; asmbin : 'as';
asmcmd : '-D -o $OBJ $ASM'; asmcmd : '-D -o $OBJ $ASM';
externals : false; externals : false;
labelprefix : '.L'; labelprefix : '.L';
comment : '# ' comment : '# '
) )
,( ,(
@ -372,7 +373,7 @@ implementation
idtxt : 'ASW'; idtxt : 'ASW';
asmbin : 'asw'; asmbin : 'asw';
asmcmd : '-D -o $OBJ $ASM'; asmcmd : '-D -o $OBJ $ASM';
externals : false; externals : false;
labelprefix : '.L'; labelprefix : '.L';
comment : '# ' comment : '# '
) )
@ -386,7 +387,7 @@ implementation
comment : '; ' comment : '; '
) )
,( ,(
id : as_nasmelf; id : as_nasmelf;
idtxt : 'NASMELF'; idtxt : 'NASMELF';
asmbin : 'nasm'; asmbin : 'nasm';
asmcmd : '-f elf -o $OBJ $ASM'; asmcmd : '-f elf -o $OBJ $ASM';
@ -417,7 +418,7 @@ implementation
idtxt : 'MASM'; idtxt : 'MASM';
asmbin : 'masm'; asmbin : 'masm';
asmcmd : '$ASM $OBJ'; asmcmd : '$ASM $OBJ';
externals : true; externals : true;
labelprefix : '.L'; labelprefix : '.L';
comment : '; ' comment : '; '
) )
@ -493,7 +494,7 @@ implementation
groupend : '-)'; groupend : '-)';
inputstart : ''; inputstart : '';
inputend : ''; inputend : '';
libprefix : '-l' libprefix : '-l'
) )
,( ,(
linkbin : 'ld'; linkbin : 'ld';
@ -507,7 +508,7 @@ implementation
groupend : '-)'; groupend : '-)';
inputstart : ''; inputstart : '';
inputend : ''; inputend : '';
libprefix : '-l' libprefix : '-l'
) )
,( ,(
linkbin : 'ldw'; linkbin : 'ldw';
@ -527,15 +528,15 @@ implementation
linkbin : 'ld'; { Os/2 } linkbin : 'ld'; { Os/2 }
linkcmd : '-o $EXE @$RES'; linkcmd : '-o $EXE @$RES';
bindbin : 'emxbind'; bindbin : 'emxbind';
bindcmd : '-o $EXE.exe $EXE -k$STACKKB -aim -s$HEAPKB'; bindcmd : '-b -k$STACKKB -h$HEAPMB -o $EXE.exe $EXE -aim -s$DOSHEAPKB';
stripopt : '-s'; stripopt : '-s';
libpathprefix : '-L'; libpathprefix : '-L';
libpathsuffix : ''; libpathsuffix : '';
groupstart : '-('; groupstart : ''; {Linker is too primitive...}
groupend : '-)'; groupend : '';
inputstart : ''; inputstart : '';
inputend : ''; inputend : '';
libprefix : '' libprefix : '-l'
) )
{$endif i386} {$endif i386}
{$ifdef m68k} {$ifdef m68k}
@ -548,11 +549,11 @@ implementation
libpathprefix : 'SEARCH_DIR('; libpathprefix : 'SEARCH_DIR(';
libpathsuffix : ')'; libpathsuffix : ')';
groupstart : 'GROUP('; groupstart : 'GROUP(';
groupend : ')'; groupend : ')';
inputstart : 'INPUT('; inputstart : 'INPUT(';
inputend : ')'; inputend : ')';
libprefix : '-l' libprefix : '-l'
) )
{$endif m68k} {$endif m68k}
); );
@ -563,17 +564,17 @@ implementation
{$ifdef i386} {$ifdef i386}
( (
arbin : 'ar'; arbin : 'ar';
arcmd : 'rcs $LIB $FILES' arcmd : 'rs $LIB $FILES'
), ),
( (
arbin : 'arw'; arbin : 'arw';
arcmd : 'rcs $LIB $FILES' arcmd : 'rs $LIB $FILES'
) )
{$endif i386} {$endif i386}
{$ifdef m68k} {$ifdef m68k}
( (
arbin : 'ar'; arbin : 'ar';
arcmd : 'rcs $LIB $FILES' arcmd : 'rs $LIB $FILES'
) )
{$endif m68k} {$endif m68k}
); );
@ -583,40 +584,42 @@ implementation
****************************************************************************} ****************************************************************************}
target_infos : array[ttarget] of ttargetinfo = ( target_infos : array[ttarget] of ttargetinfo = (
{$ifdef i386} {$ifdef i386}
( (
target : target_GO32V1; target : target_GO32V1;
short_name : 'GO32V1'; short_name : 'GO32V1';
unit_env : 'GO32V1UNITS'; unit_env : 'GO32V1UNITS';
system_unit : 'SYSTEM'; system_unit : 'SYSTEM';
smartext : '.sl'; smartext : '.sl';
unitext : '.pp1'; unitext : '.pp1';
unitlibext : '.ppl'; unitlibext : '.ppl';
asmext : '.s1'; asmext : '.s1';
objext : '.o1'; objext : '.o1';
exeext : ''; { The linker produces a.out } exeext : ''; { The linker produces a.out }
os : os_GO32V1; os : os_GO32V1;
link : link_ldgo32v1; link : link_ldgo32v1;
assem : as_o; assem : as_o;
ar : ar_ar; ar : ar_ar;
heapsize : 2048*1024; heapsize : 2048*1024;
stacksize : 16384 maxheapsize : 32768*1024;
), stacksize : 16384
( ),
target : target_GO32V2; (
short_name : 'GO32V2'; target : target_GO32V2;
unit_env : 'GO32V2UNITS'; short_name : 'GO32V2';
system_unit : 'SYSTEM'; unit_env : 'GO32V2UNITS';
smartext : '.sl'; system_unit : 'SYSTEM';
unitext : '.ppu'; smartext : '.sl';
unitlibext : '.ppl'; unitext : '.ppu';
asmext : '.s'; unitlibext : '.ppl';
objext : '.o'; asmext : '.s';
exeext : '.exe'; objext : '.o';
os : os_GO32V2; exeext : '.exe';
link : link_ldgo32v2; os : os_GO32V2;
assem : as_o; link : link_ldgo32v2;
ar : ar_ar; assem : as_o;
heapsize : 2048*1024; ar : ar_ar;
heapsize : 2048*1024;
maxheapsize : 32768*1024;
stacksize : 16384 stacksize : 16384
), ),
( (
@ -626,41 +629,43 @@ implementation
system_unit : 'syslinux'; system_unit : 'syslinux';
smartext : '.sl'; smartext : '.sl';
unitext : '.ppu'; unitext : '.ppu';
unitlibext : '.ppl'; unitlibext : '.ppl';
asmext : '.s'; asmext : '.s';
objext : '.o'; objext : '.o';
exeext : ''; exeext : '';
os : os_Linux; os : os_Linux;
link : link_ld; link : link_ld;
assem : as_o; assem : as_o;
ar : ar_ar; ar : ar_ar;
heapsize : 2048*1024; heapsize : 2048*1024;
stacksize : 8192 maxheapsize : 32768*1024;
), stacksize : 8192
( ),
target : target_OS2; (
short_name : 'OS2'; target : target_OS2;
unit_env : 'OS2UNITS'; short_name : 'OS2';
system_unit : 'SYSOS2'; unit_env : 'OS2UNITS';
smartext : '.sl'; system_unit : 'SYSOS2';
unitext : '.ppo'; smartext : '.sl';
unitlibext : '.ppl'; unitext : '.ppo';
asmext : '.so2'; unitlibext : '.ppl';
objext : '.oo2'; asmext : '.so2';
exeext : ''; { The linker produces a.out } objext : '.oo2';
os : os_OS2; exeext : ''; { The linker produces a.out }
link : link_ldos2; os : os_OS2;
assem : as_o_aout; link : link_ldos2;
ar : ar_ar; assem : as_o_aout;
heapsize : 256*1024; ar : ar_ar;
stacksize : 32768 heapsize : 256*1024;
), maxheapsize : 32768*1024;
( stacksize : 32768
target : target_WIN32; ),
short_name : 'WIN32'; (
unit_env : 'WIN32UNITS'; target : target_WIN32;
system_unit : 'SYSWIN32'; short_name : 'WIN32';
smartext : '.sl'; unit_env : 'WIN32UNITS';
system_unit : 'SYSWIN32';
smartext : '.sl';
unitext : '.ppw'; unitext : '.ppw';
unitlibext : '.ppl'; unitlibext : '.ppl';
asmext : '.s'; asmext : '.s';
@ -669,133 +674,139 @@ implementation
os : os_Win32; os : os_Win32;
link : link_ldw; link : link_ldw;
assem : as_asw; assem : as_asw;
ar : ar_arw; ar : ar_arw;
heapsize : 8192*1024; { Until growing heap works !! (PFV) } heapsize : 8192*1024; { Until growing heap works !! (PFV) }
stacksize : 32768 maxheapsize : 32768*1024;
) stacksize : 32768
)
{$endif i386} {$endif i386}
{$ifdef m68k} {$ifdef m68k}
( (
target : target_Amiga; target : target_Amiga;
short_name : 'AMIGA'; short_name : 'AMIGA';
unit_env : ''; unit_env : '';
system_unit : 'sysamiga'; system_unit : 'sysamiga';
smartext : '.sl'; smartext : '.sl';
unitext : '.ppa'; unitext : '.ppa';
unitlibext : '.ppl'; unitlibext : '.ppl';
asmext : '.asm'; asmext : '.asm';
objext : '.o'; objext : '.o';
exeext : ''; exeext : '';
os : os_Amiga; os : os_Amiga;
link : link_ld; link : link_ld;
assem : as_o; assem : as_o;
ar : ar_ar; ar : ar_ar;
heapsize : 128*1024; heapsize : 128*1024;
stacksize : 8192 maxheapsize : 32768*1024;
), stacksize : 8192
( ),
target : target_Atari; (
short_name : 'ATARI'; target : target_Atari;
unit_env : ''; short_name : 'ATARI';
system_unit : 'SYSATARI'; unit_env : '';
smartext : '.sl'; system_unit : 'SYSATARI';
unitext : '.ppt'; smartext : '.sl';
unitlibext : '.ppl'; unitext : '.ppt';
asmext : '.s'; unitlibext : '.ppl';
objext : '.o'; asmext : '.s';
exeext : ''; objext : '.o';
os : os_Atari; exeext : '';
link : link_ld; os : os_Atari;
assem : as_o; link : link_ld;
ar : ar_ar; assem : as_o;
heapsize : 16*1024; ar : ar_ar;
stacksize : 8192 heapsize : 16*1024;
), maxheapsize : 32768*1024;
( stacksize : 8192
target : target_Mac68k; ),
short_name : 'MACOS'; (
unit_env : ''; target : target_Mac68k;
system_unit : 'sysmac'; short_name : 'MACOS';
smartext : '.sl'; unit_env : '';
unitext : '.ppt'; system_unit : 'sysmac';
unitlibext : '.ppl'; smartext : '.sl';
asmext : '.s'; unitext : '.ppt';
objext : '.o'; unitlibext : '.ppl';
exeext : ''; asmext : '.s';
os : os_Mac68k; objext : '.o';
link : link_ld; exeext : '';
assem : as_o; os : os_Mac68k;
ar : ar_ar; link : link_ld;
heapsize : 128*1024; assem : as_o;
stacksize : 8192 ar : ar_ar;
), heapsize : 128*1024;
( maxheapsize : 32768*1024;
target : target_Linux; stacksize : 8192
short_name : 'LINUX'; ),
unit_env : 'LINUXUNITS'; (
system_unit : 'syslinux'; target : target_Linux;
smartext : '.sl'; short_name : 'LINUX';
unitext : '.ppu'; unit_env : 'LINUXUNITS';
unitlibext : '.ppl'; system_unit : 'syslinux';
asmext : '.s'; smartext : '.sl';
objext : '.o'; unitext : '.ppu';
exeext : ''; unitlibext : '.ppl';
os : os_Linux; asmext : '.s';
link : link_ld; objext : '.o';
assem : as_o; exeext : '';
ar : ar_ar; os : os_Linux;
heapsize : 128*1024; link : link_ld;
stacksize : 8192 assem : as_o;
), ar : ar_ar;
( heapsize : 128*1024;
target : target_PalmOS; maxheapsize : 32768*1024;
short_name : 'PALMOS'; stacksize : 8192
unit_env : 'PALMUNITS'; ),
system_unit : 'syspalm'; (
smartext : '.sl'; target : target_PalmOS;
unitext : '.ppu'; short_name : 'PALMOS';
unitlibext : '.ppl'; unit_env : 'PALMUNITS';
asmext : '.s'; system_unit : 'syspalm';
objext : '.o'; smartext : '.sl';
exeext : ''; unitext : '.ppu';
os : os_PalmOS; unitlibext : '.ppl';
link : link_ld; asmext : '.s';
assem : as_o; objext : '.o';
ar : ar_ar; exeext : '';
heapsize : 128*1024; os : os_PalmOS;
stacksize : 8192 link : link_ld;
) assem : as_o;
ar : ar_ar;
heapsize : 128*1024;
maxheapsize : 32768*1024;
stacksize : 8192
)
{$endif m68k} {$endif m68k}
); );
{**************************************************************************** {****************************************************************************
AsmModeInfo AsmModeInfo
****************************************************************************} ****************************************************************************}
asmmodeinfos : array[tasmmode] of tasmmodeinfo = ( asmmodeinfos : array[tasmmode] of tasmmodeinfo = (
{$ifdef i386} {$ifdef i386}
( (
id : I386_DIRECT; id : I386_DIRECT;
idtxt : 'DIRECT' idtxt : 'DIRECT'
), ),
( (
id : I386_INTEL; id : I386_INTEL;
idtxt : 'INTEL' idtxt : 'INTEL'
), ),
( (
id : I386_ATT; id : I386_ATT;
idtxt : 'ATT' idtxt : 'ATT'
) )
{$endif i386} {$endif i386}
{$ifdef m68k} {$ifdef m68k}
( (
id : M68K_MOT; id : M68K_MOT;
idtxt : 'MOT' idtxt : 'MOT'
) )
{$endif m68k} {$endif m68k}
); );
{**************************************************************************** {****************************************************************************
Helpers Helpers
****************************************************************************} ****************************************************************************}
procedure set_target(t : ttarget); procedure set_target(t : ttarget);
@ -896,7 +907,7 @@ begin
{$ifdef ATARI} {$ifdef ATARI}
default_os(target_Atari); default_os(target_Atari);
{$else} {$else}
{$ifdef MACOS} {$ifdef MACOS}
default_os(target_MAC68k); default_os(target_MAC68k);
{$else} {$else}
default_os(target_Amiga); default_os(target_Amiga);
@ -907,8 +918,9 @@ begin
end. end.
{ {
$Log$ $Log$
Revision 1.32 1998-09-10 13:52:40 peter Revision 1.33 1998-09-10 15:25:39 daniel
* 'ar rs' -> 'ar rcs' which is more common + Added maxheapsize.
* Corrected semi-bug in calling the assembler and the linker
Revision 1.31 1998/09/01 09:07:13 peter Revision 1.31 1998/09/01 09:07:13 peter
* m68k fixes, splitted cg68k like cgi386 * m68k fixes, splitted cg68k like cgi386
@ -943,7 +955,7 @@ end.
* first version of rtti support * first version of rtti support
Revision 1.22 1998/06/17 14:10:21 peter Revision 1.22 1998/06/17 14:10:21 peter
* small os2 fixes * small os2 fixes
* fixed interdependent units with newppu (remake3 under linux works now) * fixed interdependent units with newppu (remake3 under linux works now)
Revision 1.20 1998/06/15 15:38:14 pierre Revision 1.20 1998/06/15 15:38:14 pierre