Makefile 117 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467
  1. #
  2. # Don't edit, this file is generated by FPCMake Version 2.0.0 [2017-09-21 rev 37286]
  3. #
  4. default: all
  5. MAKEFILETARGETS=i386-linux i386-go32v2 i386-win32 i386-os2 i386-freebsd i386-beos i386-haiku i386-netbsd i386-solaris i386-netware i386-openbsd i386-wdosx i386-darwin i386-emx i386-watcom i386-netwlibc i386-wince i386-embedded i386-symbian i386-nativent i386-iphonesim i386-android i386-aros m68k-linux m68k-netbsd m68k-amiga m68k-atari m68k-palmos m68k-macos m68k-embedded powerpc-linux powerpc-netbsd powerpc-amiga powerpc-macos powerpc-darwin powerpc-morphos powerpc-embedded powerpc-wii powerpc-aix sparc-linux sparc-netbsd sparc-solaris sparc-embedded x86_64-linux x86_64-freebsd x86_64-netbsd x86_64-solaris x86_64-openbsd x86_64-darwin x86_64-win64 x86_64-embedded x86_64-iphonesim x86_64-aros x86_64-dragonfly arm-linux arm-palmos arm-darwin arm-wince arm-gba arm-nds arm-embedded arm-symbian arm-android arm-aros powerpc64-linux powerpc64-darwin powerpc64-embedded powerpc64-aix avr-embedded armeb-linux armeb-embedded mips-linux mipsel-linux mipsel-embedded mipsel-android jvm-java jvm-android i8086-embedded i8086-msdos i8086-win16 aarch64-linux aarch64-darwin wasm-wasm sparc64-linux
  6. BSDs = freebsd netbsd openbsd darwin dragonfly
  7. UNIXs = linux $(BSDs) solaris qnx haiku aix
  8. LIMIT83fs = go32v2 os2 emx watcom msdos win16
  9. OSNeedsComspecToRunBatch = go32v2 watcom
  10. FORCE:
  11. .PHONY: FORCE
  12. override PATH:=$(patsubst %/,%,$(subst \,/,$(PATH)))
  13. ifneq ($(findstring darwin,$(OSTYPE)),)
  14. inUnix=1 #darwin
  15. SEARCHPATH:=$(filter-out .,$(subst :, ,$(PATH)))
  16. else
  17. ifeq ($(findstring ;,$(PATH)),)
  18. inUnix=1
  19. SEARCHPATH:=$(filter-out .,$(subst :, ,$(PATH)))
  20. else
  21. SEARCHPATH:=$(subst ;, ,$(PATH))
  22. endif
  23. endif
  24. SEARCHPATH+=$(patsubst %/,%,$(subst \,/,$(dir $(MAKE))))
  25. PWD:=$(strip $(wildcard $(addsuffix /pwd.exe,$(SEARCHPATH))))
  26. ifeq ($(PWD),)
  27. PWD:=$(strip $(wildcard $(addsuffix /pwd,$(SEARCHPATH))))
  28. ifeq ($(PWD),)
  29. $(error You need the GNU utils package to use this Makefile)
  30. else
  31. PWD:=$(firstword $(PWD))
  32. SRCEXEEXT=
  33. endif
  34. else
  35. PWD:=$(firstword $(PWD))
  36. SRCEXEEXT=.exe
  37. endif
  38. ifndef inUnix
  39. ifeq ($(OS),Windows_NT)
  40. inWinNT=1
  41. else
  42. ifdef OS2_SHELL
  43. inOS2=1
  44. endif
  45. endif
  46. else
  47. ifneq ($(findstring cygdrive,$(PATH)),)
  48. inCygWin=1
  49. endif
  50. endif
  51. ifdef inUnix
  52. SRCBATCHEXT=.sh
  53. else
  54. ifdef inOS2
  55. SRCBATCHEXT=.cmd
  56. else
  57. SRCBATCHEXT=.bat
  58. endif
  59. endif
  60. ifdef COMSPEC
  61. ifneq ($(findstring $(OS_SOURCE),$(OSNeedsComspecToRunBatch)),)
  62. ifndef RUNBATCH
  63. RUNBATCH=$(COMSPEC) /C
  64. endif
  65. endif
  66. endif
  67. ifdef inUnix
  68. PATHSEP=/
  69. else
  70. PATHSEP:=$(subst /,\,/)
  71. ifdef inCygWin
  72. PATHSEP=/
  73. endif
  74. endif
  75. ifdef PWD
  76. BASEDIR:=$(subst \,/,$(shell $(PWD)))
  77. ifdef inCygWin
  78. ifneq ($(findstring /cygdrive/,$(BASEDIR)),)
  79. BASENODIR:=$(patsubst /cygdrive%,%,$(BASEDIR))
  80. BASEDRIVE:=$(firstword $(subst /, ,$(BASENODIR)))
  81. BASEDIR:=$(subst /cygdrive/$(BASEDRIVE)/,$(BASEDRIVE):/,$(BASEDIR))
  82. endif
  83. endif
  84. else
  85. BASEDIR=.
  86. endif
  87. ifdef inOS2
  88. ifndef ECHO
  89. ECHO:=$(strip $(wildcard $(addsuffix /gecho$(SRCEXEEXT),$(SEARCHPATH))))
  90. ifeq ($(ECHO),)
  91. ECHO:=$(strip $(wildcard $(addsuffix /echo$(SRCEXEEXT),$(SEARCHPATH))))
  92. ifeq ($(ECHO),)
  93. ECHO=echo
  94. else
  95. ECHO:=$(firstword $(ECHO))
  96. endif
  97. else
  98. ECHO:=$(firstword $(ECHO))
  99. endif
  100. endif
  101. export ECHO
  102. endif
  103. override OS_TARGET_DEFAULT=nds
  104. override CPU_TARGET_DEFAULT=arm
  105. override DEFAULT_FPCDIR=../../../../../..
  106. ifndef FPC
  107. ifdef PP
  108. FPC=$(PP)
  109. endif
  110. endif
  111. ifndef FPC
  112. FPCPROG:=$(strip $(wildcard $(addsuffix /fpc$(SRCEXEEXT),$(SEARCHPATH))))
  113. ifneq ($(FPCPROG),)
  114. FPCPROG:=$(firstword $(FPCPROG))
  115. ifneq ($(CPU_TARGET),)
  116. FPC:=$(shell $(FPCPROG) -P$(CPU_TARGET) -PB)
  117. else
  118. FPC:=$(shell $(FPCPROG) -PB)
  119. endif
  120. ifneq ($(findstring Error,$(FPC)),)
  121. override FPC=$(firstword $(strip $(wildcard $(addsuffix /ppc386$(SRCEXEEXT),$(SEARCHPATH)))))
  122. else
  123. ifeq ($(strip $(wildcard $(FPC))),)
  124. FPC:=$(firstword $(FPCPROG))
  125. endif
  126. endif
  127. else
  128. override FPC=$(firstword $(strip $(wildcard $(addsuffix /ppc386$(SRCEXEEXT),$(SEARCHPATH)))))
  129. endif
  130. endif
  131. override FPC:=$(subst $(SRCEXEEXT),,$(FPC))
  132. override FPC:=$(subst \,/,$(FPC))$(SRCEXEEXT)
  133. FOUNDFPC:=$(strip $(wildcard $(FPC)))
  134. ifeq ($(FOUNDFPC),)
  135. FOUNDFPC=$(strip $(wildcard $(addsuffix /$(FPC),$(SEARCHPATH))))
  136. ifeq ($(FOUNDFPC),)
  137. $(error Compiler $(FPC) not found)
  138. endif
  139. endif
  140. ifndef FPC_COMPILERINFO
  141. FPC_COMPILERINFO:=$(shell $(FPC) -iVSPTPSOTO)
  142. endif
  143. ifndef FPC_VERSION
  144. FPC_VERSION:=$(word 1,$(FPC_COMPILERINFO))
  145. endif
  146. export FPC FPC_VERSION FPC_COMPILERINFO
  147. unexport CHECKDEPEND ALLDEPENDENCIES
  148. ifndef CPU_TARGET
  149. ifdef CPU_TARGET_DEFAULT
  150. CPU_TARGET=$(CPU_TARGET_DEFAULT)
  151. endif
  152. endif
  153. ifndef OS_TARGET
  154. ifdef OS_TARGET_DEFAULT
  155. OS_TARGET=$(OS_TARGET_DEFAULT)
  156. endif
  157. endif
  158. ifndef CPU_SOURCE
  159. CPU_SOURCE:=$(word 2,$(FPC_COMPILERINFO))
  160. endif
  161. ifndef CPU_TARGET
  162. CPU_TARGET:=$(word 3,$(FPC_COMPILERINFO))
  163. endif
  164. ifndef OS_SOURCE
  165. OS_SOURCE:=$(word 4,$(FPC_COMPILERINFO))
  166. endif
  167. ifndef OS_TARGET
  168. OS_TARGET:=$(word 5,$(FPC_COMPILERINFO))
  169. endif
  170. FULL_TARGET=$(CPU_TARGET)-$(OS_TARGET)
  171. FULL_SOURCE=$(CPU_SOURCE)-$(OS_SOURCE)
  172. ifeq ($(CPU_TARGET),armeb)
  173. ARCH=arm
  174. override FPCOPT+=-Cb
  175. else
  176. ifeq ($(CPU_TARGET),armel)
  177. ARCH=arm
  178. override FPCOPT+=-CaEABI
  179. else
  180. ARCH=$(CPU_TARGET)
  181. endif
  182. endif
  183. ifeq ($(FULL_TARGET),arm-embedded)
  184. ifeq ($(SUBARCH),)
  185. $(error When compiling for arm-embedded, a sub-architecture (e.g. SUBARCH=armv4t or SUBARCH=armv7m) must be defined)
  186. endif
  187. override FPCOPT+=-Cp$(SUBARCH)
  188. endif
  189. ifeq ($(FULL_TARGET),avr-embedded)
  190. ifeq ($(SUBARCH),)
  191. $(error When compiling for avr-embedded, a sub-architecture (e.g. SUBARCH=avr25 or SUBARCH=avr35) must be defined)
  192. endif
  193. override FPCOPT+=-Cp$(SUBARCH)
  194. endif
  195. ifeq ($(FULL_TARGET),mipsel-embedded)
  196. ifeq ($(SUBARCH),)
  197. $(error When compiling for mipsel-embedded, a sub-architecture (e.g. SUBARCH=pic32mx) must be defined)
  198. endif
  199. override FPCOPT+=-Cp$(SUBARCH)
  200. endif
  201. ifneq ($(findstring $(OS_SOURCE),$(LIMIT83fs)),)
  202. TARGETSUFFIX=$(OS_TARGET)
  203. SOURCESUFFIX=$(OS_SOURCE)
  204. else
  205. ifneq ($(findstring $(OS_TARGET),$(LIMIT83fs)),)
  206. TARGETSUFFIX=$(OS_TARGET)
  207. else
  208. TARGETSUFFIX=$(FULL_TARGET)
  209. endif
  210. SOURCESUFFIX=$(FULL_SOURCE)
  211. endif
  212. ifneq ($(FULL_TARGET),$(FULL_SOURCE))
  213. CROSSCOMPILE=1
  214. endif
  215. ifeq ($(findstring makefile,$(MAKECMDGOALS)),)
  216. ifeq ($(findstring $(FULL_TARGET),$(MAKEFILETARGETS)),)
  217. $(error The Makefile doesn't support target $(FULL_TARGET), please run fpcmake first)
  218. endif
  219. endif
  220. ifneq ($(findstring $(OS_TARGET),$(BSDs)),)
  221. BSDhier=1
  222. endif
  223. ifeq ($(OS_TARGET),linux)
  224. linuxHier=1
  225. endif
  226. ifndef CROSSCOMPILE
  227. BUILDFULLNATIVE=1
  228. export BUILDFULLNATIVE
  229. endif
  230. ifdef BUILDFULLNATIVE
  231. BUILDNATIVE=1
  232. export BUILDNATIVE
  233. endif
  234. export OS_TARGET OS_SOURCE ARCH CPU_TARGET CPU_SOURCE FULL_TARGET FULL_SOURCE TARGETSUFFIX SOURCESUFFIX CROSSCOMPILE
  235. ifdef FPCDIR
  236. override FPCDIR:=$(subst \,/,$(FPCDIR))
  237. ifeq ($(wildcard $(addprefix $(FPCDIR)/,rtl)),)
  238. override FPCDIR=wrong
  239. endif
  240. else
  241. override FPCDIR=wrong
  242. endif
  243. ifdef DEFAULT_FPCDIR
  244. ifeq ($(FPCDIR),wrong)
  245. override FPCDIR:=$(subst \,/,$(DEFAULT_FPCDIR))
  246. ifeq ($(wildcard $(addprefix $(FPCDIR)/,rtl)),)
  247. override FPCDIR=wrong
  248. endif
  249. endif
  250. endif
  251. ifeq ($(FPCDIR),wrong)
  252. ifdef inUnix
  253. override FPCDIR=/usr/local/lib/fpc/$(FPC_VERSION)
  254. ifeq ($(wildcard $(FPCDIR)/units),)
  255. override FPCDIR=/usr/lib/fpc/$(FPC_VERSION)
  256. endif
  257. else
  258. override FPCDIR:=$(subst /$(FPC),,$(firstword $(strip $(wildcard $(addsuffix /$(FPC),$(SEARCHPATH))))))
  259. override FPCDIR:=$(FPCDIR)/..
  260. ifeq ($(wildcard $(addprefix $(FPCDIR)/,rtl)),)
  261. override FPCDIR:=$(FPCDIR)/..
  262. ifeq ($(wildcard $(addprefix $(FPCDIR)/,rtl)),)
  263. override FPCDIR:=$(BASEDIR)
  264. ifeq ($(wildcard $(addprefix $(FPCDIR)/,rtl)),)
  265. override FPCDIR=c:/pp
  266. endif
  267. endif
  268. endif
  269. endif
  270. endif
  271. ifndef CROSSBINDIR
  272. CROSSBINDIR:=$(wildcard $(FPCDIR)/bin/$(TARGETSUFFIX))
  273. endif
  274. ifneq ($(findstring $(OS_TARGET),darwin iphonesim),)
  275. ifeq ($(OS_SOURCE),darwin)
  276. DARWIN2DARWIN=1
  277. endif
  278. endif
  279. ifndef BINUTILSPREFIX
  280. ifndef CROSSBINDIR
  281. ifdef CROSSCOMPILE
  282. ifneq ($(OS_TARGET),msdos)
  283. ifndef DARWIN2DARWIN
  284. ifneq ($(CPU_TARGET),jvm)
  285. BINUTILSPREFIX=$(CPU_TARGET)-$(OS_TARGET)-
  286. ifeq ($(OS_TARGET),android)
  287. ifeq ($(CPU_TARGET),arm)
  288. BINUTILSPREFIX=arm-linux-androideabi-
  289. else
  290. ifeq ($(CPU_TARGET),i386)
  291. BINUTILSPREFIX=i686-linux-android-
  292. else
  293. ifeq ($(CPU_TARGET),mipsel)
  294. BINUTILSPREFIX=mipsel-linux-android-
  295. endif
  296. endif
  297. endif
  298. endif
  299. endif
  300. endif
  301. else
  302. BINUTILSPREFIX=$(OS_TARGET)-
  303. endif
  304. endif
  305. endif
  306. endif
  307. UNITSDIR:=$(wildcard $(FPCDIR)/units/$(TARGETSUFFIX))
  308. ifeq ($(UNITSDIR),)
  309. UNITSDIR:=$(wildcard $(FPCDIR)/units/$(OS_TARGET))
  310. endif
  311. PACKAGESDIR:=$(wildcard $(FPCDIR) $(FPCDIR)/packages)
  312. ifndef FPCFPMAKE
  313. ifdef CROSSCOMPILE
  314. ifeq ($(strip $(wildcard $(addsuffix /compiler/ppc$(SRCEXEEXT),$(FPCDIR)))),)
  315. FPCPROG:=$(strip $(wildcard $(addsuffix /fpc$(SRCEXEEXT),$(SEARCHPATH))))
  316. ifneq ($(FPCPROG),)
  317. FPCPROG:=$(firstword $(FPCPROG))
  318. FPCFPMAKE:=$(shell $(FPCPROG) -PB)
  319. ifeq ($(strip $(wildcard $(FPCFPMAKE))),)
  320. FPCFPMAKE:=$(firstword $(FPCPROG))
  321. endif
  322. else
  323. override FPCFPMAKE=$(firstword $(strip $(wildcard $(addsuffix /ppc386$(SRCEXEEXT),$(SEARCHPATH)))))
  324. endif
  325. else
  326. FPCFPMAKE=$(strip $(wildcard $(addsuffix /compiler/ppc$(SRCEXEEXT),$(FPCDIR))))
  327. FPMAKE_SKIP_CONFIG=-n
  328. export FPCFPMAKE
  329. export FPMAKE_SKIP_CONFIG
  330. endif
  331. else
  332. FPMAKE_SKIP_CONFIG=-n
  333. FPCFPMAKE=$(FPC)
  334. endif
  335. endif
  336. BIN = bin
  337. BUILD = build
  338. DATA = data
  339. FILESYSTEM = filesystem
  340. GFX = gfx
  341. INC = inc
  342. AUDIO_FILES = $(foreach dir, $(notdir $(wildcard audio/*.*)), $(CURDIR)/audio/$(dir))
  343. GFX_FILES = $(foreach dir, $(GFX), $(notdir $(wildcard $(dir)/*.bmp $(dir)/*.png)))
  344. BIN_FILES = $(foreach dir, $(DATA), $(notdir $(wildcard $(dir)/*)))
  345. GBFS_FILES = $(foreach dir, GBFS, $(notdir $(wildcard $(dir)/*)))
  346. ifeq ($(FULL_TARGET),i386-linux)
  347. override TARGET_PROGRAMS+=audio_modes
  348. endif
  349. ifeq ($(FULL_TARGET),i386-go32v2)
  350. override TARGET_PROGRAMS+=audio_modes
  351. endif
  352. ifeq ($(FULL_TARGET),i386-win32)
  353. override TARGET_PROGRAMS+=audio_modes
  354. endif
  355. ifeq ($(FULL_TARGET),i386-os2)
  356. override TARGET_PROGRAMS+=audio_modes
  357. endif
  358. ifeq ($(FULL_TARGET),i386-freebsd)
  359. override TARGET_PROGRAMS+=audio_modes
  360. endif
  361. ifeq ($(FULL_TARGET),i386-beos)
  362. override TARGET_PROGRAMS+=audio_modes
  363. endif
  364. ifeq ($(FULL_TARGET),i386-haiku)
  365. override TARGET_PROGRAMS+=audio_modes
  366. endif
  367. ifeq ($(FULL_TARGET),i386-netbsd)
  368. override TARGET_PROGRAMS+=audio_modes
  369. endif
  370. ifeq ($(FULL_TARGET),i386-solaris)
  371. override TARGET_PROGRAMS+=audio_modes
  372. endif
  373. ifeq ($(FULL_TARGET),i386-netware)
  374. override TARGET_PROGRAMS+=audio_modes
  375. endif
  376. ifeq ($(FULL_TARGET),i386-openbsd)
  377. override TARGET_PROGRAMS+=audio_modes
  378. endif
  379. ifeq ($(FULL_TARGET),i386-wdosx)
  380. override TARGET_PROGRAMS+=audio_modes
  381. endif
  382. ifeq ($(FULL_TARGET),i386-darwin)
  383. override TARGET_PROGRAMS+=audio_modes
  384. endif
  385. ifeq ($(FULL_TARGET),i386-emx)
  386. override TARGET_PROGRAMS+=audio_modes
  387. endif
  388. ifeq ($(FULL_TARGET),i386-watcom)
  389. override TARGET_PROGRAMS+=audio_modes
  390. endif
  391. ifeq ($(FULL_TARGET),i386-netwlibc)
  392. override TARGET_PROGRAMS+=audio_modes
  393. endif
  394. ifeq ($(FULL_TARGET),i386-wince)
  395. override TARGET_PROGRAMS+=audio_modes
  396. endif
  397. ifeq ($(FULL_TARGET),i386-embedded)
  398. override TARGET_PROGRAMS+=audio_modes
  399. endif
  400. ifeq ($(FULL_TARGET),i386-symbian)
  401. override TARGET_PROGRAMS+=audio_modes
  402. endif
  403. ifeq ($(FULL_TARGET),i386-nativent)
  404. override TARGET_PROGRAMS+=audio_modes
  405. endif
  406. ifeq ($(FULL_TARGET),i386-iphonesim)
  407. override TARGET_PROGRAMS+=audio_modes
  408. endif
  409. ifeq ($(FULL_TARGET),i386-android)
  410. override TARGET_PROGRAMS+=audio_modes
  411. endif
  412. ifeq ($(FULL_TARGET),i386-aros)
  413. override TARGET_PROGRAMS+=audio_modes
  414. endif
  415. ifeq ($(FULL_TARGET),m68k-linux)
  416. override TARGET_PROGRAMS+=audio_modes
  417. endif
  418. ifeq ($(FULL_TARGET),m68k-netbsd)
  419. override TARGET_PROGRAMS+=audio_modes
  420. endif
  421. ifeq ($(FULL_TARGET),m68k-amiga)
  422. override TARGET_PROGRAMS+=audio_modes
  423. endif
  424. ifeq ($(FULL_TARGET),m68k-atari)
  425. override TARGET_PROGRAMS+=audio_modes
  426. endif
  427. ifeq ($(FULL_TARGET),m68k-palmos)
  428. override TARGET_PROGRAMS+=audio_modes
  429. endif
  430. ifeq ($(FULL_TARGET),m68k-macos)
  431. override TARGET_PROGRAMS+=audio_modes
  432. endif
  433. ifeq ($(FULL_TARGET),m68k-embedded)
  434. override TARGET_PROGRAMS+=audio_modes
  435. endif
  436. ifeq ($(FULL_TARGET),powerpc-linux)
  437. override TARGET_PROGRAMS+=audio_modes
  438. endif
  439. ifeq ($(FULL_TARGET),powerpc-netbsd)
  440. override TARGET_PROGRAMS+=audio_modes
  441. endif
  442. ifeq ($(FULL_TARGET),powerpc-amiga)
  443. override TARGET_PROGRAMS+=audio_modes
  444. endif
  445. ifeq ($(FULL_TARGET),powerpc-macos)
  446. override TARGET_PROGRAMS+=audio_modes
  447. endif
  448. ifeq ($(FULL_TARGET),powerpc-darwin)
  449. override TARGET_PROGRAMS+=audio_modes
  450. endif
  451. ifeq ($(FULL_TARGET),powerpc-morphos)
  452. override TARGET_PROGRAMS+=audio_modes
  453. endif
  454. ifeq ($(FULL_TARGET),powerpc-embedded)
  455. override TARGET_PROGRAMS+=audio_modes
  456. endif
  457. ifeq ($(FULL_TARGET),powerpc-wii)
  458. override TARGET_PROGRAMS+=audio_modes
  459. endif
  460. ifeq ($(FULL_TARGET),powerpc-aix)
  461. override TARGET_PROGRAMS+=audio_modes
  462. endif
  463. ifeq ($(FULL_TARGET),sparc-linux)
  464. override TARGET_PROGRAMS+=audio_modes
  465. endif
  466. ifeq ($(FULL_TARGET),sparc-netbsd)
  467. override TARGET_PROGRAMS+=audio_modes
  468. endif
  469. ifeq ($(FULL_TARGET),sparc-solaris)
  470. override TARGET_PROGRAMS+=audio_modes
  471. endif
  472. ifeq ($(FULL_TARGET),sparc-embedded)
  473. override TARGET_PROGRAMS+=audio_modes
  474. endif
  475. ifeq ($(FULL_TARGET),x86_64-linux)
  476. override TARGET_PROGRAMS+=audio_modes
  477. endif
  478. ifeq ($(FULL_TARGET),x86_64-freebsd)
  479. override TARGET_PROGRAMS+=audio_modes
  480. endif
  481. ifeq ($(FULL_TARGET),x86_64-netbsd)
  482. override TARGET_PROGRAMS+=audio_modes
  483. endif
  484. ifeq ($(FULL_TARGET),x86_64-solaris)
  485. override TARGET_PROGRAMS+=audio_modes
  486. endif
  487. ifeq ($(FULL_TARGET),x86_64-openbsd)
  488. override TARGET_PROGRAMS+=audio_modes
  489. endif
  490. ifeq ($(FULL_TARGET),x86_64-darwin)
  491. override TARGET_PROGRAMS+=audio_modes
  492. endif
  493. ifeq ($(FULL_TARGET),x86_64-win64)
  494. override TARGET_PROGRAMS+=audio_modes
  495. endif
  496. ifeq ($(FULL_TARGET),x86_64-embedded)
  497. override TARGET_PROGRAMS+=audio_modes
  498. endif
  499. ifeq ($(FULL_TARGET),x86_64-iphonesim)
  500. override TARGET_PROGRAMS+=audio_modes
  501. endif
  502. ifeq ($(FULL_TARGET),x86_64-aros)
  503. override TARGET_PROGRAMS+=audio_modes
  504. endif
  505. ifeq ($(FULL_TARGET),x86_64-dragonfly)
  506. override TARGET_PROGRAMS+=audio_modes
  507. endif
  508. ifeq ($(FULL_TARGET),arm-linux)
  509. override TARGET_PROGRAMS+=audio_modes
  510. endif
  511. ifeq ($(FULL_TARGET),arm-palmos)
  512. override TARGET_PROGRAMS+=audio_modes
  513. endif
  514. ifeq ($(FULL_TARGET),arm-darwin)
  515. override TARGET_PROGRAMS+=audio_modes
  516. endif
  517. ifeq ($(FULL_TARGET),arm-wince)
  518. override TARGET_PROGRAMS+=audio_modes
  519. endif
  520. ifeq ($(FULL_TARGET),arm-gba)
  521. override TARGET_PROGRAMS+=audio_modes
  522. endif
  523. ifeq ($(FULL_TARGET),arm-nds)
  524. override TARGET_PROGRAMS+=audio_modes
  525. endif
  526. ifeq ($(FULL_TARGET),arm-embedded)
  527. override TARGET_PROGRAMS+=audio_modes
  528. endif
  529. ifeq ($(FULL_TARGET),arm-symbian)
  530. override TARGET_PROGRAMS+=audio_modes
  531. endif
  532. ifeq ($(FULL_TARGET),arm-android)
  533. override TARGET_PROGRAMS+=audio_modes
  534. endif
  535. ifeq ($(FULL_TARGET),arm-aros)
  536. override TARGET_PROGRAMS+=audio_modes
  537. endif
  538. ifeq ($(FULL_TARGET),powerpc64-linux)
  539. override TARGET_PROGRAMS+=audio_modes
  540. endif
  541. ifeq ($(FULL_TARGET),powerpc64-darwin)
  542. override TARGET_PROGRAMS+=audio_modes
  543. endif
  544. ifeq ($(FULL_TARGET),powerpc64-embedded)
  545. override TARGET_PROGRAMS+=audio_modes
  546. endif
  547. ifeq ($(FULL_TARGET),powerpc64-aix)
  548. override TARGET_PROGRAMS+=audio_modes
  549. endif
  550. ifeq ($(FULL_TARGET),avr-embedded)
  551. override TARGET_PROGRAMS+=audio_modes
  552. endif
  553. ifeq ($(FULL_TARGET),armeb-linux)
  554. override TARGET_PROGRAMS+=audio_modes
  555. endif
  556. ifeq ($(FULL_TARGET),armeb-embedded)
  557. override TARGET_PROGRAMS+=audio_modes
  558. endif
  559. ifeq ($(FULL_TARGET),mips-linux)
  560. override TARGET_PROGRAMS+=audio_modes
  561. endif
  562. ifeq ($(FULL_TARGET),mipsel-linux)
  563. override TARGET_PROGRAMS+=audio_modes
  564. endif
  565. ifeq ($(FULL_TARGET),mipsel-embedded)
  566. override TARGET_PROGRAMS+=audio_modes
  567. endif
  568. ifeq ($(FULL_TARGET),mipsel-android)
  569. override TARGET_PROGRAMS+=audio_modes
  570. endif
  571. ifeq ($(FULL_TARGET),jvm-java)
  572. override TARGET_PROGRAMS+=audio_modes
  573. endif
  574. ifeq ($(FULL_TARGET),jvm-android)
  575. override TARGET_PROGRAMS+=audio_modes
  576. endif
  577. ifeq ($(FULL_TARGET),i8086-embedded)
  578. override TARGET_PROGRAMS+=audio_modes
  579. endif
  580. ifeq ($(FULL_TARGET),i8086-msdos)
  581. override TARGET_PROGRAMS+=audio_modes
  582. endif
  583. ifeq ($(FULL_TARGET),i8086-win16)
  584. override TARGET_PROGRAMS+=audio_modes
  585. endif
  586. ifeq ($(FULL_TARGET),aarch64-linux)
  587. override TARGET_PROGRAMS+=audio_modes
  588. endif
  589. ifeq ($(FULL_TARGET),aarch64-darwin)
  590. override TARGET_PROGRAMS+=audio_modes
  591. endif
  592. ifeq ($(FULL_TARGET),wasm-wasm)
  593. override TARGET_PROGRAMS+=audio_modes
  594. endif
  595. ifeq ($(FULL_TARGET),sparc64-linux)
  596. override TARGET_PROGRAMS+=audio_modes
  597. endif
  598. ifeq ($(FULL_TARGET),i386-linux)
  599. override TARGET_LOADERS+=soundbank.bin
  600. endif
  601. ifeq ($(FULL_TARGET),i386-go32v2)
  602. override TARGET_LOADERS+=soundbank.bin
  603. endif
  604. ifeq ($(FULL_TARGET),i386-win32)
  605. override TARGET_LOADERS+=soundbank.bin
  606. endif
  607. ifeq ($(FULL_TARGET),i386-os2)
  608. override TARGET_LOADERS+=soundbank.bin
  609. endif
  610. ifeq ($(FULL_TARGET),i386-freebsd)
  611. override TARGET_LOADERS+=soundbank.bin
  612. endif
  613. ifeq ($(FULL_TARGET),i386-beos)
  614. override TARGET_LOADERS+=soundbank.bin
  615. endif
  616. ifeq ($(FULL_TARGET),i386-haiku)
  617. override TARGET_LOADERS+=soundbank.bin
  618. endif
  619. ifeq ($(FULL_TARGET),i386-netbsd)
  620. override TARGET_LOADERS+=soundbank.bin
  621. endif
  622. ifeq ($(FULL_TARGET),i386-solaris)
  623. override TARGET_LOADERS+=soundbank.bin
  624. endif
  625. ifeq ($(FULL_TARGET),i386-netware)
  626. override TARGET_LOADERS+=soundbank.bin
  627. endif
  628. ifeq ($(FULL_TARGET),i386-openbsd)
  629. override TARGET_LOADERS+=soundbank.bin
  630. endif
  631. ifeq ($(FULL_TARGET),i386-wdosx)
  632. override TARGET_LOADERS+=soundbank.bin
  633. endif
  634. ifeq ($(FULL_TARGET),i386-darwin)
  635. override TARGET_LOADERS+=soundbank.bin
  636. endif
  637. ifeq ($(FULL_TARGET),i386-emx)
  638. override TARGET_LOADERS+=soundbank.bin
  639. endif
  640. ifeq ($(FULL_TARGET),i386-watcom)
  641. override TARGET_LOADERS+=soundbank.bin
  642. endif
  643. ifeq ($(FULL_TARGET),i386-netwlibc)
  644. override TARGET_LOADERS+=soundbank.bin
  645. endif
  646. ifeq ($(FULL_TARGET),i386-wince)
  647. override TARGET_LOADERS+=soundbank.bin
  648. endif
  649. ifeq ($(FULL_TARGET),i386-embedded)
  650. override TARGET_LOADERS+=soundbank.bin
  651. endif
  652. ifeq ($(FULL_TARGET),i386-symbian)
  653. override TARGET_LOADERS+=soundbank.bin
  654. endif
  655. ifeq ($(FULL_TARGET),i386-nativent)
  656. override TARGET_LOADERS+=soundbank.bin
  657. endif
  658. ifeq ($(FULL_TARGET),i386-iphonesim)
  659. override TARGET_LOADERS+=soundbank.bin
  660. endif
  661. ifeq ($(FULL_TARGET),i386-android)
  662. override TARGET_LOADERS+=soundbank.bin
  663. endif
  664. ifeq ($(FULL_TARGET),i386-aros)
  665. override TARGET_LOADERS+=soundbank.bin
  666. endif
  667. ifeq ($(FULL_TARGET),m68k-linux)
  668. override TARGET_LOADERS+=soundbank.bin
  669. endif
  670. ifeq ($(FULL_TARGET),m68k-netbsd)
  671. override TARGET_LOADERS+=soundbank.bin
  672. endif
  673. ifeq ($(FULL_TARGET),m68k-amiga)
  674. override TARGET_LOADERS+=soundbank.bin
  675. endif
  676. ifeq ($(FULL_TARGET),m68k-atari)
  677. override TARGET_LOADERS+=soundbank.bin
  678. endif
  679. ifeq ($(FULL_TARGET),m68k-palmos)
  680. override TARGET_LOADERS+=soundbank.bin
  681. endif
  682. ifeq ($(FULL_TARGET),m68k-macos)
  683. override TARGET_LOADERS+=soundbank.bin
  684. endif
  685. ifeq ($(FULL_TARGET),m68k-embedded)
  686. override TARGET_LOADERS+=soundbank.bin
  687. endif
  688. ifeq ($(FULL_TARGET),powerpc-linux)
  689. override TARGET_LOADERS+=soundbank.bin
  690. endif
  691. ifeq ($(FULL_TARGET),powerpc-netbsd)
  692. override TARGET_LOADERS+=soundbank.bin
  693. endif
  694. ifeq ($(FULL_TARGET),powerpc-amiga)
  695. override TARGET_LOADERS+=soundbank.bin
  696. endif
  697. ifeq ($(FULL_TARGET),powerpc-macos)
  698. override TARGET_LOADERS+=soundbank.bin
  699. endif
  700. ifeq ($(FULL_TARGET),powerpc-darwin)
  701. override TARGET_LOADERS+=soundbank.bin
  702. endif
  703. ifeq ($(FULL_TARGET),powerpc-morphos)
  704. override TARGET_LOADERS+=soundbank.bin
  705. endif
  706. ifeq ($(FULL_TARGET),powerpc-embedded)
  707. override TARGET_LOADERS+=soundbank.bin
  708. endif
  709. ifeq ($(FULL_TARGET),powerpc-wii)
  710. override TARGET_LOADERS+=soundbank.bin
  711. endif
  712. ifeq ($(FULL_TARGET),powerpc-aix)
  713. override TARGET_LOADERS+=soundbank.bin
  714. endif
  715. ifeq ($(FULL_TARGET),sparc-linux)
  716. override TARGET_LOADERS+=soundbank.bin
  717. endif
  718. ifeq ($(FULL_TARGET),sparc-netbsd)
  719. override TARGET_LOADERS+=soundbank.bin
  720. endif
  721. ifeq ($(FULL_TARGET),sparc-solaris)
  722. override TARGET_LOADERS+=soundbank.bin
  723. endif
  724. ifeq ($(FULL_TARGET),sparc-embedded)
  725. override TARGET_LOADERS+=soundbank.bin
  726. endif
  727. ifeq ($(FULL_TARGET),x86_64-linux)
  728. override TARGET_LOADERS+=soundbank.bin
  729. endif
  730. ifeq ($(FULL_TARGET),x86_64-freebsd)
  731. override TARGET_LOADERS+=soundbank.bin
  732. endif
  733. ifeq ($(FULL_TARGET),x86_64-netbsd)
  734. override TARGET_LOADERS+=soundbank.bin
  735. endif
  736. ifeq ($(FULL_TARGET),x86_64-solaris)
  737. override TARGET_LOADERS+=soundbank.bin
  738. endif
  739. ifeq ($(FULL_TARGET),x86_64-openbsd)
  740. override TARGET_LOADERS+=soundbank.bin
  741. endif
  742. ifeq ($(FULL_TARGET),x86_64-darwin)
  743. override TARGET_LOADERS+=soundbank.bin
  744. endif
  745. ifeq ($(FULL_TARGET),x86_64-win64)
  746. override TARGET_LOADERS+=soundbank.bin
  747. endif
  748. ifeq ($(FULL_TARGET),x86_64-embedded)
  749. override TARGET_LOADERS+=soundbank.bin
  750. endif
  751. ifeq ($(FULL_TARGET),x86_64-iphonesim)
  752. override TARGET_LOADERS+=soundbank.bin
  753. endif
  754. ifeq ($(FULL_TARGET),x86_64-aros)
  755. override TARGET_LOADERS+=soundbank.bin
  756. endif
  757. ifeq ($(FULL_TARGET),x86_64-dragonfly)
  758. override TARGET_LOADERS+=soundbank.bin
  759. endif
  760. ifeq ($(FULL_TARGET),arm-linux)
  761. override TARGET_LOADERS+=soundbank.bin
  762. endif
  763. ifeq ($(FULL_TARGET),arm-palmos)
  764. override TARGET_LOADERS+=soundbank.bin
  765. endif
  766. ifeq ($(FULL_TARGET),arm-darwin)
  767. override TARGET_LOADERS+=soundbank.bin
  768. endif
  769. ifeq ($(FULL_TARGET),arm-wince)
  770. override TARGET_LOADERS+=soundbank.bin
  771. endif
  772. ifeq ($(FULL_TARGET),arm-gba)
  773. override TARGET_LOADERS+=soundbank.bin
  774. endif
  775. ifeq ($(FULL_TARGET),arm-nds)
  776. override TARGET_LOADERS+=soundbank.bin
  777. endif
  778. ifeq ($(FULL_TARGET),arm-embedded)
  779. override TARGET_LOADERS+=soundbank.bin
  780. endif
  781. ifeq ($(FULL_TARGET),arm-symbian)
  782. override TARGET_LOADERS+=soundbank.bin
  783. endif
  784. ifeq ($(FULL_TARGET),arm-android)
  785. override TARGET_LOADERS+=soundbank.bin
  786. endif
  787. ifeq ($(FULL_TARGET),arm-aros)
  788. override TARGET_LOADERS+=soundbank.bin
  789. endif
  790. ifeq ($(FULL_TARGET),powerpc64-linux)
  791. override TARGET_LOADERS+=soundbank.bin
  792. endif
  793. ifeq ($(FULL_TARGET),powerpc64-darwin)
  794. override TARGET_LOADERS+=soundbank.bin
  795. endif
  796. ifeq ($(FULL_TARGET),powerpc64-embedded)
  797. override TARGET_LOADERS+=soundbank.bin
  798. endif
  799. ifeq ($(FULL_TARGET),powerpc64-aix)
  800. override TARGET_LOADERS+=soundbank.bin
  801. endif
  802. ifeq ($(FULL_TARGET),avr-embedded)
  803. override TARGET_LOADERS+=soundbank.bin
  804. endif
  805. ifeq ($(FULL_TARGET),armeb-linux)
  806. override TARGET_LOADERS+=soundbank.bin
  807. endif
  808. ifeq ($(FULL_TARGET),armeb-embedded)
  809. override TARGET_LOADERS+=soundbank.bin
  810. endif
  811. ifeq ($(FULL_TARGET),mips-linux)
  812. override TARGET_LOADERS+=soundbank.bin
  813. endif
  814. ifeq ($(FULL_TARGET),mipsel-linux)
  815. override TARGET_LOADERS+=soundbank.bin
  816. endif
  817. ifeq ($(FULL_TARGET),mipsel-embedded)
  818. override TARGET_LOADERS+=soundbank.bin
  819. endif
  820. ifeq ($(FULL_TARGET),mipsel-android)
  821. override TARGET_LOADERS+=soundbank.bin
  822. endif
  823. ifeq ($(FULL_TARGET),jvm-java)
  824. override TARGET_LOADERS+=soundbank.bin
  825. endif
  826. ifeq ($(FULL_TARGET),jvm-android)
  827. override TARGET_LOADERS+=soundbank.bin
  828. endif
  829. ifeq ($(FULL_TARGET),i8086-embedded)
  830. override TARGET_LOADERS+=soundbank.bin
  831. endif
  832. ifeq ($(FULL_TARGET),i8086-msdos)
  833. override TARGET_LOADERS+=soundbank.bin
  834. endif
  835. ifeq ($(FULL_TARGET),i8086-win16)
  836. override TARGET_LOADERS+=soundbank.bin
  837. endif
  838. ifeq ($(FULL_TARGET),aarch64-linux)
  839. override TARGET_LOADERS+=soundbank.bin
  840. endif
  841. ifeq ($(FULL_TARGET),aarch64-darwin)
  842. override TARGET_LOADERS+=soundbank.bin
  843. endif
  844. ifeq ($(FULL_TARGET),wasm-wasm)
  845. override TARGET_LOADERS+=soundbank.bin
  846. endif
  847. ifeq ($(FULL_TARGET),sparc64-linux)
  848. override TARGET_LOADERS+=soundbank.bin
  849. endif
  850. ifeq ($(FULL_TARGET),i386-linux)
  851. override CLEAN_UNITS+=*
  852. endif
  853. ifeq ($(FULL_TARGET),i386-go32v2)
  854. override CLEAN_UNITS+=*
  855. endif
  856. ifeq ($(FULL_TARGET),i386-win32)
  857. override CLEAN_UNITS+=*
  858. endif
  859. ifeq ($(FULL_TARGET),i386-os2)
  860. override CLEAN_UNITS+=*
  861. endif
  862. ifeq ($(FULL_TARGET),i386-freebsd)
  863. override CLEAN_UNITS+=*
  864. endif
  865. ifeq ($(FULL_TARGET),i386-beos)
  866. override CLEAN_UNITS+=*
  867. endif
  868. ifeq ($(FULL_TARGET),i386-haiku)
  869. override CLEAN_UNITS+=*
  870. endif
  871. ifeq ($(FULL_TARGET),i386-netbsd)
  872. override CLEAN_UNITS+=*
  873. endif
  874. ifeq ($(FULL_TARGET),i386-solaris)
  875. override CLEAN_UNITS+=*
  876. endif
  877. ifeq ($(FULL_TARGET),i386-netware)
  878. override CLEAN_UNITS+=*
  879. endif
  880. ifeq ($(FULL_TARGET),i386-openbsd)
  881. override CLEAN_UNITS+=*
  882. endif
  883. ifeq ($(FULL_TARGET),i386-wdosx)
  884. override CLEAN_UNITS+=*
  885. endif
  886. ifeq ($(FULL_TARGET),i386-darwin)
  887. override CLEAN_UNITS+=*
  888. endif
  889. ifeq ($(FULL_TARGET),i386-emx)
  890. override CLEAN_UNITS+=*
  891. endif
  892. ifeq ($(FULL_TARGET),i386-watcom)
  893. override CLEAN_UNITS+=*
  894. endif
  895. ifeq ($(FULL_TARGET),i386-netwlibc)
  896. override CLEAN_UNITS+=*
  897. endif
  898. ifeq ($(FULL_TARGET),i386-wince)
  899. override CLEAN_UNITS+=*
  900. endif
  901. ifeq ($(FULL_TARGET),i386-embedded)
  902. override CLEAN_UNITS+=*
  903. endif
  904. ifeq ($(FULL_TARGET),i386-symbian)
  905. override CLEAN_UNITS+=*
  906. endif
  907. ifeq ($(FULL_TARGET),i386-nativent)
  908. override CLEAN_UNITS+=*
  909. endif
  910. ifeq ($(FULL_TARGET),i386-iphonesim)
  911. override CLEAN_UNITS+=*
  912. endif
  913. ifeq ($(FULL_TARGET),i386-android)
  914. override CLEAN_UNITS+=*
  915. endif
  916. ifeq ($(FULL_TARGET),i386-aros)
  917. override CLEAN_UNITS+=*
  918. endif
  919. ifeq ($(FULL_TARGET),m68k-linux)
  920. override CLEAN_UNITS+=*
  921. endif
  922. ifeq ($(FULL_TARGET),m68k-netbsd)
  923. override CLEAN_UNITS+=*
  924. endif
  925. ifeq ($(FULL_TARGET),m68k-amiga)
  926. override CLEAN_UNITS+=*
  927. endif
  928. ifeq ($(FULL_TARGET),m68k-atari)
  929. override CLEAN_UNITS+=*
  930. endif
  931. ifeq ($(FULL_TARGET),m68k-palmos)
  932. override CLEAN_UNITS+=*
  933. endif
  934. ifeq ($(FULL_TARGET),m68k-macos)
  935. override CLEAN_UNITS+=*
  936. endif
  937. ifeq ($(FULL_TARGET),m68k-embedded)
  938. override CLEAN_UNITS+=*
  939. endif
  940. ifeq ($(FULL_TARGET),powerpc-linux)
  941. override CLEAN_UNITS+=*
  942. endif
  943. ifeq ($(FULL_TARGET),powerpc-netbsd)
  944. override CLEAN_UNITS+=*
  945. endif
  946. ifeq ($(FULL_TARGET),powerpc-amiga)
  947. override CLEAN_UNITS+=*
  948. endif
  949. ifeq ($(FULL_TARGET),powerpc-macos)
  950. override CLEAN_UNITS+=*
  951. endif
  952. ifeq ($(FULL_TARGET),powerpc-darwin)
  953. override CLEAN_UNITS+=*
  954. endif
  955. ifeq ($(FULL_TARGET),powerpc-morphos)
  956. override CLEAN_UNITS+=*
  957. endif
  958. ifeq ($(FULL_TARGET),powerpc-embedded)
  959. override CLEAN_UNITS+=*
  960. endif
  961. ifeq ($(FULL_TARGET),powerpc-wii)
  962. override CLEAN_UNITS+=*
  963. endif
  964. ifeq ($(FULL_TARGET),powerpc-aix)
  965. override CLEAN_UNITS+=*
  966. endif
  967. ifeq ($(FULL_TARGET),sparc-linux)
  968. override CLEAN_UNITS+=*
  969. endif
  970. ifeq ($(FULL_TARGET),sparc-netbsd)
  971. override CLEAN_UNITS+=*
  972. endif
  973. ifeq ($(FULL_TARGET),sparc-solaris)
  974. override CLEAN_UNITS+=*
  975. endif
  976. ifeq ($(FULL_TARGET),sparc-embedded)
  977. override CLEAN_UNITS+=*
  978. endif
  979. ifeq ($(FULL_TARGET),x86_64-linux)
  980. override CLEAN_UNITS+=*
  981. endif
  982. ifeq ($(FULL_TARGET),x86_64-freebsd)
  983. override CLEAN_UNITS+=*
  984. endif
  985. ifeq ($(FULL_TARGET),x86_64-netbsd)
  986. override CLEAN_UNITS+=*
  987. endif
  988. ifeq ($(FULL_TARGET),x86_64-solaris)
  989. override CLEAN_UNITS+=*
  990. endif
  991. ifeq ($(FULL_TARGET),x86_64-openbsd)
  992. override CLEAN_UNITS+=*
  993. endif
  994. ifeq ($(FULL_TARGET),x86_64-darwin)
  995. override CLEAN_UNITS+=*
  996. endif
  997. ifeq ($(FULL_TARGET),x86_64-win64)
  998. override CLEAN_UNITS+=*
  999. endif
  1000. ifeq ($(FULL_TARGET),x86_64-embedded)
  1001. override CLEAN_UNITS+=*
  1002. endif
  1003. ifeq ($(FULL_TARGET),x86_64-iphonesim)
  1004. override CLEAN_UNITS+=*
  1005. endif
  1006. ifeq ($(FULL_TARGET),x86_64-aros)
  1007. override CLEAN_UNITS+=*
  1008. endif
  1009. ifeq ($(FULL_TARGET),x86_64-dragonfly)
  1010. override CLEAN_UNITS+=*
  1011. endif
  1012. ifeq ($(FULL_TARGET),arm-linux)
  1013. override CLEAN_UNITS+=*
  1014. endif
  1015. ifeq ($(FULL_TARGET),arm-palmos)
  1016. override CLEAN_UNITS+=*
  1017. endif
  1018. ifeq ($(FULL_TARGET),arm-darwin)
  1019. override CLEAN_UNITS+=*
  1020. endif
  1021. ifeq ($(FULL_TARGET),arm-wince)
  1022. override CLEAN_UNITS+=*
  1023. endif
  1024. ifeq ($(FULL_TARGET),arm-gba)
  1025. override CLEAN_UNITS+=*
  1026. endif
  1027. ifeq ($(FULL_TARGET),arm-nds)
  1028. override CLEAN_UNITS+=*
  1029. endif
  1030. ifeq ($(FULL_TARGET),arm-embedded)
  1031. override CLEAN_UNITS+=*
  1032. endif
  1033. ifeq ($(FULL_TARGET),arm-symbian)
  1034. override CLEAN_UNITS+=*
  1035. endif
  1036. ifeq ($(FULL_TARGET),arm-android)
  1037. override CLEAN_UNITS+=*
  1038. endif
  1039. ifeq ($(FULL_TARGET),arm-aros)
  1040. override CLEAN_UNITS+=*
  1041. endif
  1042. ifeq ($(FULL_TARGET),powerpc64-linux)
  1043. override CLEAN_UNITS+=*
  1044. endif
  1045. ifeq ($(FULL_TARGET),powerpc64-darwin)
  1046. override CLEAN_UNITS+=*
  1047. endif
  1048. ifeq ($(FULL_TARGET),powerpc64-embedded)
  1049. override CLEAN_UNITS+=*
  1050. endif
  1051. ifeq ($(FULL_TARGET),powerpc64-aix)
  1052. override CLEAN_UNITS+=*
  1053. endif
  1054. ifeq ($(FULL_TARGET),avr-embedded)
  1055. override CLEAN_UNITS+=*
  1056. endif
  1057. ifeq ($(FULL_TARGET),armeb-linux)
  1058. override CLEAN_UNITS+=*
  1059. endif
  1060. ifeq ($(FULL_TARGET),armeb-embedded)
  1061. override CLEAN_UNITS+=*
  1062. endif
  1063. ifeq ($(FULL_TARGET),mips-linux)
  1064. override CLEAN_UNITS+=*
  1065. endif
  1066. ifeq ($(FULL_TARGET),mipsel-linux)
  1067. override CLEAN_UNITS+=*
  1068. endif
  1069. ifeq ($(FULL_TARGET),mipsel-embedded)
  1070. override CLEAN_UNITS+=*
  1071. endif
  1072. ifeq ($(FULL_TARGET),mipsel-android)
  1073. override CLEAN_UNITS+=*
  1074. endif
  1075. ifeq ($(FULL_TARGET),jvm-java)
  1076. override CLEAN_UNITS+=*
  1077. endif
  1078. ifeq ($(FULL_TARGET),jvm-android)
  1079. override CLEAN_UNITS+=*
  1080. endif
  1081. ifeq ($(FULL_TARGET),i8086-embedded)
  1082. override CLEAN_UNITS+=*
  1083. endif
  1084. ifeq ($(FULL_TARGET),i8086-msdos)
  1085. override CLEAN_UNITS+=*
  1086. endif
  1087. ifeq ($(FULL_TARGET),i8086-win16)
  1088. override CLEAN_UNITS+=*
  1089. endif
  1090. ifeq ($(FULL_TARGET),aarch64-linux)
  1091. override CLEAN_UNITS+=*
  1092. endif
  1093. ifeq ($(FULL_TARGET),aarch64-darwin)
  1094. override CLEAN_UNITS+=*
  1095. endif
  1096. ifeq ($(FULL_TARGET),wasm-wasm)
  1097. override CLEAN_UNITS+=*
  1098. endif
  1099. ifeq ($(FULL_TARGET),sparc64-linux)
  1100. override CLEAN_UNITS+=*
  1101. endif
  1102. ifeq ($(FULL_TARGET),i386-linux)
  1103. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1104. endif
  1105. ifeq ($(FULL_TARGET),i386-go32v2)
  1106. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1107. endif
  1108. ifeq ($(FULL_TARGET),i386-win32)
  1109. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1110. endif
  1111. ifeq ($(FULL_TARGET),i386-os2)
  1112. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1113. endif
  1114. ifeq ($(FULL_TARGET),i386-freebsd)
  1115. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1116. endif
  1117. ifeq ($(FULL_TARGET),i386-beos)
  1118. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1119. endif
  1120. ifeq ($(FULL_TARGET),i386-haiku)
  1121. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1122. endif
  1123. ifeq ($(FULL_TARGET),i386-netbsd)
  1124. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1125. endif
  1126. ifeq ($(FULL_TARGET),i386-solaris)
  1127. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1128. endif
  1129. ifeq ($(FULL_TARGET),i386-netware)
  1130. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1131. endif
  1132. ifeq ($(FULL_TARGET),i386-openbsd)
  1133. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1134. endif
  1135. ifeq ($(FULL_TARGET),i386-wdosx)
  1136. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1137. endif
  1138. ifeq ($(FULL_TARGET),i386-darwin)
  1139. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1140. endif
  1141. ifeq ($(FULL_TARGET),i386-emx)
  1142. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1143. endif
  1144. ifeq ($(FULL_TARGET),i386-watcom)
  1145. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1146. endif
  1147. ifeq ($(FULL_TARGET),i386-netwlibc)
  1148. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1149. endif
  1150. ifeq ($(FULL_TARGET),i386-wince)
  1151. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1152. endif
  1153. ifeq ($(FULL_TARGET),i386-embedded)
  1154. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1155. endif
  1156. ifeq ($(FULL_TARGET),i386-symbian)
  1157. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1158. endif
  1159. ifeq ($(FULL_TARGET),i386-nativent)
  1160. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1161. endif
  1162. ifeq ($(FULL_TARGET),i386-iphonesim)
  1163. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1164. endif
  1165. ifeq ($(FULL_TARGET),i386-android)
  1166. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1167. endif
  1168. ifeq ($(FULL_TARGET),i386-aros)
  1169. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1170. endif
  1171. ifeq ($(FULL_TARGET),m68k-linux)
  1172. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1173. endif
  1174. ifeq ($(FULL_TARGET),m68k-netbsd)
  1175. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1176. endif
  1177. ifeq ($(FULL_TARGET),m68k-amiga)
  1178. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1179. endif
  1180. ifeq ($(FULL_TARGET),m68k-atari)
  1181. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1182. endif
  1183. ifeq ($(FULL_TARGET),m68k-palmos)
  1184. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1185. endif
  1186. ifeq ($(FULL_TARGET),m68k-macos)
  1187. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1188. endif
  1189. ifeq ($(FULL_TARGET),m68k-embedded)
  1190. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1191. endif
  1192. ifeq ($(FULL_TARGET),powerpc-linux)
  1193. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1194. endif
  1195. ifeq ($(FULL_TARGET),powerpc-netbsd)
  1196. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1197. endif
  1198. ifeq ($(FULL_TARGET),powerpc-amiga)
  1199. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1200. endif
  1201. ifeq ($(FULL_TARGET),powerpc-macos)
  1202. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1203. endif
  1204. ifeq ($(FULL_TARGET),powerpc-darwin)
  1205. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1206. endif
  1207. ifeq ($(FULL_TARGET),powerpc-morphos)
  1208. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1209. endif
  1210. ifeq ($(FULL_TARGET),powerpc-embedded)
  1211. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1212. endif
  1213. ifeq ($(FULL_TARGET),powerpc-wii)
  1214. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1215. endif
  1216. ifeq ($(FULL_TARGET),powerpc-aix)
  1217. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1218. endif
  1219. ifeq ($(FULL_TARGET),sparc-linux)
  1220. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1221. endif
  1222. ifeq ($(FULL_TARGET),sparc-netbsd)
  1223. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1224. endif
  1225. ifeq ($(FULL_TARGET),sparc-solaris)
  1226. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1227. endif
  1228. ifeq ($(FULL_TARGET),sparc-embedded)
  1229. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1230. endif
  1231. ifeq ($(FULL_TARGET),x86_64-linux)
  1232. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1233. endif
  1234. ifeq ($(FULL_TARGET),x86_64-freebsd)
  1235. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1236. endif
  1237. ifeq ($(FULL_TARGET),x86_64-netbsd)
  1238. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1239. endif
  1240. ifeq ($(FULL_TARGET),x86_64-solaris)
  1241. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1242. endif
  1243. ifeq ($(FULL_TARGET),x86_64-openbsd)
  1244. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1245. endif
  1246. ifeq ($(FULL_TARGET),x86_64-darwin)
  1247. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1248. endif
  1249. ifeq ($(FULL_TARGET),x86_64-win64)
  1250. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1251. endif
  1252. ifeq ($(FULL_TARGET),x86_64-embedded)
  1253. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1254. endif
  1255. ifeq ($(FULL_TARGET),x86_64-iphonesim)
  1256. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1257. endif
  1258. ifeq ($(FULL_TARGET),x86_64-aros)
  1259. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1260. endif
  1261. ifeq ($(FULL_TARGET),x86_64-dragonfly)
  1262. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1263. endif
  1264. ifeq ($(FULL_TARGET),arm-linux)
  1265. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1266. endif
  1267. ifeq ($(FULL_TARGET),arm-palmos)
  1268. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1269. endif
  1270. ifeq ($(FULL_TARGET),arm-darwin)
  1271. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1272. endif
  1273. ifeq ($(FULL_TARGET),arm-wince)
  1274. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1275. endif
  1276. ifeq ($(FULL_TARGET),arm-gba)
  1277. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1278. endif
  1279. ifeq ($(FULL_TARGET),arm-nds)
  1280. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1281. endif
  1282. ifeq ($(FULL_TARGET),arm-embedded)
  1283. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1284. endif
  1285. ifeq ($(FULL_TARGET),arm-symbian)
  1286. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1287. endif
  1288. ifeq ($(FULL_TARGET),arm-android)
  1289. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1290. endif
  1291. ifeq ($(FULL_TARGET),arm-aros)
  1292. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1293. endif
  1294. ifeq ($(FULL_TARGET),powerpc64-linux)
  1295. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1296. endif
  1297. ifeq ($(FULL_TARGET),powerpc64-darwin)
  1298. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1299. endif
  1300. ifeq ($(FULL_TARGET),powerpc64-embedded)
  1301. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1302. endif
  1303. ifeq ($(FULL_TARGET),powerpc64-aix)
  1304. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1305. endif
  1306. ifeq ($(FULL_TARGET),avr-embedded)
  1307. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1308. endif
  1309. ifeq ($(FULL_TARGET),armeb-linux)
  1310. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1311. endif
  1312. ifeq ($(FULL_TARGET),armeb-embedded)
  1313. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1314. endif
  1315. ifeq ($(FULL_TARGET),mips-linux)
  1316. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1317. endif
  1318. ifeq ($(FULL_TARGET),mipsel-linux)
  1319. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1320. endif
  1321. ifeq ($(FULL_TARGET),mipsel-embedded)
  1322. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1323. endif
  1324. ifeq ($(FULL_TARGET),mipsel-android)
  1325. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1326. endif
  1327. ifeq ($(FULL_TARGET),jvm-java)
  1328. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1329. endif
  1330. ifeq ($(FULL_TARGET),jvm-android)
  1331. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1332. endif
  1333. ifeq ($(FULL_TARGET),i8086-embedded)
  1334. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1335. endif
  1336. ifeq ($(FULL_TARGET),i8086-msdos)
  1337. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1338. endif
  1339. ifeq ($(FULL_TARGET),i8086-win16)
  1340. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1341. endif
  1342. ifeq ($(FULL_TARGET),aarch64-linux)
  1343. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1344. endif
  1345. ifeq ($(FULL_TARGET),aarch64-darwin)
  1346. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1347. endif
  1348. ifeq ($(FULL_TARGET),wasm-wasm)
  1349. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1350. endif
  1351. ifeq ($(FULL_TARGET),sparc64-linux)
  1352. override CLEAN_FILES+=*.elf *.o *.s *.nds *.nef *.h *.bin *.map $(BUILD)/* $(INC)/* $(BIN)/*
  1353. endif
  1354. override INSTALL_FPCPACKAGE=y
  1355. ifeq ($(FULL_TARGET),i386-linux)
  1356. override COMPILER_OPTIONS+=-Xm
  1357. endif
  1358. ifeq ($(FULL_TARGET),i386-go32v2)
  1359. override COMPILER_OPTIONS+=-Xm
  1360. endif
  1361. ifeq ($(FULL_TARGET),i386-win32)
  1362. override COMPILER_OPTIONS+=-Xm
  1363. endif
  1364. ifeq ($(FULL_TARGET),i386-os2)
  1365. override COMPILER_OPTIONS+=-Xm
  1366. endif
  1367. ifeq ($(FULL_TARGET),i386-freebsd)
  1368. override COMPILER_OPTIONS+=-Xm
  1369. endif
  1370. ifeq ($(FULL_TARGET),i386-beos)
  1371. override COMPILER_OPTIONS+=-Xm
  1372. endif
  1373. ifeq ($(FULL_TARGET),i386-haiku)
  1374. override COMPILER_OPTIONS+=-Xm
  1375. endif
  1376. ifeq ($(FULL_TARGET),i386-netbsd)
  1377. override COMPILER_OPTIONS+=-Xm
  1378. endif
  1379. ifeq ($(FULL_TARGET),i386-solaris)
  1380. override COMPILER_OPTIONS+=-Xm
  1381. endif
  1382. ifeq ($(FULL_TARGET),i386-netware)
  1383. override COMPILER_OPTIONS+=-Xm
  1384. endif
  1385. ifeq ($(FULL_TARGET),i386-openbsd)
  1386. override COMPILER_OPTIONS+=-Xm
  1387. endif
  1388. ifeq ($(FULL_TARGET),i386-wdosx)
  1389. override COMPILER_OPTIONS+=-Xm
  1390. endif
  1391. ifeq ($(FULL_TARGET),i386-darwin)
  1392. override COMPILER_OPTIONS+=-Xm
  1393. endif
  1394. ifeq ($(FULL_TARGET),i386-emx)
  1395. override COMPILER_OPTIONS+=-Xm
  1396. endif
  1397. ifeq ($(FULL_TARGET),i386-watcom)
  1398. override COMPILER_OPTIONS+=-Xm
  1399. endif
  1400. ifeq ($(FULL_TARGET),i386-netwlibc)
  1401. override COMPILER_OPTIONS+=-Xm
  1402. endif
  1403. ifeq ($(FULL_TARGET),i386-wince)
  1404. override COMPILER_OPTIONS+=-Xm
  1405. endif
  1406. ifeq ($(FULL_TARGET),i386-embedded)
  1407. override COMPILER_OPTIONS+=-Xm
  1408. endif
  1409. ifeq ($(FULL_TARGET),i386-symbian)
  1410. override COMPILER_OPTIONS+=-Xm
  1411. endif
  1412. ifeq ($(FULL_TARGET),i386-nativent)
  1413. override COMPILER_OPTIONS+=-Xm
  1414. endif
  1415. ifeq ($(FULL_TARGET),i386-iphonesim)
  1416. override COMPILER_OPTIONS+=-Xm
  1417. endif
  1418. ifeq ($(FULL_TARGET),i386-android)
  1419. override COMPILER_OPTIONS+=-Xm
  1420. endif
  1421. ifeq ($(FULL_TARGET),i386-aros)
  1422. override COMPILER_OPTIONS+=-Xm
  1423. endif
  1424. ifeq ($(FULL_TARGET),m68k-linux)
  1425. override COMPILER_OPTIONS+=-Xm
  1426. endif
  1427. ifeq ($(FULL_TARGET),m68k-netbsd)
  1428. override COMPILER_OPTIONS+=-Xm
  1429. endif
  1430. ifeq ($(FULL_TARGET),m68k-amiga)
  1431. override COMPILER_OPTIONS+=-Xm
  1432. endif
  1433. ifeq ($(FULL_TARGET),m68k-atari)
  1434. override COMPILER_OPTIONS+=-Xm
  1435. endif
  1436. ifeq ($(FULL_TARGET),m68k-palmos)
  1437. override COMPILER_OPTIONS+=-Xm
  1438. endif
  1439. ifeq ($(FULL_TARGET),m68k-macos)
  1440. override COMPILER_OPTIONS+=-Xm
  1441. endif
  1442. ifeq ($(FULL_TARGET),m68k-embedded)
  1443. override COMPILER_OPTIONS+=-Xm
  1444. endif
  1445. ifeq ($(FULL_TARGET),powerpc-linux)
  1446. override COMPILER_OPTIONS+=-Xm
  1447. endif
  1448. ifeq ($(FULL_TARGET),powerpc-netbsd)
  1449. override COMPILER_OPTIONS+=-Xm
  1450. endif
  1451. ifeq ($(FULL_TARGET),powerpc-amiga)
  1452. override COMPILER_OPTIONS+=-Xm
  1453. endif
  1454. ifeq ($(FULL_TARGET),powerpc-macos)
  1455. override COMPILER_OPTIONS+=-Xm
  1456. endif
  1457. ifeq ($(FULL_TARGET),powerpc-darwin)
  1458. override COMPILER_OPTIONS+=-Xm
  1459. endif
  1460. ifeq ($(FULL_TARGET),powerpc-morphos)
  1461. override COMPILER_OPTIONS+=-Xm
  1462. endif
  1463. ifeq ($(FULL_TARGET),powerpc-embedded)
  1464. override COMPILER_OPTIONS+=-Xm
  1465. endif
  1466. ifeq ($(FULL_TARGET),powerpc-wii)
  1467. override COMPILER_OPTIONS+=-Xm
  1468. endif
  1469. ifeq ($(FULL_TARGET),powerpc-aix)
  1470. override COMPILER_OPTIONS+=-Xm
  1471. endif
  1472. ifeq ($(FULL_TARGET),sparc-linux)
  1473. override COMPILER_OPTIONS+=-Xm
  1474. endif
  1475. ifeq ($(FULL_TARGET),sparc-netbsd)
  1476. override COMPILER_OPTIONS+=-Xm
  1477. endif
  1478. ifeq ($(FULL_TARGET),sparc-solaris)
  1479. override COMPILER_OPTIONS+=-Xm
  1480. endif
  1481. ifeq ($(FULL_TARGET),sparc-embedded)
  1482. override COMPILER_OPTIONS+=-Xm
  1483. endif
  1484. ifeq ($(FULL_TARGET),x86_64-linux)
  1485. override COMPILER_OPTIONS+=-Xm
  1486. endif
  1487. ifeq ($(FULL_TARGET),x86_64-freebsd)
  1488. override COMPILER_OPTIONS+=-Xm
  1489. endif
  1490. ifeq ($(FULL_TARGET),x86_64-netbsd)
  1491. override COMPILER_OPTIONS+=-Xm
  1492. endif
  1493. ifeq ($(FULL_TARGET),x86_64-solaris)
  1494. override COMPILER_OPTIONS+=-Xm
  1495. endif
  1496. ifeq ($(FULL_TARGET),x86_64-openbsd)
  1497. override COMPILER_OPTIONS+=-Xm
  1498. endif
  1499. ifeq ($(FULL_TARGET),x86_64-darwin)
  1500. override COMPILER_OPTIONS+=-Xm
  1501. endif
  1502. ifeq ($(FULL_TARGET),x86_64-win64)
  1503. override COMPILER_OPTIONS+=-Xm
  1504. endif
  1505. ifeq ($(FULL_TARGET),x86_64-embedded)
  1506. override COMPILER_OPTIONS+=-Xm
  1507. endif
  1508. ifeq ($(FULL_TARGET),x86_64-iphonesim)
  1509. override COMPILER_OPTIONS+=-Xm
  1510. endif
  1511. ifeq ($(FULL_TARGET),x86_64-aros)
  1512. override COMPILER_OPTIONS+=-Xm
  1513. endif
  1514. ifeq ($(FULL_TARGET),x86_64-dragonfly)
  1515. override COMPILER_OPTIONS+=-Xm
  1516. endif
  1517. ifeq ($(FULL_TARGET),arm-linux)
  1518. override COMPILER_OPTIONS+=-Xm
  1519. endif
  1520. ifeq ($(FULL_TARGET),arm-palmos)
  1521. override COMPILER_OPTIONS+=-Xm
  1522. endif
  1523. ifeq ($(FULL_TARGET),arm-darwin)
  1524. override COMPILER_OPTIONS+=-Xm
  1525. endif
  1526. ifeq ($(FULL_TARGET),arm-wince)
  1527. override COMPILER_OPTIONS+=-Xm
  1528. endif
  1529. ifeq ($(FULL_TARGET),arm-gba)
  1530. override COMPILER_OPTIONS+=-Xm
  1531. endif
  1532. ifeq ($(FULL_TARGET),arm-nds)
  1533. override COMPILER_OPTIONS+=-Xm
  1534. endif
  1535. ifeq ($(FULL_TARGET),arm-embedded)
  1536. override COMPILER_OPTIONS+=-Xm
  1537. endif
  1538. ifeq ($(FULL_TARGET),arm-symbian)
  1539. override COMPILER_OPTIONS+=-Xm
  1540. endif
  1541. ifeq ($(FULL_TARGET),arm-android)
  1542. override COMPILER_OPTIONS+=-Xm
  1543. endif
  1544. ifeq ($(FULL_TARGET),arm-aros)
  1545. override COMPILER_OPTIONS+=-Xm
  1546. endif
  1547. ifeq ($(FULL_TARGET),powerpc64-linux)
  1548. override COMPILER_OPTIONS+=-Xm
  1549. endif
  1550. ifeq ($(FULL_TARGET),powerpc64-darwin)
  1551. override COMPILER_OPTIONS+=-Xm
  1552. endif
  1553. ifeq ($(FULL_TARGET),powerpc64-embedded)
  1554. override COMPILER_OPTIONS+=-Xm
  1555. endif
  1556. ifeq ($(FULL_TARGET),powerpc64-aix)
  1557. override COMPILER_OPTIONS+=-Xm
  1558. endif
  1559. ifeq ($(FULL_TARGET),avr-embedded)
  1560. override COMPILER_OPTIONS+=-Xm
  1561. endif
  1562. ifeq ($(FULL_TARGET),armeb-linux)
  1563. override COMPILER_OPTIONS+=-Xm
  1564. endif
  1565. ifeq ($(FULL_TARGET),armeb-embedded)
  1566. override COMPILER_OPTIONS+=-Xm
  1567. endif
  1568. ifeq ($(FULL_TARGET),mips-linux)
  1569. override COMPILER_OPTIONS+=-Xm
  1570. endif
  1571. ifeq ($(FULL_TARGET),mipsel-linux)
  1572. override COMPILER_OPTIONS+=-Xm
  1573. endif
  1574. ifeq ($(FULL_TARGET),mipsel-embedded)
  1575. override COMPILER_OPTIONS+=-Xm
  1576. endif
  1577. ifeq ($(FULL_TARGET),mipsel-android)
  1578. override COMPILER_OPTIONS+=-Xm
  1579. endif
  1580. ifeq ($(FULL_TARGET),jvm-java)
  1581. override COMPILER_OPTIONS+=-Xm
  1582. endif
  1583. ifeq ($(FULL_TARGET),jvm-android)
  1584. override COMPILER_OPTIONS+=-Xm
  1585. endif
  1586. ifeq ($(FULL_TARGET),i8086-embedded)
  1587. override COMPILER_OPTIONS+=-Xm
  1588. endif
  1589. ifeq ($(FULL_TARGET),i8086-msdos)
  1590. override COMPILER_OPTIONS+=-Xm
  1591. endif
  1592. ifeq ($(FULL_TARGET),i8086-win16)
  1593. override COMPILER_OPTIONS+=-Xm
  1594. endif
  1595. ifeq ($(FULL_TARGET),aarch64-linux)
  1596. override COMPILER_OPTIONS+=-Xm
  1597. endif
  1598. ifeq ($(FULL_TARGET),aarch64-darwin)
  1599. override COMPILER_OPTIONS+=-Xm
  1600. endif
  1601. ifeq ($(FULL_TARGET),wasm-wasm)
  1602. override COMPILER_OPTIONS+=-Xm
  1603. endif
  1604. ifeq ($(FULL_TARGET),sparc64-linux)
  1605. override COMPILER_OPTIONS+=-Xm
  1606. endif
  1607. ifeq ($(FULL_TARGET),i386-linux)
  1608. override COMPILER_TARGETDIR+=$(BIN)
  1609. endif
  1610. ifeq ($(FULL_TARGET),i386-go32v2)
  1611. override COMPILER_TARGETDIR+=$(BIN)
  1612. endif
  1613. ifeq ($(FULL_TARGET),i386-win32)
  1614. override COMPILER_TARGETDIR+=$(BIN)
  1615. endif
  1616. ifeq ($(FULL_TARGET),i386-os2)
  1617. override COMPILER_TARGETDIR+=$(BIN)
  1618. endif
  1619. ifeq ($(FULL_TARGET),i386-freebsd)
  1620. override COMPILER_TARGETDIR+=$(BIN)
  1621. endif
  1622. ifeq ($(FULL_TARGET),i386-beos)
  1623. override COMPILER_TARGETDIR+=$(BIN)
  1624. endif
  1625. ifeq ($(FULL_TARGET),i386-haiku)
  1626. override COMPILER_TARGETDIR+=$(BIN)
  1627. endif
  1628. ifeq ($(FULL_TARGET),i386-netbsd)
  1629. override COMPILER_TARGETDIR+=$(BIN)
  1630. endif
  1631. ifeq ($(FULL_TARGET),i386-solaris)
  1632. override COMPILER_TARGETDIR+=$(BIN)
  1633. endif
  1634. ifeq ($(FULL_TARGET),i386-netware)
  1635. override COMPILER_TARGETDIR+=$(BIN)
  1636. endif
  1637. ifeq ($(FULL_TARGET),i386-openbsd)
  1638. override COMPILER_TARGETDIR+=$(BIN)
  1639. endif
  1640. ifeq ($(FULL_TARGET),i386-wdosx)
  1641. override COMPILER_TARGETDIR+=$(BIN)
  1642. endif
  1643. ifeq ($(FULL_TARGET),i386-darwin)
  1644. override COMPILER_TARGETDIR+=$(BIN)
  1645. endif
  1646. ifeq ($(FULL_TARGET),i386-emx)
  1647. override COMPILER_TARGETDIR+=$(BIN)
  1648. endif
  1649. ifeq ($(FULL_TARGET),i386-watcom)
  1650. override COMPILER_TARGETDIR+=$(BIN)
  1651. endif
  1652. ifeq ($(FULL_TARGET),i386-netwlibc)
  1653. override COMPILER_TARGETDIR+=$(BIN)
  1654. endif
  1655. ifeq ($(FULL_TARGET),i386-wince)
  1656. override COMPILER_TARGETDIR+=$(BIN)
  1657. endif
  1658. ifeq ($(FULL_TARGET),i386-embedded)
  1659. override COMPILER_TARGETDIR+=$(BIN)
  1660. endif
  1661. ifeq ($(FULL_TARGET),i386-symbian)
  1662. override COMPILER_TARGETDIR+=$(BIN)
  1663. endif
  1664. ifeq ($(FULL_TARGET),i386-nativent)
  1665. override COMPILER_TARGETDIR+=$(BIN)
  1666. endif
  1667. ifeq ($(FULL_TARGET),i386-iphonesim)
  1668. override COMPILER_TARGETDIR+=$(BIN)
  1669. endif
  1670. ifeq ($(FULL_TARGET),i386-android)
  1671. override COMPILER_TARGETDIR+=$(BIN)
  1672. endif
  1673. ifeq ($(FULL_TARGET),i386-aros)
  1674. override COMPILER_TARGETDIR+=$(BIN)
  1675. endif
  1676. ifeq ($(FULL_TARGET),m68k-linux)
  1677. override COMPILER_TARGETDIR+=$(BIN)
  1678. endif
  1679. ifeq ($(FULL_TARGET),m68k-netbsd)
  1680. override COMPILER_TARGETDIR+=$(BIN)
  1681. endif
  1682. ifeq ($(FULL_TARGET),m68k-amiga)
  1683. override COMPILER_TARGETDIR+=$(BIN)
  1684. endif
  1685. ifeq ($(FULL_TARGET),m68k-atari)
  1686. override COMPILER_TARGETDIR+=$(BIN)
  1687. endif
  1688. ifeq ($(FULL_TARGET),m68k-palmos)
  1689. override COMPILER_TARGETDIR+=$(BIN)
  1690. endif
  1691. ifeq ($(FULL_TARGET),m68k-macos)
  1692. override COMPILER_TARGETDIR+=$(BIN)
  1693. endif
  1694. ifeq ($(FULL_TARGET),m68k-embedded)
  1695. override COMPILER_TARGETDIR+=$(BIN)
  1696. endif
  1697. ifeq ($(FULL_TARGET),powerpc-linux)
  1698. override COMPILER_TARGETDIR+=$(BIN)
  1699. endif
  1700. ifeq ($(FULL_TARGET),powerpc-netbsd)
  1701. override COMPILER_TARGETDIR+=$(BIN)
  1702. endif
  1703. ifeq ($(FULL_TARGET),powerpc-amiga)
  1704. override COMPILER_TARGETDIR+=$(BIN)
  1705. endif
  1706. ifeq ($(FULL_TARGET),powerpc-macos)
  1707. override COMPILER_TARGETDIR+=$(BIN)
  1708. endif
  1709. ifeq ($(FULL_TARGET),powerpc-darwin)
  1710. override COMPILER_TARGETDIR+=$(BIN)
  1711. endif
  1712. ifeq ($(FULL_TARGET),powerpc-morphos)
  1713. override COMPILER_TARGETDIR+=$(BIN)
  1714. endif
  1715. ifeq ($(FULL_TARGET),powerpc-embedded)
  1716. override COMPILER_TARGETDIR+=$(BIN)
  1717. endif
  1718. ifeq ($(FULL_TARGET),powerpc-wii)
  1719. override COMPILER_TARGETDIR+=$(BIN)
  1720. endif
  1721. ifeq ($(FULL_TARGET),powerpc-aix)
  1722. override COMPILER_TARGETDIR+=$(BIN)
  1723. endif
  1724. ifeq ($(FULL_TARGET),sparc-linux)
  1725. override COMPILER_TARGETDIR+=$(BIN)
  1726. endif
  1727. ifeq ($(FULL_TARGET),sparc-netbsd)
  1728. override COMPILER_TARGETDIR+=$(BIN)
  1729. endif
  1730. ifeq ($(FULL_TARGET),sparc-solaris)
  1731. override COMPILER_TARGETDIR+=$(BIN)
  1732. endif
  1733. ifeq ($(FULL_TARGET),sparc-embedded)
  1734. override COMPILER_TARGETDIR+=$(BIN)
  1735. endif
  1736. ifeq ($(FULL_TARGET),x86_64-linux)
  1737. override COMPILER_TARGETDIR+=$(BIN)
  1738. endif
  1739. ifeq ($(FULL_TARGET),x86_64-freebsd)
  1740. override COMPILER_TARGETDIR+=$(BIN)
  1741. endif
  1742. ifeq ($(FULL_TARGET),x86_64-netbsd)
  1743. override COMPILER_TARGETDIR+=$(BIN)
  1744. endif
  1745. ifeq ($(FULL_TARGET),x86_64-solaris)
  1746. override COMPILER_TARGETDIR+=$(BIN)
  1747. endif
  1748. ifeq ($(FULL_TARGET),x86_64-openbsd)
  1749. override COMPILER_TARGETDIR+=$(BIN)
  1750. endif
  1751. ifeq ($(FULL_TARGET),x86_64-darwin)
  1752. override COMPILER_TARGETDIR+=$(BIN)
  1753. endif
  1754. ifeq ($(FULL_TARGET),x86_64-win64)
  1755. override COMPILER_TARGETDIR+=$(BIN)
  1756. endif
  1757. ifeq ($(FULL_TARGET),x86_64-embedded)
  1758. override COMPILER_TARGETDIR+=$(BIN)
  1759. endif
  1760. ifeq ($(FULL_TARGET),x86_64-iphonesim)
  1761. override COMPILER_TARGETDIR+=$(BIN)
  1762. endif
  1763. ifeq ($(FULL_TARGET),x86_64-aros)
  1764. override COMPILER_TARGETDIR+=$(BIN)
  1765. endif
  1766. ifeq ($(FULL_TARGET),x86_64-dragonfly)
  1767. override COMPILER_TARGETDIR+=$(BIN)
  1768. endif
  1769. ifeq ($(FULL_TARGET),arm-linux)
  1770. override COMPILER_TARGETDIR+=$(BIN)
  1771. endif
  1772. ifeq ($(FULL_TARGET),arm-palmos)
  1773. override COMPILER_TARGETDIR+=$(BIN)
  1774. endif
  1775. ifeq ($(FULL_TARGET),arm-darwin)
  1776. override COMPILER_TARGETDIR+=$(BIN)
  1777. endif
  1778. ifeq ($(FULL_TARGET),arm-wince)
  1779. override COMPILER_TARGETDIR+=$(BIN)
  1780. endif
  1781. ifeq ($(FULL_TARGET),arm-gba)
  1782. override COMPILER_TARGETDIR+=$(BIN)
  1783. endif
  1784. ifeq ($(FULL_TARGET),arm-nds)
  1785. override COMPILER_TARGETDIR+=$(BIN)
  1786. endif
  1787. ifeq ($(FULL_TARGET),arm-embedded)
  1788. override COMPILER_TARGETDIR+=$(BIN)
  1789. endif
  1790. ifeq ($(FULL_TARGET),arm-symbian)
  1791. override COMPILER_TARGETDIR+=$(BIN)
  1792. endif
  1793. ifeq ($(FULL_TARGET),arm-android)
  1794. override COMPILER_TARGETDIR+=$(BIN)
  1795. endif
  1796. ifeq ($(FULL_TARGET),arm-aros)
  1797. override COMPILER_TARGETDIR+=$(BIN)
  1798. endif
  1799. ifeq ($(FULL_TARGET),powerpc64-linux)
  1800. override COMPILER_TARGETDIR+=$(BIN)
  1801. endif
  1802. ifeq ($(FULL_TARGET),powerpc64-darwin)
  1803. override COMPILER_TARGETDIR+=$(BIN)
  1804. endif
  1805. ifeq ($(FULL_TARGET),powerpc64-embedded)
  1806. override COMPILER_TARGETDIR+=$(BIN)
  1807. endif
  1808. ifeq ($(FULL_TARGET),powerpc64-aix)
  1809. override COMPILER_TARGETDIR+=$(BIN)
  1810. endif
  1811. ifeq ($(FULL_TARGET),avr-embedded)
  1812. override COMPILER_TARGETDIR+=$(BIN)
  1813. endif
  1814. ifeq ($(FULL_TARGET),armeb-linux)
  1815. override COMPILER_TARGETDIR+=$(BIN)
  1816. endif
  1817. ifeq ($(FULL_TARGET),armeb-embedded)
  1818. override COMPILER_TARGETDIR+=$(BIN)
  1819. endif
  1820. ifeq ($(FULL_TARGET),mips-linux)
  1821. override COMPILER_TARGETDIR+=$(BIN)
  1822. endif
  1823. ifeq ($(FULL_TARGET),mipsel-linux)
  1824. override COMPILER_TARGETDIR+=$(BIN)
  1825. endif
  1826. ifeq ($(FULL_TARGET),mipsel-embedded)
  1827. override COMPILER_TARGETDIR+=$(BIN)
  1828. endif
  1829. ifeq ($(FULL_TARGET),mipsel-android)
  1830. override COMPILER_TARGETDIR+=$(BIN)
  1831. endif
  1832. ifeq ($(FULL_TARGET),jvm-java)
  1833. override COMPILER_TARGETDIR+=$(BIN)
  1834. endif
  1835. ifeq ($(FULL_TARGET),jvm-android)
  1836. override COMPILER_TARGETDIR+=$(BIN)
  1837. endif
  1838. ifeq ($(FULL_TARGET),i8086-embedded)
  1839. override COMPILER_TARGETDIR+=$(BIN)
  1840. endif
  1841. ifeq ($(FULL_TARGET),i8086-msdos)
  1842. override COMPILER_TARGETDIR+=$(BIN)
  1843. endif
  1844. ifeq ($(FULL_TARGET),i8086-win16)
  1845. override COMPILER_TARGETDIR+=$(BIN)
  1846. endif
  1847. ifeq ($(FULL_TARGET),aarch64-linux)
  1848. override COMPILER_TARGETDIR+=$(BIN)
  1849. endif
  1850. ifeq ($(FULL_TARGET),aarch64-darwin)
  1851. override COMPILER_TARGETDIR+=$(BIN)
  1852. endif
  1853. ifeq ($(FULL_TARGET),wasm-wasm)
  1854. override COMPILER_TARGETDIR+=$(BIN)
  1855. endif
  1856. ifeq ($(FULL_TARGET),sparc64-linux)
  1857. override COMPILER_TARGETDIR+=$(BIN)
  1858. endif
  1859. ifeq ($(FULL_TARGET),i386-linux)
  1860. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1861. endif
  1862. ifeq ($(FULL_TARGET),i386-go32v2)
  1863. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1864. endif
  1865. ifeq ($(FULL_TARGET),i386-win32)
  1866. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1867. endif
  1868. ifeq ($(FULL_TARGET),i386-os2)
  1869. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1870. endif
  1871. ifeq ($(FULL_TARGET),i386-freebsd)
  1872. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1873. endif
  1874. ifeq ($(FULL_TARGET),i386-beos)
  1875. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1876. endif
  1877. ifeq ($(FULL_TARGET),i386-haiku)
  1878. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1879. endif
  1880. ifeq ($(FULL_TARGET),i386-netbsd)
  1881. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1882. endif
  1883. ifeq ($(FULL_TARGET),i386-solaris)
  1884. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1885. endif
  1886. ifeq ($(FULL_TARGET),i386-netware)
  1887. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1888. endif
  1889. ifeq ($(FULL_TARGET),i386-openbsd)
  1890. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1891. endif
  1892. ifeq ($(FULL_TARGET),i386-wdosx)
  1893. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1894. endif
  1895. ifeq ($(FULL_TARGET),i386-darwin)
  1896. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1897. endif
  1898. ifeq ($(FULL_TARGET),i386-emx)
  1899. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1900. endif
  1901. ifeq ($(FULL_TARGET),i386-watcom)
  1902. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1903. endif
  1904. ifeq ($(FULL_TARGET),i386-netwlibc)
  1905. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1906. endif
  1907. ifeq ($(FULL_TARGET),i386-wince)
  1908. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1909. endif
  1910. ifeq ($(FULL_TARGET),i386-embedded)
  1911. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1912. endif
  1913. ifeq ($(FULL_TARGET),i386-symbian)
  1914. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1915. endif
  1916. ifeq ($(FULL_TARGET),i386-nativent)
  1917. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1918. endif
  1919. ifeq ($(FULL_TARGET),i386-iphonesim)
  1920. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1921. endif
  1922. ifeq ($(FULL_TARGET),i386-android)
  1923. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1924. endif
  1925. ifeq ($(FULL_TARGET),i386-aros)
  1926. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1927. endif
  1928. ifeq ($(FULL_TARGET),m68k-linux)
  1929. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1930. endif
  1931. ifeq ($(FULL_TARGET),m68k-netbsd)
  1932. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1933. endif
  1934. ifeq ($(FULL_TARGET),m68k-amiga)
  1935. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1936. endif
  1937. ifeq ($(FULL_TARGET),m68k-atari)
  1938. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1939. endif
  1940. ifeq ($(FULL_TARGET),m68k-palmos)
  1941. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1942. endif
  1943. ifeq ($(FULL_TARGET),m68k-macos)
  1944. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1945. endif
  1946. ifeq ($(FULL_TARGET),m68k-embedded)
  1947. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1948. endif
  1949. ifeq ($(FULL_TARGET),powerpc-linux)
  1950. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1951. endif
  1952. ifeq ($(FULL_TARGET),powerpc-netbsd)
  1953. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1954. endif
  1955. ifeq ($(FULL_TARGET),powerpc-amiga)
  1956. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1957. endif
  1958. ifeq ($(FULL_TARGET),powerpc-macos)
  1959. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1960. endif
  1961. ifeq ($(FULL_TARGET),powerpc-darwin)
  1962. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1963. endif
  1964. ifeq ($(FULL_TARGET),powerpc-morphos)
  1965. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1966. endif
  1967. ifeq ($(FULL_TARGET),powerpc-embedded)
  1968. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1969. endif
  1970. ifeq ($(FULL_TARGET),powerpc-wii)
  1971. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1972. endif
  1973. ifeq ($(FULL_TARGET),powerpc-aix)
  1974. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1975. endif
  1976. ifeq ($(FULL_TARGET),sparc-linux)
  1977. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1978. endif
  1979. ifeq ($(FULL_TARGET),sparc-netbsd)
  1980. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1981. endif
  1982. ifeq ($(FULL_TARGET),sparc-solaris)
  1983. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1984. endif
  1985. ifeq ($(FULL_TARGET),sparc-embedded)
  1986. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1987. endif
  1988. ifeq ($(FULL_TARGET),x86_64-linux)
  1989. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1990. endif
  1991. ifeq ($(FULL_TARGET),x86_64-freebsd)
  1992. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1993. endif
  1994. ifeq ($(FULL_TARGET),x86_64-netbsd)
  1995. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1996. endif
  1997. ifeq ($(FULL_TARGET),x86_64-solaris)
  1998. override COMPILER_UNITTARGETDIR+=$(BUILD)
  1999. endif
  2000. ifeq ($(FULL_TARGET),x86_64-openbsd)
  2001. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2002. endif
  2003. ifeq ($(FULL_TARGET),x86_64-darwin)
  2004. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2005. endif
  2006. ifeq ($(FULL_TARGET),x86_64-win64)
  2007. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2008. endif
  2009. ifeq ($(FULL_TARGET),x86_64-embedded)
  2010. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2011. endif
  2012. ifeq ($(FULL_TARGET),x86_64-iphonesim)
  2013. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2014. endif
  2015. ifeq ($(FULL_TARGET),x86_64-aros)
  2016. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2017. endif
  2018. ifeq ($(FULL_TARGET),x86_64-dragonfly)
  2019. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2020. endif
  2021. ifeq ($(FULL_TARGET),arm-linux)
  2022. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2023. endif
  2024. ifeq ($(FULL_TARGET),arm-palmos)
  2025. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2026. endif
  2027. ifeq ($(FULL_TARGET),arm-darwin)
  2028. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2029. endif
  2030. ifeq ($(FULL_TARGET),arm-wince)
  2031. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2032. endif
  2033. ifeq ($(FULL_TARGET),arm-gba)
  2034. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2035. endif
  2036. ifeq ($(FULL_TARGET),arm-nds)
  2037. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2038. endif
  2039. ifeq ($(FULL_TARGET),arm-embedded)
  2040. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2041. endif
  2042. ifeq ($(FULL_TARGET),arm-symbian)
  2043. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2044. endif
  2045. ifeq ($(FULL_TARGET),arm-android)
  2046. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2047. endif
  2048. ifeq ($(FULL_TARGET),arm-aros)
  2049. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2050. endif
  2051. ifeq ($(FULL_TARGET),powerpc64-linux)
  2052. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2053. endif
  2054. ifeq ($(FULL_TARGET),powerpc64-darwin)
  2055. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2056. endif
  2057. ifeq ($(FULL_TARGET),powerpc64-embedded)
  2058. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2059. endif
  2060. ifeq ($(FULL_TARGET),powerpc64-aix)
  2061. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2062. endif
  2063. ifeq ($(FULL_TARGET),avr-embedded)
  2064. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2065. endif
  2066. ifeq ($(FULL_TARGET),armeb-linux)
  2067. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2068. endif
  2069. ifeq ($(FULL_TARGET),armeb-embedded)
  2070. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2071. endif
  2072. ifeq ($(FULL_TARGET),mips-linux)
  2073. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2074. endif
  2075. ifeq ($(FULL_TARGET),mipsel-linux)
  2076. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2077. endif
  2078. ifeq ($(FULL_TARGET),mipsel-embedded)
  2079. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2080. endif
  2081. ifeq ($(FULL_TARGET),mipsel-android)
  2082. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2083. endif
  2084. ifeq ($(FULL_TARGET),jvm-java)
  2085. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2086. endif
  2087. ifeq ($(FULL_TARGET),jvm-android)
  2088. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2089. endif
  2090. ifeq ($(FULL_TARGET),i8086-embedded)
  2091. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2092. endif
  2093. ifeq ($(FULL_TARGET),i8086-msdos)
  2094. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2095. endif
  2096. ifeq ($(FULL_TARGET),i8086-win16)
  2097. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2098. endif
  2099. ifeq ($(FULL_TARGET),aarch64-linux)
  2100. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2101. endif
  2102. ifeq ($(FULL_TARGET),aarch64-darwin)
  2103. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2104. endif
  2105. ifeq ($(FULL_TARGET),wasm-wasm)
  2106. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2107. endif
  2108. ifeq ($(FULL_TARGET),sparc64-linux)
  2109. override COMPILER_UNITTARGETDIR+=$(BUILD)
  2110. endif
  2111. ifdef REQUIRE_UNITSDIR
  2112. override UNITSDIR+=$(REQUIRE_UNITSDIR)
  2113. endif
  2114. ifdef REQUIRE_PACKAGESDIR
  2115. override PACKAGESDIR+=$(REQUIRE_PACKAGESDIR)
  2116. endif
  2117. ifdef ZIPINSTALL
  2118. ifneq ($(findstring $(OS_TARGET),$(UNIXs)),)
  2119. UNIXHier=1
  2120. endif
  2121. else
  2122. ifneq ($(findstring $(OS_SOURCE),$(UNIXs)),)
  2123. UNIXHier=1
  2124. endif
  2125. endif
  2126. ifndef INSTALL_PREFIX
  2127. ifdef PREFIX
  2128. INSTALL_PREFIX=$(PREFIX)
  2129. endif
  2130. endif
  2131. ifndef INSTALL_PREFIX
  2132. ifdef UNIXHier
  2133. INSTALL_PREFIX=/usr/local
  2134. else
  2135. ifdef INSTALL_FPCPACKAGE
  2136. INSTALL_BASEDIR:=/pp
  2137. else
  2138. INSTALL_BASEDIR:=/$(PACKAGE_NAME)
  2139. endif
  2140. endif
  2141. endif
  2142. export INSTALL_PREFIX
  2143. ifdef INSTALL_FPCSUBDIR
  2144. export INSTALL_FPCSUBDIR
  2145. endif
  2146. ifndef DIST_DESTDIR
  2147. DIST_DESTDIR:=$(BASEDIR)
  2148. endif
  2149. export DIST_DESTDIR
  2150. ifndef COMPILER_UNITTARGETDIR
  2151. ifdef PACKAGEDIR_MAIN
  2152. COMPILER_UNITTARGETDIR=$(PACKAGEDIR_MAIN)/units/$(TARGETSUFFIX)
  2153. else
  2154. COMPILER_UNITTARGETDIR=units/$(TARGETSUFFIX)
  2155. endif
  2156. endif
  2157. ifndef COMPILER_TARGETDIR
  2158. COMPILER_TARGETDIR=.
  2159. endif
  2160. ifndef INSTALL_BASEDIR
  2161. ifdef UNIXHier
  2162. ifdef INSTALL_FPCPACKAGE
  2163. INSTALL_BASEDIR:=$(INSTALL_PREFIX)/lib/fpc/$(FPC_VERSION)
  2164. else
  2165. INSTALL_BASEDIR:=$(INSTALL_PREFIX)/lib/$(PACKAGE_NAME)
  2166. endif
  2167. else
  2168. INSTALL_BASEDIR:=$(INSTALL_PREFIX)
  2169. endif
  2170. endif
  2171. ifndef INSTALL_BINDIR
  2172. ifdef UNIXHier
  2173. INSTALL_BINDIR:=$(INSTALL_PREFIX)/bin
  2174. else
  2175. INSTALL_BINDIR:=$(INSTALL_BASEDIR)/bin
  2176. ifdef INSTALL_FPCPACKAGE
  2177. ifdef CROSSCOMPILE
  2178. ifdef CROSSINSTALL
  2179. INSTALL_BINDIR:=$(INSTALL_BINDIR)/$(SOURCESUFFIX)
  2180. else
  2181. INSTALL_BINDIR:=$(INSTALL_BINDIR)/$(TARGETSUFFIX)
  2182. endif
  2183. else
  2184. INSTALL_BINDIR:=$(INSTALL_BINDIR)/$(TARGETSUFFIX)
  2185. endif
  2186. endif
  2187. endif
  2188. endif
  2189. ifndef INSTALL_UNITDIR
  2190. INSTALL_UNITDIR:=$(INSTALL_BASEDIR)/units/$(TARGETSUFFIX)
  2191. ifdef INSTALL_FPCPACKAGE
  2192. ifdef PACKAGE_NAME
  2193. INSTALL_UNITDIR:=$(INSTALL_UNITDIR)/$(PACKAGE_NAME)
  2194. endif
  2195. endif
  2196. endif
  2197. ifndef INSTALL_LIBDIR
  2198. ifdef UNIXHier
  2199. INSTALL_LIBDIR:=$(INSTALL_PREFIX)/lib
  2200. else
  2201. INSTALL_LIBDIR:=$(INSTALL_UNITDIR)
  2202. endif
  2203. endif
  2204. ifndef INSTALL_SOURCEDIR
  2205. ifdef UNIXHier
  2206. ifdef BSDhier
  2207. SRCPREFIXDIR=share/src
  2208. else
  2209. ifdef linuxHier
  2210. SRCPREFIXDIR=share/src
  2211. else
  2212. SRCPREFIXDIR=src
  2213. endif
  2214. endif
  2215. ifdef INSTALL_FPCPACKAGE
  2216. ifdef INSTALL_FPCSUBDIR
  2217. INSTALL_SOURCEDIR:=$(INSTALL_PREFIX)/$(SRCPREFIXDIR)/fpc-$(FPC_VERSION)/$(INSTALL_FPCSUBDIR)/$(PACKAGE_NAME)
  2218. else
  2219. INSTALL_SOURCEDIR:=$(INSTALL_PREFIX)/$(SRCPREFIXDIR)/fpc-$(FPC_VERSION)/$(PACKAGE_NAME)
  2220. endif
  2221. else
  2222. INSTALL_SOURCEDIR:=$(INSTALL_PREFIX)/$(SRCPREFIXDIR)/$(PACKAGE_NAME)-$(PACKAGE_VERSION)
  2223. endif
  2224. else
  2225. ifdef INSTALL_FPCPACKAGE
  2226. ifdef INSTALL_FPCSUBDIR
  2227. INSTALL_SOURCEDIR:=$(INSTALL_BASEDIR)/source/$(INSTALL_FPCSUBDIR)/$(PACKAGE_NAME)
  2228. else
  2229. INSTALL_SOURCEDIR:=$(INSTALL_BASEDIR)/source/$(PACKAGE_NAME)
  2230. endif
  2231. else
  2232. INSTALL_SOURCEDIR:=$(INSTALL_BASEDIR)/source
  2233. endif
  2234. endif
  2235. endif
  2236. ifndef INSTALL_DOCDIR
  2237. ifdef UNIXHier
  2238. ifdef BSDhier
  2239. DOCPREFIXDIR=share/doc
  2240. else
  2241. ifdef linuxHier
  2242. DOCPREFIXDIR=share/doc
  2243. else
  2244. DOCPREFIXDIR=doc
  2245. endif
  2246. endif
  2247. ifdef INSTALL_FPCPACKAGE
  2248. INSTALL_DOCDIR:=$(INSTALL_PREFIX)/$(DOCPREFIXDIR)/fpc-$(FPC_VERSION)/$(PACKAGE_NAME)
  2249. else
  2250. INSTALL_DOCDIR:=$(INSTALL_PREFIX)/$(DOCPREFIXDIR)/$(PACKAGE_NAME)-$(PACKAGE_VERSION)
  2251. endif
  2252. else
  2253. ifdef INSTALL_FPCPACKAGE
  2254. INSTALL_DOCDIR:=$(INSTALL_BASEDIR)/doc/$(PACKAGE_NAME)
  2255. else
  2256. INSTALL_DOCDIR:=$(INSTALL_BASEDIR)/doc
  2257. endif
  2258. endif
  2259. endif
  2260. ifndef INSTALL_EXAMPLEDIR
  2261. ifdef UNIXHier
  2262. ifdef INSTALL_FPCPACKAGE
  2263. ifdef BSDhier
  2264. INSTALL_EXAMPLEDIR:=$(INSTALL_PREFIX)/share/examples/fpc-$(FPC_VERSION)/$(PACKAGE_NAME)
  2265. else
  2266. ifdef linuxHier
  2267. INSTALL_EXAMPLEDIR:=$(INSTALL_DOCDIR)/examples
  2268. else
  2269. INSTALL_EXAMPLEDIR:=$(INSTALL_PREFIX)/doc/fpc-$(FPC_VERSION)/examples/$(PACKAGE_NAME)
  2270. endif
  2271. endif
  2272. else
  2273. ifdef BSDhier
  2274. INSTALL_EXAMPLEDIR:=$(INSTALL_PREFIX)/share/examples/$(PACKAGE_NAME)-$(PACKAGE_VERSION)
  2275. else
  2276. ifdef linuxHier
  2277. INSTALL_EXAMPLEDIR:=$(INSTALL_DOCDIR)/examples/$(PACKAGE_NAME)-$(PACKAGE_VERSION)
  2278. else
  2279. INSTALL_EXAMPLEDIR:=$(INSTALL_PREFIX)/doc/$(PACKAGE_NAME)-$(PACKAGE_VERSION)
  2280. endif
  2281. endif
  2282. endif
  2283. else
  2284. ifdef INSTALL_FPCPACKAGE
  2285. INSTALL_EXAMPLEDIR:=$(INSTALL_BASEDIR)/examples/$(PACKAGE_NAME)
  2286. else
  2287. INSTALL_EXAMPLEDIR:=$(INSTALL_BASEDIR)/examples
  2288. endif
  2289. endif
  2290. endif
  2291. ifndef INSTALL_DATADIR
  2292. INSTALL_DATADIR=$(INSTALL_BASEDIR)
  2293. endif
  2294. ifndef INSTALL_SHAREDDIR
  2295. INSTALL_SHAREDDIR=$(INSTALL_PREFIX)/lib
  2296. endif
  2297. ifdef CROSSCOMPILE
  2298. ifndef CROSSBINDIR
  2299. CROSSBINDIR:=$(wildcard $(CROSSTARGETDIR)/bin/$(SOURCESUFFIX))
  2300. ifeq ($(CROSSBINDIR),)
  2301. CROSSBINDIR:=$(wildcard $(INSTALL_BASEDIR)/cross/$(TARGETSUFFIX)/bin/$(FULL_SOURCE))
  2302. endif
  2303. endif
  2304. else
  2305. CROSSBINDIR=
  2306. endif
  2307. BATCHEXT=.bat
  2308. LOADEREXT=.as
  2309. EXEEXT=.exe
  2310. PPLEXT=.ppl
  2311. PPUEXT=.ppu
  2312. OEXT=.o
  2313. ASMEXT=.s
  2314. SMARTEXT=.sl
  2315. STATICLIBEXT=.a
  2316. SHAREDLIBEXT=.so
  2317. SHAREDLIBPREFIX=libfp
  2318. STATICLIBPREFIX=libp
  2319. IMPORTLIBPREFIX=libimp
  2320. RSTEXT=.rst
  2321. EXEDBGEXT=.dbg
  2322. ifeq ($(OS_TARGET),go32v1)
  2323. STATICLIBPREFIX=
  2324. SHORTSUFFIX=v1
  2325. endif
  2326. ifeq ($(OS_TARGET),go32v2)
  2327. STATICLIBPREFIX=
  2328. SHORTSUFFIX=dos
  2329. IMPORTLIBPREFIX=
  2330. endif
  2331. ifeq ($(OS_TARGET),watcom)
  2332. STATICLIBPREFIX=
  2333. OEXT=.obj
  2334. ASMEXT=.asm
  2335. SHAREDLIBEXT=.dll
  2336. SHORTSUFFIX=wat
  2337. IMPORTLIBPREFIX=
  2338. endif
  2339. ifneq ($(CPU_TARGET),jvm)
  2340. ifeq ($(OS_TARGET),android)
  2341. BATCHEXT=.sh
  2342. EXEEXT=
  2343. HASSHAREDLIB=1
  2344. SHORTSUFFIX=lnx
  2345. endif
  2346. endif
  2347. ifeq ($(OS_TARGET),linux)
  2348. BATCHEXT=.sh
  2349. EXEEXT=
  2350. HASSHAREDLIB=1
  2351. SHORTSUFFIX=lnx
  2352. endif
  2353. ifeq ($(OS_TARGET),dragonfly)
  2354. BATCHEXT=.sh
  2355. EXEEXT=
  2356. HASSHAREDLIB=1
  2357. SHORTSUFFIX=df
  2358. endif
  2359. ifeq ($(OS_TARGET),freebsd)
  2360. BATCHEXT=.sh
  2361. EXEEXT=
  2362. HASSHAREDLIB=1
  2363. SHORTSUFFIX=fbs
  2364. endif
  2365. ifeq ($(OS_TARGET),netbsd)
  2366. BATCHEXT=.sh
  2367. EXEEXT=
  2368. HASSHAREDLIB=1
  2369. SHORTSUFFIX=nbs
  2370. endif
  2371. ifeq ($(OS_TARGET),openbsd)
  2372. BATCHEXT=.sh
  2373. EXEEXT=
  2374. HASSHAREDLIB=1
  2375. SHORTSUFFIX=obs
  2376. endif
  2377. ifeq ($(OS_TARGET),win32)
  2378. SHAREDLIBEXT=.dll
  2379. SHORTSUFFIX=w32
  2380. endif
  2381. ifeq ($(OS_TARGET),os2)
  2382. BATCHEXT=.cmd
  2383. AOUTEXT=.out
  2384. STATICLIBPREFIX=
  2385. SHAREDLIBEXT=.dll
  2386. SHORTSUFFIX=os2
  2387. ECHO=echo
  2388. IMPORTLIBPREFIX=
  2389. endif
  2390. ifeq ($(OS_TARGET),emx)
  2391. BATCHEXT=.cmd
  2392. AOUTEXT=.out
  2393. STATICLIBPREFIX=
  2394. SHAREDLIBEXT=.dll
  2395. SHORTSUFFIX=emx
  2396. ECHO=echo
  2397. IMPORTLIBPREFIX=
  2398. endif
  2399. ifeq ($(OS_TARGET),amiga)
  2400. EXEEXT=
  2401. SHAREDLIBEXT=.library
  2402. SHORTSUFFIX=amg
  2403. endif
  2404. ifeq ($(OS_TARGET),aros)
  2405. EXEEXT=
  2406. SHAREDLIBEXT=.library
  2407. SHORTSUFFIX=aros
  2408. endif
  2409. ifeq ($(OS_TARGET),morphos)
  2410. EXEEXT=
  2411. SHAREDLIBEXT=.library
  2412. SHORTSUFFIX=mos
  2413. endif
  2414. ifeq ($(OS_TARGET),atari)
  2415. EXEEXT=.ttp
  2416. SHORTSUFFIX=ata
  2417. endif
  2418. ifeq ($(OS_TARGET),beos)
  2419. BATCHEXT=.sh
  2420. EXEEXT=
  2421. SHORTSUFFIX=be
  2422. endif
  2423. ifeq ($(OS_TARGET),haiku)
  2424. BATCHEXT=.sh
  2425. EXEEXT=
  2426. SHORTSUFFIX=hai
  2427. endif
  2428. ifeq ($(OS_TARGET),solaris)
  2429. BATCHEXT=.sh
  2430. EXEEXT=
  2431. SHORTSUFFIX=sun
  2432. endif
  2433. ifeq ($(OS_TARGET),qnx)
  2434. BATCHEXT=.sh
  2435. EXEEXT=
  2436. SHORTSUFFIX=qnx
  2437. endif
  2438. ifeq ($(OS_TARGET),netware)
  2439. EXEEXT=.nlm
  2440. STATICLIBPREFIX=
  2441. SHORTSUFFIX=nw
  2442. IMPORTLIBPREFIX=imp
  2443. endif
  2444. ifeq ($(OS_TARGET),netwlibc)
  2445. EXEEXT=.nlm
  2446. STATICLIBPREFIX=
  2447. SHORTSUFFIX=nwl
  2448. IMPORTLIBPREFIX=imp
  2449. endif
  2450. ifeq ($(OS_TARGET),macos)
  2451. BATCHEXT=
  2452. EXEEXT=
  2453. DEBUGSYMEXT=.xcoff
  2454. SHORTSUFFIX=mac
  2455. IMPORTLIBPREFIX=imp
  2456. endif
  2457. ifneq ($(findstring $(OS_TARGET),darwin iphonesim),)
  2458. BATCHEXT=.sh
  2459. EXEEXT=
  2460. HASSHAREDLIB=1
  2461. SHORTSUFFIX=dwn
  2462. EXEDBGEXT=.dSYM
  2463. endif
  2464. ifeq ($(OS_TARGET),gba)
  2465. EXEEXT=.gba
  2466. SHAREDLIBEXT=.so
  2467. SHORTSUFFIX=gba
  2468. endif
  2469. ifeq ($(OS_TARGET),symbian)
  2470. SHAREDLIBEXT=.dll
  2471. SHORTSUFFIX=symbian
  2472. endif
  2473. ifeq ($(OS_TARGET),NativeNT)
  2474. SHAREDLIBEXT=.dll
  2475. SHORTSUFFIX=nativent
  2476. endif
  2477. ifeq ($(OS_TARGET),wii)
  2478. EXEEXT=.dol
  2479. SHAREDLIBEXT=.so
  2480. SHORTSUFFIX=wii
  2481. endif
  2482. ifeq ($(OS_TARGET),aix)
  2483. BATCHEXT=.sh
  2484. EXEEXT=
  2485. SHORTSUFFIX=aix
  2486. endif
  2487. ifeq ($(OS_TARGET),java)
  2488. OEXT=.class
  2489. ASMEXT=.j
  2490. SHAREDLIBEXT=.jar
  2491. SHORTSUFFIX=java
  2492. endif
  2493. ifeq ($(CPU_TARGET),jvm)
  2494. ifeq ($(OS_TARGET),android)
  2495. OEXT=.class
  2496. ASMEXT=.j
  2497. SHAREDLIBEXT=.jar
  2498. SHORTSUFFIX=android
  2499. endif
  2500. endif
  2501. ifeq ($(OS_TARGET),msdos)
  2502. STATICLIBPREFIX=
  2503. STATICLIBEXT=.a
  2504. SHORTSUFFIX=d16
  2505. endif
  2506. ifeq ($(OS_TARGET),embedded)
  2507. ifeq ($(CPU_TARGET),i8086)
  2508. STATICLIBPREFIX=
  2509. STATICLIBEXT=.a
  2510. else
  2511. EXEEXT=.bin
  2512. endif
  2513. SHORTSUFFIX=emb
  2514. endif
  2515. ifeq ($(OS_TARGET),win16)
  2516. STATICLIBPREFIX=
  2517. STATICLIBEXT=.a
  2518. SHAREDLIBEXT=.dll
  2519. SHORTSUFFIX=w16
  2520. endif
  2521. ifneq ($(findstring $(OS_SOURCE),$(LIMIT83fs)),)
  2522. FPCMADE=fpcmade.$(SHORTSUFFIX)
  2523. ZIPSUFFIX=$(SHORTSUFFIX)
  2524. ZIPCROSSPREFIX=
  2525. ZIPSOURCESUFFIX=src
  2526. ZIPEXAMPLESUFFIX=exm
  2527. else
  2528. FPCMADE=fpcmade.$(TARGETSUFFIX)
  2529. ZIPSOURCESUFFIX=.source
  2530. ZIPEXAMPLESUFFIX=.examples
  2531. ifdef CROSSCOMPILE
  2532. ZIPSUFFIX=.$(SOURCESUFFIX)
  2533. ZIPCROSSPREFIX=$(TARGETSUFFIX)-
  2534. else
  2535. ZIPSUFFIX=.$(TARGETSUFFIX)
  2536. ZIPCROSSPREFIX=
  2537. endif
  2538. endif
  2539. ifndef ECHO
  2540. ECHO:=$(strip $(wildcard $(addsuffix /gecho$(SRCEXEEXT),$(SEARCHPATH))))
  2541. ifeq ($(ECHO),)
  2542. ECHO:=$(strip $(wildcard $(addsuffix /echo$(SRCEXEEXT),$(SEARCHPATH))))
  2543. ifeq ($(ECHO),)
  2544. ECHO= __missing_command_ECHO
  2545. else
  2546. ECHO:=$(firstword $(ECHO))
  2547. endif
  2548. else
  2549. ECHO:=$(firstword $(ECHO))
  2550. endif
  2551. endif
  2552. export ECHO
  2553. ifndef DATE
  2554. DATE:=$(strip $(wildcard $(addsuffix /gdate$(SRCEXEEXT),$(SEARCHPATH))))
  2555. ifeq ($(DATE),)
  2556. DATE:=$(strip $(wildcard $(addsuffix /date$(SRCEXEEXT),$(SEARCHPATH))))
  2557. ifeq ($(DATE),)
  2558. DATE= __missing_command_DATE
  2559. else
  2560. DATE:=$(firstword $(DATE))
  2561. endif
  2562. else
  2563. DATE:=$(firstword $(DATE))
  2564. endif
  2565. endif
  2566. export DATE
  2567. ifndef GINSTALL
  2568. GINSTALL:=$(strip $(wildcard $(addsuffix /ginstall$(SRCEXEEXT),$(SEARCHPATH))))
  2569. ifeq ($(GINSTALL),)
  2570. GINSTALL:=$(strip $(wildcard $(addsuffix /install$(SRCEXEEXT),$(SEARCHPATH))))
  2571. ifeq ($(GINSTALL),)
  2572. GINSTALL= __missing_command_GINSTALL
  2573. else
  2574. GINSTALL:=$(firstword $(GINSTALL))
  2575. endif
  2576. else
  2577. GINSTALL:=$(firstword $(GINSTALL))
  2578. endif
  2579. endif
  2580. export GINSTALL
  2581. ifndef CPPROG
  2582. CPPROG:=$(strip $(wildcard $(addsuffix /cp$(SRCEXEEXT),$(SEARCHPATH))))
  2583. ifeq ($(CPPROG),)
  2584. CPPROG= __missing_command_CPPROG
  2585. else
  2586. CPPROG:=$(firstword $(CPPROG))
  2587. endif
  2588. endif
  2589. export CPPROG
  2590. ifndef RMPROG
  2591. RMPROG:=$(strip $(wildcard $(addsuffix /rm$(SRCEXEEXT),$(SEARCHPATH))))
  2592. ifeq ($(RMPROG),)
  2593. RMPROG= __missing_command_RMPROG
  2594. else
  2595. RMPROG:=$(firstword $(RMPROG))
  2596. endif
  2597. endif
  2598. export RMPROG
  2599. ifndef MVPROG
  2600. MVPROG:=$(strip $(wildcard $(addsuffix /mv$(SRCEXEEXT),$(SEARCHPATH))))
  2601. ifeq ($(MVPROG),)
  2602. MVPROG= __missing_command_MVPROG
  2603. else
  2604. MVPROG:=$(firstword $(MVPROG))
  2605. endif
  2606. endif
  2607. export MVPROG
  2608. ifndef MKDIRPROG
  2609. MKDIRPROG:=$(strip $(wildcard $(addsuffix /gmkdir$(SRCEXEEXT),$(SEARCHPATH))))
  2610. ifeq ($(MKDIRPROG),)
  2611. MKDIRPROG:=$(strip $(wildcard $(addsuffix /mkdir$(SRCEXEEXT),$(SEARCHPATH))))
  2612. ifeq ($(MKDIRPROG),)
  2613. MKDIRPROG= __missing_command_MKDIRPROG
  2614. else
  2615. MKDIRPROG:=$(firstword $(MKDIRPROG))
  2616. endif
  2617. else
  2618. MKDIRPROG:=$(firstword $(MKDIRPROG))
  2619. endif
  2620. endif
  2621. export MKDIRPROG
  2622. ifndef ECHOREDIR
  2623. ifndef inUnix
  2624. ECHOREDIR=echo
  2625. else
  2626. ECHOREDIR=$(ECHO)
  2627. endif
  2628. endif
  2629. ifndef COPY
  2630. COPY:=$(CPPROG) -fp
  2631. endif
  2632. ifndef COPYTREE
  2633. COPYTREE:=$(CPPROG) -Rfp
  2634. endif
  2635. ifndef MKDIRTREE
  2636. MKDIRTREE:=$(MKDIRPROG) -p
  2637. endif
  2638. ifndef MOVE
  2639. MOVE:=$(MVPROG) -f
  2640. endif
  2641. ifndef DEL
  2642. DEL:=$(RMPROG) -f
  2643. endif
  2644. ifndef DELTREE
  2645. DELTREE:=$(RMPROG) -rf
  2646. endif
  2647. ifndef INSTALL
  2648. ifdef inUnix
  2649. INSTALL:=$(GINSTALL) -c -m 644
  2650. else
  2651. INSTALL:=$(COPY)
  2652. endif
  2653. endif
  2654. ifndef INSTALLEXE
  2655. ifdef inUnix
  2656. INSTALLEXE:=$(GINSTALL) -c -m 755
  2657. else
  2658. INSTALLEXE:=$(COPY)
  2659. endif
  2660. endif
  2661. ifndef MKDIR
  2662. MKDIR:=$(GINSTALL) -m 755 -d
  2663. endif
  2664. export ECHOREDIR COPY COPYTREE MOVE DEL DELTREE INSTALL INSTALLEXE MKDIR
  2665. ifndef PPUMOVE
  2666. PPUMOVE:=$(strip $(wildcard $(addsuffix /ppumove$(SRCEXEEXT),$(SEARCHPATH))))
  2667. ifeq ($(PPUMOVE),)
  2668. PPUMOVE= __missing_command_PPUMOVE
  2669. else
  2670. PPUMOVE:=$(firstword $(PPUMOVE))
  2671. endif
  2672. endif
  2673. export PPUMOVE
  2674. ifndef FPCMAKE
  2675. FPCMAKE:=$(strip $(wildcard $(addsuffix /fpcmake$(SRCEXEEXT),$(SEARCHPATH))))
  2676. ifeq ($(FPCMAKE),)
  2677. FPCMAKE= __missing_command_FPCMAKE
  2678. else
  2679. FPCMAKE:=$(firstword $(FPCMAKE))
  2680. endif
  2681. endif
  2682. export FPCMAKE
  2683. ifndef ZIPPROG
  2684. ZIPPROG:=$(strip $(wildcard $(addsuffix /zip$(SRCEXEEXT),$(SEARCHPATH))))
  2685. ifeq ($(ZIPPROG),)
  2686. ZIPPROG= __missing_command_ZIPPROG
  2687. else
  2688. ZIPPROG:=$(firstword $(ZIPPROG))
  2689. endif
  2690. endif
  2691. export ZIPPROG
  2692. ifndef TARPROG
  2693. TARPROG:=$(strip $(wildcard $(addsuffix /gtar$(SRCEXEEXT),$(SEARCHPATH))))
  2694. ifeq ($(TARPROG),)
  2695. TARPROG:=$(strip $(wildcard $(addsuffix /tar$(SRCEXEEXT),$(SEARCHPATH))))
  2696. ifeq ($(TARPROG),)
  2697. TARPROG= __missing_command_TARPROG
  2698. else
  2699. TARPROG:=$(firstword $(TARPROG))
  2700. endif
  2701. else
  2702. TARPROG:=$(firstword $(TARPROG))
  2703. endif
  2704. endif
  2705. export TARPROG
  2706. ASNAME=$(BINUTILSPREFIX)as
  2707. LDNAME=$(BINUTILSPREFIX)ld
  2708. ARNAME=$(BINUTILSPREFIX)ar
  2709. RCNAME=$(BINUTILSPREFIX)rc
  2710. NASMNAME=$(BINUTILSPREFIX)nasm
  2711. ifndef ASPROG
  2712. ifdef CROSSBINDIR
  2713. ASPROG=$(CROSSBINDIR)/$(ASNAME)$(SRCEXEEXT)
  2714. else
  2715. ASPROG=$(ASNAME)
  2716. endif
  2717. endif
  2718. ifndef LDPROG
  2719. ifdef CROSSBINDIR
  2720. LDPROG=$(CROSSBINDIR)/$(LDNAME)$(SRCEXEEXT)
  2721. else
  2722. LDPROG=$(LDNAME)
  2723. endif
  2724. endif
  2725. ifndef RCPROG
  2726. ifdef CROSSBINDIR
  2727. RCPROG=$(CROSSBINDIR)/$(RCNAME)$(SRCEXEEXT)
  2728. else
  2729. RCPROG=$(RCNAME)
  2730. endif
  2731. endif
  2732. ifndef ARPROG
  2733. ifdef CROSSBINDIR
  2734. ARPROG=$(CROSSBINDIR)/$(ARNAME)$(SRCEXEEXT)
  2735. else
  2736. ARPROG=$(ARNAME)
  2737. endif
  2738. endif
  2739. ifndef NASMPROG
  2740. ifdef CROSSBINDIR
  2741. NASMPROG=$(CROSSBINDIR)/$(NASMNAME)$(SRCEXEEXT)
  2742. else
  2743. NASMPROG=$(NASMNAME)
  2744. endif
  2745. endif
  2746. AS=$(ASPROG)
  2747. LD=$(LDPROG)
  2748. RC=$(RCPROG)
  2749. AR=$(ARPROG)
  2750. NASM=$(NASMPROG)
  2751. ifdef inUnix
  2752. PPAS=./ppas$(SRCBATCHEXT)
  2753. else
  2754. PPAS=ppas$(SRCBATCHEXT)
  2755. endif
  2756. ifdef inUnix
  2757. LDCONFIG=ldconfig
  2758. else
  2759. LDCONFIG=
  2760. endif
  2761. ifdef DATE
  2762. DATESTR:=$(shell $(DATE) +%Y%m%d)
  2763. else
  2764. DATESTR=
  2765. endif
  2766. ZIPOPT=-9
  2767. ZIPEXT=.zip
  2768. ifeq ($(USETAR),bz2)
  2769. TAROPT=vj
  2770. TAREXT=.tar.bz2
  2771. else
  2772. TAROPT=vz
  2773. TAREXT=.tar.gz
  2774. endif
  2775. override REQUIRE_PACKAGES=libndsfpc
  2776. ifeq ($(FULL_TARGET),i386-linux)
  2777. REQUIRE_PACKAGES_RTL=1
  2778. REQUIRE_PACKAGES_PASZLIB=1
  2779. REQUIRE_PACKAGES_FCL-PROCESS=1
  2780. REQUIRE_PACKAGES_HASH=1
  2781. REQUIRE_PACKAGES_LIBTAR=1
  2782. REQUIRE_PACKAGES_FPMKUNIT=1
  2783. REQUIRE_PACKAGES_LIBNDSFPC=1
  2784. endif
  2785. ifeq ($(FULL_TARGET),i386-go32v2)
  2786. REQUIRE_PACKAGES_RTL=1
  2787. REQUIRE_PACKAGES_PASZLIB=1
  2788. REQUIRE_PACKAGES_FCL-PROCESS=1
  2789. REQUIRE_PACKAGES_HASH=1
  2790. REQUIRE_PACKAGES_LIBTAR=1
  2791. REQUIRE_PACKAGES_FPMKUNIT=1
  2792. REQUIRE_PACKAGES_LIBNDSFPC=1
  2793. endif
  2794. ifeq ($(FULL_TARGET),i386-win32)
  2795. REQUIRE_PACKAGES_RTL=1
  2796. REQUIRE_PACKAGES_PASZLIB=1
  2797. REQUIRE_PACKAGES_FCL-PROCESS=1
  2798. REQUIRE_PACKAGES_HASH=1
  2799. REQUIRE_PACKAGES_LIBTAR=1
  2800. REQUIRE_PACKAGES_FPMKUNIT=1
  2801. REQUIRE_PACKAGES_LIBNDSFPC=1
  2802. endif
  2803. ifeq ($(FULL_TARGET),i386-os2)
  2804. REQUIRE_PACKAGES_RTL=1
  2805. REQUIRE_PACKAGES_PASZLIB=1
  2806. REQUIRE_PACKAGES_FCL-PROCESS=1
  2807. REQUIRE_PACKAGES_HASH=1
  2808. REQUIRE_PACKAGES_LIBTAR=1
  2809. REQUIRE_PACKAGES_FPMKUNIT=1
  2810. REQUIRE_PACKAGES_LIBNDSFPC=1
  2811. endif
  2812. ifeq ($(FULL_TARGET),i386-freebsd)
  2813. REQUIRE_PACKAGES_RTL=1
  2814. REQUIRE_PACKAGES_PASZLIB=1
  2815. REQUIRE_PACKAGES_FCL-PROCESS=1
  2816. REQUIRE_PACKAGES_HASH=1
  2817. REQUIRE_PACKAGES_LIBTAR=1
  2818. REQUIRE_PACKAGES_FPMKUNIT=1
  2819. REQUIRE_PACKAGES_LIBNDSFPC=1
  2820. endif
  2821. ifeq ($(FULL_TARGET),i386-beos)
  2822. REQUIRE_PACKAGES_RTL=1
  2823. REQUIRE_PACKAGES_PASZLIB=1
  2824. REQUIRE_PACKAGES_FCL-PROCESS=1
  2825. REQUIRE_PACKAGES_HASH=1
  2826. REQUIRE_PACKAGES_LIBTAR=1
  2827. REQUIRE_PACKAGES_FPMKUNIT=1
  2828. REQUIRE_PACKAGES_LIBNDSFPC=1
  2829. endif
  2830. ifeq ($(FULL_TARGET),i386-haiku)
  2831. REQUIRE_PACKAGES_RTL=1
  2832. REQUIRE_PACKAGES_PASZLIB=1
  2833. REQUIRE_PACKAGES_FCL-PROCESS=1
  2834. REQUIRE_PACKAGES_HASH=1
  2835. REQUIRE_PACKAGES_LIBTAR=1
  2836. REQUIRE_PACKAGES_FPMKUNIT=1
  2837. REQUIRE_PACKAGES_LIBNDSFPC=1
  2838. endif
  2839. ifeq ($(FULL_TARGET),i386-netbsd)
  2840. REQUIRE_PACKAGES_RTL=1
  2841. REQUIRE_PACKAGES_PASZLIB=1
  2842. REQUIRE_PACKAGES_FCL-PROCESS=1
  2843. REQUIRE_PACKAGES_HASH=1
  2844. REQUIRE_PACKAGES_LIBTAR=1
  2845. REQUIRE_PACKAGES_FPMKUNIT=1
  2846. REQUIRE_PACKAGES_LIBNDSFPC=1
  2847. endif
  2848. ifeq ($(FULL_TARGET),i386-solaris)
  2849. REQUIRE_PACKAGES_RTL=1
  2850. REQUIRE_PACKAGES_PASZLIB=1
  2851. REQUIRE_PACKAGES_FCL-PROCESS=1
  2852. REQUIRE_PACKAGES_HASH=1
  2853. REQUIRE_PACKAGES_LIBTAR=1
  2854. REQUIRE_PACKAGES_FPMKUNIT=1
  2855. REQUIRE_PACKAGES_LIBNDSFPC=1
  2856. endif
  2857. ifeq ($(FULL_TARGET),i386-netware)
  2858. REQUIRE_PACKAGES_RTL=1
  2859. REQUIRE_PACKAGES_PASZLIB=1
  2860. REQUIRE_PACKAGES_FCL-PROCESS=1
  2861. REQUIRE_PACKAGES_HASH=1
  2862. REQUIRE_PACKAGES_LIBTAR=1
  2863. REQUIRE_PACKAGES_FPMKUNIT=1
  2864. REQUIRE_PACKAGES_LIBNDSFPC=1
  2865. endif
  2866. ifeq ($(FULL_TARGET),i386-openbsd)
  2867. REQUIRE_PACKAGES_RTL=1
  2868. REQUIRE_PACKAGES_PASZLIB=1
  2869. REQUIRE_PACKAGES_FCL-PROCESS=1
  2870. REQUIRE_PACKAGES_HASH=1
  2871. REQUIRE_PACKAGES_LIBTAR=1
  2872. REQUIRE_PACKAGES_FPMKUNIT=1
  2873. REQUIRE_PACKAGES_LIBNDSFPC=1
  2874. endif
  2875. ifeq ($(FULL_TARGET),i386-wdosx)
  2876. REQUIRE_PACKAGES_RTL=1
  2877. REQUIRE_PACKAGES_PASZLIB=1
  2878. REQUIRE_PACKAGES_FCL-PROCESS=1
  2879. REQUIRE_PACKAGES_HASH=1
  2880. REQUIRE_PACKAGES_LIBTAR=1
  2881. REQUIRE_PACKAGES_FPMKUNIT=1
  2882. REQUIRE_PACKAGES_LIBNDSFPC=1
  2883. endif
  2884. ifeq ($(FULL_TARGET),i386-darwin)
  2885. REQUIRE_PACKAGES_RTL=1
  2886. REQUIRE_PACKAGES_PASZLIB=1
  2887. REQUIRE_PACKAGES_FCL-PROCESS=1
  2888. REQUIRE_PACKAGES_HASH=1
  2889. REQUIRE_PACKAGES_LIBTAR=1
  2890. REQUIRE_PACKAGES_FPMKUNIT=1
  2891. REQUIRE_PACKAGES_LIBNDSFPC=1
  2892. endif
  2893. ifeq ($(FULL_TARGET),i386-emx)
  2894. REQUIRE_PACKAGES_RTL=1
  2895. REQUIRE_PACKAGES_PASZLIB=1
  2896. REQUIRE_PACKAGES_FCL-PROCESS=1
  2897. REQUIRE_PACKAGES_HASH=1
  2898. REQUIRE_PACKAGES_LIBTAR=1
  2899. REQUIRE_PACKAGES_FPMKUNIT=1
  2900. REQUIRE_PACKAGES_LIBNDSFPC=1
  2901. endif
  2902. ifeq ($(FULL_TARGET),i386-watcom)
  2903. REQUIRE_PACKAGES_RTL=1
  2904. REQUIRE_PACKAGES_PASZLIB=1
  2905. REQUIRE_PACKAGES_FCL-PROCESS=1
  2906. REQUIRE_PACKAGES_HASH=1
  2907. REQUIRE_PACKAGES_LIBTAR=1
  2908. REQUIRE_PACKAGES_FPMKUNIT=1
  2909. REQUIRE_PACKAGES_LIBNDSFPC=1
  2910. endif
  2911. ifeq ($(FULL_TARGET),i386-netwlibc)
  2912. REQUIRE_PACKAGES_RTL=1
  2913. REQUIRE_PACKAGES_PASZLIB=1
  2914. REQUIRE_PACKAGES_FCL-PROCESS=1
  2915. REQUIRE_PACKAGES_HASH=1
  2916. REQUIRE_PACKAGES_LIBTAR=1
  2917. REQUIRE_PACKAGES_FPMKUNIT=1
  2918. REQUIRE_PACKAGES_LIBNDSFPC=1
  2919. endif
  2920. ifeq ($(FULL_TARGET),i386-wince)
  2921. REQUIRE_PACKAGES_RTL=1
  2922. REQUIRE_PACKAGES_PASZLIB=1
  2923. REQUIRE_PACKAGES_FCL-PROCESS=1
  2924. REQUIRE_PACKAGES_HASH=1
  2925. REQUIRE_PACKAGES_LIBTAR=1
  2926. REQUIRE_PACKAGES_FPMKUNIT=1
  2927. REQUIRE_PACKAGES_LIBNDSFPC=1
  2928. endif
  2929. ifeq ($(FULL_TARGET),i386-embedded)
  2930. REQUIRE_PACKAGES_RTL=1
  2931. REQUIRE_PACKAGES_PASZLIB=1
  2932. REQUIRE_PACKAGES_FCL-PROCESS=1
  2933. REQUIRE_PACKAGES_HASH=1
  2934. REQUIRE_PACKAGES_LIBTAR=1
  2935. REQUIRE_PACKAGES_FPMKUNIT=1
  2936. REQUIRE_PACKAGES_LIBNDSFPC=1
  2937. endif
  2938. ifeq ($(FULL_TARGET),i386-symbian)
  2939. REQUIRE_PACKAGES_RTL=1
  2940. REQUIRE_PACKAGES_PASZLIB=1
  2941. REQUIRE_PACKAGES_FCL-PROCESS=1
  2942. REQUIRE_PACKAGES_HASH=1
  2943. REQUIRE_PACKAGES_LIBTAR=1
  2944. REQUIRE_PACKAGES_FPMKUNIT=1
  2945. REQUIRE_PACKAGES_LIBNDSFPC=1
  2946. endif
  2947. ifeq ($(FULL_TARGET),i386-nativent)
  2948. REQUIRE_PACKAGES_RTL=1
  2949. REQUIRE_PACKAGES_PASZLIB=1
  2950. REQUIRE_PACKAGES_FCL-PROCESS=1
  2951. REQUIRE_PACKAGES_HASH=1
  2952. REQUIRE_PACKAGES_LIBTAR=1
  2953. REQUIRE_PACKAGES_FPMKUNIT=1
  2954. REQUIRE_PACKAGES_LIBNDSFPC=1
  2955. endif
  2956. ifeq ($(FULL_TARGET),i386-iphonesim)
  2957. REQUIRE_PACKAGES_RTL=1
  2958. REQUIRE_PACKAGES_PASZLIB=1
  2959. REQUIRE_PACKAGES_FCL-PROCESS=1
  2960. REQUIRE_PACKAGES_HASH=1
  2961. REQUIRE_PACKAGES_LIBTAR=1
  2962. REQUIRE_PACKAGES_FPMKUNIT=1
  2963. REQUIRE_PACKAGES_LIBNDSFPC=1
  2964. endif
  2965. ifeq ($(FULL_TARGET),i386-android)
  2966. REQUIRE_PACKAGES_RTL=1
  2967. REQUIRE_PACKAGES_PASZLIB=1
  2968. REQUIRE_PACKAGES_FCL-PROCESS=1
  2969. REQUIRE_PACKAGES_HASH=1
  2970. REQUIRE_PACKAGES_LIBTAR=1
  2971. REQUIRE_PACKAGES_FPMKUNIT=1
  2972. REQUIRE_PACKAGES_LIBNDSFPC=1
  2973. endif
  2974. ifeq ($(FULL_TARGET),i386-aros)
  2975. REQUIRE_PACKAGES_RTL=1
  2976. REQUIRE_PACKAGES_PASZLIB=1
  2977. REQUIRE_PACKAGES_FCL-PROCESS=1
  2978. REQUIRE_PACKAGES_HASH=1
  2979. REQUIRE_PACKAGES_LIBTAR=1
  2980. REQUIRE_PACKAGES_FPMKUNIT=1
  2981. REQUIRE_PACKAGES_LIBNDSFPC=1
  2982. endif
  2983. ifeq ($(FULL_TARGET),m68k-linux)
  2984. REQUIRE_PACKAGES_RTL=1
  2985. REQUIRE_PACKAGES_PASZLIB=1
  2986. REQUIRE_PACKAGES_FCL-PROCESS=1
  2987. REQUIRE_PACKAGES_HASH=1
  2988. REQUIRE_PACKAGES_LIBTAR=1
  2989. REQUIRE_PACKAGES_FPMKUNIT=1
  2990. REQUIRE_PACKAGES_LIBNDSFPC=1
  2991. endif
  2992. ifeq ($(FULL_TARGET),m68k-netbsd)
  2993. REQUIRE_PACKAGES_RTL=1
  2994. REQUIRE_PACKAGES_PASZLIB=1
  2995. REQUIRE_PACKAGES_FCL-PROCESS=1
  2996. REQUIRE_PACKAGES_HASH=1
  2997. REQUIRE_PACKAGES_LIBTAR=1
  2998. REQUIRE_PACKAGES_FPMKUNIT=1
  2999. REQUIRE_PACKAGES_LIBNDSFPC=1
  3000. endif
  3001. ifeq ($(FULL_TARGET),m68k-amiga)
  3002. REQUIRE_PACKAGES_RTL=1
  3003. REQUIRE_PACKAGES_PASZLIB=1
  3004. REQUIRE_PACKAGES_FCL-PROCESS=1
  3005. REQUIRE_PACKAGES_HASH=1
  3006. REQUIRE_PACKAGES_LIBTAR=1
  3007. REQUIRE_PACKAGES_FPMKUNIT=1
  3008. REQUIRE_PACKAGES_LIBNDSFPC=1
  3009. endif
  3010. ifeq ($(FULL_TARGET),m68k-atari)
  3011. REQUIRE_PACKAGES_RTL=1
  3012. REQUIRE_PACKAGES_PASZLIB=1
  3013. REQUIRE_PACKAGES_FCL-PROCESS=1
  3014. REQUIRE_PACKAGES_HASH=1
  3015. REQUIRE_PACKAGES_LIBTAR=1
  3016. REQUIRE_PACKAGES_FPMKUNIT=1
  3017. REQUIRE_PACKAGES_LIBNDSFPC=1
  3018. endif
  3019. ifeq ($(FULL_TARGET),m68k-palmos)
  3020. REQUIRE_PACKAGES_RTL=1
  3021. REQUIRE_PACKAGES_PASZLIB=1
  3022. REQUIRE_PACKAGES_FCL-PROCESS=1
  3023. REQUIRE_PACKAGES_HASH=1
  3024. REQUIRE_PACKAGES_LIBTAR=1
  3025. REQUIRE_PACKAGES_FPMKUNIT=1
  3026. REQUIRE_PACKAGES_LIBNDSFPC=1
  3027. endif
  3028. ifeq ($(FULL_TARGET),m68k-macos)
  3029. REQUIRE_PACKAGES_RTL=1
  3030. REQUIRE_PACKAGES_PASZLIB=1
  3031. REQUIRE_PACKAGES_FCL-PROCESS=1
  3032. REQUIRE_PACKAGES_HASH=1
  3033. REQUIRE_PACKAGES_LIBTAR=1
  3034. REQUIRE_PACKAGES_FPMKUNIT=1
  3035. REQUIRE_PACKAGES_LIBNDSFPC=1
  3036. endif
  3037. ifeq ($(FULL_TARGET),m68k-embedded)
  3038. REQUIRE_PACKAGES_RTL=1
  3039. REQUIRE_PACKAGES_PASZLIB=1
  3040. REQUIRE_PACKAGES_FCL-PROCESS=1
  3041. REQUIRE_PACKAGES_HASH=1
  3042. REQUIRE_PACKAGES_LIBTAR=1
  3043. REQUIRE_PACKAGES_FPMKUNIT=1
  3044. REQUIRE_PACKAGES_LIBNDSFPC=1
  3045. endif
  3046. ifeq ($(FULL_TARGET),powerpc-linux)
  3047. REQUIRE_PACKAGES_RTL=1
  3048. REQUIRE_PACKAGES_PASZLIB=1
  3049. REQUIRE_PACKAGES_FCL-PROCESS=1
  3050. REQUIRE_PACKAGES_HASH=1
  3051. REQUIRE_PACKAGES_LIBTAR=1
  3052. REQUIRE_PACKAGES_FPMKUNIT=1
  3053. REQUIRE_PACKAGES_LIBNDSFPC=1
  3054. endif
  3055. ifeq ($(FULL_TARGET),powerpc-netbsd)
  3056. REQUIRE_PACKAGES_RTL=1
  3057. REQUIRE_PACKAGES_PASZLIB=1
  3058. REQUIRE_PACKAGES_FCL-PROCESS=1
  3059. REQUIRE_PACKAGES_HASH=1
  3060. REQUIRE_PACKAGES_LIBTAR=1
  3061. REQUIRE_PACKAGES_FPMKUNIT=1
  3062. REQUIRE_PACKAGES_LIBNDSFPC=1
  3063. endif
  3064. ifeq ($(FULL_TARGET),powerpc-amiga)
  3065. REQUIRE_PACKAGES_RTL=1
  3066. REQUIRE_PACKAGES_PASZLIB=1
  3067. REQUIRE_PACKAGES_FCL-PROCESS=1
  3068. REQUIRE_PACKAGES_HASH=1
  3069. REQUIRE_PACKAGES_LIBTAR=1
  3070. REQUIRE_PACKAGES_FPMKUNIT=1
  3071. REQUIRE_PACKAGES_LIBNDSFPC=1
  3072. endif
  3073. ifeq ($(FULL_TARGET),powerpc-macos)
  3074. REQUIRE_PACKAGES_RTL=1
  3075. REQUIRE_PACKAGES_PASZLIB=1
  3076. REQUIRE_PACKAGES_FCL-PROCESS=1
  3077. REQUIRE_PACKAGES_HASH=1
  3078. REQUIRE_PACKAGES_LIBTAR=1
  3079. REQUIRE_PACKAGES_FPMKUNIT=1
  3080. REQUIRE_PACKAGES_LIBNDSFPC=1
  3081. endif
  3082. ifeq ($(FULL_TARGET),powerpc-darwin)
  3083. REQUIRE_PACKAGES_RTL=1
  3084. REQUIRE_PACKAGES_PASZLIB=1
  3085. REQUIRE_PACKAGES_FCL-PROCESS=1
  3086. REQUIRE_PACKAGES_HASH=1
  3087. REQUIRE_PACKAGES_LIBTAR=1
  3088. REQUIRE_PACKAGES_FPMKUNIT=1
  3089. REQUIRE_PACKAGES_LIBNDSFPC=1
  3090. endif
  3091. ifeq ($(FULL_TARGET),powerpc-morphos)
  3092. REQUIRE_PACKAGES_RTL=1
  3093. REQUIRE_PACKAGES_PASZLIB=1
  3094. REQUIRE_PACKAGES_FCL-PROCESS=1
  3095. REQUIRE_PACKAGES_HASH=1
  3096. REQUIRE_PACKAGES_LIBTAR=1
  3097. REQUIRE_PACKAGES_FPMKUNIT=1
  3098. REQUIRE_PACKAGES_LIBNDSFPC=1
  3099. endif
  3100. ifeq ($(FULL_TARGET),powerpc-embedded)
  3101. REQUIRE_PACKAGES_RTL=1
  3102. REQUIRE_PACKAGES_PASZLIB=1
  3103. REQUIRE_PACKAGES_FCL-PROCESS=1
  3104. REQUIRE_PACKAGES_HASH=1
  3105. REQUIRE_PACKAGES_LIBTAR=1
  3106. REQUIRE_PACKAGES_FPMKUNIT=1
  3107. REQUIRE_PACKAGES_LIBNDSFPC=1
  3108. endif
  3109. ifeq ($(FULL_TARGET),powerpc-wii)
  3110. REQUIRE_PACKAGES_RTL=1
  3111. REQUIRE_PACKAGES_PASZLIB=1
  3112. REQUIRE_PACKAGES_FCL-PROCESS=1
  3113. REQUIRE_PACKAGES_HASH=1
  3114. REQUIRE_PACKAGES_LIBTAR=1
  3115. REQUIRE_PACKAGES_FPMKUNIT=1
  3116. REQUIRE_PACKAGES_LIBNDSFPC=1
  3117. endif
  3118. ifeq ($(FULL_TARGET),powerpc-aix)
  3119. REQUIRE_PACKAGES_RTL=1
  3120. REQUIRE_PACKAGES_PASZLIB=1
  3121. REQUIRE_PACKAGES_FCL-PROCESS=1
  3122. REQUIRE_PACKAGES_HASH=1
  3123. REQUIRE_PACKAGES_LIBTAR=1
  3124. REQUIRE_PACKAGES_FPMKUNIT=1
  3125. REQUIRE_PACKAGES_LIBNDSFPC=1
  3126. endif
  3127. ifeq ($(FULL_TARGET),sparc-linux)
  3128. REQUIRE_PACKAGES_RTL=1
  3129. REQUIRE_PACKAGES_PASZLIB=1
  3130. REQUIRE_PACKAGES_FCL-PROCESS=1
  3131. REQUIRE_PACKAGES_HASH=1
  3132. REQUIRE_PACKAGES_LIBTAR=1
  3133. REQUIRE_PACKAGES_FPMKUNIT=1
  3134. REQUIRE_PACKAGES_LIBNDSFPC=1
  3135. endif
  3136. ifeq ($(FULL_TARGET),sparc-netbsd)
  3137. REQUIRE_PACKAGES_RTL=1
  3138. REQUIRE_PACKAGES_PASZLIB=1
  3139. REQUIRE_PACKAGES_FCL-PROCESS=1
  3140. REQUIRE_PACKAGES_HASH=1
  3141. REQUIRE_PACKAGES_LIBTAR=1
  3142. REQUIRE_PACKAGES_FPMKUNIT=1
  3143. REQUIRE_PACKAGES_LIBNDSFPC=1
  3144. endif
  3145. ifeq ($(FULL_TARGET),sparc-solaris)
  3146. REQUIRE_PACKAGES_RTL=1
  3147. REQUIRE_PACKAGES_PASZLIB=1
  3148. REQUIRE_PACKAGES_FCL-PROCESS=1
  3149. REQUIRE_PACKAGES_HASH=1
  3150. REQUIRE_PACKAGES_LIBTAR=1
  3151. REQUIRE_PACKAGES_FPMKUNIT=1
  3152. REQUIRE_PACKAGES_LIBNDSFPC=1
  3153. endif
  3154. ifeq ($(FULL_TARGET),sparc-embedded)
  3155. REQUIRE_PACKAGES_RTL=1
  3156. REQUIRE_PACKAGES_PASZLIB=1
  3157. REQUIRE_PACKAGES_FCL-PROCESS=1
  3158. REQUIRE_PACKAGES_HASH=1
  3159. REQUIRE_PACKAGES_LIBTAR=1
  3160. REQUIRE_PACKAGES_FPMKUNIT=1
  3161. REQUIRE_PACKAGES_LIBNDSFPC=1
  3162. endif
  3163. ifeq ($(FULL_TARGET),x86_64-linux)
  3164. REQUIRE_PACKAGES_RTL=1
  3165. REQUIRE_PACKAGES_PASZLIB=1
  3166. REQUIRE_PACKAGES_FCL-PROCESS=1
  3167. REQUIRE_PACKAGES_HASH=1
  3168. REQUIRE_PACKAGES_LIBTAR=1
  3169. REQUIRE_PACKAGES_FPMKUNIT=1
  3170. REQUIRE_PACKAGES_LIBNDSFPC=1
  3171. endif
  3172. ifeq ($(FULL_TARGET),x86_64-freebsd)
  3173. REQUIRE_PACKAGES_RTL=1
  3174. REQUIRE_PACKAGES_PASZLIB=1
  3175. REQUIRE_PACKAGES_FCL-PROCESS=1
  3176. REQUIRE_PACKAGES_HASH=1
  3177. REQUIRE_PACKAGES_LIBTAR=1
  3178. REQUIRE_PACKAGES_FPMKUNIT=1
  3179. REQUIRE_PACKAGES_LIBNDSFPC=1
  3180. endif
  3181. ifeq ($(FULL_TARGET),x86_64-netbsd)
  3182. REQUIRE_PACKAGES_RTL=1
  3183. REQUIRE_PACKAGES_PASZLIB=1
  3184. REQUIRE_PACKAGES_FCL-PROCESS=1
  3185. REQUIRE_PACKAGES_HASH=1
  3186. REQUIRE_PACKAGES_LIBTAR=1
  3187. REQUIRE_PACKAGES_FPMKUNIT=1
  3188. REQUIRE_PACKAGES_LIBNDSFPC=1
  3189. endif
  3190. ifeq ($(FULL_TARGET),x86_64-solaris)
  3191. REQUIRE_PACKAGES_RTL=1
  3192. REQUIRE_PACKAGES_PASZLIB=1
  3193. REQUIRE_PACKAGES_FCL-PROCESS=1
  3194. REQUIRE_PACKAGES_HASH=1
  3195. REQUIRE_PACKAGES_LIBTAR=1
  3196. REQUIRE_PACKAGES_FPMKUNIT=1
  3197. REQUIRE_PACKAGES_LIBNDSFPC=1
  3198. endif
  3199. ifeq ($(FULL_TARGET),x86_64-openbsd)
  3200. REQUIRE_PACKAGES_RTL=1
  3201. REQUIRE_PACKAGES_PASZLIB=1
  3202. REQUIRE_PACKAGES_FCL-PROCESS=1
  3203. REQUIRE_PACKAGES_HASH=1
  3204. REQUIRE_PACKAGES_LIBTAR=1
  3205. REQUIRE_PACKAGES_FPMKUNIT=1
  3206. REQUIRE_PACKAGES_LIBNDSFPC=1
  3207. endif
  3208. ifeq ($(FULL_TARGET),x86_64-darwin)
  3209. REQUIRE_PACKAGES_RTL=1
  3210. REQUIRE_PACKAGES_PASZLIB=1
  3211. REQUIRE_PACKAGES_FCL-PROCESS=1
  3212. REQUIRE_PACKAGES_HASH=1
  3213. REQUIRE_PACKAGES_LIBTAR=1
  3214. REQUIRE_PACKAGES_FPMKUNIT=1
  3215. REQUIRE_PACKAGES_LIBNDSFPC=1
  3216. endif
  3217. ifeq ($(FULL_TARGET),x86_64-win64)
  3218. REQUIRE_PACKAGES_RTL=1
  3219. REQUIRE_PACKAGES_PASZLIB=1
  3220. REQUIRE_PACKAGES_FCL-PROCESS=1
  3221. REQUIRE_PACKAGES_HASH=1
  3222. REQUIRE_PACKAGES_LIBTAR=1
  3223. REQUIRE_PACKAGES_FPMKUNIT=1
  3224. REQUIRE_PACKAGES_LIBNDSFPC=1
  3225. endif
  3226. ifeq ($(FULL_TARGET),x86_64-embedded)
  3227. REQUIRE_PACKAGES_RTL=1
  3228. REQUIRE_PACKAGES_PASZLIB=1
  3229. REQUIRE_PACKAGES_FCL-PROCESS=1
  3230. REQUIRE_PACKAGES_HASH=1
  3231. REQUIRE_PACKAGES_LIBTAR=1
  3232. REQUIRE_PACKAGES_FPMKUNIT=1
  3233. REQUIRE_PACKAGES_LIBNDSFPC=1
  3234. endif
  3235. ifeq ($(FULL_TARGET),x86_64-iphonesim)
  3236. REQUIRE_PACKAGES_RTL=1
  3237. REQUIRE_PACKAGES_PASZLIB=1
  3238. REQUIRE_PACKAGES_FCL-PROCESS=1
  3239. REQUIRE_PACKAGES_HASH=1
  3240. REQUIRE_PACKAGES_LIBTAR=1
  3241. REQUIRE_PACKAGES_FPMKUNIT=1
  3242. REQUIRE_PACKAGES_LIBNDSFPC=1
  3243. endif
  3244. ifeq ($(FULL_TARGET),x86_64-aros)
  3245. REQUIRE_PACKAGES_RTL=1
  3246. REQUIRE_PACKAGES_PASZLIB=1
  3247. REQUIRE_PACKAGES_FCL-PROCESS=1
  3248. REQUIRE_PACKAGES_HASH=1
  3249. REQUIRE_PACKAGES_LIBTAR=1
  3250. REQUIRE_PACKAGES_FPMKUNIT=1
  3251. REQUIRE_PACKAGES_LIBNDSFPC=1
  3252. endif
  3253. ifeq ($(FULL_TARGET),x86_64-dragonfly)
  3254. REQUIRE_PACKAGES_RTL=1
  3255. REQUIRE_PACKAGES_PASZLIB=1
  3256. REQUIRE_PACKAGES_FCL-PROCESS=1
  3257. REQUIRE_PACKAGES_HASH=1
  3258. REQUIRE_PACKAGES_LIBTAR=1
  3259. REQUIRE_PACKAGES_FPMKUNIT=1
  3260. REQUIRE_PACKAGES_LIBNDSFPC=1
  3261. endif
  3262. ifeq ($(FULL_TARGET),arm-linux)
  3263. REQUIRE_PACKAGES_RTL=1
  3264. REQUIRE_PACKAGES_PASZLIB=1
  3265. REQUIRE_PACKAGES_FCL-PROCESS=1
  3266. REQUIRE_PACKAGES_HASH=1
  3267. REQUIRE_PACKAGES_LIBTAR=1
  3268. REQUIRE_PACKAGES_FPMKUNIT=1
  3269. REQUIRE_PACKAGES_LIBNDSFPC=1
  3270. endif
  3271. ifeq ($(FULL_TARGET),arm-palmos)
  3272. REQUIRE_PACKAGES_RTL=1
  3273. REQUIRE_PACKAGES_PASZLIB=1
  3274. REQUIRE_PACKAGES_FCL-PROCESS=1
  3275. REQUIRE_PACKAGES_HASH=1
  3276. REQUIRE_PACKAGES_LIBTAR=1
  3277. REQUIRE_PACKAGES_FPMKUNIT=1
  3278. REQUIRE_PACKAGES_LIBNDSFPC=1
  3279. endif
  3280. ifeq ($(FULL_TARGET),arm-darwin)
  3281. REQUIRE_PACKAGES_RTL=1
  3282. REQUIRE_PACKAGES_PASZLIB=1
  3283. REQUIRE_PACKAGES_FCL-PROCESS=1
  3284. REQUIRE_PACKAGES_HASH=1
  3285. REQUIRE_PACKAGES_LIBTAR=1
  3286. REQUIRE_PACKAGES_FPMKUNIT=1
  3287. REQUIRE_PACKAGES_LIBNDSFPC=1
  3288. endif
  3289. ifeq ($(FULL_TARGET),arm-wince)
  3290. REQUIRE_PACKAGES_RTL=1
  3291. REQUIRE_PACKAGES_PASZLIB=1
  3292. REQUIRE_PACKAGES_FCL-PROCESS=1
  3293. REQUIRE_PACKAGES_HASH=1
  3294. REQUIRE_PACKAGES_LIBTAR=1
  3295. REQUIRE_PACKAGES_FPMKUNIT=1
  3296. REQUIRE_PACKAGES_LIBNDSFPC=1
  3297. endif
  3298. ifeq ($(FULL_TARGET),arm-gba)
  3299. REQUIRE_PACKAGES_RTL=1
  3300. REQUIRE_PACKAGES_PASZLIB=1
  3301. REQUIRE_PACKAGES_FCL-PROCESS=1
  3302. REQUIRE_PACKAGES_HASH=1
  3303. REQUIRE_PACKAGES_LIBTAR=1
  3304. REQUIRE_PACKAGES_FPMKUNIT=1
  3305. REQUIRE_PACKAGES_LIBNDSFPC=1
  3306. endif
  3307. ifeq ($(FULL_TARGET),arm-nds)
  3308. REQUIRE_PACKAGES_RTL=1
  3309. REQUIRE_PACKAGES_PASZLIB=1
  3310. REQUIRE_PACKAGES_FCL-PROCESS=1
  3311. REQUIRE_PACKAGES_HASH=1
  3312. REQUIRE_PACKAGES_LIBTAR=1
  3313. REQUIRE_PACKAGES_FPMKUNIT=1
  3314. REQUIRE_PACKAGES_LIBNDSFPC=1
  3315. endif
  3316. ifeq ($(FULL_TARGET),arm-embedded)
  3317. REQUIRE_PACKAGES_RTL=1
  3318. REQUIRE_PACKAGES_PASZLIB=1
  3319. REQUIRE_PACKAGES_FCL-PROCESS=1
  3320. REQUIRE_PACKAGES_HASH=1
  3321. REQUIRE_PACKAGES_LIBTAR=1
  3322. REQUIRE_PACKAGES_FPMKUNIT=1
  3323. REQUIRE_PACKAGES_LIBNDSFPC=1
  3324. endif
  3325. ifeq ($(FULL_TARGET),arm-symbian)
  3326. REQUIRE_PACKAGES_RTL=1
  3327. REQUIRE_PACKAGES_PASZLIB=1
  3328. REQUIRE_PACKAGES_FCL-PROCESS=1
  3329. REQUIRE_PACKAGES_HASH=1
  3330. REQUIRE_PACKAGES_LIBTAR=1
  3331. REQUIRE_PACKAGES_FPMKUNIT=1
  3332. REQUIRE_PACKAGES_LIBNDSFPC=1
  3333. endif
  3334. ifeq ($(FULL_TARGET),arm-android)
  3335. REQUIRE_PACKAGES_RTL=1
  3336. REQUIRE_PACKAGES_PASZLIB=1
  3337. REQUIRE_PACKAGES_FCL-PROCESS=1
  3338. REQUIRE_PACKAGES_HASH=1
  3339. REQUIRE_PACKAGES_LIBTAR=1
  3340. REQUIRE_PACKAGES_FPMKUNIT=1
  3341. REQUIRE_PACKAGES_LIBNDSFPC=1
  3342. endif
  3343. ifeq ($(FULL_TARGET),arm-aros)
  3344. REQUIRE_PACKAGES_RTL=1
  3345. REQUIRE_PACKAGES_PASZLIB=1
  3346. REQUIRE_PACKAGES_FCL-PROCESS=1
  3347. REQUIRE_PACKAGES_HASH=1
  3348. REQUIRE_PACKAGES_LIBTAR=1
  3349. REQUIRE_PACKAGES_FPMKUNIT=1
  3350. REQUIRE_PACKAGES_LIBNDSFPC=1
  3351. endif
  3352. ifeq ($(FULL_TARGET),powerpc64-linux)
  3353. REQUIRE_PACKAGES_RTL=1
  3354. REQUIRE_PACKAGES_PASZLIB=1
  3355. REQUIRE_PACKAGES_FCL-PROCESS=1
  3356. REQUIRE_PACKAGES_HASH=1
  3357. REQUIRE_PACKAGES_LIBTAR=1
  3358. REQUIRE_PACKAGES_FPMKUNIT=1
  3359. REQUIRE_PACKAGES_LIBNDSFPC=1
  3360. endif
  3361. ifeq ($(FULL_TARGET),powerpc64-darwin)
  3362. REQUIRE_PACKAGES_RTL=1
  3363. REQUIRE_PACKAGES_PASZLIB=1
  3364. REQUIRE_PACKAGES_FCL-PROCESS=1
  3365. REQUIRE_PACKAGES_HASH=1
  3366. REQUIRE_PACKAGES_LIBTAR=1
  3367. REQUIRE_PACKAGES_FPMKUNIT=1
  3368. REQUIRE_PACKAGES_LIBNDSFPC=1
  3369. endif
  3370. ifeq ($(FULL_TARGET),powerpc64-embedded)
  3371. REQUIRE_PACKAGES_RTL=1
  3372. REQUIRE_PACKAGES_PASZLIB=1
  3373. REQUIRE_PACKAGES_FCL-PROCESS=1
  3374. REQUIRE_PACKAGES_HASH=1
  3375. REQUIRE_PACKAGES_LIBTAR=1
  3376. REQUIRE_PACKAGES_FPMKUNIT=1
  3377. REQUIRE_PACKAGES_LIBNDSFPC=1
  3378. endif
  3379. ifeq ($(FULL_TARGET),powerpc64-aix)
  3380. REQUIRE_PACKAGES_RTL=1
  3381. REQUIRE_PACKAGES_PASZLIB=1
  3382. REQUIRE_PACKAGES_FCL-PROCESS=1
  3383. REQUIRE_PACKAGES_HASH=1
  3384. REQUIRE_PACKAGES_LIBTAR=1
  3385. REQUIRE_PACKAGES_FPMKUNIT=1
  3386. REQUIRE_PACKAGES_LIBNDSFPC=1
  3387. endif
  3388. ifeq ($(FULL_TARGET),avr-embedded)
  3389. REQUIRE_PACKAGES_RTL=1
  3390. REQUIRE_PACKAGES_PASZLIB=1
  3391. REQUIRE_PACKAGES_FCL-PROCESS=1
  3392. REQUIRE_PACKAGES_HASH=1
  3393. REQUIRE_PACKAGES_LIBTAR=1
  3394. REQUIRE_PACKAGES_FPMKUNIT=1
  3395. REQUIRE_PACKAGES_LIBNDSFPC=1
  3396. endif
  3397. ifeq ($(FULL_TARGET),armeb-linux)
  3398. REQUIRE_PACKAGES_RTL=1
  3399. REQUIRE_PACKAGES_PASZLIB=1
  3400. REQUIRE_PACKAGES_FCL-PROCESS=1
  3401. REQUIRE_PACKAGES_HASH=1
  3402. REQUIRE_PACKAGES_LIBTAR=1
  3403. REQUIRE_PACKAGES_FPMKUNIT=1
  3404. REQUIRE_PACKAGES_LIBNDSFPC=1
  3405. endif
  3406. ifeq ($(FULL_TARGET),armeb-embedded)
  3407. REQUIRE_PACKAGES_RTL=1
  3408. REQUIRE_PACKAGES_PASZLIB=1
  3409. REQUIRE_PACKAGES_FCL-PROCESS=1
  3410. REQUIRE_PACKAGES_HASH=1
  3411. REQUIRE_PACKAGES_LIBTAR=1
  3412. REQUIRE_PACKAGES_FPMKUNIT=1
  3413. REQUIRE_PACKAGES_LIBNDSFPC=1
  3414. endif
  3415. ifeq ($(FULL_TARGET),mips-linux)
  3416. REQUIRE_PACKAGES_RTL=1
  3417. REQUIRE_PACKAGES_PASZLIB=1
  3418. REQUIRE_PACKAGES_FCL-PROCESS=1
  3419. REQUIRE_PACKAGES_HASH=1
  3420. REQUIRE_PACKAGES_LIBTAR=1
  3421. REQUIRE_PACKAGES_FPMKUNIT=1
  3422. REQUIRE_PACKAGES_LIBNDSFPC=1
  3423. endif
  3424. ifeq ($(FULL_TARGET),mipsel-linux)
  3425. REQUIRE_PACKAGES_RTL=1
  3426. REQUIRE_PACKAGES_PASZLIB=1
  3427. REQUIRE_PACKAGES_FCL-PROCESS=1
  3428. REQUIRE_PACKAGES_HASH=1
  3429. REQUIRE_PACKAGES_LIBTAR=1
  3430. REQUIRE_PACKAGES_FPMKUNIT=1
  3431. REQUIRE_PACKAGES_LIBNDSFPC=1
  3432. endif
  3433. ifeq ($(FULL_TARGET),mipsel-embedded)
  3434. REQUIRE_PACKAGES_RTL=1
  3435. REQUIRE_PACKAGES_PASZLIB=1
  3436. REQUIRE_PACKAGES_FCL-PROCESS=1
  3437. REQUIRE_PACKAGES_HASH=1
  3438. REQUIRE_PACKAGES_LIBTAR=1
  3439. REQUIRE_PACKAGES_FPMKUNIT=1
  3440. REQUIRE_PACKAGES_LIBNDSFPC=1
  3441. endif
  3442. ifeq ($(FULL_TARGET),mipsel-android)
  3443. REQUIRE_PACKAGES_RTL=1
  3444. REQUIRE_PACKAGES_PASZLIB=1
  3445. REQUIRE_PACKAGES_FCL-PROCESS=1
  3446. REQUIRE_PACKAGES_HASH=1
  3447. REQUIRE_PACKAGES_LIBTAR=1
  3448. REQUIRE_PACKAGES_FPMKUNIT=1
  3449. REQUIRE_PACKAGES_LIBNDSFPC=1
  3450. endif
  3451. ifeq ($(FULL_TARGET),jvm-java)
  3452. REQUIRE_PACKAGES_RTL=1
  3453. REQUIRE_PACKAGES_PASZLIB=1
  3454. REQUIRE_PACKAGES_FCL-PROCESS=1
  3455. REQUIRE_PACKAGES_HASH=1
  3456. REQUIRE_PACKAGES_LIBTAR=1
  3457. REQUIRE_PACKAGES_FPMKUNIT=1
  3458. REQUIRE_PACKAGES_LIBNDSFPC=1
  3459. endif
  3460. ifeq ($(FULL_TARGET),jvm-android)
  3461. REQUIRE_PACKAGES_RTL=1
  3462. REQUIRE_PACKAGES_PASZLIB=1
  3463. REQUIRE_PACKAGES_FCL-PROCESS=1
  3464. REQUIRE_PACKAGES_HASH=1
  3465. REQUIRE_PACKAGES_LIBTAR=1
  3466. REQUIRE_PACKAGES_FPMKUNIT=1
  3467. REQUIRE_PACKAGES_LIBNDSFPC=1
  3468. endif
  3469. ifeq ($(FULL_TARGET),i8086-embedded)
  3470. REQUIRE_PACKAGES_RTL=1
  3471. REQUIRE_PACKAGES_PASZLIB=1
  3472. REQUIRE_PACKAGES_FCL-PROCESS=1
  3473. REQUIRE_PACKAGES_HASH=1
  3474. REQUIRE_PACKAGES_LIBTAR=1
  3475. REQUIRE_PACKAGES_FPMKUNIT=1
  3476. REQUIRE_PACKAGES_LIBNDSFPC=1
  3477. endif
  3478. ifeq ($(FULL_TARGET),i8086-msdos)
  3479. REQUIRE_PACKAGES_RTL=1
  3480. REQUIRE_PACKAGES_PASZLIB=1
  3481. REQUIRE_PACKAGES_FCL-PROCESS=1
  3482. REQUIRE_PACKAGES_HASH=1
  3483. REQUIRE_PACKAGES_LIBTAR=1
  3484. REQUIRE_PACKAGES_FPMKUNIT=1
  3485. REQUIRE_PACKAGES_LIBNDSFPC=1
  3486. endif
  3487. ifeq ($(FULL_TARGET),i8086-win16)
  3488. REQUIRE_PACKAGES_RTL=1
  3489. REQUIRE_PACKAGES_PASZLIB=1
  3490. REQUIRE_PACKAGES_FCL-PROCESS=1
  3491. REQUIRE_PACKAGES_HASH=1
  3492. REQUIRE_PACKAGES_LIBTAR=1
  3493. REQUIRE_PACKAGES_FPMKUNIT=1
  3494. REQUIRE_PACKAGES_LIBNDSFPC=1
  3495. endif
  3496. ifeq ($(FULL_TARGET),aarch64-linux)
  3497. REQUIRE_PACKAGES_RTL=1
  3498. REQUIRE_PACKAGES_PASZLIB=1
  3499. REQUIRE_PACKAGES_FCL-PROCESS=1
  3500. REQUIRE_PACKAGES_HASH=1
  3501. REQUIRE_PACKAGES_LIBTAR=1
  3502. REQUIRE_PACKAGES_FPMKUNIT=1
  3503. REQUIRE_PACKAGES_LIBNDSFPC=1
  3504. endif
  3505. ifeq ($(FULL_TARGET),aarch64-darwin)
  3506. REQUIRE_PACKAGES_RTL=1
  3507. REQUIRE_PACKAGES_PASZLIB=1
  3508. REQUIRE_PACKAGES_FCL-PROCESS=1
  3509. REQUIRE_PACKAGES_HASH=1
  3510. REQUIRE_PACKAGES_LIBTAR=1
  3511. REQUIRE_PACKAGES_FPMKUNIT=1
  3512. REQUIRE_PACKAGES_LIBNDSFPC=1
  3513. endif
  3514. ifeq ($(FULL_TARGET),wasm-wasm)
  3515. REQUIRE_PACKAGES_RTL=1
  3516. REQUIRE_PACKAGES_PASZLIB=1
  3517. REQUIRE_PACKAGES_FCL-PROCESS=1
  3518. REQUIRE_PACKAGES_HASH=1
  3519. REQUIRE_PACKAGES_LIBTAR=1
  3520. REQUIRE_PACKAGES_FPMKUNIT=1
  3521. REQUIRE_PACKAGES_LIBNDSFPC=1
  3522. endif
  3523. ifeq ($(FULL_TARGET),sparc64-linux)
  3524. REQUIRE_PACKAGES_RTL=1
  3525. REQUIRE_PACKAGES_PASZLIB=1
  3526. REQUIRE_PACKAGES_FCL-PROCESS=1
  3527. REQUIRE_PACKAGES_HASH=1
  3528. REQUIRE_PACKAGES_LIBTAR=1
  3529. REQUIRE_PACKAGES_FPMKUNIT=1
  3530. REQUIRE_PACKAGES_LIBNDSFPC=1
  3531. endif
  3532. ifdef REQUIRE_PACKAGES_RTL
  3533. PACKAGEDIR_RTL:=$(firstword $(subst /Makefile.fpc,,$(strip $(wildcard $(addsuffix /rtl/Makefile.fpc,$(PACKAGESDIR))))))
  3534. ifneq ($(PACKAGEDIR_RTL),)
  3535. ifneq ($(wildcard $(PACKAGEDIR_RTL)/units/$(TARGETSUFFIX)),)
  3536. UNITDIR_RTL=$(PACKAGEDIR_RTL)/units/$(TARGETSUFFIX)
  3537. else
  3538. UNITDIR_RTL=$(PACKAGEDIR_RTL)
  3539. endif
  3540. ifneq ($(wildcard $(PACKAGEDIR_RTL)/units/$(SOURCESUFFIX)),)
  3541. UNITDIR_FPMAKE_RTL=$(PACKAGEDIR_RTL)/units/$(SOURCESUFFIX)
  3542. else
  3543. ifneq ($(wildcard $(PACKAGEDIR_RTL)/units_bs/$(SOURCESUFFIX)),)
  3544. UNITDIR_FPMAKE_RTL=$(PACKAGEDIR_RTL)/units_bs/$(SOURCESUFFIX)
  3545. else
  3546. UNITDIR_FPMAKE_RTL=$(PACKAGEDIR_RTL)
  3547. endif
  3548. endif
  3549. ifdef CHECKDEPEND
  3550. $(PACKAGEDIR_RTL)/$(OS_TARGET)/$(FPCMADE):
  3551. $(MAKE) -C $(PACKAGEDIR_RTL)/$(OS_TARGET) $(FPCMADE)
  3552. override ALLDEPENDENCIES+=$(PACKAGEDIR_RTL)/$(OS_TARGET)/$(FPCMADE)
  3553. endif
  3554. else
  3555. PACKAGEDIR_RTL=
  3556. UNITDIR_RTL:=$(subst /Package.fpc,,$(strip $(wildcard $(addsuffix /rtl/Package.fpc,$(UNITSDIR)))))
  3557. ifneq ($(UNITDIR_RTL),)
  3558. UNITDIR_RTL:=$(firstword $(UNITDIR_RTL))
  3559. else
  3560. UNITDIR_RTL=
  3561. endif
  3562. endif
  3563. ifdef UNITDIR_RTL
  3564. override COMPILER_UNITDIR+=$(UNITDIR_RTL)
  3565. endif
  3566. ifdef UNITDIR_FPMAKE_RTL
  3567. override COMPILER_FPMAKE_UNITDIR+=$(UNITDIR_FPMAKE_RTL)
  3568. endif
  3569. endif
  3570. ifdef REQUIRE_PACKAGES_PASZLIB
  3571. PACKAGEDIR_PASZLIB:=$(firstword $(subst /Makefile.fpc,,$(strip $(wildcard $(addsuffix /paszlib/Makefile.fpc,$(PACKAGESDIR))))))
  3572. ifneq ($(PACKAGEDIR_PASZLIB),)
  3573. ifneq ($(wildcard $(PACKAGEDIR_PASZLIB)/units/$(TARGETSUFFIX)),)
  3574. UNITDIR_PASZLIB=$(PACKAGEDIR_PASZLIB)/units/$(TARGETSUFFIX)
  3575. else
  3576. UNITDIR_PASZLIB=$(PACKAGEDIR_PASZLIB)
  3577. endif
  3578. ifneq ($(wildcard $(PACKAGEDIR_PASZLIB)/units/$(SOURCESUFFIX)),)
  3579. UNITDIR_FPMAKE_PASZLIB=$(PACKAGEDIR_PASZLIB)/units/$(SOURCESUFFIX)
  3580. else
  3581. ifneq ($(wildcard $(PACKAGEDIR_PASZLIB)/units_bs/$(SOURCESUFFIX)),)
  3582. UNITDIR_FPMAKE_PASZLIB=$(PACKAGEDIR_PASZLIB)/units_bs/$(SOURCESUFFIX)
  3583. else
  3584. UNITDIR_FPMAKE_PASZLIB=$(PACKAGEDIR_PASZLIB)
  3585. endif
  3586. endif
  3587. ifdef CHECKDEPEND
  3588. $(PACKAGEDIR_PASZLIB)/$(FPCMADE):
  3589. $(MAKE) -C $(PACKAGEDIR_PASZLIB) $(FPCMADE)
  3590. override ALLDEPENDENCIES+=$(PACKAGEDIR_PASZLIB)/$(FPCMADE)
  3591. endif
  3592. else
  3593. PACKAGEDIR_PASZLIB=
  3594. UNITDIR_PASZLIB:=$(subst /Package.fpc,,$(strip $(wildcard $(addsuffix /paszlib/Package.fpc,$(UNITSDIR)))))
  3595. ifneq ($(UNITDIR_PASZLIB),)
  3596. UNITDIR_PASZLIB:=$(firstword $(UNITDIR_PASZLIB))
  3597. else
  3598. UNITDIR_PASZLIB=
  3599. endif
  3600. endif
  3601. ifdef UNITDIR_PASZLIB
  3602. override COMPILER_UNITDIR+=$(UNITDIR_PASZLIB)
  3603. endif
  3604. ifdef UNITDIR_FPMAKE_PASZLIB
  3605. override COMPILER_FPMAKE_UNITDIR+=$(UNITDIR_FPMAKE_PASZLIB)
  3606. endif
  3607. endif
  3608. ifdef REQUIRE_PACKAGES_FCL-PROCESS
  3609. PACKAGEDIR_FCL-PROCESS:=$(firstword $(subst /Makefile.fpc,,$(strip $(wildcard $(addsuffix /fcl-process/Makefile.fpc,$(PACKAGESDIR))))))
  3610. ifneq ($(PACKAGEDIR_FCL-PROCESS),)
  3611. ifneq ($(wildcard $(PACKAGEDIR_FCL-PROCESS)/units/$(TARGETSUFFIX)),)
  3612. UNITDIR_FCL-PROCESS=$(PACKAGEDIR_FCL-PROCESS)/units/$(TARGETSUFFIX)
  3613. else
  3614. UNITDIR_FCL-PROCESS=$(PACKAGEDIR_FCL-PROCESS)
  3615. endif
  3616. ifneq ($(wildcard $(PACKAGEDIR_FCL-PROCESS)/units/$(SOURCESUFFIX)),)
  3617. UNITDIR_FPMAKE_FCL-PROCESS=$(PACKAGEDIR_FCL-PROCESS)/units/$(SOURCESUFFIX)
  3618. else
  3619. ifneq ($(wildcard $(PACKAGEDIR_FCL-PROCESS)/units_bs/$(SOURCESUFFIX)),)
  3620. UNITDIR_FPMAKE_FCL-PROCESS=$(PACKAGEDIR_FCL-PROCESS)/units_bs/$(SOURCESUFFIX)
  3621. else
  3622. UNITDIR_FPMAKE_FCL-PROCESS=$(PACKAGEDIR_FCL-PROCESS)
  3623. endif
  3624. endif
  3625. ifdef CHECKDEPEND
  3626. $(PACKAGEDIR_FCL-PROCESS)/$(FPCMADE):
  3627. $(MAKE) -C $(PACKAGEDIR_FCL-PROCESS) $(FPCMADE)
  3628. override ALLDEPENDENCIES+=$(PACKAGEDIR_FCL-PROCESS)/$(FPCMADE)
  3629. endif
  3630. else
  3631. PACKAGEDIR_FCL-PROCESS=
  3632. UNITDIR_FCL-PROCESS:=$(subst /Package.fpc,,$(strip $(wildcard $(addsuffix /fcl-process/Package.fpc,$(UNITSDIR)))))
  3633. ifneq ($(UNITDIR_FCL-PROCESS),)
  3634. UNITDIR_FCL-PROCESS:=$(firstword $(UNITDIR_FCL-PROCESS))
  3635. else
  3636. UNITDIR_FCL-PROCESS=
  3637. endif
  3638. endif
  3639. ifdef UNITDIR_FCL-PROCESS
  3640. override COMPILER_UNITDIR+=$(UNITDIR_FCL-PROCESS)
  3641. endif
  3642. ifdef UNITDIR_FPMAKE_FCL-PROCESS
  3643. override COMPILER_FPMAKE_UNITDIR+=$(UNITDIR_FPMAKE_FCL-PROCESS)
  3644. endif
  3645. endif
  3646. ifdef REQUIRE_PACKAGES_HASH
  3647. PACKAGEDIR_HASH:=$(firstword $(subst /Makefile.fpc,,$(strip $(wildcard $(addsuffix /hash/Makefile.fpc,$(PACKAGESDIR))))))
  3648. ifneq ($(PACKAGEDIR_HASH),)
  3649. ifneq ($(wildcard $(PACKAGEDIR_HASH)/units/$(TARGETSUFFIX)),)
  3650. UNITDIR_HASH=$(PACKAGEDIR_HASH)/units/$(TARGETSUFFIX)
  3651. else
  3652. UNITDIR_HASH=$(PACKAGEDIR_HASH)
  3653. endif
  3654. ifneq ($(wildcard $(PACKAGEDIR_HASH)/units/$(SOURCESUFFIX)),)
  3655. UNITDIR_FPMAKE_HASH=$(PACKAGEDIR_HASH)/units/$(SOURCESUFFIX)
  3656. else
  3657. ifneq ($(wildcard $(PACKAGEDIR_HASH)/units_bs/$(SOURCESUFFIX)),)
  3658. UNITDIR_FPMAKE_HASH=$(PACKAGEDIR_HASH)/units_bs/$(SOURCESUFFIX)
  3659. else
  3660. UNITDIR_FPMAKE_HASH=$(PACKAGEDIR_HASH)
  3661. endif
  3662. endif
  3663. ifdef CHECKDEPEND
  3664. $(PACKAGEDIR_HASH)/$(FPCMADE):
  3665. $(MAKE) -C $(PACKAGEDIR_HASH) $(FPCMADE)
  3666. override ALLDEPENDENCIES+=$(PACKAGEDIR_HASH)/$(FPCMADE)
  3667. endif
  3668. else
  3669. PACKAGEDIR_HASH=
  3670. UNITDIR_HASH:=$(subst /Package.fpc,,$(strip $(wildcard $(addsuffix /hash/Package.fpc,$(UNITSDIR)))))
  3671. ifneq ($(UNITDIR_HASH),)
  3672. UNITDIR_HASH:=$(firstword $(UNITDIR_HASH))
  3673. else
  3674. UNITDIR_HASH=
  3675. endif
  3676. endif
  3677. ifdef UNITDIR_HASH
  3678. override COMPILER_UNITDIR+=$(UNITDIR_HASH)
  3679. endif
  3680. ifdef UNITDIR_FPMAKE_HASH
  3681. override COMPILER_FPMAKE_UNITDIR+=$(UNITDIR_FPMAKE_HASH)
  3682. endif
  3683. endif
  3684. ifdef REQUIRE_PACKAGES_LIBTAR
  3685. PACKAGEDIR_LIBTAR:=$(firstword $(subst /Makefile.fpc,,$(strip $(wildcard $(addsuffix /libtar/Makefile.fpc,$(PACKAGESDIR))))))
  3686. ifneq ($(PACKAGEDIR_LIBTAR),)
  3687. ifneq ($(wildcard $(PACKAGEDIR_LIBTAR)/units/$(TARGETSUFFIX)),)
  3688. UNITDIR_LIBTAR=$(PACKAGEDIR_LIBTAR)/units/$(TARGETSUFFIX)
  3689. else
  3690. UNITDIR_LIBTAR=$(PACKAGEDIR_LIBTAR)
  3691. endif
  3692. ifneq ($(wildcard $(PACKAGEDIR_LIBTAR)/units/$(SOURCESUFFIX)),)
  3693. UNITDIR_FPMAKE_LIBTAR=$(PACKAGEDIR_LIBTAR)/units/$(SOURCESUFFIX)
  3694. else
  3695. ifneq ($(wildcard $(PACKAGEDIR_LIBTAR)/units_bs/$(SOURCESUFFIX)),)
  3696. UNITDIR_FPMAKE_LIBTAR=$(PACKAGEDIR_LIBTAR)/units_bs/$(SOURCESUFFIX)
  3697. else
  3698. UNITDIR_FPMAKE_LIBTAR=$(PACKAGEDIR_LIBTAR)
  3699. endif
  3700. endif
  3701. ifdef CHECKDEPEND
  3702. $(PACKAGEDIR_LIBTAR)/$(FPCMADE):
  3703. $(MAKE) -C $(PACKAGEDIR_LIBTAR) $(FPCMADE)
  3704. override ALLDEPENDENCIES+=$(PACKAGEDIR_LIBTAR)/$(FPCMADE)
  3705. endif
  3706. else
  3707. PACKAGEDIR_LIBTAR=
  3708. UNITDIR_LIBTAR:=$(subst /Package.fpc,,$(strip $(wildcard $(addsuffix /libtar/Package.fpc,$(UNITSDIR)))))
  3709. ifneq ($(UNITDIR_LIBTAR),)
  3710. UNITDIR_LIBTAR:=$(firstword $(UNITDIR_LIBTAR))
  3711. else
  3712. UNITDIR_LIBTAR=
  3713. endif
  3714. endif
  3715. ifdef UNITDIR_LIBTAR
  3716. override COMPILER_UNITDIR+=$(UNITDIR_LIBTAR)
  3717. endif
  3718. ifdef UNITDIR_FPMAKE_LIBTAR
  3719. override COMPILER_FPMAKE_UNITDIR+=$(UNITDIR_FPMAKE_LIBTAR)
  3720. endif
  3721. endif
  3722. ifdef REQUIRE_PACKAGES_FPMKUNIT
  3723. PACKAGEDIR_FPMKUNIT:=$(firstword $(subst /Makefile.fpc,,$(strip $(wildcard $(addsuffix /fpmkunit/Makefile.fpc,$(PACKAGESDIR))))))
  3724. ifneq ($(PACKAGEDIR_FPMKUNIT),)
  3725. ifneq ($(wildcard $(PACKAGEDIR_FPMKUNIT)/units/$(TARGETSUFFIX)),)
  3726. UNITDIR_FPMKUNIT=$(PACKAGEDIR_FPMKUNIT)/units/$(TARGETSUFFIX)
  3727. else
  3728. UNITDIR_FPMKUNIT=$(PACKAGEDIR_FPMKUNIT)
  3729. endif
  3730. ifneq ($(wildcard $(PACKAGEDIR_FPMKUNIT)/units/$(SOURCESUFFIX)),)
  3731. UNITDIR_FPMAKE_FPMKUNIT=$(PACKAGEDIR_FPMKUNIT)/units/$(SOURCESUFFIX)
  3732. else
  3733. ifneq ($(wildcard $(PACKAGEDIR_FPMKUNIT)/units_bs/$(SOURCESUFFIX)),)
  3734. UNITDIR_FPMAKE_FPMKUNIT=$(PACKAGEDIR_FPMKUNIT)/units_bs/$(SOURCESUFFIX)
  3735. else
  3736. UNITDIR_FPMAKE_FPMKUNIT=$(PACKAGEDIR_FPMKUNIT)
  3737. endif
  3738. endif
  3739. ifdef CHECKDEPEND
  3740. $(PACKAGEDIR_FPMKUNIT)/$(FPCMADE):
  3741. $(MAKE) -C $(PACKAGEDIR_FPMKUNIT) $(FPCMADE)
  3742. override ALLDEPENDENCIES+=$(PACKAGEDIR_FPMKUNIT)/$(FPCMADE)
  3743. endif
  3744. else
  3745. PACKAGEDIR_FPMKUNIT=
  3746. UNITDIR_FPMKUNIT:=$(subst /Package.fpc,,$(strip $(wildcard $(addsuffix /fpmkunit/Package.fpc,$(UNITSDIR)))))
  3747. ifneq ($(UNITDIR_FPMKUNIT),)
  3748. UNITDIR_FPMKUNIT:=$(firstword $(UNITDIR_FPMKUNIT))
  3749. else
  3750. UNITDIR_FPMKUNIT=
  3751. endif
  3752. endif
  3753. ifdef UNITDIR_FPMKUNIT
  3754. override COMPILER_UNITDIR+=$(UNITDIR_FPMKUNIT)
  3755. endif
  3756. ifdef UNITDIR_FPMAKE_FPMKUNIT
  3757. override COMPILER_FPMAKE_UNITDIR+=$(UNITDIR_FPMAKE_FPMKUNIT)
  3758. endif
  3759. endif
  3760. ifdef REQUIRE_PACKAGES_LIBNDSFPC
  3761. PACKAGEDIR_LIBNDSFPC:=$(firstword $(subst /Makefile.fpc,,$(strip $(wildcard $(addsuffix /libndsfpc/Makefile.fpc,$(PACKAGESDIR))))))
  3762. ifneq ($(PACKAGEDIR_LIBNDSFPC),)
  3763. ifneq ($(wildcard $(PACKAGEDIR_LIBNDSFPC)/units/$(TARGETSUFFIX)),)
  3764. UNITDIR_LIBNDSFPC=$(PACKAGEDIR_LIBNDSFPC)/units/$(TARGETSUFFIX)
  3765. else
  3766. UNITDIR_LIBNDSFPC=$(PACKAGEDIR_LIBNDSFPC)
  3767. endif
  3768. ifneq ($(wildcard $(PACKAGEDIR_LIBNDSFPC)/units/$(SOURCESUFFIX)),)
  3769. UNITDIR_FPMAKE_LIBNDSFPC=$(PACKAGEDIR_LIBNDSFPC)/units/$(SOURCESUFFIX)
  3770. else
  3771. ifneq ($(wildcard $(PACKAGEDIR_LIBNDSFPC)/units_bs/$(SOURCESUFFIX)),)
  3772. UNITDIR_FPMAKE_LIBNDSFPC=$(PACKAGEDIR_LIBNDSFPC)/units_bs/$(SOURCESUFFIX)
  3773. else
  3774. UNITDIR_FPMAKE_LIBNDSFPC=$(PACKAGEDIR_LIBNDSFPC)
  3775. endif
  3776. endif
  3777. ifdef CHECKDEPEND
  3778. $(PACKAGEDIR_LIBNDSFPC)/$(FPCMADE):
  3779. $(MAKE) -C $(PACKAGEDIR_LIBNDSFPC) $(FPCMADE)
  3780. override ALLDEPENDENCIES+=$(PACKAGEDIR_LIBNDSFPC)/$(FPCMADE)
  3781. endif
  3782. else
  3783. PACKAGEDIR_LIBNDSFPC=
  3784. UNITDIR_LIBNDSFPC:=$(subst /Package.fpc,,$(strip $(wildcard $(addsuffix /libndsfpc/Package.fpc,$(UNITSDIR)))))
  3785. ifneq ($(UNITDIR_LIBNDSFPC),)
  3786. UNITDIR_LIBNDSFPC:=$(firstword $(UNITDIR_LIBNDSFPC))
  3787. else
  3788. UNITDIR_LIBNDSFPC=
  3789. endif
  3790. endif
  3791. ifdef UNITDIR_LIBNDSFPC
  3792. override COMPILER_UNITDIR+=$(UNITDIR_LIBNDSFPC)
  3793. endif
  3794. ifdef UNITDIR_FPMAKE_LIBNDSFPC
  3795. override COMPILER_FPMAKE_UNITDIR+=$(UNITDIR_FPMAKE_LIBNDSFPC)
  3796. endif
  3797. endif
  3798. ifndef NOCPUDEF
  3799. override FPCOPTDEF=$(ARCH)
  3800. endif
  3801. ifneq ($(OS_TARGET),$(OS_SOURCE))
  3802. override FPCOPT+=-T$(OS_TARGET)
  3803. endif
  3804. ifneq ($(CPU_TARGET),$(CPU_SOURCE))
  3805. override FPCOPT+=-P$(ARCH)
  3806. endif
  3807. ifeq ($(OS_SOURCE),openbsd)
  3808. override FPCOPT+=-FD$(NEW_BINUTILS_PATH)
  3809. override FPCMAKEOPT+=-FD$(NEW_BINUTILS_PATH)
  3810. override FPMAKE_BUILD_OPT+=-FD$(NEW_BINUTILS_PATH)
  3811. endif
  3812. ifndef CROSSBOOTSTRAP
  3813. ifneq ($(BINUTILSPREFIX),)
  3814. override FPCOPT+=-XP$(BINUTILSPREFIX)
  3815. endif
  3816. ifneq ($(BINUTILSPREFIX),)
  3817. override FPCOPT+=-Xr$(RLINKPATH)
  3818. endif
  3819. endif
  3820. ifndef CROSSCOMPILE
  3821. ifneq ($(BINUTILSPREFIX),)
  3822. override FPCMAKEOPT+=-XP$(BINUTILSPREFIX)
  3823. override FPMAKE_BUILD_OPT+=-XP$(BINUTILSPREFIX)
  3824. endif
  3825. endif
  3826. ifdef UNITDIR
  3827. override FPCOPT+=$(addprefix -Fu,$(UNITDIR))
  3828. endif
  3829. ifdef LIBDIR
  3830. override FPCOPT+=$(addprefix -Fl,$(LIBDIR))
  3831. endif
  3832. ifdef OBJDIR
  3833. override FPCOPT+=$(addprefix -Fo,$(OBJDIR))
  3834. endif
  3835. ifdef INCDIR
  3836. override FPCOPT+=$(addprefix -Fi,$(INCDIR))
  3837. endif
  3838. ifdef LINKSMART
  3839. override FPCOPT+=-XX
  3840. endif
  3841. ifdef CREATESMART
  3842. override FPCOPT+=-CX
  3843. endif
  3844. ifdef DEBUG
  3845. override FPCOPT+=-gl
  3846. override FPCOPTDEF+=DEBUG
  3847. endif
  3848. ifdef RELEASE
  3849. ifneq ($(findstring 2.0.,$(FPC_VERSION)),)
  3850. ifeq ($(CPU_TARGET),i386)
  3851. FPCCPUOPT:=-OG2p3
  3852. endif
  3853. ifeq ($(CPU_TARGET),powerpc)
  3854. FPCCPUOPT:=-O1r
  3855. endif
  3856. else
  3857. FPCCPUOPT:=-O2
  3858. endif
  3859. override FPCOPT+=-Ur -Xs $(FPCCPUOPT) -n
  3860. override FPCOPTDEF+=RELEASE
  3861. endif
  3862. ifdef STRIP
  3863. override FPCOPT+=-Xs
  3864. endif
  3865. ifdef OPTIMIZE
  3866. override FPCOPT+=-O2
  3867. endif
  3868. ifdef VERBOSE
  3869. override FPCOPT+=-vwni
  3870. endif
  3871. ifdef COMPILER_OPTIONS
  3872. override FPCOPT+=$(COMPILER_OPTIONS)
  3873. endif
  3874. ifdef COMPILER_UNITDIR
  3875. override FPCOPT+=$(addprefix -Fu,$(COMPILER_UNITDIR))
  3876. endif
  3877. ifdef COMPILER_LIBRARYDIR
  3878. override FPCOPT+=$(addprefix -Fl,$(COMPILER_LIBRARYDIR))
  3879. endif
  3880. ifdef COMPILER_OBJECTDIR
  3881. override FPCOPT+=$(addprefix -Fo,$(COMPILER_OBJECTDIR))
  3882. endif
  3883. ifdef COMPILER_INCLUDEDIR
  3884. override FPCOPT+=$(addprefix -Fi,$(COMPILER_INCLUDEDIR))
  3885. endif
  3886. ifdef CROSSBINDIR
  3887. override FPCOPT+=-FD$(CROSSBINDIR)
  3888. endif
  3889. ifdef COMPILER_TARGETDIR
  3890. override FPCOPT+=-FE$(COMPILER_TARGETDIR)
  3891. ifeq ($(COMPILER_TARGETDIR),.)
  3892. override TARGETDIRPREFIX=
  3893. else
  3894. override TARGETDIRPREFIX=$(COMPILER_TARGETDIR)/
  3895. endif
  3896. endif
  3897. ifdef COMPILER_UNITTARGETDIR
  3898. override FPCOPT+=-FU$(COMPILER_UNITTARGETDIR)
  3899. ifeq ($(COMPILER_UNITTARGETDIR),.)
  3900. override UNITTARGETDIRPREFIX=
  3901. else
  3902. override UNITTARGETDIRPREFIX=$(COMPILER_UNITTARGETDIR)/
  3903. endif
  3904. else
  3905. ifdef COMPILER_TARGETDIR
  3906. override COMPILER_UNITTARGETDIR=$(COMPILER_TARGETDIR)
  3907. override UNITTARGETDIRPREFIX=$(TARGETDIRPREFIX)
  3908. endif
  3909. endif
  3910. ifdef CREATESHARED
  3911. override FPCOPT+=-Cg
  3912. endif
  3913. ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
  3914. ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
  3915. override FPCOPT+=-Cg
  3916. endif
  3917. endif
  3918. ifdef LINKSHARED
  3919. endif
  3920. ifdef OPT
  3921. override FPCOPT+=$(OPT)
  3922. endif
  3923. ifdef FPMAKEBUILDOPT
  3924. override FPMAKE_BUILD_OPT+=$(FPMAKEBUILDOPT)
  3925. endif
  3926. ifdef FPCOPTDEF
  3927. override FPCOPT+=$(addprefix -d,$(FPCOPTDEF))
  3928. endif
  3929. ifdef CFGFILE
  3930. override FPCOPT+=@$(CFGFILE)
  3931. endif
  3932. ifdef USEENV
  3933. override FPCEXTCMD:=$(FPCOPT)
  3934. override FPCOPT:=!FPCEXTCMD
  3935. export FPCEXTCMD
  3936. endif
  3937. override AFULL_TARGET=$(CPU_TARGET)-$(OS_TARGET)
  3938. override AFULL_SOURCE=$(CPU_SOURCE)-$(OS_SOURCE)
  3939. ifneq ($(AFULL_TARGET),$(AFULL_SOURCE))
  3940. override ACROSSCOMPILE=1
  3941. endif
  3942. ifdef ACROSSCOMPILE
  3943. override FPCOPT+=$(CROSSOPT)
  3944. endif
  3945. override COMPILER:=$(strip $(FPC) $(FPCOPT))
  3946. ifneq (,$(findstring -sh ,$(COMPILER)))
  3947. UseEXECPPAS=1
  3948. endif
  3949. ifneq (,$(findstring -s ,$(COMPILER)))
  3950. ifeq ($(FULL_SOURCE),$(FULL_TARGET))
  3951. UseEXECPPAS=1
  3952. endif
  3953. endif
  3954. ifneq ($(UseEXECPPAS),1)
  3955. EXECPPAS=
  3956. else
  3957. ifdef RUNBATCH
  3958. EXECPPAS:=@$(RUNBATCH) $(PPAS)
  3959. else
  3960. EXECPPAS:=@$(PPAS)
  3961. endif
  3962. endif
  3963. .PHONY: fpc_loaders
  3964. ifneq ($(TARGET_LOADERS),)
  3965. override ALLTARGET+=fpc_loaders
  3966. override CLEANTARGET+=fpc_loaders_clean
  3967. override INSTALLTARGET+=fpc_loaders_install
  3968. override LOADEROFILES:=$(addsuffix $(OEXT),$(TARGET_LOADERS))
  3969. endif
  3970. %$(OEXT): %$(LOADEREXT)
  3971. ifdef COMPILER_UNITTARGETDIR
  3972. $(AS) -o $(COMPILER_UNITTARGETDIR)/$*$(OEXT) $<
  3973. else
  3974. $(AS) -o $*$(OEXT) $<
  3975. endif
  3976. fpc_loaders: $(COMPILER_UNITTARGETDIR) $(LOADEROFILES)
  3977. fpc_loaders_clean:
  3978. ifdef COMPILER_UNITTARGETDIR
  3979. -$(DEL) $(addprefix $(COMPILER_UNITTARGETDIR)/,$(LOADEROFILES))
  3980. else
  3981. -$(DEL) $(LOADEROFILES)
  3982. endif
  3983. fpc_loaders_install:
  3984. $(MKDIR) $(INSTALL_UNITDIR)
  3985. ifdef COMPILER_UNITTARGETDIR
  3986. $(INSTALL) $(addprefix $(COMPILER_UNITTARGETDIR)/,$(LOADEROFILES)) $(INSTALL_UNITDIR)
  3987. else
  3988. $(INSTALL) $(LOADEROFILES) $(INSTALL_UNITDIR)
  3989. endif
  3990. .PHONY: fpc_exes
  3991. ifndef CROSSINSTALL
  3992. ifneq ($(TARGET_PROGRAMS),)
  3993. override EXEFILES=$(addsuffix $(EXEEXT),$(TARGET_PROGRAMS))
  3994. override EXEOFILES:=$(addsuffix $(OEXT),$(TARGET_PROGRAMS)) $(addprefix $(STATICLIBPREFIX),$(addsuffix $(STATICLIBEXT),$(TARGET_PROGRAMS))) $(addprefix $(IMPORTLIBPREFIX),$(addsuffix $(STATICLIBEXT),$(TARGET_PROGRAMS)))
  3995. override EXEDBGFILES:=$(addsuffix $(EXEDBGEXT),$(TARGET_PROGRAMS))
  3996. override ALLTARGET+=fpc_exes
  3997. override INSTALLEXEFILES+=$(EXEFILES)
  3998. override CLEANEXEFILES+=$(EXEFILES) $(EXEOFILES)
  3999. override CLEANEXEDBGFILES+=$(EXEDBGFILES)
  4000. ifeq ($(OS_TARGET),os2)
  4001. override CLEANEXEFILES+=$(addsuffix $(AOUTEXT),$(TARGET_PROGRAMS))
  4002. endif
  4003. ifeq ($(OS_TARGET),emx)
  4004. override CLEANEXEFILES+=$(addsuffix $(AOUTEXT),$(TARGET_PROGRAMS))
  4005. endif
  4006. endif
  4007. endif
  4008. fpc_exes: $(COMPILER_TARGETDIR) $(COMPILER_UNITTARGETDIR) $(EXEFILES)
  4009. ifdef TARGET_RSTS
  4010. override RSTFILES=$(addsuffix $(RSTEXT),$(TARGET_RSTS))
  4011. override CLEANRSTFILES+=$(RSTFILES)
  4012. endif
  4013. .PHONY: fpc_all fpc_smart fpc_debug fpc_release fpc_shared
  4014. $(FPCMADE): $(ALLDEPENDENCIES) $(ALLTARGET)
  4015. @$(ECHOREDIR) Compiled > $(FPCMADE)
  4016. fpc_all: $(FPCMADE)
  4017. fpc_smart:
  4018. $(MAKE) all LINKSMART=1 CREATESMART=1
  4019. fpc_debug:
  4020. $(MAKE) all DEBUG=1
  4021. fpc_release:
  4022. $(MAKE) all RELEASE=1
  4023. .SUFFIXES: $(EXEEXT) $(PPUEXT) $(OEXT) .pas .lpr .dpr .pp .rc .res
  4024. $(COMPILER_UNITTARGETDIR):
  4025. $(MKDIRTREE) $(COMPILER_UNITTARGETDIR)
  4026. $(COMPILER_TARGETDIR):
  4027. $(MKDIRTREE) $(COMPILER_TARGETDIR)
  4028. %$(PPUEXT): %.pp
  4029. $(COMPILER) $<
  4030. $(EXECPPAS)
  4031. %$(PPUEXT): %.pas
  4032. $(COMPILER) $<
  4033. $(EXECPPAS)
  4034. %$(EXEEXT): %.pp
  4035. $(COMPILER) $<
  4036. $(EXECPPAS)
  4037. %$(EXEEXT): %.pas
  4038. $(COMPILER) $<
  4039. $(EXECPPAS)
  4040. %$(EXEEXT): %.lpr
  4041. $(COMPILER) $<
  4042. $(EXECPPAS)
  4043. %$(EXEEXT): %.dpr
  4044. $(COMPILER) $<
  4045. $(EXECPPAS)
  4046. %.res: %.rc
  4047. windres -i $< -o $@
  4048. vpath %.pp $(COMPILER_SOURCEDIR) $(COMPILER_INCLUDEDIR)
  4049. vpath %.pas $(COMPILER_SOURCEDIR) $(COMPILER_INCLUDEDIR)
  4050. vpath %.lpr $(COMPILER_SOURCEDIR) $(COMPILER_INCLUDEDIR)
  4051. vpath %.dpr $(COMPILER_SOURCEDIR) $(COMPILER_INCLUDEDIR)
  4052. vpath %.inc $(COMPILER_INCLUDEDIR)
  4053. vpath %$(OEXT) $(COMPILER_UNITTARGETDIR)
  4054. vpath %$(PPUEXT) $(COMPILER_UNITTARGETDIR)
  4055. .PHONY: fpc_shared
  4056. override INSTALLTARGET+=fpc_shared_install
  4057. ifndef SHARED_LIBVERSION
  4058. SHARED_LIBVERSION=$(FPC_VERSION)
  4059. endif
  4060. ifndef SHARED_LIBNAME
  4061. SHARED_LIBNAME=$(PACKAGE_NAME)
  4062. endif
  4063. ifndef SHARED_FULLNAME
  4064. SHARED_FULLNAME=$(SHAREDLIBPREFIX)$(SHARED_LIBNAME)-$(SHARED_LIBVERSION)$(SHAREDLIBEXT)
  4065. endif
  4066. ifndef SHARED_LIBUNITS
  4067. SHARED_LIBUNITS:=$(TARGET_UNITS) $(TARGET_IMPLICITUNITS)
  4068. override SHARED_LIBUNITS:=$(filter-out $(INSTALL_BUILDUNIT),$(SHARED_LIBUNITS))
  4069. endif
  4070. fpc_shared:
  4071. ifdef HASSHAREDLIB
  4072. $(MAKE) all CREATESHARED=1 LINKSHARED=1 CREATESMART=1
  4073. ifneq ($(SHARED_BUILD),n)
  4074. $(PPUMOVE) -q $(SHARED_LIBUNITS) -i$(COMPILER_UNITTARGETDIR) -o$(SHARED_FULLNAME) -d$(COMPILER_UNITTARGETDIR)
  4075. endif
  4076. else
  4077. @$(ECHO) Shared Libraries not supported
  4078. endif
  4079. fpc_shared_install:
  4080. ifneq ($(SHARED_BUILD),n)
  4081. ifneq ($(SHARED_LIBUNITS),)
  4082. ifneq ($(wildcard $(COMPILER_UNITTARGETDIR)/$(SHARED_FULLNAME)),)
  4083. $(INSTALL) $(COMPILER_UNITTARGETDIR)/$(SHARED_FULLNAME) $(INSTALL_SHAREDDIR)
  4084. endif
  4085. endif
  4086. endif
  4087. .PHONY: fpc_install fpc_sourceinstall fpc_exampleinstall
  4088. ifdef INSTALL_UNITS
  4089. override INSTALLPPUFILES+=$(addsuffix $(PPUEXT),$(INSTALL_UNITS))
  4090. endif
  4091. ifdef INSTALL_BUILDUNIT
  4092. override INSTALLPPUFILES:=$(filter-out $(INSTALL_BUILDUNIT)$(PPUEXT),$(INSTALLPPUFILES))
  4093. endif
  4094. ifdef INSTALLPPUFILES
  4095. ifneq ($(IMPORTLIBPREFIX)-$(STATICLIBEXT),$(STATICLIBPREFIX)-$(STATICLIBEXT))
  4096. override INSTALLPPULINKFILES:=$(subst $(PPUEXT),$(OEXT),$(INSTALLPPUFILES)) $(addprefix $(STATICLIBPREFIX),$(subst $(PPUEXT),$(STATICLIBEXT),$(INSTALLPPUFILES))) $(addprefix $(IMPORTLIBPREFIX),$(subst $(PPUEXT),$(STATICLIBEXT),$(INSTALLPPUFILES)))
  4097. else
  4098. override INSTALLPPULINKFILES:=$(subst $(PPUEXT),$(OEXT),$(INSTALLPPUFILES)) $(addprefix $(STATICLIBPREFIX),$(subst $(PPUEXT),$(STATICLIBEXT),$(INSTALLPPUFILES)))
  4099. endif
  4100. ifneq ($(UNITTARGETDIRPREFIX),)
  4101. override INSTALLPPUFILES:=$(addprefix $(UNITTARGETDIRPREFIX),$(notdir $(INSTALLPPUFILES)))
  4102. override INSTALLPPULINKFILES:=$(wildcard $(addprefix $(UNITTARGETDIRPREFIX),$(notdir $(INSTALLPPULINKFILES))))
  4103. endif
  4104. override INSTALL_CREATEPACKAGEFPC=1
  4105. endif
  4106. ifdef INSTALLEXEFILES
  4107. ifneq ($(TARGETDIRPREFIX),)
  4108. override INSTALLEXEFILES:=$(addprefix $(TARGETDIRPREFIX),$(notdir $(INSTALLEXEFILES)))
  4109. endif
  4110. endif
  4111. fpc_install: all $(INSTALLTARGET)
  4112. ifdef INSTALLEXEFILES
  4113. $(MKDIR) $(INSTALL_BINDIR)
  4114. $(INSTALLEXE) $(INSTALLEXEFILES) $(INSTALL_BINDIR)
  4115. endif
  4116. ifdef INSTALL_CREATEPACKAGEFPC
  4117. ifdef FPCMAKE
  4118. ifdef PACKAGE_VERSION
  4119. ifneq ($(wildcard Makefile.fpc),)
  4120. $(FPCMAKE) -p -T$(CPU_TARGET)-$(OS_TARGET) Makefile.fpc
  4121. $(MKDIR) $(INSTALL_UNITDIR)
  4122. $(INSTALL) Package.fpc $(INSTALL_UNITDIR)
  4123. endif
  4124. endif
  4125. endif
  4126. endif
  4127. ifdef INSTALLPPUFILES
  4128. $(MKDIR) $(INSTALL_UNITDIR)
  4129. $(INSTALL) $(INSTALLPPUFILES) $(INSTALL_UNITDIR)
  4130. ifneq ($(INSTALLPPULINKFILES),)
  4131. $(INSTALL) $(INSTALLPPULINKFILES) $(INSTALL_UNITDIR)
  4132. endif
  4133. ifneq ($(wildcard $(LIB_FULLNAME)),)
  4134. $(MKDIR) $(INSTALL_LIBDIR)
  4135. $(INSTALL) $(LIB_FULLNAME) $(INSTALL_LIBDIR)
  4136. ifdef inUnix
  4137. ln -sf $(LIB_FULLNAME) $(INSTALL_LIBDIR)/$(LIB_NAME)
  4138. endif
  4139. endif
  4140. endif
  4141. ifdef INSTALL_FILES
  4142. $(MKDIR) $(INSTALL_DATADIR)
  4143. $(INSTALL) $(INSTALL_FILES) $(INSTALL_DATADIR)
  4144. endif
  4145. fpc_sourceinstall: distclean
  4146. $(MKDIR) $(INSTALL_SOURCEDIR)
  4147. $(COPYTREE) $(BASEDIR)/* $(INSTALL_SOURCEDIR)
  4148. fpc_exampleinstall: $(EXAMPLEINSTALLTARGET) $(addsuffix _distclean,$(TARGET_EXAMPLEDIRS))
  4149. ifdef HASEXAMPLES
  4150. $(MKDIR) $(INSTALL_EXAMPLEDIR)
  4151. endif
  4152. ifdef EXAMPLESOURCEFILES
  4153. $(COPY) $(EXAMPLESOURCEFILES) $(INSTALL_EXAMPLEDIR)
  4154. endif
  4155. ifdef TARGET_EXAMPLEDIRS
  4156. $(COPYTREE) $(addsuffix /*,$(TARGET_EXAMPLEDIRS)) $(INSTALL_EXAMPLEDIR)
  4157. endif
  4158. .PHONY: fpc_clean fpc_cleanall fpc_distclean
  4159. ifdef EXEFILES
  4160. override CLEANEXEFILES:=$(addprefix $(TARGETDIRPREFIX),$(CLEANEXEFILES))
  4161. override CLEANEXEDBGFILES:=$(addprefix $(TARGETDIRPREFIX),$(CLEANEXEDBGFILES))
  4162. endif
  4163. ifdef CLEAN_PROGRAMS
  4164. override CLEANEXEFILES+=$(addprefix $(TARGETDIRPREFIX),$(addsuffix $(EXEEXT), $(CLEAN_PROGRAMS)))
  4165. override CLEANEXEDBGFILES+=$(addprefix $(TARGETDIRPREFIX),$(addsuffix $(EXEDBGEXT), $(CLEAN_PROGRAMS)))
  4166. endif
  4167. ifdef CLEAN_UNITS
  4168. override CLEANPPUFILES+=$(addsuffix $(PPUEXT),$(CLEAN_UNITS))
  4169. endif
  4170. ifdef CLEANPPUFILES
  4171. override CLEANPPULINKFILES:=$(subst $(PPUEXT),$(OEXT),$(CLEANPPUFILES)) $(addprefix $(STATICLIBPREFIX),$(subst $(PPUEXT),$(STATICLIBEXT),$(CLEANPPUFILES))) $(addprefix $(IMPORTLIBPREFIX),$(subst $(PPUEXT),$(STATICLIBEXT),$(CLEANPPUFILES)))
  4172. ifdef DEBUGSYMEXT
  4173. override CLEANPPULINKFILES+=$(subst $(PPUEXT),$(DEBUGSYMEXT),$(CLEANPPUFILES))
  4174. endif
  4175. override CLEANPPUFILES:=$(addprefix $(UNITTARGETDIRPREFIX),$(CLEANPPUFILES))
  4176. override CLEANPPULINKFILES:=$(wildcard $(addprefix $(UNITTARGETDIRPREFIX),$(CLEANPPULINKFILES)))
  4177. endif
  4178. fpc_clean: $(CLEANTARGET)
  4179. ifdef CLEANEXEFILES
  4180. -$(DEL) $(CLEANEXEFILES)
  4181. endif
  4182. ifdef CLEANEXEDBGFILES
  4183. -$(DELTREE) $(CLEANEXEDBGFILES)
  4184. endif
  4185. ifdef CLEANPPUFILES
  4186. -$(DEL) $(CLEANPPUFILES)
  4187. endif
  4188. ifneq ($(CLEANPPULINKFILES),)
  4189. -$(DEL) $(CLEANPPULINKFILES)
  4190. endif
  4191. ifdef CLEANRSTFILES
  4192. -$(DEL) $(addprefix $(UNITTARGETDIRPREFIX),$(CLEANRSTFILES))
  4193. endif
  4194. ifdef CLEAN_FILES
  4195. -$(DEL) $(CLEAN_FILES)
  4196. endif
  4197. ifdef LIB_NAME
  4198. -$(DEL) $(LIB_NAME) $(LIB_FULLNAME)
  4199. endif
  4200. -$(DEL) $(FPCMADE) Package.fpc $(PPAS) script.res link.res $(FPCEXTFILE) $(REDIRFILE)
  4201. -$(DEL) *$(ASMEXT) *_ppas$(BATCHEXT)
  4202. fpc_cleanall: $(CLEANTARGET)
  4203. ifdef CLEANEXEFILES
  4204. -$(DEL) $(CLEANEXEFILES)
  4205. endif
  4206. ifdef COMPILER_UNITTARGETDIR
  4207. ifdef CLEANPPUFILES
  4208. -$(DEL) $(CLEANPPUFILES)
  4209. endif
  4210. ifneq ($(CLEANPPULINKFILES),)
  4211. -$(DEL) $(CLEANPPULINKFILES)
  4212. endif
  4213. ifdef CLEANRSTFILES
  4214. -$(DEL) $(addprefix $(UNITTARGETDIRPREFIX),$(CLEANRSTFILES))
  4215. endif
  4216. endif
  4217. ifdef CLEAN_FILES
  4218. -$(DEL) $(CLEAN_FILES)
  4219. endif
  4220. -$(DELTREE) units
  4221. -$(DEL) *$(OEXT) *$(PPUEXT) *$(RSTEXT) *$(ASMEXT) *$(STATICLIBEXT) *$(SHAREDLIBEXT) *$(PPLEXT)
  4222. ifneq ($(PPUEXT),.ppu)
  4223. -$(DEL) *.o *.ppu *.a
  4224. endif
  4225. -$(DELTREE) *$(SMARTEXT)
  4226. -$(DEL) fpcmade.* Package.fpc $(PPAS) script.res link.res $(FPCEXTFILE) $(REDIRFILE)
  4227. -$(DEL) *_ppas$(BATCHEXT)
  4228. ifdef AOUTEXT
  4229. -$(DEL) *$(AOUTEXT)
  4230. endif
  4231. ifdef DEBUGSYMEXT
  4232. -$(DEL) *$(DEBUGSYMEXT)
  4233. endif
  4234. ifdef LOCALFPMAKEBIN
  4235. -$(DEL) $(LOCALFPMAKEBIN)
  4236. -$(DEL) $(FPMAKEBINOBJ)
  4237. endif
  4238. fpc_distclean: cleanall
  4239. .PHONY: fpc_baseinfo
  4240. override INFORULES+=fpc_baseinfo
  4241. fpc_baseinfo:
  4242. @$(ECHO)
  4243. @$(ECHO) == Package info ==
  4244. @$(ECHO) Package Name..... $(PACKAGE_NAME)
  4245. @$(ECHO) Package Version.. $(PACKAGE_VERSION)
  4246. @$(ECHO)
  4247. @$(ECHO) == Configuration info ==
  4248. @$(ECHO)
  4249. @$(ECHO) FPC.......... $(FPC)
  4250. @$(ECHO) FPC Version.. $(FPC_VERSION)
  4251. @$(ECHO) Source CPU... $(CPU_SOURCE)
  4252. @$(ECHO) Target CPU... $(CPU_TARGET)
  4253. @$(ECHO) Source OS.... $(OS_SOURCE)
  4254. @$(ECHO) Target OS.... $(OS_TARGET)
  4255. @$(ECHO) Full Source.. $(FULL_SOURCE)
  4256. @$(ECHO) Full Target.. $(FULL_TARGET)
  4257. @$(ECHO) SourceSuffix. $(SOURCESUFFIX)
  4258. @$(ECHO) TargetSuffix. $(TARGETSUFFIX)
  4259. @$(ECHO) FPC fpmake... $(FPCFPMAKE)
  4260. @$(ECHO)
  4261. @$(ECHO) == Directory info ==
  4262. @$(ECHO)
  4263. @$(ECHO) Required pkgs... $(REQUIRE_PACKAGES)
  4264. @$(ECHO)
  4265. @$(ECHO) Basedir......... $(BASEDIR)
  4266. @$(ECHO) FPCDir.......... $(FPCDIR)
  4267. @$(ECHO) CrossBinDir..... $(CROSSBINDIR)
  4268. @$(ECHO) UnitsDir........ $(UNITSDIR)
  4269. @$(ECHO) PackagesDir..... $(PACKAGESDIR)
  4270. @$(ECHO)
  4271. @$(ECHO) GCC library..... $(GCCLIBDIR)
  4272. @$(ECHO) Other library... $(OTHERLIBDIR)
  4273. @$(ECHO)
  4274. @$(ECHO) == Tools info ==
  4275. @$(ECHO)
  4276. @$(ECHO) As........ $(AS)
  4277. @$(ECHO) Ld........ $(LD)
  4278. @$(ECHO) Ar........ $(AR)
  4279. @$(ECHO) Rc........ $(RC)
  4280. @$(ECHO)
  4281. @$(ECHO) Mv........ $(MVPROG)
  4282. @$(ECHO) Cp........ $(CPPROG)
  4283. @$(ECHO) Rm........ $(RMPROG)
  4284. @$(ECHO) GInstall.. $(GINSTALL)
  4285. @$(ECHO) Echo...... $(ECHO)
  4286. @$(ECHO) Shell..... $(SHELL)
  4287. @$(ECHO) Date...... $(DATE)
  4288. @$(ECHO) FPCMake... $(FPCMAKE)
  4289. @$(ECHO) PPUMove... $(PPUMOVE)
  4290. @$(ECHO) Zip....... $(ZIPPROG)
  4291. @$(ECHO)
  4292. @$(ECHO) == Object info ==
  4293. @$(ECHO)
  4294. @$(ECHO) Target Loaders........ $(TARGET_LOADERS)
  4295. @$(ECHO) Target Units.......... $(TARGET_UNITS)
  4296. @$(ECHO) Target Implicit Units. $(TARGET_IMPLICITUNITS)
  4297. @$(ECHO) Target Programs....... $(TARGET_PROGRAMS)
  4298. @$(ECHO) Target Dirs........... $(TARGET_DIRS)
  4299. @$(ECHO) Target Examples....... $(TARGET_EXAMPLES)
  4300. @$(ECHO) Target ExampleDirs.... $(TARGET_EXAMPLEDIRS)
  4301. @$(ECHO)
  4302. @$(ECHO) Clean Units......... $(CLEAN_UNITS)
  4303. @$(ECHO) Clean Files......... $(CLEAN_FILES)
  4304. @$(ECHO)
  4305. @$(ECHO) Install Units....... $(INSTALL_UNITS)
  4306. @$(ECHO) Install Files....... $(INSTALL_FILES)
  4307. @$(ECHO)
  4308. @$(ECHO) == Install info ==
  4309. @$(ECHO)
  4310. @$(ECHO) DateStr.............. $(DATESTR)
  4311. @$(ECHO) ZipName.............. $(ZIPNAME)
  4312. @$(ECHO) ZipPrefix............ $(ZIPPREFIX)
  4313. @$(ECHO) ZipCrossPrefix....... $(ZIPCROSSPREFIX)
  4314. @$(ECHO) ZipSuffix............ $(ZIPSUFFIX)
  4315. @$(ECHO) FullZipName.......... $(FULLZIPNAME)
  4316. @$(ECHO) Install FPC Package.. $(INSTALL_FPCPACKAGE)
  4317. @$(ECHO)
  4318. @$(ECHO) Install base dir..... $(INSTALL_BASEDIR)
  4319. @$(ECHO) Install binary dir... $(INSTALL_BINDIR)
  4320. @$(ECHO) Install library dir.. $(INSTALL_LIBDIR)
  4321. @$(ECHO) Install units dir.... $(INSTALL_UNITDIR)
  4322. @$(ECHO) Install source dir... $(INSTALL_SOURCEDIR)
  4323. @$(ECHO) Install doc dir...... $(INSTALL_DOCDIR)
  4324. @$(ECHO) Install example dir.. $(INSTALL_EXAMPLEDIR)
  4325. @$(ECHO) Install data dir..... $(INSTALL_DATADIR)
  4326. @$(ECHO)
  4327. @$(ECHO) Dist destination dir. $(DIST_DESTDIR)
  4328. @$(ECHO) Dist zip name........ $(DIST_ZIPNAME)
  4329. @$(ECHO)
  4330. .PHONY: fpc_info
  4331. fpc_info: $(INFORULES)
  4332. .PHONY: fpc_makefile fpc_makefiles fpc_makefile_sub1 fpc_makefile_sub2 \
  4333. fpc_makefile_dirs
  4334. fpc_makefile:
  4335. $(FPCMAKE) -w -T$(OS_TARGET) Makefile.fpc
  4336. fpc_makefile_sub1:
  4337. ifdef TARGET_DIRS
  4338. $(FPCMAKE) -w -T$(OS_TARGET) $(addsuffix /Makefile.fpc,$(TARGET_DIRS))
  4339. endif
  4340. ifdef TARGET_EXAMPLEDIRS
  4341. $(FPCMAKE) -w -T$(OS_TARGET) $(addsuffix /Makefile.fpc,$(TARGET_EXAMPLEDIRS))
  4342. endif
  4343. fpc_makefile_sub2: $(addsuffix _makefile_dirs,$(TARGET_DIRS) $(TARGET_EXAMPLEDIRS))
  4344. fpc_makefile_dirs: fpc_makefile_sub1 fpc_makefile_sub2
  4345. fpc_makefiles: fpc_makefile fpc_makefile_dirs
  4346. ifndef BIN2S
  4347. BIN2S:=$(strip $(wildcard $(addsuffix /bin2s$(SRCEXEEXT),$(SEARCHPATH))))
  4348. ifeq ($(BIN2S),)
  4349. BIN2S= __missing_command_BIN2S
  4350. else
  4351. BIN2S:=$(firstword $(BIN2S))
  4352. endif
  4353. endif
  4354. export BIN2S
  4355. ifndef MMUTIL
  4356. MMUTIL:=$(strip $(wildcard $(addsuffix /mmutil$(SRCEXEEXT),$(SEARCHPATH))))
  4357. ifeq ($(MMUTIL),)
  4358. MMUTIL= __missing_command_MMUTIL
  4359. else
  4360. MMUTIL:=$(firstword $(MMUTIL))
  4361. endif
  4362. endif
  4363. export MMUTIL
  4364. ifndef GRIT_FPC
  4365. GRIT_FPC:=$(strip $(wildcard $(addsuffix /grit_fpc$(SRCEXEEXT),$(SEARCHPATH))))
  4366. ifeq ($(GRIT_FPC),)
  4367. GRIT_FPC= __missing_command_GRIT_FPC
  4368. else
  4369. GRIT_FPC:=$(firstword $(GRIT_FPC))
  4370. endif
  4371. endif
  4372. export GRIT_FPC
  4373. ifndef RMDIR
  4374. RMDIR:=$(strip $(wildcard $(addsuffix /rmdir$(SRCEXEEXT),$(SEARCHPATH))))
  4375. ifeq ($(RMDIR),)
  4376. RMDIR= __missing_command_RMDIR
  4377. else
  4378. RMDIR:=$(firstword $(RMDIR))
  4379. endif
  4380. endif
  4381. export RMDIR
  4382. ifndef MV
  4383. MV:=$(strip $(wildcard $(addsuffix /mv$(SRCEXEEXT),$(SEARCHPATH))))
  4384. ifeq ($(MV),)
  4385. MV= __missing_command_MV
  4386. else
  4387. MV:=$(firstword $(MV))
  4388. endif
  4389. endif
  4390. export MV
  4391. ifndef NDSTOOL
  4392. NDSTOOL:=$(strip $(wildcard $(addsuffix /ndstool$(SRCEXEEXT),$(SEARCHPATH))))
  4393. ifeq ($(NDSTOOL),)
  4394. NDSTOOL= __missing_command_NDSTOOL
  4395. else
  4396. NDSTOOL:=$(firstword $(NDSTOOL))
  4397. endif
  4398. endif
  4399. export NDSTOOL
  4400. debug: fpc_debug
  4401. smart: fpc_smart
  4402. release: fpc_release
  4403. units: fpc_units
  4404. examples:
  4405. shared: fpc_shared
  4406. install: fpc_install
  4407. sourceinstall: fpc_sourceinstall
  4408. exampleinstall: fpc_exampleinstall
  4409. distinstall:
  4410. zipinstall:
  4411. zipsourceinstall:
  4412. zipexampleinstall:
  4413. zipdistinstall:
  4414. distclean: fpc_distclean
  4415. cleanall: fpc_cleanall
  4416. info: fpc_info
  4417. makefiles: fpc_makefiles
  4418. .PHONY: debug smart release units examples shared install sourceinstall exampleinstall distinstall zipinstall zipsourceinstall zipexampleinstall zipdistinstall distclean cleanall info makefiles
  4419. ifneq ($(wildcard fpcmake.loc),)
  4420. include fpcmake.loc
  4421. endif
  4422. .NOTPARALLEL:
  4423. clean: dir_delete fpc_clean fpc_cleanall
  4424. all: dir_make $(BIN_FILES) $(GFX_FILES) fpc_all
  4425. filesystem: all make_filesystem
  4426. dir_delete:
  4427. @$(DELTREE) $(CURDIR)/$(BUILD)
  4428. @$(DELTREE) $(CURDIR)/$(INC)
  4429. @$(DELTREE) $(CURDIR)/$(BIN)
  4430. dir_make:
  4431. ifneq ($(BUILD), $(CURDIR))
  4432. @$(MKDIR) $(BUILD)
  4433. endif
  4434. ifneq ($(INC), $(CURDIR))
  4435. @$(MKDIR) $(INC)
  4436. endif
  4437. ifneq ($(BIN), $(CURDIR))
  4438. @$(MKDIR) $(BIN)
  4439. endif
  4440. soundbank.bin.o : $(AUDIO_FILES)
  4441. @$(MMUTIL) $^ -d -o$(BUILD)/soundbank.bin -h$(BUILD)/soundbank.h
  4442. $(BIN2S) $(BUILD)/soundbank.bin > $(BUILD)/soundbank.bin.s
  4443. $(AS) -o $(BUILD)/soundbank.bin.o $(BUILD)/soundbank.bin.s
  4444. $(GFX_FILES): $(wildcard %.bmp %.png)
  4445. @echo 'Converting $(@) file to asm...'
  4446. $(GRIT_FPC) $(GFX)/$(@) -fp -fts -ff $(GFX)/$(basename $(@)).grit -o$(BUILD)/$(@)
  4447. @echo 'Assembling $(@).s file...'
  4448. $(AS) -o $(BUILD)/$(basename $(@)).o $(BUILD)/$(basename $(@)).s
  4449. $(MV) -f $(BUILD)/$(basename $(@)).inc $(INC)/$(basename $(@)).inc
  4450. @echo 'Done!'
  4451. $(BIN_FILES): $(wildcard %.*)
  4452. @echo 'Converting $(@) file to asm...'
  4453. @$(BIN2S) $(DATA)/$(@) > $(BUILD)/$(@).s
  4454. @echo 'Creating $(@).inc include file...'
  4455. @echo "var" > `(echo "$(INC)/"$(@F) | tr . .)`.inc
  4456. @echo " " `(echo $(@F) | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`"_end: array [0..0] of cuint8; cvar; external;" >> `(echo "$(INC)/"$(@F) | tr . .)`.inc
  4457. @echo " " `(echo $(@F) | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`": array [0..0] of cuint8; cvar; external;" >> `(echo "$(INC)/"$(@F) | tr . .)`.inc
  4458. @echo " " `(echo $(@F) | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`_size": cuint32; cvar; external;" >> `(echo "$(INC)/"$(@F) | tr . .)`.inc
  4459. @echo 'Assembling $(@).s file...'
  4460. @$(AS) -o $(BUILD)/$(@).o $(BUILD)/$(@).s
  4461. @echo 'Done!'
  4462. data.gbfs.o:
  4463. @cd GBFS && gbfs ../$(BUILD)/data.gbfs $(GBFS_FILES)
  4464. $(BIN2S) $(BUILD)/data.gbfs > $(BUILD)/data.gbfs.s
  4465. $(AS) -o $(BUILD)/data.gbfs.o $(BUILD)/data.gbfs.s
  4466. make_filesystem:
  4467. @$(NDSTOOL) -c $(BIN)/$(TARGET_PROGRAMS).fs.nds -9 $(BIN)/$(TARGET_PROGRAMS).nef.bin -d $(CURDIR)/$(FILESYSTEM)