2
$Id: systems.pas,v 1.1.2.4 2000/09/24 21:13:37 hajny Exp $
3
Copyright (C) 1998-2000 by Florian Klaempfl
5
This unit contains information about the target systems supported
6
(these are not processor specific)
8
This progsam is free software; you can redistribute it and/or modify
9
iu under the terms of the GNU General Public License as published by
10
the Free Software Foundation; either version 3 of the License, or
11
(at your option) any later version.
13
This program is distributed in the hope that it will be useful,
14
but WITHOUT ANY WARRANTY; without even the implied warranty of
15
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
GNU General Public License for more details.
18
You should have received a copy of the GNU General Public License
19
along with this program; if not, write to the Free Software
20
Foundation, Inc., 675 Mass Ave, Cambridge- MA 02139, USA.
22
****************************************************************************
27
{$ifdef PACKENUMFIXED}
35
tendian = (endian_little,endian_big);
38
,i386,m68k,alpha,powerpc
41
tprocessors = (no_processor
42
,Class386,ClassP5,ClassP6
43
,MC68000,MC68100,MC68020
47
sec_code,sec_data,sec_bss,
48
sec_idata2,sec_idata4,sec_idata5,sec_idata6,sec_idata7,sec_edata,
53
tasmmode= (asmmode_none
54
,asmmode_i386_direct,asmmode_i386_att,asmmode_i386_intel
55
,asmmode_m68k_mot,asmmode_alpha_direct,asmmode_powerpc_direct
58
{$ifdef i386} i386asmmodecnt=3; {$else} i386asmmodecnt=0; {$endif}
59
{$ifdef m68k} m68kasmmodecnt=1; {$else} m68kasmmodecnt=0; {$endif}
60
{$ifdef alpha} alphaasmmodecnt=1; {$else} alphaasmmodecnt=0; {$endif}
61
{$ifdef powerpc} powerpcasmmodecnt=1; {$else} powerpcasmmodecnt=0; {$endif}
62
asmmodecnt=i386asmmodecnt+m68kasmmodecnt+Alphaasmmodecnt+powerpcasmmodecnt+1;
65
ttarget = (target_none
66
,target_i386_GO32V1,target_i386_GO32V2,target_i386_linux,
67
target_i386_OS2,target_i386_Win32,target_i386_freebsd
68
,target_m68k_Amiga,target_m68k_Atari,target_m68k_Mac,
69
target_m68k_linux,target_m68k_PalmOS,target_alpha_linux,
70
target_powerpc_linux,target_powerpc_macos
73
ttargetflags = (tf_none,
74
tf_supports_stack_checking,tf_need_export,tf_needs_isconsole
78
{ alias for supported_target field in tasminfo }
79
target_any = target_none;
81
{$ifdef i386} i386targetcnt=6; {$else} i386targetcnt=0; {$endif}
82
{$ifdef m68k} m68ktargetcnt=5; {$else} m68ktargetcnt=0; {$endif}
83
{$ifdef alpha} alphatargetcnt=1; {$else} alphatargetcnt=0; {$endif}
84
{$ifdef powerpc} powerpctargetcnt=2; {$else} powerpctargetcnt=0; {$endif}
85
targetcnt=i386targetcnt+m68ktargetcnt+alphatargetcnt+powerpctargetcnt+1;
89
,as_i386_as,as_i386_as_aout,as_i386_asw,
90
as_i386_nasmcoff,as_i386_nasmwin32,
91
as_i386_nasmelf,as_i386_nasmobj,
92
as_i386_tasm,as_i386_masm,
93
as_i386_dbg,as_i386_coff,as_i386_pecoff
94
,as_m68k_as,as_m68k_gas,as_m68k_mit,as_m68k_mot,as_m68k_mpw,
95
as_alpha_as,as_powerpc_as,as_powerpc_mpw
97
{ binary assembler writers, needed to test for -a }
99
{$ifdef i386} i386asmcnt=12; {$else} i386asmcnt=0; {$endif}
100
{$ifdef m68k} m68kasmcnt=5; {$else} m68kasmcnt=0; {$endif}
101
{$ifdef alpha} alphaasmcnt=1; {$else} alphaasmcnt=0; {$endif}
102
{$ifdef powerpc} powerpcasmcnt=2; {$else} powerpcasmcnt=0; {$endif}
103
asmcnt=i386asmcnt+m68kasmcnt+alphaasmcnt+powerpcasmcnt+1;
105
binassem : set of tasm = [
106
as_i386_dbg,as_i386_coff,as_i386_pecoff
111
,ar_i386_ar,ar_i386_arw
112
,ar_m68k_ar,ar_alpha_ar,ar_powerpc_ar
115
{$ifdef i386} i386arcnt=2; {$else} i386arcnt=0; {$endif}
116
{$ifdef m68k} m68karcnt=1; {$else} m68karcnt=0; {$endif}
117
{$ifdef alpha} alphaarcnt=1; {$else} alphaarcnt=0; {$endif}
118
{$ifdef powerpc} powerpcarcnt=1; {$else} powerpcarcnt=0; {$endif}
119
arcnt=i386arcnt+m68karcnt+alphaarcnt+powerpcarcnt+1;
123
,res_i386_windres,res_m68k_mpw,res_powerpc_mpw, res_i386_emx
126
{$ifdef i386} i386rescnt=2; {$else} i386rescnt=0; {$endif}
127
{$ifdef m68k} m68krescnt=1; {$else} m68krescnt=0; {$endif}
128
{$ifdef alpha} alpharescnt=0; {$else} alpharescnt=0; {$endif}
129
{$ifdef powerpc} powerpcrescnt=1; {$else} powerpcrescnt=0; {$endif}
130
rescnt=i386rescnt+m68krescnt+alpharescnt+powerpcrescnt+1;
134
os_i386_GO32V1,os_i386_GO32V2,os_i386_Linux,os_i386_OS2,
135
os_i386_Win32,os_i386_freeBSD,
136
os_m68k_Amiga,os_m68k_Atari,os_m68k_Mac,os_m68k_Linux,
137
os_m68k_PalmOS,os_alpha_linux,os_powerpc_linux,os_powerpc_macos
144
oscnt=i386oscnt+m68koscnt+alphaoscnt+powerpcoscnt+1;
147
tosinfo = packed record
150
shortname : string[9];
151
sharedlibext : string[10];
157
scriptext : string[4];
158
libprefix : string[3];
162
{longint this is a little overkill no ?? but 256 is possible one day }
163
stackalignment : word;
164
maxCrecordalignment : word;
165
size_of_pointer : byte;
166
size_of_longint : byte;
167
use_bound_instruction : boolean;
168
use_function_relative_addresses : boolean;
171
tasminfo = packed record
176
supported_target : ttarget;
180
labelprefix : string[2];
182
secnames : array[tsection] of string[20];
185
tarinfo = packed record
190
tresinfo = packed record
196
ttargetinfo = packed record
198
flags : set of ttargetflags;
200
short_name : string[8];
201
unit_env : string[12];
202
system_unit : string[8];
213
assemsrc : tasm; { default source writing assembler }
221
tasmmodeinfo=packed record
227
target_cpu : ttargetcpu;
228
target_info : ttargetinfo;
230
target_asm : tasminfo;
232
target_res : tresinfo;
233
target_path : string[12]; { for rtl/<X>/,fcl/<X>/, etc. }
236
function set_target_os(t:tos):boolean;
237
function set_target_asm(t:tasm):boolean;
238
function set_target_ar(t:tar):boolean;
239
function set_target_res(t:tres):boolean;
240
function set_target_info(t:ttarget):boolean;
242
function set_string_target(s : string) : boolean;
243
function set_string_asm(s : string) : boolean;
244
function set_string_asmmode(s:string;var t:tasmmode):boolean;
246
procedure InitSystems;
253
{****************************************************************************
255
****************************************************************************}
256
os_infos : array[1..oscnt] of tosinfo = (
259
name : 'No operating system';
264
name : 'GO32 V1 DOS extender';
265
shortname : 'go32v1';
266
sharedlibext : '.dll';
270
exeext : ''; { No .exe, the linker only output a.out ! }
276
endian : endian_little;
278
maxCrecordalignment : 4;
281
use_bound_instruction : false;
282
use_function_relative_addresses : true
286
name : 'GO32 V2 DOS extender';
287
shortname : 'go32v2';
288
sharedlibext : '.dll';
298
endian : endian_little;
300
maxCrecordalignment : 4;
303
use_bound_instruction : false;
304
use_function_relative_addresses : true
308
name : 'Linux for i386';
310
sharedlibext : '.so';
320
endian : endian_little;
322
maxCrecordalignment : 4;
325
use_bound_instruction : false;
326
use_function_relative_addresses : true
329
id : os_i386_FreeBSD;
330
name : 'FreeBSD/ELF for i386';
331
shortname : 'freebsd';
332
sharedlibext : '.so';
342
endian : endian_little;
344
maxCrecordalignment : 4;
347
use_bound_instruction : false;
348
use_function_relative_addresses : true
352
name : 'OS/2 via EMX';
354
sharedlibext : '.ao2';
355
staticlibext : '.ao2';
364
endian : endian_little;
366
maxCrecordalignment : 4;
369
use_bound_instruction : false;
370
use_function_relative_addresses : false
374
name : 'Win32 for i386';
376
sharedlibext : '.dll';
377
staticlibext : '.aw';
386
endian : endian_little;
388
maxCrecordalignment : 16;
391
use_bound_instruction : false;
392
use_function_relative_addresses : true
396
name : 'Commodore Amiga';
398
sharedlibext : '.library';
410
maxCrecordalignment : 4;
413
use_bound_instruction : false;
414
use_function_relative_addresses : false
418
name : 'Atari ST/STE';
420
sharedlibext : '.dll';
432
maxCrecordalignment : 4;
435
use_bound_instruction : false;
436
use_function_relative_addresses : false
440
name : 'Macintosh m68k';
442
sharedlibext : 'Lib';
443
staticlibext : 'Lib';
454
maxCrecordalignment : 4;
457
use_bound_instruction : false;
458
use_function_relative_addresses : false
462
name : 'Linux for m68k';
464
sharedlibext : '.so';
476
maxCrecordalignment : 32;
479
use_bound_instruction : false;
480
use_function_relative_addresses : true
485
shortname : 'palmos';
486
sharedlibext : '.so';
498
maxCrecordalignment : 32;
501
use_bound_instruction : false;
502
use_function_relative_addresses : false
506
name : 'Linux for Alpha';
507
shortname : 'axplinux';
508
sharedlibext : '.so';
518
endian : endian_little;
520
maxCrecordalignment : 32;
523
use_bound_instruction : false;
524
use_function_relative_addresses : true
527
id : os_powerpc_linux;
528
name : 'Linux for PowerPC';
529
shortname : 'linuxppc';
530
sharedlibext : '.so';
542
maxCrecordalignment : 32;
545
use_bound_instruction : false;
546
use_function_relative_addresses : true
549
id : os_powerpc_macos;
550
name : 'MacOs (PowerPC)';
551
shortname : 'MacOs/PPC';
552
sharedlibext : 'Lib';
553
staticlibext : 'Lib';
564
maxCrecordalignment : 32;
567
use_bound_instruction : false;
568
use_function_relative_addresses : true
573
{****************************************************************************
575
****************************************************************************}
577
as_infos : array[1..asmcnt] of tasminfo = (
587
asmcmd : '-o $OBJ $ASM';
588
supported_target : target_any;
595
'.text','.data','.bss',
600
id : as_i386_as_aout;
603
asmcmd : '-o $OBJ $ASM';
604
supported_target : target_i386_os2;
611
'.text','.data','.bss',
619
asmcmd : '-o $OBJ $ASM';
620
supported_target : target_i386_win32;
627
'.text','.data','.section .bss',
628
'.section .idata$2','.section .idata$4','.section .idata$5',
629
'.section .idata$6','.section .idata$7','.section .edata',
633
id : as_i386_nasmcoff;
636
asmcmd : '-f coff -o $OBJ $ASM';
637
supported_target : target_i386_go32v2;
644
'.text','.data','.bss',
645
'.idata2','.idata4','.idata5','.idata6','.idata7','.edata',
649
id : as_i386_nasmwin32;
652
asmcmd : '-f win32 -o $OBJ $ASM';
653
supported_target : target_i386_win32;
660
'.text','.data','.bss',
661
'.idata2','.idata4','.idata5','.idata6','.idata7','.edata',
665
id : as_i386_nasmelf;
668
asmcmd : '-f elf -o $OBJ $ASM';
669
supported_target : target_i386_linux;
676
'.text','.data','.bss',
677
'.idata2','.idata4','.idata5','.idata6','.idata7','.edata',
681
id : as_i386_nasmobj;
684
asmcmd : '-f obj -o $OBJ $ASM';
685
supported_target : target_any; { what should I write here ?? }
692
'.text','.data','.bss',
693
'.idata2','.idata4','.idata5','.idata6','.idata7','.edata',
700
asmcmd : '/m2 $ASM $OBJ';
701
supported_target : target_any; { what should I write here ?? }
716
asmcmd : '$ASM $OBJ';
717
supported_target : target_any; { what should I write here ?? }
733
supported_target : target_any;
740
'.text','.data','.bss',
741
'.idata$2','.idata$4','.idata$5','.idata$6','.idata$7','.edata',
749
supported_target : target_i386_go32v2;
756
'.text','.data','.bss',
757
'.idata$2','.idata$4','.idata$5','.idata$6','.idata$7','.edata',
765
supported_target : target_i386_win32;
772
'.text','.data','.bss',
773
'.idata$2','.idata$4','.idata$5','.idata$6','.idata$7','.edata',
782
asmcmd : '-o $OBJ $ASM';
783
supported_target : target_any;
790
'.text','.data','.bss',
791
'.idata$2','.idata$4','.idata$5','.idata$6','.idata$7','.edata',
797
asmbin : 'as68k'; { Gas for the Amiga}
798
asmcmd : '--register-prefix-optional -o $OBJ $ASM';
799
supported_target : target_any;
806
'.text','.data','.bss',
807
'.idata$2','.idata$4','.idata$5','.idata$6','.idata$7','.edata',
814
asmcmd : '-o $OBJ $ASM';
815
supported_target : target_any;
822
'.text','.data','.bss',
823
'.idata$2','.idata$4','.idata$5','.idata$6','.idata$7','.edata',
830
asmcmd : '-o $OBJ $ASM';
831
supported_target : target_any;
838
'.text','.data','.bss',
839
'.idata$2','.idata$4','.idata$5','.idata$6','.idata$7','.edata',
846
asmcmd : '-model far -o $OBJ $ASM';
847
supported_target : target_any;
854
'.text','.data','.bss',
855
'.idata$2','.idata$4','.idata$5','.idata$6','.idata$7','.edata',
864
asmcmd : '-o $OBJ $ASM';
865
supported_target : target_any;
872
'.text','.data','.bss',
882
asmcmd : '-o $OBJ $ASM';
883
supported_target : target_any;
890
'.text','.data','.bss',
898
asmcmd : '-o $OBJ $ASM';
899
supported_target : target_any;
906
'.text','.data','.bss',
914
{****************************************************************************
916
****************************************************************************}
917
ar_infos : array[1..arcnt] of tarinfo = (
924
arcmd : 'ar rs $LIB $FILES'
928
arcmd : 'arw rs $LIB $FILES'
934
arcmd : 'ar rs $LIB $FILES'
940
arcmd : 'ar rs $LIB $FILES'
946
arcmd : 'ar rs $LIB $FILES'
952
{****************************************************************************
954
****************************************************************************}
955
res_infos : array[1..rescnt] of tresinfo = (
961
id : res_i386_windres;
963
rescmd : '--include $INC -O coff -o $OBJ $RES'
968
rescmd : '-b -r $RES $OBJ'
969
(* Not really used - see TLinkeros2.SetDefaultInfo in t_os2.pas. *)
976
rescmd : '-i $INC -o $OBJ $RES'
981
id : res_powerpc_mpw;
983
rescmd : '-i $INC -o $OBJ $RES'
989
{****************************************************************************
991
****************************************************************************}
992
target_infos : array[1..targetcnt] of ttargetinfo = (
994
target : target_none;
997
short_name : 'notarget'
1001
target : target_i386_GO32V1;
1004
short_name : 'GO32V1';
1005
unit_env : 'GO32V1UNITS';
1006
system_unit : 'SYSTEM';
1009
unitlibext : '.ppl';
1014
exeext : ''; { The linker produces a.out }
1015
os : os_i386_GO32V1;
1017
assemsrc : as_i386_as;
1020
heapsize : 2048*1024;
1021
maxheapsize : 32768*1024;
1025
target : target_i386_GO32V2;
1028
short_name : 'GO32V2';
1029
unit_env : 'GO32V2UNITS';
1030
system_unit : 'SYSTEM';
1033
unitlibext : '.ppl';
1039
os : os_i386_GO32V2;
1040
assem : as_i386_coff;
1041
assemsrc : as_i386_as;
1044
heapsize : 2048*1024;
1045
maxheapsize : 32768*1024;
1049
target : target_i386_LINUX;
1052
short_name : 'LINUX';
1053
unit_env : 'LINUXUNITS';
1054
system_unit : 'syslinux';
1057
unitlibext : '.ppl';
1065
assemsrc : as_i386_as;
1068
heapsize : 256*1024;
1069
maxheapsize : 32768*1024;
1073
target : target_i386_FreeBSD;
1076
short_name : 'FREEBSD';
1077
unit_env : 'BSDUNITS';
1078
system_unit : 'sysbsd';
1081
unitlibext : '.ppl';
1087
os : os_i386_Freebsd;
1089
assemsrc : as_i386_as;
1092
heapsize : 256*1024;
1093
maxheapsize : 32768*1024;
1097
target : target_i386_OS2;
1098
flags : [tf_need_export];
1101
unit_env : 'OS2UNITS';
1102
system_unit : 'SYSOS2';
1105
unitlibext : '.ppl';
1110
exeext : ''; { The linker produces a.out }
1112
assem : as_i386_as_aout;
1113
assemsrc : as_i386_as_aout;
1116
heapsize : 256*1024;
1117
maxheapsize : 32768*1024;
1118
stacksize : 256*1024
1121
target : target_i386_WIN32;
1124
short_name : 'WIN32';
1125
unit_env : 'WIN32UNITS';
1126
system_unit : 'SYSWIN32';
1129
unitlibext : '.ppl';
1136
assem : as_i386_pecoff;
1137
assemsrc : as_i386_asw;
1139
res : res_i386_windres;
1140
heapsize : 256*1024;
1141
maxheapsize : 32*1024*1024;
1142
stacksize : 32*1024*1024
1147
target : target_m68k_Amiga;
1150
short_name : 'AMIGA';
1152
system_unit : 'sysamiga';
1155
unitlibext : '.ppl';
1163
assemsrc : as_m68k_as;
1166
heapsize : 128*1024;
1167
maxheapsize : 32768*1024;
1171
target : target_m68k_Atari;
1174
short_name : 'ATARI';
1176
system_unit : 'SYSATARI';
1179
unitlibext : '.ppl';
1187
assemsrc : as_m68k_as;
1191
maxheapsize : 32768*1024;
1195
target : target_m68k_Mac;
1198
short_name : 'MACOS';
1200
system_unit : 'sysmac';
1203
unitlibext : '.ppl';
1210
assem : as_m68k_mpw;
1211
assemsrc : as_m68k_mpw;
1214
heapsize : 128*1024;
1215
maxheapsize : 32768*1024;
1219
target : target_m68k_linux;
1222
short_name : 'LINUX';
1223
unit_env : 'LINUXUNITS';
1224
system_unit : 'syslinux';
1227
unitlibext : '.ppl';
1235
assemsrc : as_m68k_as;
1238
heapsize : 128*1024;
1239
maxheapsize : 32768*1024;
1243
target : target_m68k_PalmOS;
1246
short_name : 'PALMOS';
1247
unit_env : 'PALMUNITS';
1248
system_unit : 'syspalm';
1251
unitlibext : '.ppl';
1257
os : os_m68k_PalmOS;
1259
assemsrc : as_m68k_as;
1262
heapsize : 128*1024;
1263
maxheapsize : 32768*1024;
1269
target : target_alpha_LINUX;
1272
short_name : 'LINUX';
1273
unit_env : 'LINUXUNITS';
1274
system_unit : 'syslinux';
1277
unitlibext : '.ppl';
1283
os : os_alpha_Linux;
1284
assem : as_alpha_as;
1285
assemsrc : as_alpha_as;
1288
heapsize : 256*1024;
1289
maxheapsize : 32768*1024;
1295
target : target_powerpc_LINUX;
1298
short_name : 'LINUX';
1300
system_unit : 'syslinux';
1303
unitlibext : '.ppl';
1309
os : os_powerpc_Linux;
1310
assem : as_powerpc_as;
1311
assemsrc : as_powerpc_as;
1314
heapsize : 256*1024;
1315
maxheapsize : 32768*1024;
1319
target : target_powerpc_MACOS;
1322
short_name : 'MACOS';
1324
system_unit : 'sysmac';
1327
unitlibext : '.ppl';
1333
os : os_powerpc_macos;
1334
assem : as_powerpc_mpw;
1335
assemsrc : as_powerpc_mpw;
1337
res : res_powerpc_mpw;
1338
heapsize : 256*1024;
1339
maxheapsize : 32768*1024;
1345
{****************************************************************************
1347
****************************************************************************}
1348
asmmodeinfos : array[1..asmmodecnt] of tasmmodeinfo = (
1355
id : asmmode_i386_direct;
1359
id : asmmode_i386_att;
1363
id : asmmode_i386_intel;
1369
id : asmmode_m68k_mot;
1375
id : asmmode_alpha_direct;
1381
id : asmmode_powerpc_direct;
1387
{****************************************************************************
1389
****************************************************************************}
1391
function upper(const s : string) : string;
1395
for i:=1 to length(s) do
1396
if s[i] in ['a'..'z'] then
1397
upper[i]:=char(byte(s[i])-32)
1402
SetLength(upper,length(s));
1411
function lower(const s : string) : string;
1415
for i:=1 to length(s) do
1416
if s[i] in ['A'..'Z'] then
1417
lower[i]:=char(byte(s[i])+32)
1422
setlength(lower,length(s));
1432
function set_target_os(t:tos):boolean;
1436
set_target_os:=false;
1437
{ target 1 is none }
1438
for i:=2 to oscnt do
1439
if os_infos[i].id=t then
1441
target_os:=os_infos[i];
1442
set_target_os:=true;
1448
function set_target_asm(t:tasm):boolean;
1452
set_target_asm:=false;
1453
for i:=1 to asmcnt do
1454
if as_infos[i].id=t then
1456
target_asm:=as_infos[i];
1457
set_target_asm:=true;
1463
function set_target_ar(t:tar):boolean;
1467
set_target_ar:=false;
1468
for i:=1 to arcnt do
1469
if ar_infos[i].id=t then
1471
target_ar:=ar_infos[i];
1472
set_target_ar:=true;
1478
function set_target_res(t:tres):boolean;
1482
set_target_res:=false;
1483
for i:=1 to rescnt do
1484
if res_infos[i].id=t then
1486
target_res:=res_infos[i];
1487
set_target_res:=true;
1493
function set_target_info(t:ttarget):boolean;
1497
set_target_info:=false;
1498
for i:=1 to targetcnt do
1499
if target_infos[i].target=t then
1501
target_info:=target_infos[i];
1502
set_target_os(target_info.os);
1503
set_target_asm(target_info.assem);
1504
set_target_ar(target_info.ar);
1505
set_target_res(target_info.res);
1506
target_path:=lower(target_info.short_name);
1507
target_cpu:=target_info.cpu;
1508
set_target_info:=true;
1514
{****************************************************************************
1516
****************************************************************************}
1518
function set_string_target(s : string) : boolean;
1522
set_string_target:=false;
1523
{ this should be case insensitive !! PM }
1525
for i:=1 to targetcnt do
1526
if target_infos[i].short_name=s then
1528
set_target_info(target_infos[i].target);
1529
set_string_target:=true;
1535
function set_string_asm(s : string) : boolean;
1539
set_string_asm:=false;
1540
{ this should be case insensitive !! PM }
1542
for i:=1 to asmcnt do
1543
if as_infos[i].idtxt=s then
1545
target_asm:=as_infos[i];
1546
set_string_asm:=true;
1551
function set_string_asmmode(s:string;var t:tasmmode):boolean;
1555
set_string_asmmode:=false;
1556
{ this should be case insensitive !! PM }
1558
for i:=1 to asmmodecnt do
1559
if asmmodeinfos[i].idtxt=s then
1561
t:=asmmodeinfos[i].id;
1562
set_string_asmmode:=true;
1567
{****************************************************************************
1568
Initialization of default target
1569
****************************************************************************}
1571
procedure default_os(t:ttarget);
1574
if source_os.name='' then
1575
source_os:=target_os;
1579
procedure set_source_os(t:tos);
1583
{ can't use message() here (PFV) }
1584
if source_os.name<>'' then
1585
Writeln('Warning: Source OS Redefined!');
1586
for i:=1 to oscnt do
1587
if os_infos[i].id=t then
1589
source_os:=os_infos[i];
1595
procedure InitSystems;
1597
{ first get source OS }
1599
{ please note then we use cpu86 and cpu68 here on purpose !! }
1602
set_source_os(os_i386_GO32V1);
1605
set_source_os(os_i386_GO32V2);
1608
set_source_os(os_i386_OS2);
1609
if (OS_Mode = osDOS) or (OS_Mode = osDPMI)
1610
then source_os.scriptext := '.bat';
1611
{OS/2 via EMX can be run under DOS as well}
1615
set_source_os(os_i386_FreeBSD);
1617
set_source_os(os_i386_LINUX);
1621
set_source_os(os_i386_WIN32);
1630
set_source_os(os_m68k_Amiga);
1633
set_source_os(os_m68k_Atari);
1636
set_source_os(os_m68k_MAC);
1639
set_source_os(os_m68k_linux);
1646
{ Now default target !! }
1649
default_os(target_i386_GO32V1);
1652
default_os(target_i386_GO32V2);
1655
default_os(target_i386_OS2);
1659
default_os(target_i386_FreeBSD);
1661
default_os(target_i386_LINUX);
1665
default_os(target_i386_WIN32);
1667
default_os(target_i386_GO32V2);
1676
default_os(target_m68k_Amiga);
1679
default_os(target_m68k_Atari);
1682
default_os(target_m68k_Mac);
1685
default_os(target_m68k_linux);
1687
default_os(target_m68k_Amiga);
1694
default_os(target_alpha_linux);
1697
default_os(target_powerpc_linux);
1706
$Log: systems.pas,v $
1707
Revision 1.1.2.4 2000/09/24 21:13:37 hajny
1708
* OS/2 default stack size increased
1710
Revision 1.1.2.3 2000/09/24 19:55:30 hajny
1711
* OS/2 stack alignment corrected (4)
1713
Revision 1.1.2.2 2000/09/13 13:57:41 marco
1714
* FreeBSD compiler support
1716
Revision 1.1.2.1 2000/08/07 12:32:47 jonas
1717
* reordered severam object fields to make optimal use of memory (avoid
1720
Revision 1.1 2000/07/13 06:29:57 michael
1723
Revision 1.106 2000/06/25 19:08:28 hajny
1724
+ $R support for OS/2 (EMX) added
1726
Revision 1.105 2000/06/23 21:31:18 pierre
1727
+ new target_os field: maxCstructalignment
1729
Revision 1.104 2000/05/23 21:26:52 pierre
1730
+ added supported_target fiedl to tasminfo record
1731
to disregard wrong assembler settings
1733
Revision 1.103 2000/05/11 09:07:45 pierre
1734
* change tosinfo.shortname length, reported by Kovacs Attila Zoltan
1736
Revision 1.102 2000/04/22 14:25:03 jonas
1737
* aasm.pas: pai_align instead of pai_align_abstract if cpu <> i386
1738
+ systems.pas: info for macos/ppc
1739
* new/cgobj.pas: compiles again without newst define
1740
* new/powerpc/cgcpu: generate different entry/exit code depending on
1741
whether target_os is MacOs or Linux
1743
Revision 1.101 2000/04/04 14:18:15 pierre
1744
* nasmwin32 is 9 chars long, idtxt changed accordingly
1746
Revision 1.100 2000/04/04 13:54:58 pierre
1747
+ nasmwin32 for win32 object output with nasm assembler
1749
Revision 1.99 2000/02/09 13:23:06 peter
1752
Revision 1.98 2000/01/07 01:14:42 peter
1753
* updated copyright to 2000
1755
Revision 1.97 1999/11/06 14:34:28 peter
1756
* truncated log to 20 revs
1758
Revision 1.96 1999/11/03 23:43:45 peter
1761
Revision 1.95 1999/10/21 14:29:37 peter
1762
* redesigned linker object
1763
+ library support for linux (only procedures can be exported)
1765
Revision 1.94 1999/09/15 22:09:27 florian
1766
+ rtti is now automatically generated for published classes, i.e.
1767
they are handled like an implicit property
1769
Revision 1.93 1999/09/15 20:24:56 daniel
1770
+ Dw switch now does something.
1772
Revision 1.92 1999/09/07 15:02:41 pierre
1773
* powerpc default was alpha !!
1775
Revision 1.91 1999/08/16 15:35:29 pierre
1776
* fix for DLL relocation problems
1777
* external bss vars had wrong stabs for pecoff
1778
+ -WB11000000 to specify default image base, allows to
1779
load several DLLs with debugging info included
1780
(relocatable DLL are stripped because the relocation
1781
of the .Stab section is misplaced by ldw)
1783
Revision 1.90 1999/08/04 13:03:11 jonas
1784
* all tokens now start with an underscore
1785
* PowerPC compiles!!
1787
Revision 1.89 1999/08/04 00:23:32 florian
1788
* renamed i386asm and i386base to cpuasm and cpubase
1790
Revision 1.88 1999/08/03 22:03:23 peter
1791
* moved bitmask constants to sets
1792
* some other type/const renamings
1794
Revision 1.87 1999/08/03 17:09:43 florian
1795
* the alpha compiler can be compiled now
1797
Revision 1.86 1999/08/03 15:52:00 michael
1798
* changed shortname for linux alpha
1800
Revision 1.85 1999/08/03 13:50:19 michael
1803
Revision 1.84 1999/08/02 23:56:51 michael
1804
+ Added alpha cpu and linux for alpha os
b'\\ No newline at end of file'