2
0

fpmake.pp 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. {$ifndef ALLPACKAGES}
  2. {$define allpackages}
  3. {$define no_parent}
  4. {$mode objfpc}{$H+}
  5. program fpmake;
  6. {$IFDEF MORPHOS}
  7. {$DEFINE NO_UNIT_PROCESS}
  8. {$DEFINE NO_THREADING}
  9. {$ENDIF}
  10. {$IFDEF OS2}
  11. {$DEFINE NO_UNIT_PROCESS}
  12. {$ENDIF OS2}
  13. {$IFDEF GO32V2}
  14. {$DEFINE NO_UNIT_PROCESS}
  15. {$ENDIF GO32V2}
  16. {$ifndef NO_UNIT_PROCESS}
  17. {$define HAS_UNIT_PROCESS}
  18. {$endif NO_UNIT_PROCESS}
  19. uses
  20. fpmkunit,
  21. {$IFDEF HAS_UNIT_PROCESS}
  22. process,
  23. {$ENDIF HAS_UNIT_PROCESS}
  24. sysutils;
  25. {$endif ALLPACKAGES}
  26. (*
  27. The include files are generated with the following commands:
  28. rm fpmake_proc.inc fpmake_add.inc ; /bin/ls -1 */fpmake.pp| while read file; do cleanedname=`dirname $file | sed -e 's+-+_+g'` ; if ! `grep -i "^procedure add_$cleanedname" $file >/dev/null` ; then printf 'procedure add_%s(const ADirectory: string);\nbegin\n with Installer do\n{$include %s}\nend;\n\n' $cleanedname $file >> fpmake_proc.inc; else printf '{$include %s}\n\n' $file >> fpmake_proc.inc; fi; echo " add_$cleanedname(ADirectory+IncludeTrailingPathDelimiter('$cleanedname'));" >> fpmake_add.inc; done
  29. *)
  30. {$include fpmake_proc.inc}
  31. procedure add_utils(const ADirectory: string);
  32. Var
  33. P : TPackage;
  34. T : TTarget;
  35. begin
  36. With Installer do
  37. begin
  38. P:=AddPackage('utils');
  39. P.ShortName := 'tils';
  40. P.OSes:=AllOSes-[embedded,msdos,win16,macosclassic,palmos];
  41. if Defaults.CPU=jvm then
  42. P.OSes := P.OSes - [java,android];
  43. P.Author := '<various>';
  44. P.License := 'LGPL with modification';
  45. P.HomepageURL := 'www.freepascal.org';
  46. P.Email := '';
  47. P.Description := 'Various Free Pascal utilities.';
  48. P.NeedLibC:= false;
  49. {$ifndef NO_PARENT}
  50. P.Directory:=ADirectory;
  51. {$endif ALLPACKAGES}
  52. P.Dependencies.Add('fcl-base');
  53. P.Dependencies.Add('paszlib');
  54. P.Dependencies.Add('hash');
  55. P.Dependencies.Add('univint',[darwin,iphonesim,ios]);
  56. P.Dependencies.Add('fcl-json');
  57. P.Dependencies.Add('rtl-extra');
  58. P.Dependencies.Add('rtl-objpas');
  59. P.Version:='3.2.4-rc1';
  60. T:=P.Targets.AddProgram('ptop.pp');
  61. T.Dependencies.AddUnit('ptopu');
  62. T.ResourceStrings:=true;
  63. P.Targets.AddProgram('ppdep.pp');
  64. T:=P.Targets.AddProgram('rstconv.pp');
  65. T.ResourceStrings:=true;
  66. P.Targets.AddProgram('data2inc.pp');
  67. P.Targets.AddProgram('delp.pp');
  68. P.Targets.AddProgram('bin2obj.pp');
  69. P.Targets.AddProgram('mkinsadd.pp');
  70. P.Targets.AddProgram('postw32.pp');
  71. P.Targets.AddProgram('rmcvsdir.pp');
  72. P.Targets.AddProgram('grab_vcsa.pp',[linux]);
  73. T:=P.Targets.AddProgram('fpcsubst.pp');
  74. T.Dependencies.AddUnit('usubst');
  75. T.ResourceStrings:=true;
  76. P.Targets.AddUnit('usubst.pp').install:=false;
  77. P.Targets.AddUnit('ptopu.pp').install:=false;
  78. end;
  79. {$include fpmake_add.inc}
  80. end;
  81. {$ifdef NO_PARENT}
  82. begin
  83. add_utils('');
  84. Installer.Run;
  85. end.
  86. {$endif NO_PARENT}