fpmake.pp 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115
  1. {$ifndef ALLPACKAGES}
  2. {$mode objfpc}{$H+}
  3. program fpmake;
  4. uses fpmkunit;
  5. {$endif ALLPACKAGES}
  6. procedure add_rtl_console(const ADirectory: string);
  7. Const
  8. // All Unices have full set of KVM+Crt in unix/ except QNX which is not
  9. // in workable state atm.
  10. UnixLikes = AllUnixOSes -[QNX];
  11. WinEventOSes = [win32,win64];
  12. KVMAll = [emx,go32v2,netware,netwlibc,os2,win32,win64]+UnixLikes+AllAmigaLikeOSes;
  13. // all full KVMers have crt too, except Amigalikes
  14. CrtOSes = KVMALL+[msdos,WatCom]-[aros,morphos];
  15. KbdOSes = KVMALL+[msdos];
  16. VideoOSes = KVMALL;
  17. MouseOSes = KVMALL;
  18. TerminfoOSes = UnixLikes-[beos,haiku];
  19. rtl_consoleOSes =KVMALL+CrtOSes+TermInfoOSes;
  20. // Amiga has a crt in its RTL dir, but it is commented in the makefile
  21. Var
  22. P : TPackage;
  23. T : TTarget;
  24. begin
  25. With Installer do
  26. begin
  27. P:=AddPackage('rtl-console');
  28. P.Directory:=ADirectory;
  29. P.Version:='2.7.1';
  30. P.Author := 'FPC core team, Pierre Mueller, Peter Vreman';
  31. P.License := 'LGPL with modification, ';
  32. P.HomepageURL := 'www.freepascal.org';
  33. P.OSes:=Rtl_ConsoleOSes;
  34. P.Email := '';
  35. P.Description := 'Rtl-console, console abstraction';
  36. P.NeedLibC:= false;
  37. P.Dependencies.Add('rtl-extra'); // linux,android gpm.
  38. P.Dependencies.Add('morphunits',[morphos]);
  39. P.Dependencies.Add('arosunits',[aros]);
  40. P.Dependencies.Add('amunits',[amiga]);
  41. P.SourcePath.Add('src/inc');
  42. P.SourcePath.Add('src/$(OS)');
  43. P.SourcePath.Add('src/darwin',[iphonesim]);
  44. P.SourcePath.Add('src/unix',AllUnixOSes);
  45. P.SourcePath.Add('src/os2commn',[os2,emx]);
  46. P.SourcePath.Add('src/amicommon',AllAmigaLikeOSes);
  47. P.SourcePath.Add('src/win',WinEventOSes);
  48. P.IncludePath.Add('src/inc');
  49. P.IncludePath.Add('src/unix',AllUnixOSes);
  50. P.IncludePath.add('src/amicommon',AllAmigaLikeOSes);
  51. P.IncludePath.Add('src/$(OS)');
  52. P.IncludePath.Add('src/darwin',[iphonesim]);
  53. T:=P.Targets.AddUnit('winevent.pp',WinEventOSes);
  54. T:=P.Targets.AddUnit('keyboard.pp',KbdOSes);
  55. with T.Dependencies do
  56. begin
  57. AddInclude('keybrdh.inc');
  58. AddInclude('keyboard.inc');
  59. AddInclude('keyscan.inc',AllUnixOSes);
  60. AddUnit ('winevent',[win32,win64]);
  61. AddInclude('nwsys.inc',[netware]);
  62. end;
  63. T:=P.Targets.AddUnit('mouse.pp',MouseOSes);
  64. with T.Dependencies do
  65. begin
  66. AddInclude('mouseh.inc');
  67. AddInclude('mouse.inc');
  68. AddUnit ('winevent',[win32,win64]);
  69. end;
  70. T:=P.Targets.AddUnit('video.pp',VideoOSes);
  71. with T.Dependencies do
  72. begin
  73. AddInclude('videoh.inc');
  74. AddInclude('video.inc');
  75. AddInclude('videodata.inc',AllAmigaLikeOSes);
  76. AddInclude('convert.inc',AllUnixOSes);
  77. AddInclude('nwsys.inc',[netware]);
  78. end;
  79. T:=P.Targets.AddUnit('crt.pp',CrtOSes);
  80. with T.Dependencies do
  81. begin
  82. AddInclude('crth.inc');
  83. AddInclude('crt.inc');
  84. AddInclude('nwsys.inc',[netware]);
  85. end;
  86. T:=P.Targets.AddUnit('vesamode.pp',[go32v2]);
  87. with T.Dependencies do
  88. AddUnit('video');
  89. end
  90. end;
  91. {$ifndef ALLPACKAGES}
  92. begin
  93. add_rtl_console('');
  94. Installer.Run;
  95. end.
  96. {$endif ALLPACKAGES}