aclocal.m4 367 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277827882798280828182828283828482858286828782888289829082918292829382948295829682978298829983008301830283038304830583068307830883098310831183128313831483158316831783188319832083218322832383248325832683278328832983308331833283338334833583368337833883398340834183428343834483458346834783488349835083518352835383548355835683578358835983608361836283638364836583668367836883698370837183728373837483758376837783788379838083818382838383848385838683878388838983908391839283938394839583968397839883998400840184028403840484058406840784088409841084118412841384148415841684178418841984208421842284238424842584268427842884298430843184328433843484358436843784388439844084418442844384448445844684478448844984508451845284538454845584568457845884598460846184628463846484658466846784688469847084718472847384748475847684778478847984808481848284838484848584868487848884898490849184928493849484958496849784988499850085018502850385048505850685078508850985108511851285138514851585168517851885198520852185228523852485258526852785288529853085318532853385348535853685378538853985408541854285438544854585468547854885498550855185528553855485558556855785588559856085618562856385648565856685678568856985708571857285738574857585768577857885798580858185828583858485858586858785888589859085918592859385948595859685978598859986008601860286038604860586068607860886098610861186128613861486158616861786188619862086218622862386248625862686278628862986308631863286338634863586368637863886398640864186428643864486458646864786488649865086518652865386548655865686578658865986608661866286638664866586668667866886698670867186728673867486758676867786788679868086818682868386848685868686878688868986908691869286938694869586968697869886998700870187028703870487058706870787088709871087118712871387148715871687178718871987208721872287238724872587268727872887298730873187328733873487358736873787388739874087418742874387448745874687478748874987508751875287538754875587568757875887598760876187628763876487658766876787688769877087718772877387748775877687778778877987808781878287838784878587868787878887898790879187928793879487958796879787988799880088018802880388048805880688078808880988108811881288138814881588168817881888198820882188228823882488258826882788288829883088318832883388348835883688378838883988408841884288438844884588468847884888498850885188528853885488558856885788588859886088618862886388648865886688678868886988708871887288738874887588768877887888798880888188828883888488858886888788888889889088918892889388948895889688978898889989008901890289038904890589068907890889098910891189128913891489158916891789188919892089218922892389248925892689278928892989308931893289338934893589368937893889398940894189428943894489458946894789488949895089518952895389548955895689578958895989608961896289638964896589668967896889698970897189728973897489758976897789788979898089818982898389848985898689878988898989908991899289938994899589968997899889999000900190029003900490059006900790089009901090119012901390149015901690179018901990209021902290239024902590269027902890299030903190329033903490359036903790389039904090419042904390449045904690479048904990509051905290539054905590569057905890599060906190629063906490659066906790689069907090719072907390749075907690779078907990809081908290839084908590869087908890899090909190929093909490959096909790989099910091019102910391049105910691079108910991109111911291139114911591169117911891199120912191229123912491259126912791289129913091319132913391349135913691379138913991409141914291439144914591469147914891499150915191529153915491559156915791589159916091619162916391649165916691679168916991709171917291739174917591769177917891799180918191829183918491859186918791889189919091919192919391949195919691979198919992009201920292039204920592069207920892099210921192129213921492159216921792189219922092219222922392249225922692279228922992309231923292339234923592369237923892399240924192429243924492459246924792489249925092519252925392549255925692579258925992609261926292639264926592669267926892699270927192729273927492759276927792789279928092819282928392849285928692879288928992909291929292939294929592969297929892999300930193029303930493059306930793089309931093119312931393149315931693179318931993209321932293239324932593269327932893299330933193329333933493359336933793389339934093419342934393449345934693479348934993509351935293539354935593569357935893599360936193629363936493659366936793689369937093719372937393749375937693779378937993809381938293839384938593869387938893899390939193929393939493959396939793989399940094019402940394049405940694079408940994109411941294139414941594169417941894199420942194229423942494259426942794289429943094319432943394349435943694379438943994409441944294439444944594469447944894499450945194529453945494559456945794589459946094619462946394649465946694679468946994709471947294739474947594769477947894799480948194829483948494859486948794889489949094919492949394949495949694979498949995009501950295039504950595069507950895099510951195129513951495159516951795189519952095219522952395249525952695279528952995309531953295339534953595369537953895399540954195429543954495459546954795489549955095519552955395549555955695579558955995609561956295639564956595669567956895699570957195729573957495759576957795789579958095819582958395849585958695879588958995909591959295939594959595969597959895999600960196029603960496059606960796089609961096119612961396149615961696179618961996209621962296239624962596269627962896299630963196329633963496359636963796389639964096419642964396449645964696479648964996509651965296539654965596569657965896599660966196629663966496659666966796689669967096719672967396749675967696779678967996809681968296839684968596869687968896899690969196929693969496959696969796989699970097019702970397049705970697079708970997109711971297139714971597169717971897199720972197229723972497259726972797289729973097319732973397349735973697379738973997409741974297439744974597469747974897499750975197529753975497559756975797589759976097619762976397649765976697679768976997709771977297739774977597769777977897799780978197829783978497859786978797889789979097919792979397949795979697979798979998009801980298039804980598069807980898099810981198129813981498159816981798189819982098219822982398249825982698279828982998309831983298339834983598369837983898399840984198429843984498459846984798489849985098519852985398549855985698579858985998609861986298639864986598669867986898699870987198729873987498759876987798789879988098819882988398849885988698879888988998909891989298939894989598969897989898999900990199029903990499059906990799089909991099119912991399149915991699179918991999209921992299239924992599269927992899299930993199329933993499359936993799389939994099419942994399449945994699479948994999509951995299539954995599569957995899599960996199629963996499659966996799689969997099719972997399749975997699779978997999809981998299839984998599869987998899899990999199929993999499959996999799989999100001000110002100031000410005100061000710008100091001010011100121001310014100151001610017100181001910020100211002210023100241002510026100271002810029100301003110032100331003410035100361003710038100391004010041100421004310044100451004610047100481004910050100511005210053100541005510056100571005810059100601006110062100631006410065100661006710068100691007010071100721007310074100751007610077100781007910080100811008210083100841008510086100871008810089100901009110092100931009410095100961009710098100991010010101101021010310104101051010610107101081010910110101111011210113101141011510116101171011810119101201012110122101231012410125101261012710128101291013010131101321013310134101351013610137101381013910140101411014210143101441014510146101471014810149101501015110152101531015410155101561015710158101591016010161101621016310164101651016610167101681016910170101711017210173101741017510176101771017810179101801018110182101831018410185101861018710188101891019010191101921019310194101951019610197101981019910200102011020210203102041020510206102071020810209102101021110212102131021410215102161021710218102191022010221102221022310224102251022610227102281022910230102311023210233102341023510236102371023810239102401024110242102431024410245102461024710248102491025010251102521025310254102551025610257102581025910260102611026210263102641026510266102671026810269
  1. # generated automatically by aclocal 1.16.5 -*- Autoconf -*-
  2. # Copyright (C) 1996-2021 Free Software Foundation, Inc.
  3. # This file is free software; the Free Software Foundation
  4. # gives unlimited permission to copy and/or distribute it,
  5. # with or without modifications, as long as this notice is preserved.
  6. # This program is distributed in the hope that it will be useful,
  7. # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
  8. # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
  9. # PARTICULAR PURPOSE.
  10. m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
  11. m4_ifndef([AC_AUTOCONF_VERSION],
  12. [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
  13. m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.72],,
  14. [m4_warning([this file was generated for autoconf 2.72.
  15. You have another version of autoconf. It may work, but is not guaranteed to.
  16. If you have problems, you may need to regenerate the build system entirely.
  17. To do so, use the procedure documented by the package, typically 'autoreconf'.])])
  18. # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
  19. #
  20. # Copyright (C) 1996-2001, 2003-2019, 2021-2022 Free Software
  21. # Foundation, Inc.
  22. # Written by Gordon Matzigkeit, 1996
  23. #
  24. # This file is free software; the Free Software Foundation gives
  25. # unlimited permission to copy and/or distribute it, with or without
  26. # modifications, as long as this notice is preserved.
  27. m4_define([_LT_COPYING], [dnl
  28. # Copyright (C) 2014 Free Software Foundation, Inc.
  29. # This is free software; see the source for copying conditions. There is NO
  30. # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  31. # GNU Libtool is free software; you can redistribute it and/or modify
  32. # it under the terms of the GNU General Public License as published by
  33. # the Free Software Foundation; either version 2 of of the License, or
  34. # (at your option) any later version.
  35. #
  36. # As a special exception to the GNU General Public License, if you
  37. # distribute this file as part of a program or library that is built
  38. # using GNU Libtool, you may include this file under the same
  39. # distribution terms that you use for the rest of that program.
  40. #
  41. # GNU Libtool is distributed in the hope that it will be useful, but
  42. # WITHOUT ANY WARRANTY; without even the implied warranty of
  43. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  44. # GNU General Public License for more details.
  45. #
  46. # You should have received a copy of the GNU General Public License
  47. # along with this program. If not, see <http://www.gnu.org/licenses/>.
  48. ])
  49. # serial 59 LT_INIT
  50. # LT_PREREQ(VERSION)
  51. # ------------------
  52. # Complain and exit if this libtool version is less that VERSION.
  53. m4_defun([LT_PREREQ],
  54. [m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
  55. [m4_default([$3],
  56. [m4_fatal([Libtool version $1 or higher is required],
  57. 63)])],
  58. [$2])])
  59. # _LT_CHECK_BUILDDIR
  60. # ------------------
  61. # Complain if the absolute build directory name contains unusual characters
  62. m4_defun([_LT_CHECK_BUILDDIR],
  63. [case `pwd` in
  64. *\ * | *\ *)
  65. AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;;
  66. esac
  67. ])
  68. # LT_INIT([OPTIONS])
  69. # ------------------
  70. AC_DEFUN([LT_INIT],
  71. [AC_PREREQ([2.62])dnl We use AC_PATH_PROGS_FEATURE_CHECK
  72. AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
  73. AC_BEFORE([$0], [LT_LANG])dnl
  74. AC_BEFORE([$0], [LT_OUTPUT])dnl
  75. AC_BEFORE([$0], [LTDL_INIT])dnl
  76. m4_require([_LT_CHECK_BUILDDIR])dnl
  77. dnl Autoconf doesn't catch unexpanded LT_ macros by default:
  78. m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
  79. m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW)$])dnl
  80. dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
  81. dnl unless we require an AC_DEFUNed macro:
  82. AC_REQUIRE([LTOPTIONS_VERSION])dnl
  83. AC_REQUIRE([LTSUGAR_VERSION])dnl
  84. AC_REQUIRE([LTVERSION_VERSION])dnl
  85. AC_REQUIRE([LTOBSOLETE_VERSION])dnl
  86. m4_require([_LT_PROG_LTMAIN])dnl
  87. _LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}])
  88. dnl Parse OPTIONS
  89. _LT_SET_OPTIONS([$0], [$1])
  90. # This can be used to rebuild libtool when needed
  91. LIBTOOL_DEPS=$ltmain
  92. # Always use our own libtool.
  93. LIBTOOL='$(SHELL) $(top_builddir)/libtool'
  94. AC_SUBST(LIBTOOL)dnl
  95. _LT_SETUP
  96. # Only expand once:
  97. m4_define([LT_INIT])
  98. ])# LT_INIT
  99. # Old names:
  100. AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
  101. AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
  102. dnl aclocal-1.4 backwards compatibility:
  103. dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
  104. dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
  105. # _LT_PREPARE_CC_BASENAME
  106. # -----------------------
  107. m4_defun([_LT_PREPARE_CC_BASENAME], [
  108. # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
  109. func_cc_basename ()
  110. {
  111. for cc_temp in @S|@*""; do
  112. case $cc_temp in
  113. compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
  114. distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
  115. \-*) ;;
  116. *) break;;
  117. esac
  118. done
  119. func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
  120. }
  121. ])# _LT_PREPARE_CC_BASENAME
  122. # _LT_CC_BASENAME(CC)
  123. # -------------------
  124. # It would be clearer to call AC_REQUIREs from _LT_PREPARE_CC_BASENAME,
  125. # but that macro is also expanded into generated libtool script, which
  126. # arranges for $SED and $ECHO to be set by different means.
  127. m4_defun([_LT_CC_BASENAME],
  128. [m4_require([_LT_PREPARE_CC_BASENAME])dnl
  129. AC_REQUIRE([_LT_DECL_SED])dnl
  130. AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
  131. func_cc_basename $1
  132. cc_basename=$func_cc_basename_result
  133. ])
  134. # _LT_FILEUTILS_DEFAULTS
  135. # ----------------------
  136. # It is okay to use these file commands and assume they have been set
  137. # sensibly after 'm4_require([_LT_FILEUTILS_DEFAULTS])'.
  138. m4_defun([_LT_FILEUTILS_DEFAULTS],
  139. [: ${CP="cp -f"}
  140. : ${MV="mv -f"}
  141. : ${RM="rm -f"}
  142. ])# _LT_FILEUTILS_DEFAULTS
  143. # _LT_SETUP
  144. # ---------
  145. m4_defun([_LT_SETUP],
  146. [AC_REQUIRE([AC_CANONICAL_HOST])dnl
  147. AC_REQUIRE([AC_CANONICAL_BUILD])dnl
  148. AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl
  149. AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
  150. _LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl
  151. dnl
  152. _LT_DECL([], [host_alias], [0], [The host system])dnl
  153. _LT_DECL([], [host], [0])dnl
  154. _LT_DECL([], [host_os], [0])dnl
  155. dnl
  156. _LT_DECL([], [build_alias], [0], [The build system])dnl
  157. _LT_DECL([], [build], [0])dnl
  158. _LT_DECL([], [build_os], [0])dnl
  159. dnl
  160. AC_REQUIRE([AC_PROG_CC])dnl
  161. AC_REQUIRE([LT_PATH_LD])dnl
  162. AC_REQUIRE([LT_PATH_NM])dnl
  163. dnl
  164. AC_REQUIRE([AC_PROG_LN_S])dnl
  165. test -z "$LN_S" && LN_S="ln -s"
  166. _LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
  167. dnl
  168. AC_REQUIRE([LT_CMD_MAX_LEN])dnl
  169. _LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
  170. _LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
  171. dnl
  172. m4_require([_LT_FILEUTILS_DEFAULTS])dnl
  173. m4_require([_LT_CHECK_SHELL_FEATURES])dnl
  174. m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl
  175. m4_require([_LT_CMD_RELOAD])dnl
  176. m4_require([_LT_DECL_FILECMD])dnl
  177. m4_require([_LT_CHECK_MAGIC_METHOD])dnl
  178. m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl
  179. m4_require([_LT_CMD_OLD_ARCHIVE])dnl
  180. m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
  181. m4_require([_LT_WITH_SYSROOT])dnl
  182. m4_require([_LT_CMD_TRUNCATE])dnl
  183. _LT_CONFIG_LIBTOOL_INIT([
  184. # See if we are running on zsh, and set the options that allow our
  185. # commands through without removal of \ escapes INIT.
  186. if test -n "\${ZSH_VERSION+set}"; then
  187. setopt NO_GLOB_SUBST
  188. fi
  189. ])
  190. if test -n "${ZSH_VERSION+set}"; then
  191. setopt NO_GLOB_SUBST
  192. fi
  193. _LT_CHECK_OBJDIR
  194. m4_require([_LT_TAG_COMPILER])dnl
  195. case $host_os in
  196. aix3*)
  197. # AIX sometimes has problems with the GCC collect2 program. For some
  198. # reason, if we set the COLLECT_NAMES environment variable, the problems
  199. # vanish in a puff of smoke.
  200. if test set != "${COLLECT_NAMES+set}"; then
  201. COLLECT_NAMES=
  202. export COLLECT_NAMES
  203. fi
  204. ;;
  205. esac
  206. # Global variables:
  207. ofile=libtool
  208. can_build_shared=yes
  209. # All known linkers require a '.a' archive for static linking (except MSVC and
  210. # ICC, which need '.lib').
  211. libext=a
  212. with_gnu_ld=$lt_cv_prog_gnu_ld
  213. old_CC=$CC
  214. old_CFLAGS=$CFLAGS
  215. # Set sane defaults for various variables
  216. test -z "$CC" && CC=cc
  217. test -z "$LTCC" && LTCC=$CC
  218. test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
  219. test -z "$LD" && LD=ld
  220. test -z "$ac_objext" && ac_objext=o
  221. _LT_CC_BASENAME([$compiler])
  222. # Only perform the check for file, if the check method requires it
  223. test -z "$MAGIC_CMD" && MAGIC_CMD=file
  224. case $deplibs_check_method in
  225. file_magic*)
  226. if test "$file_magic_cmd" = '$MAGIC_CMD'; then
  227. _LT_PATH_MAGIC
  228. fi
  229. ;;
  230. esac
  231. # Use C for the default configuration in the libtool script
  232. LT_SUPPORTED_TAG([CC])
  233. _LT_LANG_C_CONFIG
  234. _LT_LANG_DEFAULT_CONFIG
  235. _LT_CONFIG_COMMANDS
  236. ])# _LT_SETUP
  237. # _LT_PREPARE_SED_QUOTE_VARS
  238. # --------------------------
  239. # Define a few sed substitution that help us do robust quoting.
  240. m4_defun([_LT_PREPARE_SED_QUOTE_VARS],
  241. [# Backslashify metacharacters that are still active within
  242. # double-quoted strings.
  243. sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
  244. # Same as above, but do not quote variable references.
  245. double_quote_subst='s/\([["`\\]]\)/\\\1/g'
  246. # Sed substitution to delay expansion of an escaped shell variable in a
  247. # double_quote_subst'ed string.
  248. delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
  249. # Sed substitution to delay expansion of an escaped single quote.
  250. delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
  251. # Sed substitution to avoid accidental globbing in evaled expressions
  252. no_glob_subst='s/\*/\\\*/g'
  253. ])
  254. # _LT_PROG_LTMAIN
  255. # ---------------
  256. # Note that this code is called both from 'configure', and 'config.status'
  257. # now that we use AC_CONFIG_COMMANDS to generate libtool. Notably,
  258. # 'config.status' has no value for ac_aux_dir unless we are using Automake,
  259. # so we pass a copy along to make sure it has a sensible value anyway.
  260. m4_defun([_LT_PROG_LTMAIN],
  261. [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
  262. _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
  263. ltmain=$ac_aux_dir/ltmain.sh
  264. ])# _LT_PROG_LTMAIN
  265. # So that we can recreate a full libtool script including additional
  266. # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
  267. # in macros and then make a single call at the end using the 'libtool'
  268. # label.
  269. # _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
  270. # ----------------------------------------
  271. # Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
  272. m4_define([_LT_CONFIG_LIBTOOL_INIT],
  273. [m4_ifval([$1],
  274. [m4_append([_LT_OUTPUT_LIBTOOL_INIT],
  275. [$1
  276. ])])])
  277. # Initialize.
  278. m4_define([_LT_OUTPUT_LIBTOOL_INIT])
  279. # _LT_CONFIG_LIBTOOL([COMMANDS])
  280. # ------------------------------
  281. # Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
  282. m4_define([_LT_CONFIG_LIBTOOL],
  283. [m4_ifval([$1],
  284. [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
  285. [$1
  286. ])])])
  287. # Initialize.
  288. m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
  289. # _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
  290. # -----------------------------------------------------
  291. m4_defun([_LT_CONFIG_SAVE_COMMANDS],
  292. [_LT_CONFIG_LIBTOOL([$1])
  293. _LT_CONFIG_LIBTOOL_INIT([$2])
  294. ])
  295. # _LT_FORMAT_COMMENT([COMMENT])
  296. # -----------------------------
  297. # Add leading comment marks to the start of each line, and a trailing
  298. # full-stop to the whole comment if one is not present already.
  299. m4_define([_LT_FORMAT_COMMENT],
  300. [m4_ifval([$1], [
  301. m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
  302. [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
  303. )])
  304. # _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
  305. # -------------------------------------------------------------------
  306. # CONFIGNAME is the name given to the value in the libtool script.
  307. # VARNAME is the (base) name used in the configure script.
  308. # VALUE may be 0, 1 or 2 for a computed quote escaped value based on
  309. # VARNAME. Any other value will be used directly.
  310. m4_define([_LT_DECL],
  311. [lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
  312. [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
  313. [m4_ifval([$1], [$1], [$2])])
  314. lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
  315. m4_ifval([$4],
  316. [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
  317. lt_dict_add_subkey([lt_decl_dict], [$2],
  318. [tagged?], [m4_ifval([$5], [yes], [no])])])
  319. ])
  320. # _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
  321. # --------------------------------------------------------
  322. m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
  323. # lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
  324. # ------------------------------------------------
  325. m4_define([lt_decl_tag_varnames],
  326. [_lt_decl_filter([tagged?], [yes], $@)])
  327. # _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
  328. # ---------------------------------------------------------
  329. m4_define([_lt_decl_filter],
  330. [m4_case([$#],
  331. [0], [m4_fatal([$0: too few arguments: $#])],
  332. [1], [m4_fatal([$0: too few arguments: $#: $1])],
  333. [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
  334. [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
  335. [lt_dict_filter([lt_decl_dict], $@)])[]dnl
  336. ])
  337. # lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
  338. # --------------------------------------------------
  339. m4_define([lt_decl_quote_varnames],
  340. [_lt_decl_filter([value], [1], $@)])
  341. # lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
  342. # ---------------------------------------------------
  343. m4_define([lt_decl_dquote_varnames],
  344. [_lt_decl_filter([value], [2], $@)])
  345. # lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
  346. # ---------------------------------------------------
  347. m4_define([lt_decl_varnames_tagged],
  348. [m4_assert([$# <= 2])dnl
  349. _$0(m4_quote(m4_default([$1], [[, ]])),
  350. m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]),
  351. m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))])
  352. m4_define([_lt_decl_varnames_tagged],
  353. [m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])])
  354. # lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
  355. # ------------------------------------------------
  356. m4_define([lt_decl_all_varnames],
  357. [_$0(m4_quote(m4_default([$1], [[, ]])),
  358. m4_if([$2], [],
  359. m4_quote(lt_decl_varnames),
  360. m4_quote(m4_shift($@))))[]dnl
  361. ])
  362. m4_define([_lt_decl_all_varnames],
  363. [lt_join($@, lt_decl_varnames_tagged([$1],
  364. lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
  365. ])
  366. # _LT_CONFIG_STATUS_DECLARE([VARNAME])
  367. # ------------------------------------
  368. # Quote a variable value, and forward it to 'config.status' so that its
  369. # declaration there will have the same value as in 'configure'. VARNAME
  370. # must have a single quote delimited value for this to work.
  371. m4_define([_LT_CONFIG_STATUS_DECLARE],
  372. [$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`'])
  373. # _LT_CONFIG_STATUS_DECLARATIONS
  374. # ------------------------------
  375. # We delimit libtool config variables with single quotes, so when
  376. # we write them to config.status, we have to be sure to quote all
  377. # embedded single quotes properly. In configure, this macro expands
  378. # each variable declared with _LT_DECL (and _LT_TAGDECL) into:
  379. #
  380. # <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`'
  381. m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
  382. [m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
  383. [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
  384. # _LT_LIBTOOL_TAGS
  385. # ----------------
  386. # Output comment and list of tags supported by the script
  387. m4_defun([_LT_LIBTOOL_TAGS],
  388. [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
  389. available_tags='_LT_TAGS'dnl
  390. ])
  391. # _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
  392. # -----------------------------------
  393. # Extract the dictionary values for VARNAME (optionally with TAG) and
  394. # expand to a commented shell variable setting:
  395. #
  396. # # Some comment about what VAR is for.
  397. # visible_name=$lt_internal_name
  398. m4_define([_LT_LIBTOOL_DECLARE],
  399. [_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
  400. [description])))[]dnl
  401. m4_pushdef([_libtool_name],
  402. m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
  403. m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
  404. [0], [_libtool_name=[$]$1],
  405. [1], [_libtool_name=$lt_[]$1],
  406. [2], [_libtool_name=$lt_[]$1],
  407. [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
  408. m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
  409. ])
  410. # _LT_LIBTOOL_CONFIG_VARS
  411. # -----------------------
  412. # Produce commented declarations of non-tagged libtool config variables
  413. # suitable for insertion in the LIBTOOL CONFIG section of the 'libtool'
  414. # script. Tagged libtool config variables (even for the LIBTOOL CONFIG
  415. # section) are produced by _LT_LIBTOOL_TAG_VARS.
  416. m4_defun([_LT_LIBTOOL_CONFIG_VARS],
  417. [m4_foreach([_lt_var],
  418. m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
  419. [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
  420. # _LT_LIBTOOL_TAG_VARS(TAG)
  421. # -------------------------
  422. m4_define([_LT_LIBTOOL_TAG_VARS],
  423. [m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
  424. [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
  425. # _LT_TAGVAR(VARNAME, [TAGNAME])
  426. # ------------------------------
  427. m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
  428. # _LT_CONFIG_COMMANDS
  429. # -------------------
  430. # Send accumulated output to $CONFIG_STATUS. Thanks to the lists of
  431. # variables for single and double quote escaping we saved from calls
  432. # to _LT_DECL, we can put quote escaped variables declarations
  433. # into 'config.status', and then the shell code to quote escape them in
  434. # for loops in 'config.status'. Finally, any additional code accumulated
  435. # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
  436. m4_defun([_LT_CONFIG_COMMANDS],
  437. [AC_PROVIDE_IFELSE([LT_OUTPUT],
  438. dnl If the libtool generation code has been placed in $CONFIG_LT,
  439. dnl instead of duplicating it all over again into config.status,
  440. dnl then we will have config.status run $CONFIG_LT later, so it
  441. dnl needs to know what name is stored there:
  442. [AC_CONFIG_COMMANDS([libtool],
  443. [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
  444. dnl If the libtool generation code is destined for config.status,
  445. dnl expand the accumulated commands and init code now:
  446. [AC_CONFIG_COMMANDS([libtool],
  447. [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
  448. ])#_LT_CONFIG_COMMANDS
  449. # Initialize.
  450. m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
  451. [
  452. # The HP-UX ksh and POSIX shell print the target directory to stdout
  453. # if CDPATH is set.
  454. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
  455. sed_quote_subst='$sed_quote_subst'
  456. double_quote_subst='$double_quote_subst'
  457. delay_variable_subst='$delay_variable_subst'
  458. _LT_CONFIG_STATUS_DECLARATIONS
  459. LTCC='$LTCC'
  460. LTCFLAGS='$LTCFLAGS'
  461. compiler='$compiler_DEFAULT'
  462. # A function that is used when there is no print builtin or printf.
  463. func_fallback_echo ()
  464. {
  465. eval 'cat <<_LTECHO_EOF
  466. \$[]1
  467. _LTECHO_EOF'
  468. }
  469. # Quote evaled strings.
  470. for var in lt_decl_all_varnames([[ \
  471. ]], lt_decl_quote_varnames); do
  472. case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
  473. *[[\\\\\\\`\\"\\\$]]*)
  474. eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
  475. ;;
  476. *)
  477. eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
  478. ;;
  479. esac
  480. done
  481. # Double-quote double-evaled strings.
  482. for var in lt_decl_all_varnames([[ \
  483. ]], lt_decl_dquote_varnames); do
  484. case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
  485. *[[\\\\\\\`\\"\\\$]]*)
  486. eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
  487. ;;
  488. *)
  489. eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
  490. ;;
  491. esac
  492. done
  493. _LT_OUTPUT_LIBTOOL_INIT
  494. ])
  495. # _LT_GENERATED_FILE_INIT(FILE, [COMMENT])
  496. # ------------------------------------
  497. # Generate a child script FILE with all initialization necessary to
  498. # reuse the environment learned by the parent script, and make the
  499. # file executable. If COMMENT is supplied, it is inserted after the
  500. # '#!' sequence but before initialization text begins. After this
  501. # macro, additional text can be appended to FILE to form the body of
  502. # the child script. The macro ends with non-zero status if the
  503. # file could not be fully written (such as if the disk is full).
  504. m4_ifdef([AS_INIT_GENERATED],
  505. [m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])],
  506. [m4_defun([_LT_GENERATED_FILE_INIT],
  507. [m4_require([AS_PREPARE])]dnl
  508. [m4_pushdef([AS_MESSAGE_LOG_FD])]dnl
  509. [lt_write_fail=0
  510. cat >$1 <<_ASEOF || lt_write_fail=1
  511. #! $SHELL
  512. # Generated by $as_me.
  513. $2
  514. SHELL=\${CONFIG_SHELL-$SHELL}
  515. export SHELL
  516. _ASEOF
  517. cat >>$1 <<\_ASEOF || lt_write_fail=1
  518. AS_SHELL_SANITIZE
  519. _AS_PREPARE
  520. exec AS_MESSAGE_FD>&1
  521. _ASEOF
  522. test 0 = "$lt_write_fail" && chmod +x $1[]dnl
  523. m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT
  524. # LT_OUTPUT
  525. # ---------
  526. # This macro allows early generation of the libtool script (before
  527. # AC_OUTPUT is called), incase it is used in configure for compilation
  528. # tests.
  529. AC_DEFUN([LT_OUTPUT],
  530. [: ${CONFIG_LT=./config.lt}
  531. AC_MSG_NOTICE([creating $CONFIG_LT])
  532. _LT_GENERATED_FILE_INIT(["$CONFIG_LT"],
  533. [# Run this file to recreate a libtool stub with the current configuration.])
  534. cat >>"$CONFIG_LT" <<\_LTEOF
  535. lt_cl_silent=false
  536. exec AS_MESSAGE_LOG_FD>>config.log
  537. {
  538. echo
  539. AS_BOX([Running $as_me.])
  540. } >&AS_MESSAGE_LOG_FD
  541. lt_cl_help="\
  542. '$as_me' creates a local libtool stub from the current configuration,
  543. for use in further configure time tests before the real libtool is
  544. generated.
  545. Usage: $[0] [[OPTIONS]]
  546. -h, --help print this help, then exit
  547. -V, --version print version number, then exit
  548. -q, --quiet do not print progress messages
  549. -d, --debug don't remove temporary files
  550. Report bugs to <bug-libtool@gnu.org>."
  551. lt_cl_version="\
  552. m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
  553. m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
  554. configured by $[0], generated by m4_PACKAGE_STRING.
  555. Copyright (C) 2011 Free Software Foundation, Inc.
  556. This config.lt script is free software; the Free Software Foundation
  557. gives unlimited permision to copy, distribute and modify it."
  558. while test 0 != $[#]
  559. do
  560. case $[1] in
  561. --version | --v* | -V )
  562. echo "$lt_cl_version"; exit 0 ;;
  563. --help | --h* | -h )
  564. echo "$lt_cl_help"; exit 0 ;;
  565. --debug | --d* | -d )
  566. debug=: ;;
  567. --quiet | --q* | --silent | --s* | -q )
  568. lt_cl_silent=: ;;
  569. -*) AC_MSG_ERROR([unrecognized option: $[1]
  570. Try '$[0] --help' for more information.]) ;;
  571. *) AC_MSG_ERROR([unrecognized argument: $[1]
  572. Try '$[0] --help' for more information.]) ;;
  573. esac
  574. shift
  575. done
  576. if $lt_cl_silent; then
  577. exec AS_MESSAGE_FD>/dev/null
  578. fi
  579. _LTEOF
  580. cat >>"$CONFIG_LT" <<_LTEOF
  581. _LT_OUTPUT_LIBTOOL_COMMANDS_INIT
  582. _LTEOF
  583. cat >>"$CONFIG_LT" <<\_LTEOF
  584. AC_MSG_NOTICE([creating $ofile])
  585. _LT_OUTPUT_LIBTOOL_COMMANDS
  586. AS_EXIT(0)
  587. _LTEOF
  588. chmod +x "$CONFIG_LT"
  589. # configure is writing to config.log, but config.lt does its own redirection,
  590. # appending to config.log, which fails on DOS, as config.log is still kept
  591. # open by configure. Here we exec the FD to /dev/null, effectively closing
  592. # config.log, so it can be properly (re)opened and appended to by config.lt.
  593. lt_cl_success=:
  594. test yes = "$silent" &&
  595. lt_config_lt_args="$lt_config_lt_args --quiet"
  596. exec AS_MESSAGE_LOG_FD>/dev/null
  597. $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
  598. exec AS_MESSAGE_LOG_FD>>config.log
  599. $lt_cl_success || AS_EXIT(1)
  600. ])# LT_OUTPUT
  601. # _LT_CONFIG(TAG)
  602. # ---------------
  603. # If TAG is the built-in tag, create an initial libtool script with a
  604. # default configuration from the untagged config vars. Otherwise add code
  605. # to config.status for appending the configuration named by TAG from the
  606. # matching tagged config vars.
  607. m4_defun([_LT_CONFIG],
  608. [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
  609. _LT_CONFIG_SAVE_COMMANDS([
  610. m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
  611. m4_if(_LT_TAG, [C], [
  612. # See if we are running on zsh, and set the options that allow our
  613. # commands through without removal of \ escapes.
  614. if test -n "${ZSH_VERSION+set}"; then
  615. setopt NO_GLOB_SUBST
  616. fi
  617. cfgfile=${ofile}T
  618. trap "$RM \"$cfgfile\"; exit 1" 1 2 15
  619. $RM "$cfgfile"
  620. cat <<_LT_EOF >> "$cfgfile"
  621. #! $SHELL
  622. # Generated automatically by $as_me ($PACKAGE) $VERSION
  623. # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
  624. # NOTE: Changes made to this file will be lost: look at ltmain.sh.
  625. # Provide generalized library-building support services.
  626. # Written by Gordon Matzigkeit, 1996
  627. _LT_COPYING
  628. _LT_LIBTOOL_TAGS
  629. # Configured defaults for sys_lib_dlsearch_path munging.
  630. : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"}
  631. # ### BEGIN LIBTOOL CONFIG
  632. _LT_LIBTOOL_CONFIG_VARS
  633. _LT_LIBTOOL_TAG_VARS
  634. # ### END LIBTOOL CONFIG
  635. _LT_EOF
  636. cat <<'_LT_EOF' >> "$cfgfile"
  637. # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE
  638. _LT_PREPARE_MUNGE_PATH_LIST
  639. _LT_PREPARE_CC_BASENAME
  640. # ### END FUNCTIONS SHARED WITH CONFIGURE
  641. _LT_EOF
  642. case $host_os in
  643. aix3*)
  644. cat <<\_LT_EOF >> "$cfgfile"
  645. # AIX sometimes has problems with the GCC collect2 program. For some
  646. # reason, if we set the COLLECT_NAMES environment variable, the problems
  647. # vanish in a puff of smoke.
  648. if test set != "${COLLECT_NAMES+set}"; then
  649. COLLECT_NAMES=
  650. export COLLECT_NAMES
  651. fi
  652. _LT_EOF
  653. ;;
  654. esac
  655. _LT_PROG_LTMAIN
  656. # We use sed instead of cat because bash on DJGPP gets confused if
  657. # if finds mixed CR/LF and LF-only lines. Since sed operates in
  658. # text mode, it properly converts lines to CR/LF. This bash problem
  659. # is reportedly fixed, but why not run on old versions too?
  660. $SED '$q' "$ltmain" >> "$cfgfile" \
  661. || (rm -f "$cfgfile"; exit 1)
  662. mv -f "$cfgfile" "$ofile" ||
  663. (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
  664. chmod +x "$ofile"
  665. ],
  666. [cat <<_LT_EOF >> "$ofile"
  667. dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
  668. dnl in a comment (ie after a #).
  669. # ### BEGIN LIBTOOL TAG CONFIG: $1
  670. _LT_LIBTOOL_TAG_VARS(_LT_TAG)
  671. # ### END LIBTOOL TAG CONFIG: $1
  672. _LT_EOF
  673. ])dnl /m4_if
  674. ],
  675. [m4_if([$1], [], [
  676. PACKAGE='$PACKAGE'
  677. VERSION='$VERSION'
  678. RM='$RM'
  679. ofile='$ofile'], [])
  680. ])dnl /_LT_CONFIG_SAVE_COMMANDS
  681. ])# _LT_CONFIG
  682. # LT_SUPPORTED_TAG(TAG)
  683. # ---------------------
  684. # Trace this macro to discover what tags are supported by the libtool
  685. # --tag option, using:
  686. # autoconf --trace 'LT_SUPPORTED_TAG:$1'
  687. AC_DEFUN([LT_SUPPORTED_TAG], [])
  688. # C support is built-in for now
  689. m4_define([_LT_LANG_C_enabled], [])
  690. m4_define([_LT_TAGS], [])
  691. # LT_LANG(LANG)
  692. # -------------
  693. # Enable libtool support for the given language if not already enabled.
  694. AC_DEFUN([LT_LANG],
  695. [AC_BEFORE([$0], [LT_OUTPUT])dnl
  696. m4_case([$1],
  697. [C], [_LT_LANG(C)],
  698. [C++], [_LT_LANG(CXX)],
  699. [Go], [_LT_LANG(GO)],
  700. [Java], [_LT_LANG(GCJ)],
  701. [Fortran 77], [_LT_LANG(F77)],
  702. [Fortran], [_LT_LANG(FC)],
  703. [Windows Resource], [_LT_LANG(RC)],
  704. [m4_ifdef([_LT_LANG_]$1[_CONFIG],
  705. [_LT_LANG($1)],
  706. [m4_fatal([$0: unsupported language: "$1"])])])dnl
  707. ])# LT_LANG
  708. # _LT_LANG(LANGNAME)
  709. # ------------------
  710. m4_defun([_LT_LANG],
  711. [m4_ifdef([_LT_LANG_]$1[_enabled], [],
  712. [LT_SUPPORTED_TAG([$1])dnl
  713. m4_append([_LT_TAGS], [$1 ])dnl
  714. m4_define([_LT_LANG_]$1[_enabled], [])dnl
  715. _LT_LANG_$1_CONFIG($1)])dnl
  716. ])# _LT_LANG
  717. m4_ifndef([AC_PROG_GO], [
  718. # NOTE: This macro has been submitted for inclusion into #
  719. # GNU Autoconf as AC_PROG_GO. When it is available in #
  720. # a released version of Autoconf we should remove this #
  721. # macro and use it instead. #
  722. m4_defun([AC_PROG_GO],
  723. [AC_LANG_PUSH(Go)dnl
  724. AC_ARG_VAR([GOC], [Go compiler command])dnl
  725. AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl
  726. _AC_ARG_VAR_LDFLAGS()dnl
  727. AC_CHECK_TOOL(GOC, gccgo)
  728. if test -z "$GOC"; then
  729. if test -n "$ac_tool_prefix"; then
  730. AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo])
  731. fi
  732. fi
  733. if test -z "$GOC"; then
  734. AC_CHECK_PROG(GOC, gccgo, gccgo, false)
  735. fi
  736. ])#m4_defun
  737. ])#m4_ifndef
  738. # _LT_LANG_DEFAULT_CONFIG
  739. # -----------------------
  740. m4_defun([_LT_LANG_DEFAULT_CONFIG],
  741. [AC_PROVIDE_IFELSE([AC_PROG_CXX],
  742. [LT_LANG(CXX)],
  743. [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
  744. AC_PROVIDE_IFELSE([AC_PROG_F77],
  745. [LT_LANG(F77)],
  746. [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
  747. AC_PROVIDE_IFELSE([AC_PROG_FC],
  748. [LT_LANG(FC)],
  749. [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
  750. dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
  751. dnl pulling things in needlessly.
  752. AC_PROVIDE_IFELSE([AC_PROG_GCJ],
  753. [LT_LANG(GCJ)],
  754. [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
  755. [LT_LANG(GCJ)],
  756. [AC_PROVIDE_IFELSE([LT_PROG_GCJ],
  757. [LT_LANG(GCJ)],
  758. [m4_ifdef([AC_PROG_GCJ],
  759. [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
  760. m4_ifdef([A][M_PROG_GCJ],
  761. [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
  762. m4_ifdef([LT_PROG_GCJ],
  763. [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
  764. AC_PROVIDE_IFELSE([AC_PROG_GO],
  765. [LT_LANG(GO)],
  766. [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])])
  767. AC_PROVIDE_IFELSE([LT_PROG_RC],
  768. [LT_LANG(RC)],
  769. [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
  770. ])# _LT_LANG_DEFAULT_CONFIG
  771. # Obsolete macros:
  772. AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
  773. AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
  774. AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
  775. AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
  776. AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)])
  777. dnl aclocal-1.4 backwards compatibility:
  778. dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
  779. dnl AC_DEFUN([AC_LIBTOOL_F77], [])
  780. dnl AC_DEFUN([AC_LIBTOOL_FC], [])
  781. dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
  782. dnl AC_DEFUN([AC_LIBTOOL_RC], [])
  783. # _LT_TAG_COMPILER
  784. # ----------------
  785. m4_defun([_LT_TAG_COMPILER],
  786. [AC_REQUIRE([AC_PROG_CC])dnl
  787. _LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
  788. _LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
  789. _LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
  790. _LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
  791. # If no C compiler was specified, use CC.
  792. LTCC=${LTCC-"$CC"}
  793. # If no C compiler flags were specified, use CFLAGS.
  794. LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
  795. # Allow CC to be a program name with arguments.
  796. compiler=$CC
  797. ])# _LT_TAG_COMPILER
  798. # _LT_COMPILER_BOILERPLATE
  799. # ------------------------
  800. # Check for compiler boilerplate output or warnings with
  801. # the simple compiler test code.
  802. m4_defun([_LT_COMPILER_BOILERPLATE],
  803. [m4_require([_LT_DECL_SED])dnl
  804. ac_outfile=conftest.$ac_objext
  805. echo "$lt_simple_compile_test_code" >conftest.$ac_ext
  806. eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
  807. _lt_compiler_boilerplate=`cat conftest.err`
  808. $RM conftest*
  809. ])# _LT_COMPILER_BOILERPLATE
  810. # _LT_LINKER_BOILERPLATE
  811. # ----------------------
  812. # Check for linker boilerplate output or warnings with
  813. # the simple link test code.
  814. m4_defun([_LT_LINKER_BOILERPLATE],
  815. [m4_require([_LT_DECL_SED])dnl
  816. ac_outfile=conftest.$ac_objext
  817. echo "$lt_simple_link_test_code" >conftest.$ac_ext
  818. eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
  819. _lt_linker_boilerplate=`cat conftest.err`
  820. $RM -r conftest*
  821. ])# _LT_LINKER_BOILERPLATE
  822. # _LT_REQUIRED_DARWIN_CHECKS
  823. # -------------------------
  824. m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
  825. case $host_os in
  826. rhapsody* | darwin*)
  827. AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
  828. AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
  829. AC_CHECK_TOOL([LIPO], [lipo], [:])
  830. AC_CHECK_TOOL([OTOOL], [otool], [:])
  831. AC_CHECK_TOOL([OTOOL64], [otool64], [:])
  832. _LT_DECL([], [DSYMUTIL], [1],
  833. [Tool to manipulate archived DWARF debug symbol files on Mac OS X])
  834. _LT_DECL([], [NMEDIT], [1],
  835. [Tool to change global to local symbols on Mac OS X])
  836. _LT_DECL([], [LIPO], [1],
  837. [Tool to manipulate fat objects and archives on Mac OS X])
  838. _LT_DECL([], [OTOOL], [1],
  839. [ldd/readelf like tool for Mach-O binaries on Mac OS X])
  840. _LT_DECL([], [OTOOL64], [1],
  841. [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4])
  842. AC_CACHE_CHECK([for -exported_symbols_list linker flag],
  843. [lt_cv_ld_exported_symbols_list],
  844. [lt_cv_ld_exported_symbols_list=no
  845. save_LDFLAGS=$LDFLAGS
  846. echo "_main" > conftest.sym
  847. LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
  848. AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
  849. [lt_cv_ld_exported_symbols_list=yes],
  850. [lt_cv_ld_exported_symbols_list=no])
  851. LDFLAGS=$save_LDFLAGS
  852. ])
  853. AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load],
  854. [lt_cv_ld_force_load=no
  855. cat > conftest.c << _LT_EOF
  856. int forced_loaded() { return 2;}
  857. _LT_EOF
  858. echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD
  859. $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD
  860. echo "$AR $AR_FLAGS libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
  861. $AR $AR_FLAGS libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
  862. echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD
  863. $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD
  864. cat > conftest.c << _LT_EOF
  865. int main() { return 0;}
  866. _LT_EOF
  867. echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD
  868. $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
  869. _lt_result=$?
  870. if test -s conftest.err && $GREP force_load conftest.err; then
  871. cat conftest.err >&AS_MESSAGE_LOG_FD
  872. elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then
  873. lt_cv_ld_force_load=yes
  874. else
  875. cat conftest.err >&AS_MESSAGE_LOG_FD
  876. fi
  877. rm -f conftest.err libconftest.a conftest conftest.c
  878. rm -rf conftest.dSYM
  879. ])
  880. case $host_os in
  881. rhapsody* | darwin1.[[012]])
  882. _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;;
  883. darwin1.*)
  884. _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
  885. darwin*)
  886. case $MACOSX_DEPLOYMENT_TARGET,$host in
  887. 10.[[012]],*|,*powerpc*-darwin[[5-8]]*)
  888. _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
  889. *)
  890. _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
  891. esac
  892. ;;
  893. esac
  894. if test yes = "$lt_cv_ld_exported_symbols_list"; then
  895. _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym'
  896. else
  897. _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib'
  898. fi
  899. if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then
  900. _lt_dsymutil='~$DSYMUTIL $lib || :'
  901. else
  902. _lt_dsymutil=
  903. fi
  904. ;;
  905. esac
  906. ])
  907. # _LT_DARWIN_LINKER_FEATURES([TAG])
  908. # ---------------------------------
  909. # Checks for linker and compiler features on darwin
  910. m4_defun([_LT_DARWIN_LINKER_FEATURES],
  911. [
  912. m4_require([_LT_REQUIRED_DARWIN_CHECKS])
  913. _LT_TAGVAR(archive_cmds_need_lc, $1)=no
  914. _LT_TAGVAR(hardcode_direct, $1)=no
  915. _LT_TAGVAR(hardcode_automatic, $1)=yes
  916. _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
  917. if test yes = "$lt_cv_ld_force_load"; then
  918. _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
  919. m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes],
  920. [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes])
  921. else
  922. _LT_TAGVAR(whole_archive_flag_spec, $1)=''
  923. fi
  924. _LT_TAGVAR(link_all_deplibs, $1)=yes
  925. _LT_TAGVAR(allow_undefined_flag, $1)=$_lt_dar_allow_undefined
  926. case $cc_basename in
  927. ifort*|nagfor*) _lt_dar_can_shared=yes ;;
  928. *) _lt_dar_can_shared=$GCC ;;
  929. esac
  930. if test yes = "$_lt_dar_can_shared"; then
  931. output_verbose_link_cmd=func_echo_all
  932. _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dsymutil"
  933. _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil"
  934. _LT_TAGVAR(archive_expsym_cmds, $1)="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_export_syms$_lt_dsymutil"
  935. _LT_TAGVAR(module_expsym_cmds, $1)="$SED -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil"
  936. else
  937. _LT_TAGVAR(ld_shlibs, $1)=no
  938. fi
  939. ])
  940. # _LT_SYS_MODULE_PATH_AIX([TAGNAME])
  941. # ----------------------------------
  942. # Links a minimal program and checks the executable
  943. # for the system default hardcoded library path. In most cases,
  944. # this is /usr/lib:/lib, but when the MPI compilers are used
  945. # the location of the communication and MPI libs are included too.
  946. # If we don't find anything, use the default library path according
  947. # to the aix ld manual.
  948. # Store the results from the different compilers for each TAGNAME.
  949. # Allow to override them for all tags through lt_cv_aix_libpath.
  950. m4_defun([_LT_SYS_MODULE_PATH_AIX],
  951. [m4_require([_LT_DECL_SED])dnl
  952. if test set = "${lt_cv_aix_libpath+set}"; then
  953. aix_libpath=$lt_cv_aix_libpath
  954. else
  955. AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])],
  956. [AC_LINK_IFELSE([AC_LANG_PROGRAM],[
  957. lt_aix_libpath_sed='[
  958. /Import File Strings/,/^$/ {
  959. /^0/ {
  960. s/^0 *\([^ ]*\) *$/\1/
  961. p
  962. }
  963. }]'
  964. _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
  965. # Check for a 64-bit object if we didn't find anything.
  966. if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
  967. _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
  968. fi],[])
  969. if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
  970. _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=/usr/lib:/lib
  971. fi
  972. ])
  973. aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])
  974. fi
  975. ])# _LT_SYS_MODULE_PATH_AIX
  976. # _LT_SHELL_INIT(ARG)
  977. # -------------------
  978. m4_define([_LT_SHELL_INIT],
  979. [m4_divert_text([M4SH-INIT], [$1
  980. ])])# _LT_SHELL_INIT
  981. # _LT_PROG_ECHO_BACKSLASH
  982. # -----------------------
  983. # Find how we can fake an echo command that does not interpret backslash.
  984. # In particular, with Autoconf 2.60 or later we add some code to the start
  985. # of the generated configure script that will find a shell with a builtin
  986. # printf (that we can use as an echo command).
  987. m4_defun([_LT_PROG_ECHO_BACKSLASH],
  988. [ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
  989. ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
  990. ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
  991. AC_MSG_CHECKING([how to print strings])
  992. # Test print first, because it will be a builtin if present.
  993. if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
  994. test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
  995. ECHO='print -r --'
  996. elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
  997. ECHO='printf %s\n'
  998. else
  999. # Use this function as a fallback that always works.
  1000. func_fallback_echo ()
  1001. {
  1002. eval 'cat <<_LTECHO_EOF
  1003. $[]1
  1004. _LTECHO_EOF'
  1005. }
  1006. ECHO='func_fallback_echo'
  1007. fi
  1008. # func_echo_all arg...
  1009. # Invoke $ECHO with all args, space-separated.
  1010. func_echo_all ()
  1011. {
  1012. $ECHO "$*"
  1013. }
  1014. case $ECHO in
  1015. printf*) AC_MSG_RESULT([printf]) ;;
  1016. print*) AC_MSG_RESULT([print -r]) ;;
  1017. *) AC_MSG_RESULT([cat]) ;;
  1018. esac
  1019. m4_ifdef([_AS_DETECT_SUGGESTED],
  1020. [_AS_DETECT_SUGGESTED([
  1021. test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || (
  1022. ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
  1023. ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
  1024. ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
  1025. PATH=/empty FPATH=/empty; export PATH FPATH
  1026. test "X`printf %s $ECHO`" = "X$ECHO" \
  1027. || test "X`print -r -- $ECHO`" = "X$ECHO" )])])
  1028. _LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
  1029. _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes])
  1030. ])# _LT_PROG_ECHO_BACKSLASH
  1031. # _LT_WITH_SYSROOT
  1032. # ----------------
  1033. AC_DEFUN([_LT_WITH_SYSROOT],
  1034. [m4_require([_LT_DECL_SED])dnl
  1035. AC_MSG_CHECKING([for sysroot])
  1036. AC_ARG_WITH([sysroot],
  1037. [AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@],
  1038. [Search for dependent libraries within DIR (or the compiler's sysroot
  1039. if not specified).])],
  1040. [], [with_sysroot=no])
  1041. dnl lt_sysroot will always be passed unquoted. We quote it here
  1042. dnl in case the user passed a directory name.
  1043. lt_sysroot=
  1044. case $with_sysroot in #(
  1045. yes)
  1046. if test yes = "$GCC"; then
  1047. lt_sysroot=`$CC --print-sysroot 2>/dev/null`
  1048. fi
  1049. ;; #(
  1050. /*)
  1051. lt_sysroot=`echo "$with_sysroot" | $SED -e "$sed_quote_subst"`
  1052. ;; #(
  1053. no|'')
  1054. ;; #(
  1055. *)
  1056. AC_MSG_RESULT([$with_sysroot])
  1057. AC_MSG_ERROR([The sysroot must be an absolute path.])
  1058. ;;
  1059. esac
  1060. AC_MSG_RESULT([${lt_sysroot:-no}])
  1061. _LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl
  1062. [dependent libraries, and where our libraries should be installed.])])
  1063. # _LT_ENABLE_LOCK
  1064. # ---------------
  1065. m4_defun([_LT_ENABLE_LOCK],
  1066. [AC_ARG_ENABLE([libtool-lock],
  1067. [AS_HELP_STRING([--disable-libtool-lock],
  1068. [avoid locking (might break parallel builds)])])
  1069. test no = "$enable_libtool_lock" || enable_libtool_lock=yes
  1070. # Some flags need to be propagated to the compiler or linker for good
  1071. # libtool support.
  1072. case $host in
  1073. ia64-*-hpux*)
  1074. # Find out what ABI is being produced by ac_compile, and set mode
  1075. # options accordingly.
  1076. echo 'int i;' > conftest.$ac_ext
  1077. if AC_TRY_EVAL(ac_compile); then
  1078. case `$FILECMD conftest.$ac_objext` in
  1079. *ELF-32*)
  1080. HPUX_IA64_MODE=32
  1081. ;;
  1082. *ELF-64*)
  1083. HPUX_IA64_MODE=64
  1084. ;;
  1085. esac
  1086. fi
  1087. rm -rf conftest*
  1088. ;;
  1089. *-*-irix6*)
  1090. # Find out what ABI is being produced by ac_compile, and set linker
  1091. # options accordingly.
  1092. echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
  1093. if AC_TRY_EVAL(ac_compile); then
  1094. if test yes = "$lt_cv_prog_gnu_ld"; then
  1095. case `$FILECMD conftest.$ac_objext` in
  1096. *32-bit*)
  1097. LD="${LD-ld} -melf32bsmip"
  1098. ;;
  1099. *N32*)
  1100. LD="${LD-ld} -melf32bmipn32"
  1101. ;;
  1102. *64-bit*)
  1103. LD="${LD-ld} -melf64bmip"
  1104. ;;
  1105. esac
  1106. else
  1107. case `$FILECMD conftest.$ac_objext` in
  1108. *32-bit*)
  1109. LD="${LD-ld} -32"
  1110. ;;
  1111. *N32*)
  1112. LD="${LD-ld} -n32"
  1113. ;;
  1114. *64-bit*)
  1115. LD="${LD-ld} -64"
  1116. ;;
  1117. esac
  1118. fi
  1119. fi
  1120. rm -rf conftest*
  1121. ;;
  1122. mips64*-*linux*)
  1123. # Find out what ABI is being produced by ac_compile, and set linker
  1124. # options accordingly.
  1125. echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
  1126. if AC_TRY_EVAL(ac_compile); then
  1127. emul=elf
  1128. case `$FILECMD conftest.$ac_objext` in
  1129. *32-bit*)
  1130. emul="${emul}32"
  1131. ;;
  1132. *64-bit*)
  1133. emul="${emul}64"
  1134. ;;
  1135. esac
  1136. case `$FILECMD conftest.$ac_objext` in
  1137. *MSB*)
  1138. emul="${emul}btsmip"
  1139. ;;
  1140. *LSB*)
  1141. emul="${emul}ltsmip"
  1142. ;;
  1143. esac
  1144. case `$FILECMD conftest.$ac_objext` in
  1145. *N32*)
  1146. emul="${emul}n32"
  1147. ;;
  1148. esac
  1149. LD="${LD-ld} -m $emul"
  1150. fi
  1151. rm -rf conftest*
  1152. ;;
  1153. x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
  1154. s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
  1155. # Find out what ABI is being produced by ac_compile, and set linker
  1156. # options accordingly. Note that the listed cases only cover the
  1157. # situations where additional linker options are needed (such as when
  1158. # doing 32-bit compilation for a host where ld defaults to 64-bit, or
  1159. # vice versa); the common cases where no linker options are needed do
  1160. # not appear in the list.
  1161. echo 'int i;' > conftest.$ac_ext
  1162. if AC_TRY_EVAL(ac_compile); then
  1163. case `$FILECMD conftest.o` in
  1164. *32-bit*)
  1165. case $host in
  1166. x86_64-*kfreebsd*-gnu)
  1167. LD="${LD-ld} -m elf_i386_fbsd"
  1168. ;;
  1169. x86_64-*linux*)
  1170. case `$FILECMD conftest.o` in
  1171. *x86-64*)
  1172. LD="${LD-ld} -m elf32_x86_64"
  1173. ;;
  1174. *)
  1175. LD="${LD-ld} -m elf_i386"
  1176. ;;
  1177. esac
  1178. ;;
  1179. powerpc64le-*linux*)
  1180. LD="${LD-ld} -m elf32lppclinux"
  1181. ;;
  1182. powerpc64-*linux*)
  1183. LD="${LD-ld} -m elf32ppclinux"
  1184. ;;
  1185. s390x-*linux*)
  1186. LD="${LD-ld} -m elf_s390"
  1187. ;;
  1188. sparc64-*linux*)
  1189. LD="${LD-ld} -m elf32_sparc"
  1190. ;;
  1191. esac
  1192. ;;
  1193. *64-bit*)
  1194. case $host in
  1195. x86_64-*kfreebsd*-gnu)
  1196. LD="${LD-ld} -m elf_x86_64_fbsd"
  1197. ;;
  1198. x86_64-*linux*)
  1199. LD="${LD-ld} -m elf_x86_64"
  1200. ;;
  1201. powerpcle-*linux*)
  1202. LD="${LD-ld} -m elf64lppc"
  1203. ;;
  1204. powerpc-*linux*)
  1205. LD="${LD-ld} -m elf64ppc"
  1206. ;;
  1207. s390*-*linux*|s390*-*tpf*)
  1208. LD="${LD-ld} -m elf64_s390"
  1209. ;;
  1210. sparc*-*linux*)
  1211. LD="${LD-ld} -m elf64_sparc"
  1212. ;;
  1213. esac
  1214. ;;
  1215. esac
  1216. fi
  1217. rm -rf conftest*
  1218. ;;
  1219. *-*-sco3.2v5*)
  1220. # On SCO OpenServer 5, we need -belf to get full-featured binaries.
  1221. SAVE_CFLAGS=$CFLAGS
  1222. CFLAGS="$CFLAGS -belf"
  1223. AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
  1224. [AC_LANG_PUSH(C)
  1225. AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
  1226. AC_LANG_POP])
  1227. if test yes != "$lt_cv_cc_needs_belf"; then
  1228. # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
  1229. CFLAGS=$SAVE_CFLAGS
  1230. fi
  1231. ;;
  1232. *-*solaris*)
  1233. # Find out what ABI is being produced by ac_compile, and set linker
  1234. # options accordingly.
  1235. echo 'int i;' > conftest.$ac_ext
  1236. if AC_TRY_EVAL(ac_compile); then
  1237. case `$FILECMD conftest.o` in
  1238. *64-bit*)
  1239. case $lt_cv_prog_gnu_ld in
  1240. yes*)
  1241. case $host in
  1242. i?86-*-solaris*|x86_64-*-solaris*)
  1243. LD="${LD-ld} -m elf_x86_64"
  1244. ;;
  1245. sparc*-*-solaris*)
  1246. LD="${LD-ld} -m elf64_sparc"
  1247. ;;
  1248. esac
  1249. # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
  1250. if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
  1251. LD=${LD-ld}_sol2
  1252. fi
  1253. ;;
  1254. *)
  1255. if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
  1256. LD="${LD-ld} -64"
  1257. fi
  1258. ;;
  1259. esac
  1260. ;;
  1261. esac
  1262. fi
  1263. rm -rf conftest*
  1264. ;;
  1265. esac
  1266. need_locks=$enable_libtool_lock
  1267. ])# _LT_ENABLE_LOCK
  1268. # _LT_PROG_AR
  1269. # -----------
  1270. m4_defun([_LT_PROG_AR],
  1271. [AC_CHECK_TOOLS(AR, [ar], false)
  1272. : ${AR=ar}
  1273. _LT_DECL([], [AR], [1], [The archiver])
  1274. # Use ARFLAGS variable as AR's operation code to sync the variable naming with
  1275. # Automake. If both AR_FLAGS and ARFLAGS are specified, AR_FLAGS should have
  1276. # higher priority because thats what people were doing historically (setting
  1277. # ARFLAGS for automake and AR_FLAGS for libtool). FIXME: Make the AR_FLAGS
  1278. # variable obsoleted/removed.
  1279. test ${AR_FLAGS+y} || AR_FLAGS=${ARFLAGS-cr}
  1280. lt_ar_flags=$AR_FLAGS
  1281. _LT_DECL([], [lt_ar_flags], [0], [Flags to create an archive (by configure)])
  1282. # Make AR_FLAGS overridable by 'make ARFLAGS='. Don't try to run-time override
  1283. # by AR_FLAGS because that was never working and AR_FLAGS is about to die.
  1284. _LT_DECL([], [AR_FLAGS], [\@S|@{ARFLAGS-"\@S|@lt_ar_flags"}],
  1285. [Flags to create an archive])
  1286. AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file],
  1287. [lt_cv_ar_at_file=no
  1288. AC_COMPILE_IFELSE([AC_LANG_PROGRAM],
  1289. [echo conftest.$ac_objext > conftest.lst
  1290. lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD'
  1291. AC_TRY_EVAL([lt_ar_try])
  1292. if test 0 -eq "$ac_status"; then
  1293. # Ensure the archiver fails upon bogus file names.
  1294. rm -f conftest.$ac_objext libconftest.a
  1295. AC_TRY_EVAL([lt_ar_try])
  1296. if test 0 -ne "$ac_status"; then
  1297. lt_cv_ar_at_file=@
  1298. fi
  1299. fi
  1300. rm -f conftest.* libconftest.a
  1301. ])
  1302. ])
  1303. if test no = "$lt_cv_ar_at_file"; then
  1304. archiver_list_spec=
  1305. else
  1306. archiver_list_spec=$lt_cv_ar_at_file
  1307. fi
  1308. _LT_DECL([], [archiver_list_spec], [1],
  1309. [How to feed a file listing to the archiver])
  1310. ])# _LT_PROG_AR
  1311. # _LT_CMD_OLD_ARCHIVE
  1312. # -------------------
  1313. m4_defun([_LT_CMD_OLD_ARCHIVE],
  1314. [_LT_PROG_AR
  1315. AC_CHECK_TOOL(STRIP, strip, :)
  1316. test -z "$STRIP" && STRIP=:
  1317. _LT_DECL([], [STRIP], [1], [A symbol stripping program])
  1318. AC_CHECK_TOOL(RANLIB, ranlib, :)
  1319. test -z "$RANLIB" && RANLIB=:
  1320. _LT_DECL([], [RANLIB], [1],
  1321. [Commands used to install an old-style archive])
  1322. # Determine commands to create old-style static archives.
  1323. old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
  1324. old_postinstall_cmds='chmod 644 $oldlib'
  1325. old_postuninstall_cmds=
  1326. if test -n "$RANLIB"; then
  1327. case $host_os in
  1328. bitrig* | openbsd*)
  1329. old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
  1330. ;;
  1331. *)
  1332. old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
  1333. ;;
  1334. esac
  1335. old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
  1336. fi
  1337. case $host_os in
  1338. darwin*)
  1339. lock_old_archive_extraction=yes ;;
  1340. *)
  1341. lock_old_archive_extraction=no ;;
  1342. esac
  1343. _LT_DECL([], [old_postinstall_cmds], [2])
  1344. _LT_DECL([], [old_postuninstall_cmds], [2])
  1345. _LT_TAGDECL([], [old_archive_cmds], [2],
  1346. [Commands used to build an old-style archive])
  1347. _LT_DECL([], [lock_old_archive_extraction], [0],
  1348. [Whether to use a lock for old archive extraction])
  1349. ])# _LT_CMD_OLD_ARCHIVE
  1350. # _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
  1351. # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
  1352. # ----------------------------------------------------------------
  1353. # Check whether the given compiler option works
  1354. AC_DEFUN([_LT_COMPILER_OPTION],
  1355. [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
  1356. m4_require([_LT_DECL_SED])dnl
  1357. AC_CACHE_CHECK([$1], [$2],
  1358. [$2=no
  1359. m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
  1360. echo "$lt_simple_compile_test_code" > conftest.$ac_ext
  1361. lt_compiler_flag="$3" ## exclude from sc_useless_quotes_in_assignment
  1362. # Insert the option either (1) after the last *FLAGS variable, or
  1363. # (2) before a word containing "conftest.", or (3) at the end.
  1364. # Note that $ac_compile itself does not contain backslashes and begins
  1365. # with a dollar sign (not a hyphen), so the echo should work correctly.
  1366. # The option is referenced via a variable to avoid confusing sed.
  1367. lt_compile=`echo "$ac_compile" | $SED \
  1368. -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
  1369. -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
  1370. -e 's:$: $lt_compiler_flag:'`
  1371. (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
  1372. (eval "$lt_compile" 2>conftest.err)
  1373. ac_status=$?
  1374. cat conftest.err >&AS_MESSAGE_LOG_FD
  1375. echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
  1376. if (exit $ac_status) && test -s "$ac_outfile"; then
  1377. # The compiler can only warn and ignore the option if not recognized
  1378. # So say no if there are warnings other than the usual output.
  1379. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
  1380. $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
  1381. if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
  1382. $2=yes
  1383. fi
  1384. fi
  1385. $RM conftest*
  1386. ])
  1387. if test yes = "[$]$2"; then
  1388. m4_if([$5], , :, [$5])
  1389. else
  1390. m4_if([$6], , :, [$6])
  1391. fi
  1392. ])# _LT_COMPILER_OPTION
  1393. # Old name:
  1394. AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
  1395. dnl aclocal-1.4 backwards compatibility:
  1396. dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
  1397. # _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
  1398. # [ACTION-SUCCESS], [ACTION-FAILURE])
  1399. # ----------------------------------------------------
  1400. # Check whether the given linker option works
  1401. AC_DEFUN([_LT_LINKER_OPTION],
  1402. [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
  1403. m4_require([_LT_DECL_SED])dnl
  1404. AC_CACHE_CHECK([$1], [$2],
  1405. [$2=no
  1406. save_LDFLAGS=$LDFLAGS
  1407. LDFLAGS="$LDFLAGS $3"
  1408. echo "$lt_simple_link_test_code" > conftest.$ac_ext
  1409. if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
  1410. # The linker can only warn and ignore the option if not recognized
  1411. # So say no if there are warnings
  1412. if test -s conftest.err; then
  1413. # Append any errors to the config.log.
  1414. cat conftest.err 1>&AS_MESSAGE_LOG_FD
  1415. $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
  1416. $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
  1417. if diff conftest.exp conftest.er2 >/dev/null; then
  1418. $2=yes
  1419. fi
  1420. else
  1421. $2=yes
  1422. fi
  1423. fi
  1424. $RM -r conftest*
  1425. LDFLAGS=$save_LDFLAGS
  1426. ])
  1427. if test yes = "[$]$2"; then
  1428. m4_if([$4], , :, [$4])
  1429. else
  1430. m4_if([$5], , :, [$5])
  1431. fi
  1432. ])# _LT_LINKER_OPTION
  1433. # Old name:
  1434. AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
  1435. dnl aclocal-1.4 backwards compatibility:
  1436. dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
  1437. # LT_CMD_MAX_LEN
  1438. #---------------
  1439. AC_DEFUN([LT_CMD_MAX_LEN],
  1440. [AC_REQUIRE([AC_CANONICAL_HOST])dnl
  1441. # find the maximum length of command line arguments
  1442. AC_MSG_CHECKING([the maximum length of command line arguments])
  1443. AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
  1444. i=0
  1445. teststring=ABCD
  1446. case $build_os in
  1447. msdosdjgpp*)
  1448. # On DJGPP, this test can blow up pretty badly due to problems in libc
  1449. # (any single argument exceeding 2000 bytes causes a buffer overrun
  1450. # during glob expansion). Even if it were fixed, the result of this
  1451. # check would be larger than it should be.
  1452. lt_cv_sys_max_cmd_len=12288; # 12K is about right
  1453. ;;
  1454. gnu*)
  1455. # Under GNU Hurd, this test is not required because there is
  1456. # no limit to the length of command line arguments.
  1457. # Libtool will interpret -1 as no limit whatsoever
  1458. lt_cv_sys_max_cmd_len=-1;
  1459. ;;
  1460. cygwin* | mingw* | cegcc*)
  1461. # On Win9x/ME, this test blows up -- it succeeds, but takes
  1462. # about 5 minutes as the teststring grows exponentially.
  1463. # Worse, since 9x/ME are not pre-emptively multitasking,
  1464. # you end up with a "frozen" computer, even though with patience
  1465. # the test eventually succeeds (with a max line length of 256k).
  1466. # Instead, let's just punt: use the minimum linelength reported by
  1467. # all of the supported platforms: 8192 (on NT/2K/XP).
  1468. lt_cv_sys_max_cmd_len=8192;
  1469. ;;
  1470. mint*)
  1471. # On MiNT this can take a long time and run out of memory.
  1472. lt_cv_sys_max_cmd_len=8192;
  1473. ;;
  1474. amigaos*)
  1475. # On AmigaOS with pdksh, this test takes hours, literally.
  1476. # So we just punt and use a minimum line length of 8192.
  1477. lt_cv_sys_max_cmd_len=8192;
  1478. ;;
  1479. bitrig* | darwin* | dragonfly* | freebsd* | midnightbsd* | netbsd* | openbsd*)
  1480. # This has been around since 386BSD, at least. Likely further.
  1481. if test -x /sbin/sysctl; then
  1482. lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
  1483. elif test -x /usr/sbin/sysctl; then
  1484. lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
  1485. else
  1486. lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
  1487. fi
  1488. # And add a safety zone
  1489. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
  1490. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
  1491. ;;
  1492. interix*)
  1493. # We know the value 262144 and hardcode it with a safety zone (like BSD)
  1494. lt_cv_sys_max_cmd_len=196608
  1495. ;;
  1496. os2*)
  1497. # The test takes a long time on OS/2.
  1498. lt_cv_sys_max_cmd_len=8192
  1499. ;;
  1500. osf*)
  1501. # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
  1502. # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
  1503. # nice to cause kernel panics so lets avoid the loop below.
  1504. # First set a reasonable default.
  1505. lt_cv_sys_max_cmd_len=16384
  1506. #
  1507. if test -x /sbin/sysconfig; then
  1508. case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
  1509. *1*) lt_cv_sys_max_cmd_len=-1 ;;
  1510. esac
  1511. fi
  1512. ;;
  1513. sco3.2v5*)
  1514. lt_cv_sys_max_cmd_len=102400
  1515. ;;
  1516. sysv5* | sco5v6* | sysv4.2uw2*)
  1517. kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
  1518. if test -n "$kargmax"; then
  1519. lt_cv_sys_max_cmd_len=`echo $kargmax | $SED 's/.*[[ ]]//'`
  1520. else
  1521. lt_cv_sys_max_cmd_len=32768
  1522. fi
  1523. ;;
  1524. *)
  1525. lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
  1526. if test -n "$lt_cv_sys_max_cmd_len" && \
  1527. test undefined != "$lt_cv_sys_max_cmd_len"; then
  1528. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
  1529. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
  1530. else
  1531. # Make teststring a little bigger before we do anything with it.
  1532. # a 1K string should be a reasonable start.
  1533. for i in 1 2 3 4 5 6 7 8; do
  1534. teststring=$teststring$teststring
  1535. done
  1536. SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
  1537. # If test is not a shell built-in, we'll probably end up computing a
  1538. # maximum length that is only half of the actual maximum length, but
  1539. # we can't tell.
  1540. while { test X`env echo "$teststring$teststring" 2>/dev/null` \
  1541. = "X$teststring$teststring"; } >/dev/null 2>&1 &&
  1542. test 17 != "$i" # 1/2 MB should be enough
  1543. do
  1544. i=`expr $i + 1`
  1545. teststring=$teststring$teststring
  1546. done
  1547. # Only check the string length outside the loop.
  1548. lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
  1549. teststring=
  1550. # Add a significant safety factor because C++ compilers can tack on
  1551. # massive amounts of additional arguments before passing them to the
  1552. # linker. It appears as though 1/2 is a usable value.
  1553. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
  1554. fi
  1555. ;;
  1556. esac
  1557. ])
  1558. if test -n "$lt_cv_sys_max_cmd_len"; then
  1559. AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
  1560. else
  1561. AC_MSG_RESULT(none)
  1562. fi
  1563. max_cmd_len=$lt_cv_sys_max_cmd_len
  1564. _LT_DECL([], [max_cmd_len], [0],
  1565. [What is the maximum length of a command?])
  1566. ])# LT_CMD_MAX_LEN
  1567. # Old name:
  1568. AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
  1569. dnl aclocal-1.4 backwards compatibility:
  1570. dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
  1571. # _LT_HEADER_DLFCN
  1572. # ----------------
  1573. m4_defun([_LT_HEADER_DLFCN],
  1574. [AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
  1575. ])# _LT_HEADER_DLFCN
  1576. # _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
  1577. # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
  1578. # ----------------------------------------------------------------
  1579. m4_defun([_LT_TRY_DLOPEN_SELF],
  1580. [m4_require([_LT_HEADER_DLFCN])dnl
  1581. if test yes = "$cross_compiling"; then :
  1582. [$4]
  1583. else
  1584. lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
  1585. lt_status=$lt_dlunknown
  1586. cat > conftest.$ac_ext <<_LT_EOF
  1587. [#line $LINENO "configure"
  1588. #include "confdefs.h"
  1589. #if HAVE_DLFCN_H
  1590. #include <dlfcn.h>
  1591. #endif
  1592. #include <stdio.h>
  1593. #ifdef RTLD_GLOBAL
  1594. # define LT_DLGLOBAL RTLD_GLOBAL
  1595. #else
  1596. # ifdef DL_GLOBAL
  1597. # define LT_DLGLOBAL DL_GLOBAL
  1598. # else
  1599. # define LT_DLGLOBAL 0
  1600. # endif
  1601. #endif
  1602. /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
  1603. find out it does not work in some platform. */
  1604. #ifndef LT_DLLAZY_OR_NOW
  1605. # ifdef RTLD_LAZY
  1606. # define LT_DLLAZY_OR_NOW RTLD_LAZY
  1607. # else
  1608. # ifdef DL_LAZY
  1609. # define LT_DLLAZY_OR_NOW DL_LAZY
  1610. # else
  1611. # ifdef RTLD_NOW
  1612. # define LT_DLLAZY_OR_NOW RTLD_NOW
  1613. # else
  1614. # ifdef DL_NOW
  1615. # define LT_DLLAZY_OR_NOW DL_NOW
  1616. # else
  1617. # define LT_DLLAZY_OR_NOW 0
  1618. # endif
  1619. # endif
  1620. # endif
  1621. # endif
  1622. #endif
  1623. /* When -fvisibility=hidden is used, assume the code has been annotated
  1624. correspondingly for the symbols needed. */
  1625. #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
  1626. int fnord () __attribute__((visibility("default")));
  1627. #endif
  1628. int fnord () { return 42; }
  1629. int main ()
  1630. {
  1631. void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
  1632. int status = $lt_dlunknown;
  1633. if (self)
  1634. {
  1635. if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
  1636. else
  1637. {
  1638. if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
  1639. else puts (dlerror ());
  1640. }
  1641. /* dlclose (self); */
  1642. }
  1643. else
  1644. puts (dlerror ());
  1645. return status;
  1646. }]
  1647. _LT_EOF
  1648. if AC_TRY_EVAL(ac_link) && test -s "conftest$ac_exeext" 2>/dev/null; then
  1649. (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
  1650. lt_status=$?
  1651. case x$lt_status in
  1652. x$lt_dlno_uscore) $1 ;;
  1653. x$lt_dlneed_uscore) $2 ;;
  1654. x$lt_dlunknown|x*) $3 ;;
  1655. esac
  1656. else :
  1657. # compilation failed
  1658. $3
  1659. fi
  1660. fi
  1661. rm -fr conftest*
  1662. ])# _LT_TRY_DLOPEN_SELF
  1663. # LT_SYS_DLOPEN_SELF
  1664. # ------------------
  1665. AC_DEFUN([LT_SYS_DLOPEN_SELF],
  1666. [m4_require([_LT_HEADER_DLFCN])dnl
  1667. if test yes != "$enable_dlopen"; then
  1668. enable_dlopen=unknown
  1669. enable_dlopen_self=unknown
  1670. enable_dlopen_self_static=unknown
  1671. else
  1672. lt_cv_dlopen=no
  1673. lt_cv_dlopen_libs=
  1674. case $host_os in
  1675. beos*)
  1676. lt_cv_dlopen=load_add_on
  1677. lt_cv_dlopen_libs=
  1678. lt_cv_dlopen_self=yes
  1679. ;;
  1680. mingw* | pw32* | cegcc*)
  1681. lt_cv_dlopen=LoadLibrary
  1682. lt_cv_dlopen_libs=
  1683. ;;
  1684. cygwin*)
  1685. lt_cv_dlopen=dlopen
  1686. lt_cv_dlopen_libs=
  1687. ;;
  1688. darwin*)
  1689. # if libdl is installed we need to link against it
  1690. AC_CHECK_LIB([dl], [dlopen],
  1691. [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],[
  1692. lt_cv_dlopen=dyld
  1693. lt_cv_dlopen_libs=
  1694. lt_cv_dlopen_self=yes
  1695. ])
  1696. ;;
  1697. tpf*)
  1698. # Don't try to run any link tests for TPF. We know it's impossible
  1699. # because TPF is a cross-compiler, and we know how we open DSOs.
  1700. lt_cv_dlopen=dlopen
  1701. lt_cv_dlopen_libs=
  1702. lt_cv_dlopen_self=no
  1703. ;;
  1704. *)
  1705. AC_CHECK_FUNC([shl_load],
  1706. [lt_cv_dlopen=shl_load],
  1707. [AC_CHECK_LIB([dld], [shl_load],
  1708. [lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld],
  1709. [AC_CHECK_FUNC([dlopen],
  1710. [lt_cv_dlopen=dlopen],
  1711. [AC_CHECK_LIB([dl], [dlopen],
  1712. [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],
  1713. [AC_CHECK_LIB([svld], [dlopen],
  1714. [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld],
  1715. [AC_CHECK_LIB([dld], [dld_link],
  1716. [lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld])
  1717. ])
  1718. ])
  1719. ])
  1720. ])
  1721. ])
  1722. ;;
  1723. esac
  1724. if test no = "$lt_cv_dlopen"; then
  1725. enable_dlopen=no
  1726. else
  1727. enable_dlopen=yes
  1728. fi
  1729. case $lt_cv_dlopen in
  1730. dlopen)
  1731. save_CPPFLAGS=$CPPFLAGS
  1732. test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
  1733. save_LDFLAGS=$LDFLAGS
  1734. wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
  1735. save_LIBS=$LIBS
  1736. LIBS="$lt_cv_dlopen_libs $LIBS"
  1737. AC_CACHE_CHECK([whether a program can dlopen itself],
  1738. lt_cv_dlopen_self, [dnl
  1739. _LT_TRY_DLOPEN_SELF(
  1740. lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
  1741. lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
  1742. ])
  1743. if test yes = "$lt_cv_dlopen_self"; then
  1744. wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
  1745. AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
  1746. lt_cv_dlopen_self_static, [dnl
  1747. _LT_TRY_DLOPEN_SELF(
  1748. lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
  1749. lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
  1750. ])
  1751. fi
  1752. CPPFLAGS=$save_CPPFLAGS
  1753. LDFLAGS=$save_LDFLAGS
  1754. LIBS=$save_LIBS
  1755. ;;
  1756. esac
  1757. case $lt_cv_dlopen_self in
  1758. yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
  1759. *) enable_dlopen_self=unknown ;;
  1760. esac
  1761. case $lt_cv_dlopen_self_static in
  1762. yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
  1763. *) enable_dlopen_self_static=unknown ;;
  1764. esac
  1765. fi
  1766. _LT_DECL([dlopen_support], [enable_dlopen], [0],
  1767. [Whether dlopen is supported])
  1768. _LT_DECL([dlopen_self], [enable_dlopen_self], [0],
  1769. [Whether dlopen of programs is supported])
  1770. _LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
  1771. [Whether dlopen of statically linked programs is supported])
  1772. ])# LT_SYS_DLOPEN_SELF
  1773. # Old name:
  1774. AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
  1775. dnl aclocal-1.4 backwards compatibility:
  1776. dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
  1777. # _LT_COMPILER_C_O([TAGNAME])
  1778. # ---------------------------
  1779. # Check to see if options -c and -o are simultaneously supported by compiler.
  1780. # This macro does not hard code the compiler like AC_PROG_CC_C_O.
  1781. m4_defun([_LT_COMPILER_C_O],
  1782. [m4_require([_LT_DECL_SED])dnl
  1783. m4_require([_LT_FILEUTILS_DEFAULTS])dnl
  1784. m4_require([_LT_TAG_COMPILER])dnl
  1785. AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
  1786. [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
  1787. [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
  1788. $RM -r conftest 2>/dev/null
  1789. mkdir conftest
  1790. cd conftest
  1791. mkdir out
  1792. echo "$lt_simple_compile_test_code" > conftest.$ac_ext
  1793. lt_compiler_flag="-o out/conftest2.$ac_objext"
  1794. # Insert the option either (1) after the last *FLAGS variable, or
  1795. # (2) before a word containing "conftest.", or (3) at the end.
  1796. # Note that $ac_compile itself does not contain backslashes and begins
  1797. # with a dollar sign (not a hyphen), so the echo should work correctly.
  1798. lt_compile=`echo "$ac_compile" | $SED \
  1799. -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
  1800. -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
  1801. -e 's:$: $lt_compiler_flag:'`
  1802. (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
  1803. (eval "$lt_compile" 2>out/conftest.err)
  1804. ac_status=$?
  1805. cat out/conftest.err >&AS_MESSAGE_LOG_FD
  1806. echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
  1807. if (exit $ac_status) && test -s out/conftest2.$ac_objext
  1808. then
  1809. # The compiler can only warn and ignore the option if not recognized
  1810. # So say no if there are warnings
  1811. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
  1812. $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
  1813. if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
  1814. _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
  1815. fi
  1816. fi
  1817. chmod u+w . 2>&AS_MESSAGE_LOG_FD
  1818. $RM conftest*
  1819. # SGI C++ compiler will create directory out/ii_files/ for
  1820. # template instantiation
  1821. test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
  1822. $RM out/* && rmdir out
  1823. cd ..
  1824. $RM -r conftest
  1825. $RM conftest*
  1826. ])
  1827. _LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
  1828. [Does compiler simultaneously support -c and -o options?])
  1829. ])# _LT_COMPILER_C_O
  1830. # _LT_COMPILER_FILE_LOCKS([TAGNAME])
  1831. # ----------------------------------
  1832. # Check to see if we can do hard links to lock some files if needed
  1833. m4_defun([_LT_COMPILER_FILE_LOCKS],
  1834. [m4_require([_LT_ENABLE_LOCK])dnl
  1835. m4_require([_LT_FILEUTILS_DEFAULTS])dnl
  1836. _LT_COMPILER_C_O([$1])
  1837. hard_links=nottested
  1838. if test no = "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" && test no != "$need_locks"; then
  1839. # do not overwrite the value of need_locks provided by the user
  1840. AC_MSG_CHECKING([if we can lock with hard links])
  1841. hard_links=yes
  1842. $RM conftest*
  1843. ln conftest.a conftest.b 2>/dev/null && hard_links=no
  1844. touch conftest.a
  1845. ln conftest.a conftest.b 2>&5 || hard_links=no
  1846. ln conftest.a conftest.b 2>/dev/null && hard_links=no
  1847. AC_MSG_RESULT([$hard_links])
  1848. if test no = "$hard_links"; then
  1849. AC_MSG_WARN(['$CC' does not support '-c -o', so 'make -j' may be unsafe])
  1850. need_locks=warn
  1851. fi
  1852. else
  1853. need_locks=no
  1854. fi
  1855. _LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
  1856. ])# _LT_COMPILER_FILE_LOCKS
  1857. # _LT_CHECK_OBJDIR
  1858. # ----------------
  1859. m4_defun([_LT_CHECK_OBJDIR],
  1860. [AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
  1861. [rm -f .libs 2>/dev/null
  1862. mkdir .libs 2>/dev/null
  1863. if test -d .libs; then
  1864. lt_cv_objdir=.libs
  1865. else
  1866. # MS-DOS does not allow filenames that begin with a dot.
  1867. lt_cv_objdir=_libs
  1868. fi
  1869. rmdir .libs 2>/dev/null])
  1870. objdir=$lt_cv_objdir
  1871. _LT_DECL([], [objdir], [0],
  1872. [The name of the directory that contains temporary libtool files])dnl
  1873. m4_pattern_allow([LT_OBJDIR])dnl
  1874. AC_DEFINE_UNQUOTED([LT_OBJDIR], "$lt_cv_objdir/",
  1875. [Define to the sub-directory where libtool stores uninstalled libraries.])
  1876. ])# _LT_CHECK_OBJDIR
  1877. # _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
  1878. # --------------------------------------
  1879. # Check hardcoding attributes.
  1880. m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
  1881. [AC_MSG_CHECKING([how to hardcode library paths into programs])
  1882. _LT_TAGVAR(hardcode_action, $1)=
  1883. if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
  1884. test -n "$_LT_TAGVAR(runpath_var, $1)" ||
  1885. test yes = "$_LT_TAGVAR(hardcode_automatic, $1)"; then
  1886. # We can hardcode non-existent directories.
  1887. if test no != "$_LT_TAGVAR(hardcode_direct, $1)" &&
  1888. # If the only mechanism to avoid hardcoding is shlibpath_var, we
  1889. # have to relink, otherwise we might link with an installed library
  1890. # when we should be linking with a yet-to-be-installed one
  1891. ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" &&
  1892. test no != "$_LT_TAGVAR(hardcode_minus_L, $1)"; then
  1893. # Linking always hardcodes the temporary library directory.
  1894. _LT_TAGVAR(hardcode_action, $1)=relink
  1895. else
  1896. # We can link without hardcoding, and we can hardcode nonexisting dirs.
  1897. _LT_TAGVAR(hardcode_action, $1)=immediate
  1898. fi
  1899. else
  1900. # We cannot hardcode anything, or else we can only hardcode existing
  1901. # directories.
  1902. _LT_TAGVAR(hardcode_action, $1)=unsupported
  1903. fi
  1904. AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
  1905. if test relink = "$_LT_TAGVAR(hardcode_action, $1)" ||
  1906. test yes = "$_LT_TAGVAR(inherit_rpath, $1)"; then
  1907. # Fast installation is not supported
  1908. enable_fast_install=no
  1909. elif test yes = "$shlibpath_overrides_runpath" ||
  1910. test no = "$enable_shared"; then
  1911. # Fast installation is not necessary
  1912. enable_fast_install=needless
  1913. fi
  1914. _LT_TAGDECL([], [hardcode_action], [0],
  1915. [How to hardcode a shared library path into an executable])
  1916. ])# _LT_LINKER_HARDCODE_LIBPATH
  1917. # _LT_CMD_STRIPLIB
  1918. # ----------------
  1919. m4_defun([_LT_CMD_STRIPLIB],
  1920. [m4_require([_LT_DECL_EGREP])
  1921. striplib=
  1922. old_striplib=
  1923. AC_MSG_CHECKING([whether stripping libraries is possible])
  1924. if test -z "$STRIP"; then
  1925. AC_MSG_RESULT([no])
  1926. else
  1927. if $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
  1928. old_striplib="$STRIP --strip-debug"
  1929. striplib="$STRIP --strip-unneeded"
  1930. AC_MSG_RESULT([yes])
  1931. else
  1932. case $host_os in
  1933. darwin*)
  1934. # FIXME - insert some real tests, host_os isn't really good enough
  1935. striplib="$STRIP -x"
  1936. old_striplib="$STRIP -S"
  1937. AC_MSG_RESULT([yes])
  1938. ;;
  1939. freebsd*)
  1940. if $STRIP -V 2>&1 | $GREP "elftoolchain" >/dev/null; then
  1941. old_striplib="$STRIP --strip-debug"
  1942. striplib="$STRIP --strip-unneeded"
  1943. AC_MSG_RESULT([yes])
  1944. else
  1945. AC_MSG_RESULT([no])
  1946. fi
  1947. ;;
  1948. *)
  1949. AC_MSG_RESULT([no])
  1950. ;;
  1951. esac
  1952. fi
  1953. fi
  1954. _LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
  1955. _LT_DECL([], [striplib], [1])
  1956. ])# _LT_CMD_STRIPLIB
  1957. # _LT_PREPARE_MUNGE_PATH_LIST
  1958. # ---------------------------
  1959. # Make sure func_munge_path_list() is defined correctly.
  1960. m4_defun([_LT_PREPARE_MUNGE_PATH_LIST],
  1961. [[# func_munge_path_list VARIABLE PATH
  1962. # -----------------------------------
  1963. # VARIABLE is name of variable containing _space_ separated list of
  1964. # directories to be munged by the contents of PATH, which is string
  1965. # having a format:
  1966. # "DIR[:DIR]:"
  1967. # string "DIR[ DIR]" will be prepended to VARIABLE
  1968. # ":DIR[:DIR]"
  1969. # string "DIR[ DIR]" will be appended to VARIABLE
  1970. # "DIRP[:DIRP]::[DIRA:]DIRA"
  1971. # string "DIRP[ DIRP]" will be prepended to VARIABLE and string
  1972. # "DIRA[ DIRA]" will be appended to VARIABLE
  1973. # "DIR[:DIR]"
  1974. # VARIABLE will be replaced by "DIR[ DIR]"
  1975. func_munge_path_list ()
  1976. {
  1977. case x@S|@2 in
  1978. x)
  1979. ;;
  1980. *:)
  1981. eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'` \@S|@@S|@1\"
  1982. ;;
  1983. x:*)
  1984. eval @S|@1=\"\@S|@@S|@1 `$ECHO @S|@2 | $SED 's/:/ /g'`\"
  1985. ;;
  1986. *::*)
  1987. eval @S|@1=\"\@S|@@S|@1\ `$ECHO @S|@2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
  1988. eval @S|@1=\"`$ECHO @S|@2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \@S|@@S|@1\"
  1989. ;;
  1990. *)
  1991. eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'`\"
  1992. ;;
  1993. esac
  1994. }
  1995. ]])# _LT_PREPARE_PATH_LIST
  1996. # _LT_SYS_DYNAMIC_LINKER([TAG])
  1997. # -----------------------------
  1998. # PORTME Fill in your ld.so characteristics
  1999. m4_defun([_LT_SYS_DYNAMIC_LINKER],
  2000. [AC_REQUIRE([AC_CANONICAL_HOST])dnl
  2001. m4_require([_LT_DECL_EGREP])dnl
  2002. m4_require([_LT_FILEUTILS_DEFAULTS])dnl
  2003. m4_require([_LT_DECL_OBJDUMP])dnl
  2004. m4_require([_LT_DECL_SED])dnl
  2005. m4_require([_LT_CHECK_SHELL_FEATURES])dnl
  2006. m4_require([_LT_PREPARE_MUNGE_PATH_LIST])dnl
  2007. AC_MSG_CHECKING([dynamic linker characteristics])
  2008. m4_if([$1],
  2009. [], [
  2010. if test yes = "$GCC"; then
  2011. case $host_os in
  2012. darwin*) lt_awk_arg='/^libraries:/,/LR/' ;;
  2013. *) lt_awk_arg='/^libraries:/' ;;
  2014. esac
  2015. case $host_os in
  2016. mingw* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;;
  2017. *) lt_sed_strip_eq='s|=/|/|g' ;;
  2018. esac
  2019. lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
  2020. case $lt_search_path_spec in
  2021. *\;*)
  2022. # if the path contains ";" then we assume it to be the separator
  2023. # otherwise default to the standard path separator (i.e. ":") - it is
  2024. # assumed that no part of a normal pathname contains ";" but that should
  2025. # okay in the real world where ";" in dirpaths is itself problematic.
  2026. lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
  2027. ;;
  2028. *)
  2029. lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
  2030. ;;
  2031. esac
  2032. # Ok, now we have the path, separated by spaces, we can step through it
  2033. # and add multilib dir if necessary...
  2034. lt_tmp_lt_search_path_spec=
  2035. lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
  2036. # ...but if some path component already ends with the multilib dir we assume
  2037. # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer).
  2038. case "$lt_multi_os_dir; $lt_search_path_spec " in
  2039. "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*)
  2040. lt_multi_os_dir=
  2041. ;;
  2042. esac
  2043. for lt_sys_path in $lt_search_path_spec; do
  2044. if test -d "$lt_sys_path$lt_multi_os_dir"; then
  2045. lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir"
  2046. elif test -n "$lt_multi_os_dir"; then
  2047. test -d "$lt_sys_path" && \
  2048. lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
  2049. fi
  2050. done
  2051. lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
  2052. BEGIN {RS = " "; FS = "/|\n";} {
  2053. lt_foo = "";
  2054. lt_count = 0;
  2055. for (lt_i = NF; lt_i > 0; lt_i--) {
  2056. if ($lt_i != "" && $lt_i != ".") {
  2057. if ($lt_i == "..") {
  2058. lt_count++;
  2059. } else {
  2060. if (lt_count == 0) {
  2061. lt_foo = "/" $lt_i lt_foo;
  2062. } else {
  2063. lt_count--;
  2064. }
  2065. }
  2066. }
  2067. }
  2068. if (lt_foo != "") { lt_freq[[lt_foo]]++; }
  2069. if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
  2070. }'`
  2071. # AWK program above erroneously prepends '/' to C:/dos/paths
  2072. # for these hosts.
  2073. case $host_os in
  2074. mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
  2075. $SED 's|/\([[A-Za-z]]:\)|\1|g'` ;;
  2076. esac
  2077. sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
  2078. else
  2079. sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
  2080. fi])
  2081. library_names_spec=
  2082. libname_spec='lib$name'
  2083. soname_spec=
  2084. shrext_cmds=.so
  2085. postinstall_cmds=
  2086. postuninstall_cmds=
  2087. finish_cmds=
  2088. finish_eval=
  2089. shlibpath_var=
  2090. shlibpath_overrides_runpath=unknown
  2091. version_type=none
  2092. dynamic_linker="$host_os ld.so"
  2093. sys_lib_dlsearch_path_spec="/lib /usr/lib"
  2094. need_lib_prefix=unknown
  2095. hardcode_into_libs=no
  2096. # when you set need_version to no, make sure it does not cause -set_version
  2097. # flags to be left without arguments
  2098. need_version=unknown
  2099. AC_ARG_VAR([LT_SYS_LIBRARY_PATH],
  2100. [User-defined run-time library search path.])
  2101. case $host_os in
  2102. aix3*)
  2103. version_type=linux # correct to gnu/linux during the next big refactor
  2104. library_names_spec='$libname$release$shared_ext$versuffix $libname.a'
  2105. shlibpath_var=LIBPATH
  2106. # AIX 3 has no versioning support, so we append a major version to the name.
  2107. soname_spec='$libname$release$shared_ext$major'
  2108. ;;
  2109. aix[[4-9]]*)
  2110. version_type=linux # correct to gnu/linux during the next big refactor
  2111. need_lib_prefix=no
  2112. need_version=no
  2113. hardcode_into_libs=yes
  2114. if test ia64 = "$host_cpu"; then
  2115. # AIX 5 supports IA64
  2116. library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext'
  2117. shlibpath_var=LD_LIBRARY_PATH
  2118. else
  2119. # With GCC up to 2.95.x, collect2 would create an import file
  2120. # for dependence libraries. The import file would start with
  2121. # the line '#! .'. This would cause the generated library to
  2122. # depend on '.', always an invalid library. This was fixed in
  2123. # development snapshots of GCC prior to 3.0.
  2124. case $host_os in
  2125. aix4 | aix4.[[01]] | aix4.[[01]].*)
  2126. if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
  2127. echo ' yes '
  2128. echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then
  2129. :
  2130. else
  2131. can_build_shared=no
  2132. fi
  2133. ;;
  2134. esac
  2135. # Using Import Files as archive members, it is possible to support
  2136. # filename-based versioning of shared library archives on AIX. While
  2137. # this would work for both with and without runtime linking, it will
  2138. # prevent static linking of such archives. So we do filename-based
  2139. # shared library versioning with .so extension only, which is used
  2140. # when both runtime linking and shared linking is enabled.
  2141. # Unfortunately, runtime linking may impact performance, so we do
  2142. # not want this to be the default eventually. Also, we use the
  2143. # versioned .so libs for executables only if there is the -brtl
  2144. # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only.
  2145. # To allow for filename-based versioning support, we need to create
  2146. # libNAME.so.V as an archive file, containing:
  2147. # *) an Import File, referring to the versioned filename of the
  2148. # archive as well as the shared archive member, telling the
  2149. # bitwidth (32 or 64) of that shared object, and providing the
  2150. # list of exported symbols of that shared object, eventually
  2151. # decorated with the 'weak' keyword
  2152. # *) the shared object with the F_LOADONLY flag set, to really avoid
  2153. # it being seen by the linker.
  2154. # At run time we better use the real file rather than another symlink,
  2155. # but for link time we create the symlink libNAME.so -> libNAME.so.V
  2156. case $with_aix_soname,$aix_use_runtimelinking in
  2157. # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct
  2158. # soname into executable. Probably we can add versioning support to
  2159. # collect2, so additional links can be useful in future.
  2160. aix,yes) # traditional libtool
  2161. dynamic_linker='AIX unversionable lib.so'
  2162. # If using run time linking (on AIX 4.2 or later) use lib<name>.so
  2163. # instead of lib<name>.a to let people know that these are not
  2164. # typical AIX shared libraries.
  2165. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2166. ;;
  2167. aix,no) # traditional AIX only
  2168. dynamic_linker='AIX lib.a[(]lib.so.V[)]'
  2169. # We preserve .a as extension for shared libraries through AIX4.2
  2170. # and later when we are not doing run time linking.
  2171. library_names_spec='$libname$release.a $libname.a'
  2172. soname_spec='$libname$release$shared_ext$major'
  2173. ;;
  2174. svr4,*) # full svr4 only
  2175. dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)]"
  2176. library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
  2177. # We do not specify a path in Import Files, so LIBPATH fires.
  2178. shlibpath_overrides_runpath=yes
  2179. ;;
  2180. *,yes) # both, prefer svr4
  2181. dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)], lib.a[(]lib.so.V[)]"
  2182. library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
  2183. # unpreferred sharedlib libNAME.a needs extra handling
  2184. postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"'
  2185. postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"'
  2186. # We do not specify a path in Import Files, so LIBPATH fires.
  2187. shlibpath_overrides_runpath=yes
  2188. ;;
  2189. *,no) # both, prefer aix
  2190. dynamic_linker="AIX lib.a[(]lib.so.V[)], lib.so.V[(]$shared_archive_member_spec.o[)]"
  2191. library_names_spec='$libname$release.a $libname.a'
  2192. soname_spec='$libname$release$shared_ext$major'
  2193. # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling
  2194. postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)'
  2195. postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"'
  2196. ;;
  2197. esac
  2198. shlibpath_var=LIBPATH
  2199. fi
  2200. ;;
  2201. amigaos*)
  2202. case $host_cpu in
  2203. powerpc)
  2204. # Since July 2007 AmigaOS4 officially supports .so libraries.
  2205. # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
  2206. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2207. ;;
  2208. m68k)
  2209. library_names_spec='$libname.ixlibrary $libname.a'
  2210. # Create ${libname}_ixlibrary.a entries in /sys/libs.
  2211. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
  2212. ;;
  2213. esac
  2214. ;;
  2215. beos*)
  2216. library_names_spec='$libname$shared_ext'
  2217. dynamic_linker="$host_os ld.so"
  2218. shlibpath_var=LIBRARY_PATH
  2219. ;;
  2220. bsdi[[45]]*)
  2221. version_type=linux # correct to gnu/linux during the next big refactor
  2222. need_version=no
  2223. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2224. soname_spec='$libname$release$shared_ext$major'
  2225. finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
  2226. shlibpath_var=LD_LIBRARY_PATH
  2227. sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
  2228. sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
  2229. # the default ld.so.conf also contains /usr/contrib/lib and
  2230. # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
  2231. # libtool to hard-code these into programs
  2232. ;;
  2233. cygwin* | mingw* | pw32* | cegcc*)
  2234. version_type=windows
  2235. shrext_cmds=.dll
  2236. need_version=no
  2237. need_lib_prefix=no
  2238. case $GCC,$cc_basename in
  2239. yes,*)
  2240. # gcc
  2241. library_names_spec='$libname.dll.a'
  2242. # DLL is installed to $(libdir)/../bin by postinstall_cmds
  2243. postinstall_cmds='base_file=`basename \$file`~
  2244. dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
  2245. dldir=$destdir/`dirname \$dlpath`~
  2246. test -d \$dldir || mkdir -p \$dldir~
  2247. $install_prog $dir/$dlname \$dldir/$dlname~
  2248. chmod a+x \$dldir/$dlname~
  2249. if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
  2250. eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
  2251. fi'
  2252. postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
  2253. dlpath=$dir/\$dldll~
  2254. $RM \$dlpath'
  2255. shlibpath_overrides_runpath=yes
  2256. case $host_os in
  2257. cygwin*)
  2258. # Cygwin DLLs use 'cyg' prefix rather than 'lib'
  2259. soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
  2260. m4_if([$1], [],[
  2261. sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"])
  2262. ;;
  2263. mingw* | cegcc*)
  2264. # MinGW DLLs use traditional 'lib' prefix
  2265. soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
  2266. ;;
  2267. pw32*)
  2268. # pw32 DLLs use 'pw' prefix rather than 'lib'
  2269. library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
  2270. ;;
  2271. esac
  2272. dynamic_linker='Win32 ld.exe'
  2273. ;;
  2274. *,cl* | *,icl*)
  2275. # Native MSVC or ICC
  2276. libname_spec='$name'
  2277. soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
  2278. library_names_spec='$libname.dll.lib'
  2279. case $build_os in
  2280. mingw*)
  2281. sys_lib_search_path_spec=
  2282. lt_save_ifs=$IFS
  2283. IFS=';'
  2284. for lt_path in $LIB
  2285. do
  2286. IFS=$lt_save_ifs
  2287. # Let DOS variable expansion print the short 8.3 style file name.
  2288. lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
  2289. sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
  2290. done
  2291. IFS=$lt_save_ifs
  2292. # Convert to MSYS style.
  2293. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'`
  2294. ;;
  2295. cygwin*)
  2296. # Convert to unix form, then to dos form, then back to unix form
  2297. # but this time dos style (no spaces!) so that the unix form looks
  2298. # like /cygdrive/c/PROGRA~1:/cygdr...
  2299. sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
  2300. sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
  2301. sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
  2302. ;;
  2303. *)
  2304. sys_lib_search_path_spec=$LIB
  2305. if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
  2306. # It is most probably a Windows format PATH.
  2307. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
  2308. else
  2309. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
  2310. fi
  2311. # FIXME: find the short name or the path components, as spaces are
  2312. # common. (e.g. "Program Files" -> "PROGRA~1")
  2313. ;;
  2314. esac
  2315. # DLL is installed to $(libdir)/../bin by postinstall_cmds
  2316. postinstall_cmds='base_file=`basename \$file`~
  2317. dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
  2318. dldir=$destdir/`dirname \$dlpath`~
  2319. test -d \$dldir || mkdir -p \$dldir~
  2320. $install_prog $dir/$dlname \$dldir/$dlname'
  2321. postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
  2322. dlpath=$dir/\$dldll~
  2323. $RM \$dlpath'
  2324. shlibpath_overrides_runpath=yes
  2325. dynamic_linker='Win32 link.exe'
  2326. ;;
  2327. *)
  2328. # Assume MSVC and ICC wrapper
  2329. library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib'
  2330. dynamic_linker='Win32 ld.exe'
  2331. ;;
  2332. esac
  2333. # FIXME: first we should search . and the directory the executable is in
  2334. shlibpath_var=PATH
  2335. ;;
  2336. darwin* | rhapsody*)
  2337. dynamic_linker="$host_os dyld"
  2338. version_type=darwin
  2339. need_lib_prefix=no
  2340. need_version=no
  2341. library_names_spec='$libname$release$major$shared_ext $libname$shared_ext'
  2342. soname_spec='$libname$release$major$shared_ext'
  2343. shlibpath_overrides_runpath=yes
  2344. shlibpath_var=DYLD_LIBRARY_PATH
  2345. shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
  2346. m4_if([$1], [],[
  2347. sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
  2348. sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
  2349. ;;
  2350. dgux*)
  2351. version_type=linux # correct to gnu/linux during the next big refactor
  2352. need_lib_prefix=no
  2353. need_version=no
  2354. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2355. soname_spec='$libname$release$shared_ext$major'
  2356. shlibpath_var=LD_LIBRARY_PATH
  2357. ;;
  2358. freebsd* | dragonfly* | midnightbsd*)
  2359. # DragonFly does not have aout. When/if they implement a new
  2360. # versioning mechanism, adjust this.
  2361. if test -x /usr/bin/objformat; then
  2362. objformat=`/usr/bin/objformat`
  2363. else
  2364. case $host_os in
  2365. freebsd[[23]].*) objformat=aout ;;
  2366. *) objformat=elf ;;
  2367. esac
  2368. fi
  2369. version_type=freebsd-$objformat
  2370. case $version_type in
  2371. freebsd-elf*)
  2372. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2373. soname_spec='$libname$release$shared_ext$major'
  2374. need_version=no
  2375. need_lib_prefix=no
  2376. ;;
  2377. freebsd-*)
  2378. library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
  2379. need_version=yes
  2380. ;;
  2381. esac
  2382. shlibpath_var=LD_LIBRARY_PATH
  2383. case $host_os in
  2384. freebsd2.*)
  2385. shlibpath_overrides_runpath=yes
  2386. ;;
  2387. freebsd3.[[01]]* | freebsdelf3.[[01]]*)
  2388. shlibpath_overrides_runpath=yes
  2389. hardcode_into_libs=yes
  2390. ;;
  2391. freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
  2392. freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
  2393. shlibpath_overrides_runpath=no
  2394. hardcode_into_libs=yes
  2395. ;;
  2396. *) # from 4.6 on, and DragonFly
  2397. shlibpath_overrides_runpath=yes
  2398. hardcode_into_libs=yes
  2399. ;;
  2400. esac
  2401. ;;
  2402. haiku*)
  2403. version_type=linux # correct to gnu/linux during the next big refactor
  2404. need_lib_prefix=no
  2405. need_version=no
  2406. dynamic_linker="$host_os runtime_loader"
  2407. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2408. soname_spec='$libname$release$shared_ext$major'
  2409. shlibpath_var=LIBRARY_PATH
  2410. shlibpath_overrides_runpath=no
  2411. sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
  2412. hardcode_into_libs=yes
  2413. ;;
  2414. hpux9* | hpux10* | hpux11*)
  2415. # Give a soname corresponding to the major version so that dld.sl refuses to
  2416. # link against other versions.
  2417. version_type=sunos
  2418. need_lib_prefix=no
  2419. need_version=no
  2420. case $host_cpu in
  2421. ia64*)
  2422. shrext_cmds='.so'
  2423. hardcode_into_libs=yes
  2424. dynamic_linker="$host_os dld.so"
  2425. shlibpath_var=LD_LIBRARY_PATH
  2426. shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
  2427. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2428. soname_spec='$libname$release$shared_ext$major'
  2429. if test 32 = "$HPUX_IA64_MODE"; then
  2430. sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
  2431. sys_lib_dlsearch_path_spec=/usr/lib/hpux32
  2432. else
  2433. sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
  2434. sys_lib_dlsearch_path_spec=/usr/lib/hpux64
  2435. fi
  2436. ;;
  2437. hppa*64*)
  2438. shrext_cmds='.sl'
  2439. hardcode_into_libs=yes
  2440. dynamic_linker="$host_os dld.sl"
  2441. shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
  2442. shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
  2443. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2444. soname_spec='$libname$release$shared_ext$major'
  2445. sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
  2446. sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
  2447. ;;
  2448. *)
  2449. shrext_cmds='.sl'
  2450. dynamic_linker="$host_os dld.sl"
  2451. shlibpath_var=SHLIB_PATH
  2452. shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
  2453. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2454. soname_spec='$libname$release$shared_ext$major'
  2455. ;;
  2456. esac
  2457. # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
  2458. postinstall_cmds='chmod 555 $lib'
  2459. # or fails outright, so override atomically:
  2460. install_override_mode=555
  2461. ;;
  2462. interix[[3-9]]*)
  2463. version_type=linux # correct to gnu/linux during the next big refactor
  2464. need_lib_prefix=no
  2465. need_version=no
  2466. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2467. soname_spec='$libname$release$shared_ext$major'
  2468. dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
  2469. shlibpath_var=LD_LIBRARY_PATH
  2470. shlibpath_overrides_runpath=no
  2471. hardcode_into_libs=yes
  2472. ;;
  2473. irix5* | irix6* | nonstopux*)
  2474. case $host_os in
  2475. nonstopux*) version_type=nonstopux ;;
  2476. *)
  2477. if test yes = "$lt_cv_prog_gnu_ld"; then
  2478. version_type=linux # correct to gnu/linux during the next big refactor
  2479. else
  2480. version_type=irix
  2481. fi ;;
  2482. esac
  2483. need_lib_prefix=no
  2484. need_version=no
  2485. soname_spec='$libname$release$shared_ext$major'
  2486. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext'
  2487. case $host_os in
  2488. irix5* | nonstopux*)
  2489. libsuff= shlibsuff=
  2490. ;;
  2491. *)
  2492. case $LD in # libtool.m4 will add one of these switches to LD
  2493. *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
  2494. libsuff= shlibsuff= libmagic=32-bit;;
  2495. *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
  2496. libsuff=32 shlibsuff=N32 libmagic=N32;;
  2497. *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
  2498. libsuff=64 shlibsuff=64 libmagic=64-bit;;
  2499. *) libsuff= shlibsuff= libmagic=never-match;;
  2500. esac
  2501. ;;
  2502. esac
  2503. shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
  2504. shlibpath_overrides_runpath=no
  2505. sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff"
  2506. sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff"
  2507. hardcode_into_libs=yes
  2508. ;;
  2509. # No shared lib support for Linux oldld, aout, or coff.
  2510. linux*oldld* | linux*aout* | linux*coff*)
  2511. dynamic_linker=no
  2512. ;;
  2513. linux*android*)
  2514. version_type=none # Android doesn't support versioned libraries.
  2515. need_lib_prefix=no
  2516. need_version=no
  2517. library_names_spec='$libname$release$shared_ext'
  2518. soname_spec='$libname$release$shared_ext'
  2519. finish_cmds=
  2520. shlibpath_var=LD_LIBRARY_PATH
  2521. shlibpath_overrides_runpath=yes
  2522. # This implies no fast_install, which is unacceptable.
  2523. # Some rework will be needed to allow for fast_install
  2524. # before this can be enabled.
  2525. hardcode_into_libs=yes
  2526. dynamic_linker='Android linker'
  2527. # Don't embed -rpath directories since the linker doesn't support them.
  2528. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  2529. ;;
  2530. # This must be glibc/ELF.
  2531. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
  2532. version_type=linux # correct to gnu/linux during the next big refactor
  2533. need_lib_prefix=no
  2534. need_version=no
  2535. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2536. soname_spec='$libname$release$shared_ext$major'
  2537. finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
  2538. shlibpath_var=LD_LIBRARY_PATH
  2539. shlibpath_overrides_runpath=no
  2540. # Some binutils ld are patched to set DT_RUNPATH
  2541. AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath],
  2542. [lt_cv_shlibpath_overrides_runpath=no
  2543. save_LDFLAGS=$LDFLAGS
  2544. save_libdir=$libdir
  2545. eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
  2546. LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
  2547. AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
  2548. [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
  2549. [lt_cv_shlibpath_overrides_runpath=yes])])
  2550. LDFLAGS=$save_LDFLAGS
  2551. libdir=$save_libdir
  2552. ])
  2553. shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
  2554. # This implies no fast_install, which is unacceptable.
  2555. # Some rework will be needed to allow for fast_install
  2556. # before this can be enabled.
  2557. hardcode_into_libs=yes
  2558. # Ideally, we could use ldconfig to report *all* directores which are
  2559. # searched for libraries, however this is still not possible. Aside from not
  2560. # being certain /sbin/ldconfig is available, command
  2561. # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64,
  2562. # even though it is searched at run-time. Try to do the best guess by
  2563. # appending ld.so.conf contents (and includes) to the search path.
  2564. if test -f /etc/ld.so.conf; then
  2565. lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
  2566. sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
  2567. fi
  2568. # We used to test for /lib/ld.so.1 and disable shared libraries on
  2569. # powerpc, because MkLinux only supported shared libraries with the
  2570. # GNU dynamic linker. Since this was broken with cross compilers,
  2571. # most powerpc-linux boxes support dynamic linking these days and
  2572. # people can always --disable-shared, the test was removed, and we
  2573. # assume the GNU/Linux dynamic linker is in use.
  2574. dynamic_linker='GNU/Linux ld.so'
  2575. ;;
  2576. netbsd*)
  2577. version_type=sunos
  2578. need_lib_prefix=no
  2579. need_version=no
  2580. if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
  2581. library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
  2582. finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
  2583. dynamic_linker='NetBSD (a.out) ld.so'
  2584. else
  2585. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2586. soname_spec='$libname$release$shared_ext$major'
  2587. dynamic_linker='NetBSD ld.elf_so'
  2588. fi
  2589. shlibpath_var=LD_LIBRARY_PATH
  2590. shlibpath_overrides_runpath=yes
  2591. hardcode_into_libs=yes
  2592. ;;
  2593. newsos6)
  2594. version_type=linux # correct to gnu/linux during the next big refactor
  2595. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2596. shlibpath_var=LD_LIBRARY_PATH
  2597. shlibpath_overrides_runpath=yes
  2598. ;;
  2599. *nto* | *qnx*)
  2600. version_type=qnx
  2601. need_lib_prefix=no
  2602. need_version=no
  2603. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2604. soname_spec='$libname$release$shared_ext$major'
  2605. shlibpath_var=LD_LIBRARY_PATH
  2606. shlibpath_overrides_runpath=no
  2607. hardcode_into_libs=yes
  2608. dynamic_linker='ldqnx.so'
  2609. ;;
  2610. openbsd* | bitrig*)
  2611. version_type=sunos
  2612. sys_lib_dlsearch_path_spec=/usr/lib
  2613. need_lib_prefix=no
  2614. if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
  2615. need_version=no
  2616. else
  2617. need_version=yes
  2618. fi
  2619. library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
  2620. finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
  2621. shlibpath_var=LD_LIBRARY_PATH
  2622. shlibpath_overrides_runpath=yes
  2623. ;;
  2624. os2*)
  2625. libname_spec='$name'
  2626. version_type=windows
  2627. shrext_cmds=.dll
  2628. need_version=no
  2629. need_lib_prefix=no
  2630. # OS/2 can only load a DLL with a base name of 8 characters or less.
  2631. soname_spec='`test -n "$os2dllname" && libname="$os2dllname";
  2632. v=$($ECHO $release$versuffix | tr -d .-);
  2633. n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _);
  2634. $ECHO $n$v`$shared_ext'
  2635. library_names_spec='${libname}_dll.$libext'
  2636. dynamic_linker='OS/2 ld.exe'
  2637. shlibpath_var=BEGINLIBPATH
  2638. sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
  2639. sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
  2640. postinstall_cmds='base_file=`basename \$file`~
  2641. dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~
  2642. dldir=$destdir/`dirname \$dlpath`~
  2643. test -d \$dldir || mkdir -p \$dldir~
  2644. $install_prog $dir/$dlname \$dldir/$dlname~
  2645. chmod a+x \$dldir/$dlname~
  2646. if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
  2647. eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
  2648. fi'
  2649. postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~
  2650. dlpath=$dir/\$dldll~
  2651. $RM \$dlpath'
  2652. ;;
  2653. osf3* | osf4* | osf5*)
  2654. version_type=osf
  2655. need_lib_prefix=no
  2656. need_version=no
  2657. soname_spec='$libname$release$shared_ext$major'
  2658. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2659. shlibpath_var=LD_LIBRARY_PATH
  2660. sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
  2661. sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
  2662. ;;
  2663. rdos*)
  2664. dynamic_linker=no
  2665. ;;
  2666. solaris*)
  2667. version_type=linux # correct to gnu/linux during the next big refactor
  2668. need_lib_prefix=no
  2669. need_version=no
  2670. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2671. soname_spec='$libname$release$shared_ext$major'
  2672. shlibpath_var=LD_LIBRARY_PATH
  2673. shlibpath_overrides_runpath=yes
  2674. hardcode_into_libs=yes
  2675. # ldd complains unless libraries are executable
  2676. postinstall_cmds='chmod +x $lib'
  2677. ;;
  2678. sunos4*)
  2679. version_type=sunos
  2680. library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
  2681. finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
  2682. shlibpath_var=LD_LIBRARY_PATH
  2683. shlibpath_overrides_runpath=yes
  2684. if test yes = "$with_gnu_ld"; then
  2685. need_lib_prefix=no
  2686. fi
  2687. need_version=yes
  2688. ;;
  2689. sysv4 | sysv4.3*)
  2690. version_type=linux # correct to gnu/linux during the next big refactor
  2691. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2692. soname_spec='$libname$release$shared_ext$major'
  2693. shlibpath_var=LD_LIBRARY_PATH
  2694. case $host_vendor in
  2695. sni)
  2696. shlibpath_overrides_runpath=no
  2697. need_lib_prefix=no
  2698. runpath_var=LD_RUN_PATH
  2699. ;;
  2700. siemens)
  2701. need_lib_prefix=no
  2702. ;;
  2703. motorola)
  2704. need_lib_prefix=no
  2705. need_version=no
  2706. shlibpath_overrides_runpath=no
  2707. sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
  2708. ;;
  2709. esac
  2710. ;;
  2711. sysv4*MP*)
  2712. if test -d /usr/nec; then
  2713. version_type=linux # correct to gnu/linux during the next big refactor
  2714. library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext'
  2715. soname_spec='$libname$shared_ext.$major'
  2716. shlibpath_var=LD_LIBRARY_PATH
  2717. fi
  2718. ;;
  2719. sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
  2720. version_type=sco
  2721. need_lib_prefix=no
  2722. need_version=no
  2723. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext'
  2724. soname_spec='$libname$release$shared_ext$major'
  2725. shlibpath_var=LD_LIBRARY_PATH
  2726. shlibpath_overrides_runpath=yes
  2727. hardcode_into_libs=yes
  2728. if test yes = "$with_gnu_ld"; then
  2729. sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
  2730. else
  2731. sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
  2732. case $host_os in
  2733. sco3.2v5*)
  2734. sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
  2735. ;;
  2736. esac
  2737. fi
  2738. sys_lib_dlsearch_path_spec='/usr/lib'
  2739. ;;
  2740. tpf*)
  2741. # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
  2742. version_type=linux # correct to gnu/linux during the next big refactor
  2743. need_lib_prefix=no
  2744. need_version=no
  2745. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2746. shlibpath_var=LD_LIBRARY_PATH
  2747. shlibpath_overrides_runpath=no
  2748. hardcode_into_libs=yes
  2749. ;;
  2750. uts4*)
  2751. version_type=linux # correct to gnu/linux during the next big refactor
  2752. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
  2753. soname_spec='$libname$release$shared_ext$major'
  2754. shlibpath_var=LD_LIBRARY_PATH
  2755. ;;
  2756. *)
  2757. dynamic_linker=no
  2758. ;;
  2759. esac
  2760. AC_MSG_RESULT([$dynamic_linker])
  2761. test no = "$dynamic_linker" && can_build_shared=no
  2762. variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
  2763. if test yes = "$GCC"; then
  2764. variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
  2765. fi
  2766. if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then
  2767. sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec
  2768. fi
  2769. if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then
  2770. sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec
  2771. fi
  2772. # remember unaugmented sys_lib_dlsearch_path content for libtool script decls...
  2773. configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec
  2774. # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code
  2775. func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH"
  2776. # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool
  2777. configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH
  2778. _LT_DECL([], [variables_saved_for_relink], [1],
  2779. [Variables whose values should be saved in libtool wrapper scripts and
  2780. restored at link time])
  2781. _LT_DECL([], [need_lib_prefix], [0],
  2782. [Do we need the "lib" prefix for modules?])
  2783. _LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
  2784. _LT_DECL([], [version_type], [0], [Library versioning type])
  2785. _LT_DECL([], [runpath_var], [0], [Shared library runtime path variable])
  2786. _LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
  2787. _LT_DECL([], [shlibpath_overrides_runpath], [0],
  2788. [Is shlibpath searched before the hard-coded library search path?])
  2789. _LT_DECL([], [libname_spec], [1], [Format of library name prefix])
  2790. _LT_DECL([], [library_names_spec], [1],
  2791. [[List of archive names. First name is the real one, the rest are links.
  2792. The last name is the one that the linker finds with -lNAME]])
  2793. _LT_DECL([], [soname_spec], [1],
  2794. [[The coded name of the library, if different from the real name]])
  2795. _LT_DECL([], [install_override_mode], [1],
  2796. [Permission mode override for installation of shared libraries])
  2797. _LT_DECL([], [postinstall_cmds], [2],
  2798. [Command to use after installation of a shared archive])
  2799. _LT_DECL([], [postuninstall_cmds], [2],
  2800. [Command to use after uninstallation of a shared archive])
  2801. _LT_DECL([], [finish_cmds], [2],
  2802. [Commands used to finish a libtool library installation in a directory])
  2803. _LT_DECL([], [finish_eval], [1],
  2804. [[As "finish_cmds", except a single script fragment to be evaled but
  2805. not shown]])
  2806. _LT_DECL([], [hardcode_into_libs], [0],
  2807. [Whether we should hardcode library paths into libraries])
  2808. _LT_DECL([], [sys_lib_search_path_spec], [2],
  2809. [Compile-time system search path for libraries])
  2810. _LT_DECL([sys_lib_dlsearch_path_spec], [configure_time_dlsearch_path], [2],
  2811. [Detected run-time system search path for libraries])
  2812. _LT_DECL([], [configure_time_lt_sys_library_path], [2],
  2813. [Explicit LT_SYS_LIBRARY_PATH set during ./configure time])
  2814. ])# _LT_SYS_DYNAMIC_LINKER
  2815. # _LT_PATH_TOOL_PREFIX(TOOL)
  2816. # --------------------------
  2817. # find a file program that can recognize shared library
  2818. AC_DEFUN([_LT_PATH_TOOL_PREFIX],
  2819. [m4_require([_LT_DECL_EGREP])dnl
  2820. AC_MSG_CHECKING([for $1])
  2821. AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
  2822. [case $MAGIC_CMD in
  2823. [[\\/*] | ?:[\\/]*])
  2824. lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
  2825. ;;
  2826. *)
  2827. lt_save_MAGIC_CMD=$MAGIC_CMD
  2828. lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
  2829. dnl $ac_dummy forces splitting on constant user-supplied paths.
  2830. dnl POSIX.2 word splitting is done only on the output of word expansions,
  2831. dnl not every word. This closes a longstanding sh security hole.
  2832. ac_dummy="m4_if([$2], , $PATH, [$2])"
  2833. for ac_dir in $ac_dummy; do
  2834. IFS=$lt_save_ifs
  2835. test -z "$ac_dir" && ac_dir=.
  2836. if test -f "$ac_dir/$1"; then
  2837. lt_cv_path_MAGIC_CMD=$ac_dir/"$1"
  2838. if test -n "$file_magic_test_file"; then
  2839. case $deplibs_check_method in
  2840. "file_magic "*)
  2841. file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
  2842. MAGIC_CMD=$lt_cv_path_MAGIC_CMD
  2843. if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
  2844. $EGREP "$file_magic_regex" > /dev/null; then
  2845. :
  2846. else
  2847. cat <<_LT_EOF 1>&2
  2848. *** Warning: the command libtool uses to detect shared libraries,
  2849. *** $file_magic_cmd, produces output that libtool cannot recognize.
  2850. *** The result is that libtool may fail to recognize shared libraries
  2851. *** as such. This will affect the creation of libtool libraries that
  2852. *** depend on shared libraries, but programs linked with such libtool
  2853. *** libraries will work regardless of this problem. Nevertheless, you
  2854. *** may want to report the problem to your system manager and/or to
  2855. *** bug-libtool@gnu.org
  2856. _LT_EOF
  2857. fi ;;
  2858. esac
  2859. fi
  2860. break
  2861. fi
  2862. done
  2863. IFS=$lt_save_ifs
  2864. MAGIC_CMD=$lt_save_MAGIC_CMD
  2865. ;;
  2866. esac])
  2867. MAGIC_CMD=$lt_cv_path_MAGIC_CMD
  2868. if test -n "$MAGIC_CMD"; then
  2869. AC_MSG_RESULT($MAGIC_CMD)
  2870. else
  2871. AC_MSG_RESULT(no)
  2872. fi
  2873. _LT_DECL([], [MAGIC_CMD], [0],
  2874. [Used to examine libraries when file_magic_cmd begins with "file"])dnl
  2875. ])# _LT_PATH_TOOL_PREFIX
  2876. # Old name:
  2877. AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
  2878. dnl aclocal-1.4 backwards compatibility:
  2879. dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
  2880. # _LT_PATH_MAGIC
  2881. # --------------
  2882. # find a file program that can recognize a shared library
  2883. m4_defun([_LT_PATH_MAGIC],
  2884. [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
  2885. if test -z "$lt_cv_path_MAGIC_CMD"; then
  2886. if test -n "$ac_tool_prefix"; then
  2887. _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
  2888. else
  2889. MAGIC_CMD=:
  2890. fi
  2891. fi
  2892. ])# _LT_PATH_MAGIC
  2893. # LT_PATH_LD
  2894. # ----------
  2895. # find the pathname to the GNU or non-GNU linker
  2896. AC_DEFUN([LT_PATH_LD],
  2897. [AC_REQUIRE([AC_PROG_CC])dnl
  2898. AC_REQUIRE([AC_CANONICAL_HOST])dnl
  2899. AC_REQUIRE([AC_CANONICAL_BUILD])dnl
  2900. m4_require([_LT_DECL_SED])dnl
  2901. m4_require([_LT_DECL_EGREP])dnl
  2902. m4_require([_LT_PROG_ECHO_BACKSLASH])dnl
  2903. AC_ARG_WITH([gnu-ld],
  2904. [AS_HELP_STRING([--with-gnu-ld],
  2905. [assume the C compiler uses GNU ld @<:@default=no@:>@])],
  2906. [test no = "$withval" || with_gnu_ld=yes],
  2907. [with_gnu_ld=no])dnl
  2908. ac_prog=ld
  2909. if test yes = "$GCC"; then
  2910. # Check if gcc -print-prog-name=ld gives a path.
  2911. AC_MSG_CHECKING([for ld used by $CC])
  2912. case $host in
  2913. *-*-mingw*)
  2914. # gcc leaves a trailing carriage return, which upsets mingw
  2915. ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
  2916. *)
  2917. ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
  2918. esac
  2919. case $ac_prog in
  2920. # Accept absolute paths.
  2921. [[\\/]]* | ?:[[\\/]]*)
  2922. re_direlt='/[[^/]][[^/]]*/\.\./'
  2923. # Canonicalize the pathname of ld
  2924. ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
  2925. while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
  2926. ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
  2927. done
  2928. test -z "$LD" && LD=$ac_prog
  2929. ;;
  2930. "")
  2931. # If it fails, then pretend we aren't using GCC.
  2932. ac_prog=ld
  2933. ;;
  2934. *)
  2935. # If it is relative, then search for the first ld in PATH.
  2936. with_gnu_ld=unknown
  2937. ;;
  2938. esac
  2939. elif test yes = "$with_gnu_ld"; then
  2940. AC_MSG_CHECKING([for GNU ld])
  2941. else
  2942. AC_MSG_CHECKING([for non-GNU ld])
  2943. fi
  2944. AC_CACHE_VAL(lt_cv_path_LD,
  2945. [if test -z "$LD"; then
  2946. lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
  2947. for ac_dir in $PATH; do
  2948. IFS=$lt_save_ifs
  2949. test -z "$ac_dir" && ac_dir=.
  2950. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
  2951. lt_cv_path_LD=$ac_dir/$ac_prog
  2952. # Check to see if the program is GNU ld. I'd rather use --version,
  2953. # but apparently some variants of GNU ld only accept -v.
  2954. # Break only if it was the GNU/non-GNU ld that we prefer.
  2955. case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
  2956. *GNU* | *'with BFD'*)
  2957. test no != "$with_gnu_ld" && break
  2958. ;;
  2959. *)
  2960. test yes != "$with_gnu_ld" && break
  2961. ;;
  2962. esac
  2963. fi
  2964. done
  2965. IFS=$lt_save_ifs
  2966. else
  2967. lt_cv_path_LD=$LD # Let the user override the test with a path.
  2968. fi])
  2969. LD=$lt_cv_path_LD
  2970. if test -n "$LD"; then
  2971. AC_MSG_RESULT($LD)
  2972. else
  2973. AC_MSG_RESULT(no)
  2974. fi
  2975. test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
  2976. _LT_PATH_LD_GNU
  2977. AC_SUBST([LD])
  2978. _LT_TAGDECL([], [LD], [1], [The linker used to build libraries])
  2979. ])# LT_PATH_LD
  2980. # Old names:
  2981. AU_ALIAS([AM_PROG_LD], [LT_PATH_LD])
  2982. AU_ALIAS([AC_PROG_LD], [LT_PATH_LD])
  2983. dnl aclocal-1.4 backwards compatibility:
  2984. dnl AC_DEFUN([AM_PROG_LD], [])
  2985. dnl AC_DEFUN([AC_PROG_LD], [])
  2986. # _LT_PATH_LD_GNU
  2987. #- --------------
  2988. m4_defun([_LT_PATH_LD_GNU],
  2989. [AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
  2990. [# I'd rather use --version here, but apparently some GNU lds only accept -v.
  2991. case `$LD -v 2>&1 </dev/null` in
  2992. *GNU* | *'with BFD'*)
  2993. lt_cv_prog_gnu_ld=yes
  2994. ;;
  2995. *)
  2996. lt_cv_prog_gnu_ld=no
  2997. ;;
  2998. esac])
  2999. with_gnu_ld=$lt_cv_prog_gnu_ld
  3000. ])# _LT_PATH_LD_GNU
  3001. # _LT_CMD_RELOAD
  3002. # --------------
  3003. # find reload flag for linker
  3004. # -- PORTME Some linkers may need a different reload flag.
  3005. m4_defun([_LT_CMD_RELOAD],
  3006. [AC_CACHE_CHECK([for $LD option to reload object files],
  3007. lt_cv_ld_reload_flag,
  3008. [lt_cv_ld_reload_flag='-r'])
  3009. reload_flag=$lt_cv_ld_reload_flag
  3010. case $reload_flag in
  3011. "" | " "*) ;;
  3012. *) reload_flag=" $reload_flag" ;;
  3013. esac
  3014. reload_cmds='$LD$reload_flag -o $output$reload_objs'
  3015. case $host_os in
  3016. cygwin* | mingw* | pw32* | cegcc*)
  3017. if test yes != "$GCC"; then
  3018. reload_cmds=false
  3019. fi
  3020. ;;
  3021. darwin*)
  3022. if test yes = "$GCC"; then
  3023. reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs'
  3024. else
  3025. reload_cmds='$LD$reload_flag -o $output$reload_objs'
  3026. fi
  3027. ;;
  3028. esac
  3029. _LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl
  3030. _LT_TAGDECL([], [reload_cmds], [2])dnl
  3031. ])# _LT_CMD_RELOAD
  3032. # _LT_PATH_DD
  3033. # -----------
  3034. # find a working dd
  3035. m4_defun([_LT_PATH_DD],
  3036. [AC_CACHE_CHECK([for a working dd], [ac_cv_path_lt_DD],
  3037. [printf 0123456789abcdef0123456789abcdef >conftest.i
  3038. cat conftest.i conftest.i >conftest2.i
  3039. : ${lt_DD:=$DD}
  3040. AC_PATH_PROGS_FEATURE_CHECK([lt_DD], [dd],
  3041. [if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
  3042. cmp -s conftest.i conftest.out \
  3043. && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=:
  3044. fi])
  3045. rm -f conftest.i conftest2.i conftest.out])
  3046. ])# _LT_PATH_DD
  3047. # _LT_CMD_TRUNCATE
  3048. # ----------------
  3049. # find command to truncate a binary pipe
  3050. m4_defun([_LT_CMD_TRUNCATE],
  3051. [m4_require([_LT_PATH_DD])
  3052. AC_CACHE_CHECK([how to truncate binary pipes], [lt_cv_truncate_bin],
  3053. [printf 0123456789abcdef0123456789abcdef >conftest.i
  3054. cat conftest.i conftest.i >conftest2.i
  3055. lt_cv_truncate_bin=
  3056. if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
  3057. cmp -s conftest.i conftest.out \
  3058. && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1"
  3059. fi
  3060. rm -f conftest.i conftest2.i conftest.out
  3061. test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"])
  3062. _LT_DECL([lt_truncate_bin], [lt_cv_truncate_bin], [1],
  3063. [Command to truncate a binary pipe])
  3064. ])# _LT_CMD_TRUNCATE
  3065. # _LT_CHECK_MAGIC_METHOD
  3066. # ----------------------
  3067. # how to check for library dependencies
  3068. # -- PORTME fill in with the dynamic library characteristics
  3069. m4_defun([_LT_CHECK_MAGIC_METHOD],
  3070. [m4_require([_LT_DECL_EGREP])
  3071. m4_require([_LT_DECL_OBJDUMP])
  3072. AC_CACHE_CHECK([how to recognize dependent libraries],
  3073. lt_cv_deplibs_check_method,
  3074. [lt_cv_file_magic_cmd='$MAGIC_CMD'
  3075. lt_cv_file_magic_test_file=
  3076. lt_cv_deplibs_check_method='unknown'
  3077. # Need to set the preceding variable on all platforms that support
  3078. # interlibrary dependencies.
  3079. # 'none' -- dependencies not supported.
  3080. # 'unknown' -- same as none, but documents that we really don't know.
  3081. # 'pass_all' -- all dependencies passed with no checks.
  3082. # 'test_compile' -- check by making test program.
  3083. # 'file_magic [[regex]]' -- check by looking for files in library path
  3084. # that responds to the $file_magic_cmd with a given extended regex.
  3085. # If you have 'file' or equivalent on your system and you're not sure
  3086. # whether 'pass_all' will *always* work, you probably want this one.
  3087. case $host_os in
  3088. aix[[4-9]]*)
  3089. lt_cv_deplibs_check_method=pass_all
  3090. ;;
  3091. beos*)
  3092. lt_cv_deplibs_check_method=pass_all
  3093. ;;
  3094. bsdi[[45]]*)
  3095. lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
  3096. lt_cv_file_magic_cmd='$FILECMD -L'
  3097. lt_cv_file_magic_test_file=/shlib/libc.so
  3098. ;;
  3099. cygwin*)
  3100. # func_win32_libid is a shell function defined in ltmain.sh
  3101. lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
  3102. lt_cv_file_magic_cmd='func_win32_libid'
  3103. ;;
  3104. mingw* | pw32*)
  3105. # Base MSYS/MinGW do not provide the 'file' command needed by
  3106. # func_win32_libid shell function, so use a weaker test based on 'objdump',
  3107. # unless we find 'file', for example because we are cross-compiling.
  3108. if ( file / ) >/dev/null 2>&1; then
  3109. lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
  3110. lt_cv_file_magic_cmd='func_win32_libid'
  3111. else
  3112. # Keep this pattern in sync with the one in func_win32_libid.
  3113. lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
  3114. lt_cv_file_magic_cmd='$OBJDUMP -f'
  3115. fi
  3116. ;;
  3117. cegcc*)
  3118. # use the weaker test based on 'objdump'. See mingw*.
  3119. lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
  3120. lt_cv_file_magic_cmd='$OBJDUMP -f'
  3121. ;;
  3122. darwin* | rhapsody*)
  3123. lt_cv_deplibs_check_method=pass_all
  3124. ;;
  3125. freebsd* | dragonfly* | midnightbsd*)
  3126. if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
  3127. case $host_cpu in
  3128. i*86 )
  3129. # Not sure whether the presence of OpenBSD here was a mistake.
  3130. # Let's accept both of them until this is cleared up.
  3131. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
  3132. lt_cv_file_magic_cmd=$FILECMD
  3133. lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
  3134. ;;
  3135. esac
  3136. else
  3137. lt_cv_deplibs_check_method=pass_all
  3138. fi
  3139. ;;
  3140. haiku*)
  3141. lt_cv_deplibs_check_method=pass_all
  3142. ;;
  3143. hpux10.20* | hpux11*)
  3144. lt_cv_file_magic_cmd=$FILECMD
  3145. case $host_cpu in
  3146. ia64*)
  3147. lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
  3148. lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
  3149. ;;
  3150. hppa*64*)
  3151. [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]']
  3152. lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
  3153. ;;
  3154. *)
  3155. lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library'
  3156. lt_cv_file_magic_test_file=/usr/lib/libc.sl
  3157. ;;
  3158. esac
  3159. ;;
  3160. interix[[3-9]]*)
  3161. # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
  3162. lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
  3163. ;;
  3164. irix5* | irix6* | nonstopux*)
  3165. case $LD in
  3166. *-32|*"-32 ") libmagic=32-bit;;
  3167. *-n32|*"-n32 ") libmagic=N32;;
  3168. *-64|*"-64 ") libmagic=64-bit;;
  3169. *) libmagic=never-match;;
  3170. esac
  3171. lt_cv_deplibs_check_method=pass_all
  3172. ;;
  3173. # This must be glibc/ELF.
  3174. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
  3175. lt_cv_deplibs_check_method=pass_all
  3176. ;;
  3177. netbsd*)
  3178. if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
  3179. lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
  3180. else
  3181. lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
  3182. fi
  3183. ;;
  3184. newos6*)
  3185. lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
  3186. lt_cv_file_magic_cmd=$FILECMD
  3187. lt_cv_file_magic_test_file=/usr/lib/libnls.so
  3188. ;;
  3189. *nto* | *qnx*)
  3190. lt_cv_deplibs_check_method=pass_all
  3191. ;;
  3192. openbsd* | bitrig*)
  3193. if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
  3194. lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
  3195. else
  3196. lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
  3197. fi
  3198. ;;
  3199. osf3* | osf4* | osf5*)
  3200. lt_cv_deplibs_check_method=pass_all
  3201. ;;
  3202. rdos*)
  3203. lt_cv_deplibs_check_method=pass_all
  3204. ;;
  3205. solaris*)
  3206. lt_cv_deplibs_check_method=pass_all
  3207. ;;
  3208. sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
  3209. lt_cv_deplibs_check_method=pass_all
  3210. ;;
  3211. sysv4 | sysv4.3*)
  3212. case $host_vendor in
  3213. motorola)
  3214. lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]'
  3215. lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
  3216. ;;
  3217. ncr)
  3218. lt_cv_deplibs_check_method=pass_all
  3219. ;;
  3220. sequent)
  3221. lt_cv_file_magic_cmd='/bin/file'
  3222. lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
  3223. ;;
  3224. sni)
  3225. lt_cv_file_magic_cmd='/bin/file'
  3226. lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
  3227. lt_cv_file_magic_test_file=/lib/libc.so
  3228. ;;
  3229. siemens)
  3230. lt_cv_deplibs_check_method=pass_all
  3231. ;;
  3232. pc)
  3233. lt_cv_deplibs_check_method=pass_all
  3234. ;;
  3235. esac
  3236. ;;
  3237. tpf*)
  3238. lt_cv_deplibs_check_method=pass_all
  3239. ;;
  3240. os2*)
  3241. lt_cv_deplibs_check_method=pass_all
  3242. ;;
  3243. esac
  3244. ])
  3245. file_magic_glob=
  3246. want_nocaseglob=no
  3247. if test "$build" = "$host"; then
  3248. case $host_os in
  3249. mingw* | pw32*)
  3250. if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
  3251. want_nocaseglob=yes
  3252. else
  3253. file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"`
  3254. fi
  3255. ;;
  3256. esac
  3257. fi
  3258. file_magic_cmd=$lt_cv_file_magic_cmd
  3259. deplibs_check_method=$lt_cv_deplibs_check_method
  3260. test -z "$deplibs_check_method" && deplibs_check_method=unknown
  3261. _LT_DECL([], [deplibs_check_method], [1],
  3262. [Method to check whether dependent libraries are shared objects])
  3263. _LT_DECL([], [file_magic_cmd], [1],
  3264. [Command to use when deplibs_check_method = "file_magic"])
  3265. _LT_DECL([], [file_magic_glob], [1],
  3266. [How to find potential files when deplibs_check_method = "file_magic"])
  3267. _LT_DECL([], [want_nocaseglob], [1],
  3268. [Find potential files using nocaseglob when deplibs_check_method = "file_magic"])
  3269. ])# _LT_CHECK_MAGIC_METHOD
  3270. # LT_PATH_NM
  3271. # ----------
  3272. # find the pathname to a BSD- or MS-compatible name lister
  3273. AC_DEFUN([LT_PATH_NM],
  3274. [AC_REQUIRE([AC_PROG_CC])dnl
  3275. AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
  3276. [if test -n "$NM"; then
  3277. # Let the user override the test.
  3278. lt_cv_path_NM=$NM
  3279. else
  3280. lt_nm_to_check=${ac_tool_prefix}nm
  3281. if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
  3282. lt_nm_to_check="$lt_nm_to_check nm"
  3283. fi
  3284. for lt_tmp_nm in $lt_nm_to_check; do
  3285. lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
  3286. for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
  3287. IFS=$lt_save_ifs
  3288. test -z "$ac_dir" && ac_dir=.
  3289. tmp_nm=$ac_dir/$lt_tmp_nm
  3290. if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then
  3291. # Check to see if the nm accepts a BSD-compat flag.
  3292. # Adding the 'sed 1q' prevents false positives on HP-UX, which says:
  3293. # nm: unknown option "B" ignored
  3294. # Tru64's nm complains that /dev/null is an invalid object file
  3295. # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty
  3296. case $build_os in
  3297. mingw*) lt_bad_file=conftest.nm/nofile ;;
  3298. *) lt_bad_file=/dev/null ;;
  3299. esac
  3300. case `"$tmp_nm" -B $lt_bad_file 2>&1 | $SED '1q'` in
  3301. *$lt_bad_file* | *'Invalid file or object type'*)
  3302. lt_cv_path_NM="$tmp_nm -B"
  3303. break 2
  3304. ;;
  3305. *)
  3306. case `"$tmp_nm" -p /dev/null 2>&1 | $SED '1q'` in
  3307. */dev/null*)
  3308. lt_cv_path_NM="$tmp_nm -p"
  3309. break 2
  3310. ;;
  3311. *)
  3312. lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
  3313. continue # so that we can try to find one that supports BSD flags
  3314. ;;
  3315. esac
  3316. ;;
  3317. esac
  3318. fi
  3319. done
  3320. IFS=$lt_save_ifs
  3321. done
  3322. : ${lt_cv_path_NM=no}
  3323. fi])
  3324. if test no != "$lt_cv_path_NM"; then
  3325. NM=$lt_cv_path_NM
  3326. else
  3327. # Didn't find any BSD compatible name lister, look for dumpbin.
  3328. if test -n "$DUMPBIN"; then :
  3329. # Let the user override the test.
  3330. else
  3331. AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :)
  3332. case `$DUMPBIN -symbols -headers /dev/null 2>&1 | $SED '1q'` in
  3333. *COFF*)
  3334. DUMPBIN="$DUMPBIN -symbols -headers"
  3335. ;;
  3336. *)
  3337. DUMPBIN=:
  3338. ;;
  3339. esac
  3340. fi
  3341. AC_SUBST([DUMPBIN])
  3342. if test : != "$DUMPBIN"; then
  3343. NM=$DUMPBIN
  3344. fi
  3345. fi
  3346. test -z "$NM" && NM=nm
  3347. AC_SUBST([NM])
  3348. _LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
  3349. AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
  3350. [lt_cv_nm_interface="BSD nm"
  3351. echo "int some_variable = 0;" > conftest.$ac_ext
  3352. (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
  3353. (eval "$ac_compile" 2>conftest.err)
  3354. cat conftest.err >&AS_MESSAGE_LOG_FD
  3355. (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
  3356. (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
  3357. cat conftest.err >&AS_MESSAGE_LOG_FD
  3358. (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD)
  3359. cat conftest.out >&AS_MESSAGE_LOG_FD
  3360. if $GREP 'External.*some_variable' conftest.out > /dev/null; then
  3361. lt_cv_nm_interface="MS dumpbin"
  3362. fi
  3363. rm -f conftest*])
  3364. ])# LT_PATH_NM
  3365. # Old names:
  3366. AU_ALIAS([AM_PROG_NM], [LT_PATH_NM])
  3367. AU_ALIAS([AC_PROG_NM], [LT_PATH_NM])
  3368. dnl aclocal-1.4 backwards compatibility:
  3369. dnl AC_DEFUN([AM_PROG_NM], [])
  3370. dnl AC_DEFUN([AC_PROG_NM], [])
  3371. # _LT_CHECK_SHAREDLIB_FROM_LINKLIB
  3372. # --------------------------------
  3373. # how to determine the name of the shared library
  3374. # associated with a specific link library.
  3375. # -- PORTME fill in with the dynamic library characteristics
  3376. m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB],
  3377. [m4_require([_LT_DECL_EGREP])
  3378. m4_require([_LT_DECL_OBJDUMP])
  3379. m4_require([_LT_DECL_DLLTOOL])
  3380. AC_CACHE_CHECK([how to associate runtime and link libraries],
  3381. lt_cv_sharedlib_from_linklib_cmd,
  3382. [lt_cv_sharedlib_from_linklib_cmd='unknown'
  3383. case $host_os in
  3384. cygwin* | mingw* | pw32* | cegcc*)
  3385. # two different shell functions defined in ltmain.sh;
  3386. # decide which one to use based on capabilities of $DLLTOOL
  3387. case `$DLLTOOL --help 2>&1` in
  3388. *--identify-strict*)
  3389. lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
  3390. ;;
  3391. *)
  3392. lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
  3393. ;;
  3394. esac
  3395. ;;
  3396. *)
  3397. # fallback: assume linklib IS sharedlib
  3398. lt_cv_sharedlib_from_linklib_cmd=$ECHO
  3399. ;;
  3400. esac
  3401. ])
  3402. sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
  3403. test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
  3404. _LT_DECL([], [sharedlib_from_linklib_cmd], [1],
  3405. [Command to associate shared and link libraries])
  3406. ])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
  3407. # _LT_PATH_MANIFEST_TOOL
  3408. # ----------------------
  3409. # locate the manifest tool
  3410. m4_defun([_LT_PATH_MANIFEST_TOOL],
  3411. [AC_CHECK_TOOL(MANIFEST_TOOL, mt, :)
  3412. test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
  3413. AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool],
  3414. [lt_cv_path_mainfest_tool=no
  3415. echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD
  3416. $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
  3417. cat conftest.err >&AS_MESSAGE_LOG_FD
  3418. if $GREP 'Manifest Tool' conftest.out > /dev/null; then
  3419. lt_cv_path_mainfest_tool=yes
  3420. fi
  3421. rm -f conftest*])
  3422. if test yes != "$lt_cv_path_mainfest_tool"; then
  3423. MANIFEST_TOOL=:
  3424. fi
  3425. _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl
  3426. ])# _LT_PATH_MANIFEST_TOOL
  3427. # _LT_DLL_DEF_P([FILE])
  3428. # ---------------------
  3429. # True iff FILE is a Windows DLL '.def' file.
  3430. # Keep in sync with func_dll_def_p in the libtool script
  3431. AC_DEFUN([_LT_DLL_DEF_P],
  3432. [dnl
  3433. test DEF = "`$SED -n dnl
  3434. -e '\''s/^[[ ]]*//'\'' dnl Strip leading whitespace
  3435. -e '\''/^\(;.*\)*$/d'\'' dnl Delete empty lines and comments
  3436. -e '\''s/^\(EXPORTS\|LIBRARY\)\([[ ]].*\)*$/DEF/p'\'' dnl
  3437. -e q dnl Only consider the first "real" line
  3438. $1`" dnl
  3439. ])# _LT_DLL_DEF_P
  3440. # LT_LIB_M
  3441. # --------
  3442. # check for math library
  3443. AC_DEFUN([LT_LIB_M],
  3444. [AC_REQUIRE([AC_CANONICAL_HOST])dnl
  3445. LIBM=
  3446. case $host in
  3447. *-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*)
  3448. # These system don't have libm, or don't need it
  3449. ;;
  3450. *-ncr-sysv4.3*)
  3451. AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM=-lmw)
  3452. AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
  3453. ;;
  3454. *)
  3455. AC_CHECK_LIB(m, cos, LIBM=-lm)
  3456. ;;
  3457. esac
  3458. AC_SUBST([LIBM])
  3459. ])# LT_LIB_M
  3460. # Old name:
  3461. AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M])
  3462. dnl aclocal-1.4 backwards compatibility:
  3463. dnl AC_DEFUN([AC_CHECK_LIBM], [])
  3464. # _LT_COMPILER_NO_RTTI([TAGNAME])
  3465. # -------------------------------
  3466. m4_defun([_LT_COMPILER_NO_RTTI],
  3467. [m4_require([_LT_TAG_COMPILER])dnl
  3468. _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
  3469. if test yes = "$GCC"; then
  3470. case $cc_basename in
  3471. nvcc*)
  3472. _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;;
  3473. *)
  3474. _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;;
  3475. esac
  3476. _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
  3477. lt_cv_prog_compiler_rtti_exceptions,
  3478. [-fno-rtti -fno-exceptions], [],
  3479. [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
  3480. fi
  3481. _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
  3482. [Compiler flag to turn off builtin functions])
  3483. ])# _LT_COMPILER_NO_RTTI
  3484. # _LT_CMD_GLOBAL_SYMBOLS
  3485. # ----------------------
  3486. m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
  3487. [AC_REQUIRE([AC_CANONICAL_HOST])dnl
  3488. AC_REQUIRE([AC_PROG_CC])dnl
  3489. AC_REQUIRE([AC_PROG_AWK])dnl
  3490. AC_REQUIRE([LT_PATH_NM])dnl
  3491. AC_REQUIRE([LT_PATH_LD])dnl
  3492. m4_require([_LT_DECL_SED])dnl
  3493. m4_require([_LT_DECL_EGREP])dnl
  3494. m4_require([_LT_TAG_COMPILER])dnl
  3495. # Check for command to grab the raw symbol name followed by C symbol from nm.
  3496. AC_MSG_CHECKING([command to parse $NM output from $compiler object])
  3497. AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
  3498. [
  3499. # These are sane defaults that work on at least a few old systems.
  3500. # [They come from Ultrix. What could be older than Ultrix?!! ;)]
  3501. # Character class describing NM global symbol codes.
  3502. symcode='[[BCDEGRST]]'
  3503. # Regexp to match symbols that can be accessed directly from C.
  3504. sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
  3505. # Define system-specific variables.
  3506. case $host_os in
  3507. aix*)
  3508. symcode='[[BCDT]]'
  3509. ;;
  3510. cygwin* | mingw* | pw32* | cegcc*)
  3511. symcode='[[ABCDGISTW]]'
  3512. ;;
  3513. hpux*)
  3514. if test ia64 = "$host_cpu"; then
  3515. symcode='[[ABCDEGRST]]'
  3516. fi
  3517. ;;
  3518. irix* | nonstopux*)
  3519. symcode='[[BCDEGRST]]'
  3520. ;;
  3521. osf*)
  3522. symcode='[[BCDEGQRST]]'
  3523. ;;
  3524. solaris*)
  3525. symcode='[[BDRT]]'
  3526. ;;
  3527. sco3.2v5*)
  3528. symcode='[[DT]]'
  3529. ;;
  3530. sysv4.2uw2*)
  3531. symcode='[[DT]]'
  3532. ;;
  3533. sysv5* | sco5v6* | unixware* | OpenUNIX*)
  3534. symcode='[[ABDT]]'
  3535. ;;
  3536. sysv4)
  3537. symcode='[[DFNSTU]]'
  3538. ;;
  3539. esac
  3540. # If we're using GNU nm, then use its standard symbol codes.
  3541. case `$NM -V 2>&1` in
  3542. *GNU* | *'with BFD'*)
  3543. symcode='[[ABCDGIRSTW]]' ;;
  3544. esac
  3545. if test "$lt_cv_nm_interface" = "MS dumpbin"; then
  3546. # Gets list of data symbols to import.
  3547. lt_cv_sys_global_symbol_to_import="$SED -n -e 's/^I .* \(.*\)$/\1/p'"
  3548. # Adjust the below global symbol transforms to fixup imported variables.
  3549. lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'"
  3550. lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'"
  3551. lt_c_name_lib_hook="\
  3552. -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\
  3553. -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'"
  3554. else
  3555. # Disable hooks by default.
  3556. lt_cv_sys_global_symbol_to_import=
  3557. lt_cdecl_hook=
  3558. lt_c_name_hook=
  3559. lt_c_name_lib_hook=
  3560. fi
  3561. # Transform an extracted symbol line into a proper C declaration.
  3562. # Some systems (esp. on ia64) link data and code symbols differently,
  3563. # so use this general approach.
  3564. lt_cv_sys_global_symbol_to_cdecl="$SED -n"\
  3565. $lt_cdecl_hook\
  3566. " -e 's/^T .* \(.*\)$/extern int \1();/p'"\
  3567. " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'"
  3568. # Transform an extracted symbol line into symbol name and symbol address
  3569. lt_cv_sys_global_symbol_to_c_name_address="$SED -n"\
  3570. $lt_c_name_hook\
  3571. " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
  3572. " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'"
  3573. # Transform an extracted symbol line into symbol name with lib prefix and
  3574. # symbol address.
  3575. lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="$SED -n"\
  3576. $lt_c_name_lib_hook\
  3577. " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
  3578. " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\
  3579. " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'"
  3580. # Handle CRLF in mingw tool chain
  3581. opt_cr=
  3582. case $build_os in
  3583. mingw*)
  3584. opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
  3585. ;;
  3586. esac
  3587. # Try without a prefix underscore, then with it.
  3588. for ac_symprfx in "" "_"; do
  3589. # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
  3590. symxfrm="\\1 $ac_symprfx\\2 \\2"
  3591. # Write the raw and C identifiers.
  3592. if test "$lt_cv_nm_interface" = "MS dumpbin"; then
  3593. # Fake it for dumpbin and say T for any non-static function,
  3594. # D for any global variable and I for any imported variable.
  3595. # Also find C++ and __fastcall symbols from MSVC++ or ICC,
  3596. # which start with @ or ?.
  3597. lt_cv_sys_global_symbol_pipe="$AWK ['"\
  3598. " {last_section=section; section=\$ 3};"\
  3599. " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
  3600. " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
  3601. " /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\
  3602. " /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\
  3603. " /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\
  3604. " \$ 0!~/External *\|/{next};"\
  3605. " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
  3606. " {if(hide[section]) next};"\
  3607. " {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\
  3608. " {split(\$ 0,a,/\||\r/); split(a[2],s)};"\
  3609. " s[1]~/^[@?]/{print f,s[1],s[1]; next};"\
  3610. " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\
  3611. " ' prfx=^$ac_symprfx]"
  3612. else
  3613. lt_cv_sys_global_symbol_pipe="$SED -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
  3614. fi
  3615. lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | $SED '/ __gnu_lto/d'"
  3616. # Check to see that the pipe works correctly.
  3617. pipe_works=no
  3618. rm -f conftest*
  3619. cat > conftest.$ac_ext <<_LT_EOF
  3620. #ifdef __cplusplus
  3621. extern "C" {
  3622. #endif
  3623. char nm_test_var;
  3624. void nm_test_func(void);
  3625. void nm_test_func(void){}
  3626. #ifdef __cplusplus
  3627. }
  3628. #endif
  3629. int main(){nm_test_var='a';nm_test_func();return(0);}
  3630. _LT_EOF
  3631. if AC_TRY_EVAL(ac_compile); then
  3632. # Now try to grab the symbols.
  3633. nlist=conftest.nm
  3634. if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then
  3635. # Try sorting and uniquifying the output.
  3636. if sort "$nlist" | uniq > "$nlist"T; then
  3637. mv -f "$nlist"T "$nlist"
  3638. else
  3639. rm -f "$nlist"T
  3640. fi
  3641. # Make sure that we snagged all the symbols we need.
  3642. if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
  3643. if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
  3644. cat <<_LT_EOF > conftest.$ac_ext
  3645. /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
  3646. #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE
  3647. /* DATA imports from DLLs on WIN32 can't be const, because runtime
  3648. relocations are performed -- see ld's documentation on pseudo-relocs. */
  3649. # define LT@&t@_DLSYM_CONST
  3650. #elif defined __osf__
  3651. /* This system does not cope well with relocations in const data. */
  3652. # define LT@&t@_DLSYM_CONST
  3653. #else
  3654. # define LT@&t@_DLSYM_CONST const
  3655. #endif
  3656. #ifdef __cplusplus
  3657. extern "C" {
  3658. #endif
  3659. _LT_EOF
  3660. # Now generate the symbol file.
  3661. eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
  3662. cat <<_LT_EOF >> conftest.$ac_ext
  3663. /* The mapping between symbol names and symbols. */
  3664. LT@&t@_DLSYM_CONST struct {
  3665. const char *name;
  3666. void *address;
  3667. }
  3668. lt__PROGRAM__LTX_preloaded_symbols[[]] =
  3669. {
  3670. { "@PROGRAM@", (void *) 0 },
  3671. _LT_EOF
  3672. $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
  3673. cat <<\_LT_EOF >> conftest.$ac_ext
  3674. {0, (void *) 0}
  3675. };
  3676. /* This works around a problem in FreeBSD linker */
  3677. #ifdef FREEBSD_WORKAROUND
  3678. static const void *lt_preloaded_setup() {
  3679. return lt__PROGRAM__LTX_preloaded_symbols;
  3680. }
  3681. #endif
  3682. #ifdef __cplusplus
  3683. }
  3684. #endif
  3685. _LT_EOF
  3686. # Now try linking the two files.
  3687. mv conftest.$ac_objext conftstm.$ac_objext
  3688. lt_globsym_save_LIBS=$LIBS
  3689. lt_globsym_save_CFLAGS=$CFLAGS
  3690. LIBS=conftstm.$ac_objext
  3691. CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
  3692. if AC_TRY_EVAL(ac_link) && test -s conftest$ac_exeext; then
  3693. pipe_works=yes
  3694. fi
  3695. LIBS=$lt_globsym_save_LIBS
  3696. CFLAGS=$lt_globsym_save_CFLAGS
  3697. else
  3698. echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
  3699. fi
  3700. else
  3701. echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
  3702. fi
  3703. else
  3704. echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
  3705. fi
  3706. else
  3707. echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
  3708. cat conftest.$ac_ext >&5
  3709. fi
  3710. rm -rf conftest* conftst*
  3711. # Do not use the global_symbol_pipe unless it works.
  3712. if test yes = "$pipe_works"; then
  3713. break
  3714. else
  3715. lt_cv_sys_global_symbol_pipe=
  3716. fi
  3717. done
  3718. ])
  3719. if test -z "$lt_cv_sys_global_symbol_pipe"; then
  3720. lt_cv_sys_global_symbol_to_cdecl=
  3721. fi
  3722. if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
  3723. AC_MSG_RESULT(failed)
  3724. else
  3725. AC_MSG_RESULT(ok)
  3726. fi
  3727. # Response file support.
  3728. if test "$lt_cv_nm_interface" = "MS dumpbin"; then
  3729. nm_file_list_spec='@'
  3730. elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then
  3731. nm_file_list_spec='@'
  3732. fi
  3733. _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
  3734. [Take the output of nm and produce a listing of raw symbols and C names])
  3735. _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
  3736. [Transform the output of nm in a proper C declaration])
  3737. _LT_DECL([global_symbol_to_import], [lt_cv_sys_global_symbol_to_import], [1],
  3738. [Transform the output of nm into a list of symbols to manually relocate])
  3739. _LT_DECL([global_symbol_to_c_name_address],
  3740. [lt_cv_sys_global_symbol_to_c_name_address], [1],
  3741. [Transform the output of nm in a C name address pair])
  3742. _LT_DECL([global_symbol_to_c_name_address_lib_prefix],
  3743. [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
  3744. [Transform the output of nm in a C name address pair when lib prefix is needed])
  3745. _LT_DECL([nm_interface], [lt_cv_nm_interface], [1],
  3746. [The name lister interface])
  3747. _LT_DECL([], [nm_file_list_spec], [1],
  3748. [Specify filename containing input files for $NM])
  3749. ]) # _LT_CMD_GLOBAL_SYMBOLS
  3750. # _LT_COMPILER_PIC([TAGNAME])
  3751. # ---------------------------
  3752. m4_defun([_LT_COMPILER_PIC],
  3753. [m4_require([_LT_TAG_COMPILER])dnl
  3754. _LT_TAGVAR(lt_prog_compiler_wl, $1)=
  3755. _LT_TAGVAR(lt_prog_compiler_pic, $1)=
  3756. _LT_TAGVAR(lt_prog_compiler_static, $1)=
  3757. m4_if([$1], [CXX], [
  3758. # C++ specific cases for pic, static, wl, etc.
  3759. if test yes = "$GXX"; then
  3760. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  3761. _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
  3762. case $host_os in
  3763. aix*)
  3764. # All AIX code is PIC.
  3765. if test ia64 = "$host_cpu"; then
  3766. # AIX 5 now supports IA64 processor
  3767. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  3768. fi
  3769. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  3770. ;;
  3771. amigaos*)
  3772. case $host_cpu in
  3773. powerpc)
  3774. # see comment about AmigaOS4 .so support
  3775. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  3776. ;;
  3777. m68k)
  3778. # FIXME: we need at least 68020 code to build shared libraries, but
  3779. # adding the '-m68020' flag to GCC prevents building anything better,
  3780. # like '-m68040'.
  3781. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
  3782. ;;
  3783. esac
  3784. ;;
  3785. beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
  3786. # PIC is the default for these OSes.
  3787. ;;
  3788. mingw* | cygwin* | os2* | pw32* | cegcc*)
  3789. # This hack is so that the source file can tell whether it is being
  3790. # built for inclusion in a dll (and should export symbols for example).
  3791. # Although the cygwin gcc ignores -fPIC, still need this for old-style
  3792. # (--disable-auto-import) libraries
  3793. m4_if([$1], [GCJ], [],
  3794. [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
  3795. case $host_os in
  3796. os2*)
  3797. _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static'
  3798. ;;
  3799. esac
  3800. ;;
  3801. darwin* | rhapsody*)
  3802. # PIC is the default on this platform
  3803. # Common symbols not allowed in MH_DYLIB files
  3804. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
  3805. ;;
  3806. *djgpp*)
  3807. # DJGPP does not support shared libraries at all
  3808. _LT_TAGVAR(lt_prog_compiler_pic, $1)=
  3809. ;;
  3810. haiku*)
  3811. # PIC is the default for Haiku.
  3812. # The "-static" flag exists, but is broken.
  3813. _LT_TAGVAR(lt_prog_compiler_static, $1)=
  3814. ;;
  3815. interix[[3-9]]*)
  3816. # Interix 3.x gcc -fpic/-fPIC options generate broken code.
  3817. # Instead, we relocate shared libraries at runtime.
  3818. ;;
  3819. sysv4*MP*)
  3820. if test -d /usr/nec; then
  3821. _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
  3822. fi
  3823. ;;
  3824. hpux*)
  3825. # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
  3826. # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
  3827. # sets the default TLS model and affects inlining.
  3828. case $host_cpu in
  3829. hppa*64*)
  3830. ;;
  3831. *)
  3832. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  3833. ;;
  3834. esac
  3835. ;;
  3836. *qnx* | *nto*)
  3837. # QNX uses GNU C++, but need to define -shared option too, otherwise
  3838. # it will coredump.
  3839. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
  3840. ;;
  3841. *)
  3842. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  3843. ;;
  3844. esac
  3845. else
  3846. case $host_os in
  3847. aix[[4-9]]*)
  3848. # All AIX code is PIC.
  3849. if test ia64 = "$host_cpu"; then
  3850. # AIX 5 now supports IA64 processor
  3851. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  3852. else
  3853. _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
  3854. fi
  3855. ;;
  3856. chorus*)
  3857. case $cc_basename in
  3858. cxch68*)
  3859. # Green Hills C++ Compiler
  3860. # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a"
  3861. ;;
  3862. esac
  3863. ;;
  3864. mingw* | cygwin* | os2* | pw32* | cegcc*)
  3865. # This hack is so that the source file can tell whether it is being
  3866. # built for inclusion in a dll (and should export symbols for example).
  3867. m4_if([$1], [GCJ], [],
  3868. [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
  3869. ;;
  3870. dgux*)
  3871. case $cc_basename in
  3872. ec++*)
  3873. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  3874. ;;
  3875. ghcx*)
  3876. # Green Hills C++ Compiler
  3877. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
  3878. ;;
  3879. *)
  3880. ;;
  3881. esac
  3882. ;;
  3883. freebsd* | dragonfly* | midnightbsd*)
  3884. # FreeBSD uses GNU C++
  3885. ;;
  3886. hpux9* | hpux10* | hpux11*)
  3887. case $cc_basename in
  3888. CC*)
  3889. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  3890. _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive'
  3891. if test ia64 != "$host_cpu"; then
  3892. _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
  3893. fi
  3894. ;;
  3895. aCC*)
  3896. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  3897. _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive'
  3898. case $host_cpu in
  3899. hppa*64*|ia64*)
  3900. # +Z the default
  3901. ;;
  3902. *)
  3903. _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
  3904. ;;
  3905. esac
  3906. ;;
  3907. *)
  3908. ;;
  3909. esac
  3910. ;;
  3911. interix*)
  3912. # This is c89, which is MS Visual C++ (no shared libs)
  3913. # Anyone wants to do a port?
  3914. ;;
  3915. irix5* | irix6* | nonstopux*)
  3916. case $cc_basename in
  3917. CC*)
  3918. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  3919. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
  3920. # CC pic flag -KPIC is the default.
  3921. ;;
  3922. *)
  3923. ;;
  3924. esac
  3925. ;;
  3926. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
  3927. case $cc_basename in
  3928. KCC*)
  3929. # KAI C++ Compiler
  3930. _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
  3931. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  3932. ;;
  3933. ecpc* )
  3934. # old Intel C++ for x86_64, which still supported -KPIC.
  3935. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  3936. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  3937. _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
  3938. ;;
  3939. icpc* )
  3940. # Intel C++, used to be incompatible with GCC.
  3941. # ICC 10 doesn't accept -KPIC any more.
  3942. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  3943. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  3944. _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
  3945. ;;
  3946. pgCC* | pgcpp*)
  3947. # Portland Group C++ compiler
  3948. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  3949. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
  3950. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  3951. ;;
  3952. cxx*)
  3953. # Compaq C++
  3954. # Make sure the PIC flag is empty. It appears that all Alpha
  3955. # Linux and Compaq Tru64 Unix objects are PIC.
  3956. _LT_TAGVAR(lt_prog_compiler_pic, $1)=
  3957. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
  3958. ;;
  3959. xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*)
  3960. # IBM XL 8.0, 9.0 on PPC and BlueGene
  3961. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  3962. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
  3963. _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
  3964. ;;
  3965. *)
  3966. case `$CC -V 2>&1 | $SED 5q` in
  3967. *Sun\ C*)
  3968. # Sun C++ 5.9
  3969. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  3970. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  3971. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
  3972. ;;
  3973. esac
  3974. ;;
  3975. esac
  3976. ;;
  3977. lynxos*)
  3978. ;;
  3979. m88k*)
  3980. ;;
  3981. mvs*)
  3982. case $cc_basename in
  3983. cxx*)
  3984. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
  3985. ;;
  3986. *)
  3987. ;;
  3988. esac
  3989. ;;
  3990. netbsd*)
  3991. ;;
  3992. *qnx* | *nto*)
  3993. # QNX uses GNU C++, but need to define -shared option too, otherwise
  3994. # it will coredump.
  3995. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
  3996. ;;
  3997. osf3* | osf4* | osf5*)
  3998. case $cc_basename in
  3999. KCC*)
  4000. _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
  4001. ;;
  4002. RCC*)
  4003. # Rational C++ 2.4.1
  4004. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
  4005. ;;
  4006. cxx*)
  4007. # Digital/Compaq C++
  4008. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4009. # Make sure the PIC flag is empty. It appears that all Alpha
  4010. # Linux and Compaq Tru64 Unix objects are PIC.
  4011. _LT_TAGVAR(lt_prog_compiler_pic, $1)=
  4012. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
  4013. ;;
  4014. *)
  4015. ;;
  4016. esac
  4017. ;;
  4018. psos*)
  4019. ;;
  4020. solaris*)
  4021. case $cc_basename in
  4022. CC* | sunCC*)
  4023. # Sun C++ 4.2, 5.x and Centerline C++
  4024. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  4025. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4026. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
  4027. ;;
  4028. gcx*)
  4029. # Green Hills C++ Compiler
  4030. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
  4031. ;;
  4032. *)
  4033. ;;
  4034. esac
  4035. ;;
  4036. sunos4*)
  4037. case $cc_basename in
  4038. CC*)
  4039. # Sun C++ 4.x
  4040. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
  4041. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4042. ;;
  4043. lcc*)
  4044. # Lucid
  4045. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
  4046. ;;
  4047. *)
  4048. ;;
  4049. esac
  4050. ;;
  4051. sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
  4052. case $cc_basename in
  4053. CC*)
  4054. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4055. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  4056. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4057. ;;
  4058. esac
  4059. ;;
  4060. tandem*)
  4061. case $cc_basename in
  4062. NCC*)
  4063. # NonStop-UX NCC 3.20
  4064. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  4065. ;;
  4066. *)
  4067. ;;
  4068. esac
  4069. ;;
  4070. vxworks*)
  4071. ;;
  4072. *)
  4073. _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
  4074. ;;
  4075. esac
  4076. fi
  4077. ],
  4078. [
  4079. if test yes = "$GCC"; then
  4080. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4081. _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
  4082. case $host_os in
  4083. aix*)
  4084. # All AIX code is PIC.
  4085. if test ia64 = "$host_cpu"; then
  4086. # AIX 5 now supports IA64 processor
  4087. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4088. fi
  4089. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  4090. ;;
  4091. amigaos*)
  4092. case $host_cpu in
  4093. powerpc)
  4094. # see comment about AmigaOS4 .so support
  4095. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  4096. ;;
  4097. m68k)
  4098. # FIXME: we need at least 68020 code to build shared libraries, but
  4099. # adding the '-m68020' flag to GCC prevents building anything better,
  4100. # like '-m68040'.
  4101. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
  4102. ;;
  4103. esac
  4104. ;;
  4105. beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
  4106. # PIC is the default for these OSes.
  4107. ;;
  4108. mingw* | cygwin* | pw32* | os2* | cegcc*)
  4109. # This hack is so that the source file can tell whether it is being
  4110. # built for inclusion in a dll (and should export symbols for example).
  4111. # Although the cygwin gcc ignores -fPIC, still need this for old-style
  4112. # (--disable-auto-import) libraries
  4113. m4_if([$1], [GCJ], [],
  4114. [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
  4115. case $host_os in
  4116. os2*)
  4117. _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static'
  4118. ;;
  4119. esac
  4120. ;;
  4121. darwin* | rhapsody*)
  4122. # PIC is the default on this platform
  4123. # Common symbols not allowed in MH_DYLIB files
  4124. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
  4125. ;;
  4126. haiku*)
  4127. # PIC is the default for Haiku.
  4128. # The "-static" flag exists, but is broken.
  4129. _LT_TAGVAR(lt_prog_compiler_static, $1)=
  4130. ;;
  4131. hpux*)
  4132. # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
  4133. # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
  4134. # sets the default TLS model and affects inlining.
  4135. case $host_cpu in
  4136. hppa*64*)
  4137. # +Z the default
  4138. ;;
  4139. *)
  4140. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  4141. ;;
  4142. esac
  4143. ;;
  4144. interix[[3-9]]*)
  4145. # Interix 3.x gcc -fpic/-fPIC options generate broken code.
  4146. # Instead, we relocate shared libraries at runtime.
  4147. ;;
  4148. msdosdjgpp*)
  4149. # Just because we use GCC doesn't mean we suddenly get shared libraries
  4150. # on systems that don't support them.
  4151. _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
  4152. enable_shared=no
  4153. ;;
  4154. *nto* | *qnx*)
  4155. # QNX uses GNU C++, but need to define -shared option too, otherwise
  4156. # it will coredump.
  4157. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
  4158. ;;
  4159. sysv4*MP*)
  4160. if test -d /usr/nec; then
  4161. _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
  4162. fi
  4163. ;;
  4164. *)
  4165. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  4166. ;;
  4167. esac
  4168. case $cc_basename in
  4169. nvcc*) # Cuda Compiler Driver 2.2
  4170. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker '
  4171. if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
  4172. _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)"
  4173. fi
  4174. ;;
  4175. esac
  4176. else
  4177. # PORTME Check for flag to pass linker flags through the system compiler.
  4178. case $host_os in
  4179. aix*)
  4180. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4181. if test ia64 = "$host_cpu"; then
  4182. # AIX 5 now supports IA64 processor
  4183. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4184. else
  4185. _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
  4186. fi
  4187. ;;
  4188. darwin* | rhapsody*)
  4189. # PIC is the default on this platform
  4190. # Common symbols not allowed in MH_DYLIB files
  4191. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
  4192. case $cc_basename in
  4193. nagfor*)
  4194. # NAG Fortran compiler
  4195. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
  4196. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
  4197. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4198. ;;
  4199. esac
  4200. ;;
  4201. mingw* | cygwin* | pw32* | os2* | cegcc*)
  4202. # This hack is so that the source file can tell whether it is being
  4203. # built for inclusion in a dll (and should export symbols for example).
  4204. m4_if([$1], [GCJ], [],
  4205. [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
  4206. case $host_os in
  4207. os2*)
  4208. _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static'
  4209. ;;
  4210. esac
  4211. ;;
  4212. hpux9* | hpux10* | hpux11*)
  4213. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4214. # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
  4215. # not for PA HP-UX.
  4216. case $host_cpu in
  4217. hppa*64*|ia64*)
  4218. # +Z the default
  4219. ;;
  4220. *)
  4221. _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
  4222. ;;
  4223. esac
  4224. # Is there a better lt_prog_compiler_static that works with the bundled CC?
  4225. _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive'
  4226. ;;
  4227. irix5* | irix6* | nonstopux*)
  4228. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4229. # PIC (with -KPIC) is the default.
  4230. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
  4231. ;;
  4232. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
  4233. case $cc_basename in
  4234. # old Intel for x86_64, which still supported -KPIC.
  4235. ecc*)
  4236. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4237. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  4238. _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
  4239. ;;
  4240. # icc used to be incompatible with GCC.
  4241. # ICC 10 doesn't accept -KPIC any more.
  4242. icc* | ifort*)
  4243. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4244. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  4245. _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
  4246. ;;
  4247. # Lahey Fortran 8.1.
  4248. lf95*)
  4249. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4250. _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
  4251. _LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
  4252. ;;
  4253. nagfor*)
  4254. # NAG Fortran compiler
  4255. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
  4256. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
  4257. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4258. ;;
  4259. tcc*)
  4260. # Fabrice Bellard et al's Tiny C Compiler
  4261. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4262. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  4263. _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
  4264. ;;
  4265. pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
  4266. # Portland Group compilers (*not* the Pentium gcc compiler,
  4267. # which looks to be a dead project)
  4268. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4269. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
  4270. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4271. ;;
  4272. ccc*)
  4273. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4274. # All Alpha code is PIC.
  4275. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
  4276. ;;
  4277. xl* | bgxl* | bgf* | mpixl*)
  4278. # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
  4279. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4280. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
  4281. _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
  4282. ;;
  4283. *)
  4284. case `$CC -V 2>&1 | $SED 5q` in
  4285. *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*)
  4286. # Sun Fortran 8.3 passes all unrecognized flags to the linker
  4287. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  4288. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4289. _LT_TAGVAR(lt_prog_compiler_wl, $1)=''
  4290. ;;
  4291. *Sun\ F* | *Sun*Fortran*)
  4292. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  4293. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4294. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
  4295. ;;
  4296. *Sun\ C*)
  4297. # Sun C 5.9
  4298. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  4299. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4300. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4301. ;;
  4302. *Intel*\ [[CF]]*Compiler*)
  4303. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4304. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  4305. _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
  4306. ;;
  4307. *Portland\ Group*)
  4308. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4309. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
  4310. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4311. ;;
  4312. esac
  4313. ;;
  4314. esac
  4315. ;;
  4316. newsos6)
  4317. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  4318. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4319. ;;
  4320. *nto* | *qnx*)
  4321. # QNX uses GNU C++, but need to define -shared option too, otherwise
  4322. # it will coredump.
  4323. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
  4324. ;;
  4325. osf3* | osf4* | osf5*)
  4326. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4327. # All OSF/1 code is PIC.
  4328. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
  4329. ;;
  4330. rdos*)
  4331. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
  4332. ;;
  4333. solaris*)
  4334. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  4335. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4336. case $cc_basename in
  4337. f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
  4338. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
  4339. *)
  4340. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
  4341. esac
  4342. ;;
  4343. sunos4*)
  4344. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
  4345. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
  4346. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4347. ;;
  4348. sysv4 | sysv4.2uw2* | sysv4.3*)
  4349. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4350. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  4351. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4352. ;;
  4353. sysv4*MP*)
  4354. if test -d /usr/nec; then
  4355. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
  4356. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4357. fi
  4358. ;;
  4359. sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
  4360. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4361. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  4362. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4363. ;;
  4364. unicos*)
  4365. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  4366. _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
  4367. ;;
  4368. uts4*)
  4369. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
  4370. _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  4371. ;;
  4372. *)
  4373. _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
  4374. ;;
  4375. esac
  4376. fi
  4377. ])
  4378. case $host_os in
  4379. # For platforms that do not support PIC, -DPIC is meaningless:
  4380. *djgpp*)
  4381. _LT_TAGVAR(lt_prog_compiler_pic, $1)=
  4382. ;;
  4383. *)
  4384. _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
  4385. ;;
  4386. esac
  4387. AC_CACHE_CHECK([for $compiler option to produce PIC],
  4388. [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)],
  4389. [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
  4390. _LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)
  4391. #
  4392. # Check to make sure the PIC flag actually works.
  4393. #
  4394. if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
  4395. _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works],
  4396. [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)],
  4397. [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [],
  4398. [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in
  4399. "" | " "*) ;;
  4400. *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;;
  4401. esac],
  4402. [_LT_TAGVAR(lt_prog_compiler_pic, $1)=
  4403. _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
  4404. fi
  4405. _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
  4406. [Additional compiler flags for building library objects])
  4407. _LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
  4408. [How to pass a linker flag through the compiler])
  4409. #
  4410. # Check to make sure the static flag actually works.
  4411. #
  4412. wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\"
  4413. _LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
  4414. _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1),
  4415. $lt_tmp_static_flag,
  4416. [],
  4417. [_LT_TAGVAR(lt_prog_compiler_static, $1)=])
  4418. _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
  4419. [Compiler flag to prevent dynamic linking])
  4420. ])# _LT_COMPILER_PIC
  4421. # _LT_LINKER_SHLIBS([TAGNAME])
  4422. # ----------------------------
  4423. # See if the linker supports building shared libraries.
  4424. m4_defun([_LT_LINKER_SHLIBS],
  4425. [AC_REQUIRE([LT_PATH_LD])dnl
  4426. AC_REQUIRE([LT_PATH_NM])dnl
  4427. m4_require([_LT_PATH_MANIFEST_TOOL])dnl
  4428. m4_require([_LT_FILEUTILS_DEFAULTS])dnl
  4429. m4_require([_LT_DECL_EGREP])dnl
  4430. m4_require([_LT_DECL_SED])dnl
  4431. m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
  4432. m4_require([_LT_TAG_COMPILER])dnl
  4433. AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
  4434. m4_if([$1], [CXX], [
  4435. _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
  4436. _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
  4437. case $host_os in
  4438. aix[[4-9]]*)
  4439. # If we're using GNU nm, then we don't want the "-C" option.
  4440. # -C means demangle to GNU nm, but means don't demangle to AIX nm.
  4441. # Without the "-l" option, or with the "-B" option, AIX nm treats
  4442. # weak defined symbols like other global defined symbols, whereas
  4443. # GNU nm marks them as "W".
  4444. # While the 'weak' keyword is ignored in the Export File, we need
  4445. # it in the Import File for the 'aix-soname' feature, so we have
  4446. # to replace the "-B" option with "-P" for AIX nm.
  4447. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
  4448. _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols'
  4449. else
  4450. _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
  4451. fi
  4452. ;;
  4453. pw32*)
  4454. _LT_TAGVAR(export_symbols_cmds, $1)=$ltdll_cmds
  4455. ;;
  4456. cygwin* | mingw* | cegcc*)
  4457. case $cc_basename in
  4458. cl* | icl*)
  4459. _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
  4460. ;;
  4461. *)
  4462. _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
  4463. _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
  4464. ;;
  4465. esac
  4466. ;;
  4467. *)
  4468. _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
  4469. ;;
  4470. esac
  4471. ], [
  4472. runpath_var=
  4473. _LT_TAGVAR(allow_undefined_flag, $1)=
  4474. _LT_TAGVAR(always_export_symbols, $1)=no
  4475. _LT_TAGVAR(archive_cmds, $1)=
  4476. _LT_TAGVAR(archive_expsym_cmds, $1)=
  4477. _LT_TAGVAR(compiler_needs_object, $1)=no
  4478. _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
  4479. _LT_TAGVAR(export_dynamic_flag_spec, $1)=
  4480. _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
  4481. _LT_TAGVAR(hardcode_automatic, $1)=no
  4482. _LT_TAGVAR(hardcode_direct, $1)=no
  4483. _LT_TAGVAR(hardcode_direct_absolute, $1)=no
  4484. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
  4485. _LT_TAGVAR(hardcode_libdir_separator, $1)=
  4486. _LT_TAGVAR(hardcode_minus_L, $1)=no
  4487. _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
  4488. _LT_TAGVAR(inherit_rpath, $1)=no
  4489. _LT_TAGVAR(link_all_deplibs, $1)=unknown
  4490. _LT_TAGVAR(module_cmds, $1)=
  4491. _LT_TAGVAR(module_expsym_cmds, $1)=
  4492. _LT_TAGVAR(old_archive_from_new_cmds, $1)=
  4493. _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)=
  4494. _LT_TAGVAR(thread_safe_flag_spec, $1)=
  4495. _LT_TAGVAR(whole_archive_flag_spec, $1)=
  4496. # include_expsyms should be a list of space-separated symbols to be *always*
  4497. # included in the symbol list
  4498. _LT_TAGVAR(include_expsyms, $1)=
  4499. # exclude_expsyms can be an extended regexp of symbols to exclude
  4500. # it will be wrapped by ' (' and ')$', so one must not match beginning or
  4501. # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc',
  4502. # as well as any symbol that contains 'd'.
  4503. _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
  4504. # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
  4505. # platforms (ab)use it in PIC code, but their linkers get confused if
  4506. # the symbol is explicitly referenced. Since portable code cannot
  4507. # rely on this symbol name, it's probably fine to never include it in
  4508. # preloaded symbol tables.
  4509. # Exclude shared library initialization/finalization symbols.
  4510. dnl Note also adjust exclude_expsyms for C++ above.
  4511. extract_expsyms_cmds=
  4512. case $host_os in
  4513. cygwin* | mingw* | pw32* | cegcc*)
  4514. # FIXME: the MSVC++ and ICC port hasn't been tested in a loooong time
  4515. # When not using gcc, we currently assume that we are using
  4516. # Microsoft Visual C++ or Intel C++ Compiler.
  4517. if test yes != "$GCC"; then
  4518. with_gnu_ld=no
  4519. fi
  4520. ;;
  4521. interix*)
  4522. # we just hope/assume this is gcc and not c89 (= MSVC++ or ICC)
  4523. with_gnu_ld=yes
  4524. ;;
  4525. openbsd* | bitrig*)
  4526. with_gnu_ld=no
  4527. ;;
  4528. esac
  4529. _LT_TAGVAR(ld_shlibs, $1)=yes
  4530. # On some targets, GNU ld is compatible enough with the native linker
  4531. # that we're better off using the native interface for both.
  4532. lt_use_gnu_ld_interface=no
  4533. if test yes = "$with_gnu_ld"; then
  4534. case $host_os in
  4535. aix*)
  4536. # The AIX port of GNU ld has always aspired to compatibility
  4537. # with the native linker. However, as the warning in the GNU ld
  4538. # block says, versions before 2.19.5* couldn't really create working
  4539. # shared libraries, regardless of the interface used.
  4540. case `$LD -v 2>&1` in
  4541. *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
  4542. *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;;
  4543. *\ \(GNU\ Binutils\)\ [[3-9]]*) ;;
  4544. *)
  4545. lt_use_gnu_ld_interface=yes
  4546. ;;
  4547. esac
  4548. ;;
  4549. *)
  4550. lt_use_gnu_ld_interface=yes
  4551. ;;
  4552. esac
  4553. fi
  4554. if test yes = "$lt_use_gnu_ld_interface"; then
  4555. # If archive_cmds runs LD, not CC, wlarc should be empty
  4556. wlarc='$wl'
  4557. # Set some defaults for GNU ld with shared library support. These
  4558. # are reset later if shared libraries are not supported. Putting them
  4559. # here allows them to be overridden if necessary.
  4560. runpath_var=LD_RUN_PATH
  4561. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
  4562. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
  4563. # ancient GNU ld didn't support --whole-archive et. al.
  4564. if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
  4565. _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
  4566. else
  4567. _LT_TAGVAR(whole_archive_flag_spec, $1)=
  4568. fi
  4569. supports_anon_versioning=no
  4570. case `$LD -v | $SED -e 's/([[^)]]\+)\s\+//' 2>&1` in
  4571. *GNU\ gold*) supports_anon_versioning=yes ;;
  4572. *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
  4573. *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
  4574. *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
  4575. *\ 2.11.*) ;; # other 2.11 versions
  4576. *) supports_anon_versioning=yes ;;
  4577. esac
  4578. # See if GNU ld supports shared libraries.
  4579. case $host_os in
  4580. aix[[3-9]]*)
  4581. # On AIX/PPC, the GNU linker is very broken
  4582. if test ia64 != "$host_cpu"; then
  4583. _LT_TAGVAR(ld_shlibs, $1)=no
  4584. cat <<_LT_EOF 1>&2
  4585. *** Warning: the GNU linker, at least up to release 2.19, is reported
  4586. *** to be unable to reliably create shared libraries on AIX.
  4587. *** Therefore, libtool is disabling shared libraries support. If you
  4588. *** really care for shared libraries, you may want to install binutils
  4589. *** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
  4590. *** You will then need to restart the configuration process.
  4591. _LT_EOF
  4592. fi
  4593. ;;
  4594. amigaos*)
  4595. case $host_cpu in
  4596. powerpc)
  4597. # see comment about AmigaOS4 .so support
  4598. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
  4599. _LT_TAGVAR(archive_expsym_cmds, $1)=''
  4600. ;;
  4601. m68k)
  4602. _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
  4603. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  4604. _LT_TAGVAR(hardcode_minus_L, $1)=yes
  4605. ;;
  4606. esac
  4607. ;;
  4608. beos*)
  4609. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
  4610. _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
  4611. # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
  4612. # support --undefined. This deserves some investigation. FIXME
  4613. _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
  4614. else
  4615. _LT_TAGVAR(ld_shlibs, $1)=no
  4616. fi
  4617. ;;
  4618. cygwin* | mingw* | pw32* | cegcc*)
  4619. # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
  4620. # as there is no search path for DLLs.
  4621. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  4622. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols'
  4623. _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
  4624. _LT_TAGVAR(always_export_symbols, $1)=no
  4625. _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
  4626. _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
  4627. _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
  4628. if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
  4629. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
  4630. # If the export-symbols file already is a .def file, use it as
  4631. # is; otherwise, prepend EXPORTS...
  4632. _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then
  4633. cp $export_symbols $output_objdir/$soname.def;
  4634. else
  4635. echo EXPORTS > $output_objdir/$soname.def;
  4636. cat $export_symbols >> $output_objdir/$soname.def;
  4637. fi~
  4638. $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
  4639. else
  4640. _LT_TAGVAR(ld_shlibs, $1)=no
  4641. fi
  4642. ;;
  4643. haiku*)
  4644. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
  4645. _LT_TAGVAR(link_all_deplibs, $1)=yes
  4646. ;;
  4647. os2*)
  4648. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  4649. _LT_TAGVAR(hardcode_minus_L, $1)=yes
  4650. _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
  4651. shrext_cmds=.dll
  4652. _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
  4653. $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
  4654. $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
  4655. $ECHO EXPORTS >> $output_objdir/$libname.def~
  4656. emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
  4657. $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
  4658. emximp -o $lib $output_objdir/$libname.def'
  4659. _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
  4660. $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
  4661. $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
  4662. $ECHO EXPORTS >> $output_objdir/$libname.def~
  4663. prefix_cmds="$SED"~
  4664. if test EXPORTS = "`$SED 1q $export_symbols`"; then
  4665. prefix_cmds="$prefix_cmds -e 1d";
  4666. fi~
  4667. prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
  4668. cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
  4669. $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
  4670. emximp -o $lib $output_objdir/$libname.def'
  4671. _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
  4672. _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
  4673. _LT_TAGVAR(file_list_spec, $1)='@'
  4674. ;;
  4675. interix[[3-9]]*)
  4676. _LT_TAGVAR(hardcode_direct, $1)=no
  4677. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  4678. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
  4679. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
  4680. # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
  4681. # Instead, shared libraries are loaded at an image base (0x10000000 by
  4682. # default) and relocated if they conflict, which is a slow very memory
  4683. # consuming and fragmenting process. To avoid this, we pick a random,
  4684. # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
  4685. # time. Moving up from 0x10000000 also allows more sbrk(2) space.
  4686. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
  4687. _LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
  4688. ;;
  4689. gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
  4690. tmp_diet=no
  4691. if test linux-dietlibc = "$host_os"; then
  4692. case $cc_basename in
  4693. diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
  4694. esac
  4695. fi
  4696. if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
  4697. && test no = "$tmp_diet"
  4698. then
  4699. tmp_addflag=' $pic_flag'
  4700. tmp_sharedflag='-shared'
  4701. case $cc_basename,$host_cpu in
  4702. pgcc*) # Portland Group C compiler
  4703. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
  4704. tmp_addflag=' $pic_flag'
  4705. ;;
  4706. pgf77* | pgf90* | pgf95* | pgfortran*)
  4707. # Portland Group f77 and f90 compilers
  4708. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
  4709. tmp_addflag=' $pic_flag -Mnomain' ;;
  4710. ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
  4711. tmp_addflag=' -i_dynamic' ;;
  4712. efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
  4713. tmp_addflag=' -i_dynamic -nofor_main' ;;
  4714. ifc* | ifort*) # Intel Fortran compiler
  4715. tmp_addflag=' -nofor_main' ;;
  4716. lf95*) # Lahey Fortran 8.1
  4717. _LT_TAGVAR(whole_archive_flag_spec, $1)=
  4718. tmp_sharedflag='--shared' ;;
  4719. nagfor*) # NAGFOR 5.3
  4720. tmp_sharedflag='-Wl,-shared' ;;
  4721. xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
  4722. tmp_sharedflag='-qmkshrobj'
  4723. tmp_addflag= ;;
  4724. nvcc*) # Cuda Compiler Driver 2.2
  4725. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
  4726. _LT_TAGVAR(compiler_needs_object, $1)=yes
  4727. ;;
  4728. esac
  4729. case `$CC -V 2>&1 | $SED 5q` in
  4730. *Sun\ C*) # Sun C 5.9
  4731. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
  4732. _LT_TAGVAR(compiler_needs_object, $1)=yes
  4733. tmp_sharedflag='-G' ;;
  4734. *Sun\ F*) # Sun Fortran 8.3
  4735. tmp_sharedflag='-G' ;;
  4736. esac
  4737. _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
  4738. if test yes = "$supports_anon_versioning"; then
  4739. _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
  4740. cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
  4741. echo "local: *; };" >> $output_objdir/$libname.ver~
  4742. $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
  4743. fi
  4744. case $cc_basename in
  4745. tcc*)
  4746. _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic'
  4747. ;;
  4748. xlf* | bgf* | bgxlf* | mpixlf*)
  4749. # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
  4750. _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
  4751. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
  4752. _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
  4753. if test yes = "$supports_anon_versioning"; then
  4754. _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
  4755. cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
  4756. echo "local: *; };" >> $output_objdir/$libname.ver~
  4757. $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
  4758. fi
  4759. ;;
  4760. esac
  4761. else
  4762. _LT_TAGVAR(ld_shlibs, $1)=no
  4763. fi
  4764. ;;
  4765. netbsd*)
  4766. if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
  4767. _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
  4768. wlarc=
  4769. else
  4770. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
  4771. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
  4772. fi
  4773. ;;
  4774. solaris*)
  4775. if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
  4776. _LT_TAGVAR(ld_shlibs, $1)=no
  4777. cat <<_LT_EOF 1>&2
  4778. *** Warning: The releases 2.8.* of the GNU linker cannot reliably
  4779. *** create shared libraries on Solaris systems. Therefore, libtool
  4780. *** is disabling shared libraries support. We urge you to upgrade GNU
  4781. *** binutils to release 2.9.1 or newer. Another option is to modify
  4782. *** your PATH or compiler configuration so that the native linker is
  4783. *** used, and then restart.
  4784. _LT_EOF
  4785. elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
  4786. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
  4787. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
  4788. else
  4789. _LT_TAGVAR(ld_shlibs, $1)=no
  4790. fi
  4791. ;;
  4792. sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
  4793. case `$LD -v 2>&1` in
  4794. *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
  4795. _LT_TAGVAR(ld_shlibs, $1)=no
  4796. cat <<_LT_EOF 1>&2
  4797. *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot
  4798. *** reliably create shared libraries on SCO systems. Therefore, libtool
  4799. *** is disabling shared libraries support. We urge you to upgrade GNU
  4800. *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
  4801. *** your PATH or compiler configuration so that the native linker is
  4802. *** used, and then restart.
  4803. _LT_EOF
  4804. ;;
  4805. *)
  4806. # For security reasons, it is highly recommended that you always
  4807. # use absolute paths for naming shared libraries, and exclude the
  4808. # DT_RUNPATH tag from executables and libraries. But doing so
  4809. # requires that you compile everything twice, which is a pain.
  4810. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
  4811. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
  4812. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
  4813. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
  4814. else
  4815. _LT_TAGVAR(ld_shlibs, $1)=no
  4816. fi
  4817. ;;
  4818. esac
  4819. ;;
  4820. sunos4*)
  4821. _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
  4822. wlarc=
  4823. _LT_TAGVAR(hardcode_direct, $1)=yes
  4824. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  4825. ;;
  4826. *)
  4827. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
  4828. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
  4829. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
  4830. else
  4831. _LT_TAGVAR(ld_shlibs, $1)=no
  4832. fi
  4833. ;;
  4834. esac
  4835. if test no = "$_LT_TAGVAR(ld_shlibs, $1)"; then
  4836. runpath_var=
  4837. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
  4838. _LT_TAGVAR(export_dynamic_flag_spec, $1)=
  4839. _LT_TAGVAR(whole_archive_flag_spec, $1)=
  4840. fi
  4841. else
  4842. # PORTME fill in a description of your system's linker (not GNU ld)
  4843. case $host_os in
  4844. aix3*)
  4845. _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
  4846. _LT_TAGVAR(always_export_symbols, $1)=yes
  4847. _LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
  4848. # Note: this linker hardcodes the directories in LIBPATH if there
  4849. # are no directories specified by -L.
  4850. _LT_TAGVAR(hardcode_minus_L, $1)=yes
  4851. if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then
  4852. # Neither direct hardcoding nor static linking is supported with a
  4853. # broken collect2.
  4854. _LT_TAGVAR(hardcode_direct, $1)=unsupported
  4855. fi
  4856. ;;
  4857. aix[[4-9]]*)
  4858. if test ia64 = "$host_cpu"; then
  4859. # On IA64, the linker does run time linking by default, so we don't
  4860. # have to do anything special.
  4861. aix_use_runtimelinking=no
  4862. exp_sym_flag='-Bexport'
  4863. no_entry_flag=
  4864. else
  4865. # If we're using GNU nm, then we don't want the "-C" option.
  4866. # -C means demangle to GNU nm, but means don't demangle to AIX nm.
  4867. # Without the "-l" option, or with the "-B" option, AIX nm treats
  4868. # weak defined symbols like other global defined symbols, whereas
  4869. # GNU nm marks them as "W".
  4870. # While the 'weak' keyword is ignored in the Export File, we need
  4871. # it in the Import File for the 'aix-soname' feature, so we have
  4872. # to replace the "-B" option with "-P" for AIX nm.
  4873. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
  4874. _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols'
  4875. else
  4876. _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
  4877. fi
  4878. aix_use_runtimelinking=no
  4879. # Test if we are trying to use run time linking or normal
  4880. # AIX style linking. If -brtl is somewhere in LDFLAGS, we
  4881. # have runtime linking enabled, and use it for executables.
  4882. # For shared libraries, we enable/disable runtime linking
  4883. # depending on the kind of the shared library created -
  4884. # when "with_aix_soname,aix_use_runtimelinking" is:
  4885. # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables
  4886. # "aix,yes" lib.so shared, rtl:yes, for executables
  4887. # lib.a static archive
  4888. # "both,no" lib.so.V(shr.o) shared, rtl:yes
  4889. # lib.a(lib.so.V) shared, rtl:no, for executables
  4890. # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
  4891. # lib.a(lib.so.V) shared, rtl:no
  4892. # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables
  4893. # lib.a static archive
  4894. case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
  4895. for ld_flag in $LDFLAGS; do
  4896. if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then
  4897. aix_use_runtimelinking=yes
  4898. break
  4899. fi
  4900. done
  4901. if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
  4902. # With aix-soname=svr4, we create the lib.so.V shared archives only,
  4903. # so we don't have lib.a shared libs to link our executables.
  4904. # We have to force runtime linking in this case.
  4905. aix_use_runtimelinking=yes
  4906. LDFLAGS="$LDFLAGS -Wl,-brtl"
  4907. fi
  4908. ;;
  4909. esac
  4910. exp_sym_flag='-bexport'
  4911. no_entry_flag='-bnoentry'
  4912. fi
  4913. # When large executables or shared objects are built, AIX ld can
  4914. # have problems creating the table of contents. If linking a library
  4915. # or program results in "error TOC overflow" add -mminimal-toc to
  4916. # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
  4917. # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
  4918. _LT_TAGVAR(archive_cmds, $1)=''
  4919. _LT_TAGVAR(hardcode_direct, $1)=yes
  4920. _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
  4921. _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
  4922. _LT_TAGVAR(link_all_deplibs, $1)=yes
  4923. _LT_TAGVAR(file_list_spec, $1)='$wl-f,'
  4924. case $with_aix_soname,$aix_use_runtimelinking in
  4925. aix,*) ;; # traditional, no import file
  4926. svr4,* | *,yes) # use import file
  4927. # The Import File defines what to hardcode.
  4928. _LT_TAGVAR(hardcode_direct, $1)=no
  4929. _LT_TAGVAR(hardcode_direct_absolute, $1)=no
  4930. ;;
  4931. esac
  4932. if test yes = "$GCC"; then
  4933. case $host_os in aix4.[[012]]|aix4.[[012]].*)
  4934. # We only want to do this on AIX 4.2 and lower, the check
  4935. # below for broken collect2 doesn't work under 4.3+
  4936. collect2name=`$CC -print-prog-name=collect2`
  4937. if test -f "$collect2name" &&
  4938. strings "$collect2name" | $GREP resolve_lib_name >/dev/null
  4939. then
  4940. # We have reworked collect2
  4941. :
  4942. else
  4943. # We have old collect2
  4944. _LT_TAGVAR(hardcode_direct, $1)=unsupported
  4945. # It fails to find uninstalled libraries when the uninstalled
  4946. # path is not listed in the libpath. Setting hardcode_minus_L
  4947. # to unsupported forces relinking
  4948. _LT_TAGVAR(hardcode_minus_L, $1)=yes
  4949. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  4950. _LT_TAGVAR(hardcode_libdir_separator, $1)=
  4951. fi
  4952. ;;
  4953. esac
  4954. shared_flag='-shared'
  4955. if test yes = "$aix_use_runtimelinking"; then
  4956. shared_flag="$shared_flag "'$wl-G'
  4957. fi
  4958. # Need to ensure runtime linking is disabled for the traditional
  4959. # shared library, or the linker may eventually find shared libraries
  4960. # /with/ Import File - we do not want to mix them.
  4961. shared_flag_aix='-shared'
  4962. shared_flag_svr4='-shared $wl-G'
  4963. else
  4964. # not using gcc
  4965. if test ia64 = "$host_cpu"; then
  4966. # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
  4967. # chokes on -Wl,-G. The following line is correct:
  4968. shared_flag='-G'
  4969. else
  4970. if test yes = "$aix_use_runtimelinking"; then
  4971. shared_flag='$wl-G'
  4972. else
  4973. shared_flag='$wl-bM:SRE'
  4974. fi
  4975. shared_flag_aix='$wl-bM:SRE'
  4976. shared_flag_svr4='$wl-G'
  4977. fi
  4978. fi
  4979. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall'
  4980. # It seems that -bexpall does not export symbols beginning with
  4981. # underscore (_), so it is better to generate a list of symbols to export.
  4982. _LT_TAGVAR(always_export_symbols, $1)=yes
  4983. if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
  4984. # Warning - without using the other runtime loading flags (-brtl),
  4985. # -berok will link without error, but may produce a broken library.
  4986. _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
  4987. # Determine the default libpath from the value encoded in an
  4988. # empty executable.
  4989. _LT_SYS_MODULE_PATH_AIX([$1])
  4990. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath"
  4991. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag
  4992. else
  4993. if test ia64 = "$host_cpu"; then
  4994. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib'
  4995. _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
  4996. _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols"
  4997. else
  4998. # Determine the default libpath from the value encoded in an
  4999. # empty executable.
  5000. _LT_SYS_MODULE_PATH_AIX([$1])
  5001. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath"
  5002. # Warning - without using the other run time loading flags,
  5003. # -berok will link without error, but may produce a broken library.
  5004. _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok'
  5005. _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok'
  5006. if test yes = "$with_gnu_ld"; then
  5007. # We only use this code for GNU lds that support --whole-archive.
  5008. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive'
  5009. else
  5010. # Exported symbols can be pulled into shared objects from archives
  5011. _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
  5012. fi
  5013. _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
  5014. _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
  5015. # -brtl affects multiple linker settings, -berok does not and is overridden later
  5016. compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`'
  5017. if test svr4 != "$with_aix_soname"; then
  5018. # This is similar to how AIX traditionally builds its shared libraries.
  5019. _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname'
  5020. fi
  5021. if test aix != "$with_aix_soname"; then
  5022. _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp'
  5023. else
  5024. # used by -dlpreopen to get the symbols
  5025. _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir'
  5026. fi
  5027. _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d'
  5028. fi
  5029. fi
  5030. ;;
  5031. amigaos*)
  5032. case $host_cpu in
  5033. powerpc)
  5034. # see comment about AmigaOS4 .so support
  5035. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
  5036. _LT_TAGVAR(archive_expsym_cmds, $1)=''
  5037. ;;
  5038. m68k)
  5039. _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
  5040. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  5041. _LT_TAGVAR(hardcode_minus_L, $1)=yes
  5042. ;;
  5043. esac
  5044. ;;
  5045. bsdi[[45]]*)
  5046. _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
  5047. ;;
  5048. cygwin* | mingw* | pw32* | cegcc*)
  5049. # When not using gcc, we currently assume that we are using
  5050. # Microsoft Visual C++ or Intel C++ Compiler.
  5051. # hardcode_libdir_flag_spec is actually meaningless, as there is
  5052. # no search path for DLLs.
  5053. case $cc_basename in
  5054. cl* | icl*)
  5055. # Native MSVC or ICC
  5056. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
  5057. _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
  5058. _LT_TAGVAR(always_export_symbols, $1)=yes
  5059. _LT_TAGVAR(file_list_spec, $1)='@'
  5060. # Tell ltmain to make .lib files, not .a files.
  5061. libext=lib
  5062. # Tell ltmain to make .dll files, not .so files.
  5063. shrext_cmds=.dll
  5064. # FIXME: Setting linknames here is a bad hack.
  5065. _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
  5066. _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then
  5067. cp "$export_symbols" "$output_objdir/$soname.def";
  5068. echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
  5069. else
  5070. $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
  5071. fi~
  5072. $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
  5073. linknames='
  5074. # The linker will not automatically build a static lib if we build a DLL.
  5075. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
  5076. _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
  5077. _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
  5078. _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
  5079. # Don't use ranlib
  5080. _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
  5081. _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
  5082. lt_tool_outputfile="@TOOL_OUTPUT@"~
  5083. case $lt_outputfile in
  5084. *.exe|*.EXE) ;;
  5085. *)
  5086. lt_outputfile=$lt_outputfile.exe
  5087. lt_tool_outputfile=$lt_tool_outputfile.exe
  5088. ;;
  5089. esac~
  5090. if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
  5091. $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
  5092. $RM "$lt_outputfile.manifest";
  5093. fi'
  5094. ;;
  5095. *)
  5096. # Assume MSVC and ICC wrapper
  5097. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
  5098. _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
  5099. # Tell ltmain to make .lib files, not .a files.
  5100. libext=lib
  5101. # Tell ltmain to make .dll files, not .so files.
  5102. shrext_cmds=.dll
  5103. # FIXME: Setting linknames here is a bad hack.
  5104. _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
  5105. # The linker will automatically build a .lib file if we build a DLL.
  5106. _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
  5107. # FIXME: Should let the user specify the lib program.
  5108. _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
  5109. _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
  5110. ;;
  5111. esac
  5112. ;;
  5113. darwin* | rhapsody*)
  5114. _LT_DARWIN_LINKER_FEATURES($1)
  5115. ;;
  5116. dgux*)
  5117. _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  5118. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  5119. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  5120. ;;
  5121. # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
  5122. # support. Future versions do this automatically, but an explicit c++rt0.o
  5123. # does not break anything, and helps significantly (at the cost of a little
  5124. # extra space).
  5125. freebsd2.2*)
  5126. _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
  5127. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
  5128. _LT_TAGVAR(hardcode_direct, $1)=yes
  5129. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  5130. ;;
  5131. # Unfortunately, older versions of FreeBSD 2 do not have this feature.
  5132. freebsd2.*)
  5133. _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
  5134. _LT_TAGVAR(hardcode_direct, $1)=yes
  5135. _LT_TAGVAR(hardcode_minus_L, $1)=yes
  5136. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  5137. ;;
  5138. # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
  5139. freebsd* | dragonfly* | midnightbsd*)
  5140. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
  5141. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
  5142. _LT_TAGVAR(hardcode_direct, $1)=yes
  5143. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  5144. ;;
  5145. hpux9*)
  5146. if test yes = "$GCC"; then
  5147. _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
  5148. else
  5149. _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
  5150. fi
  5151. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
  5152. _LT_TAGVAR(hardcode_libdir_separator, $1)=:
  5153. _LT_TAGVAR(hardcode_direct, $1)=yes
  5154. # hardcode_minus_L: Not really in the search PATH,
  5155. # but as the default location of the library.
  5156. _LT_TAGVAR(hardcode_minus_L, $1)=yes
  5157. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
  5158. ;;
  5159. hpux10*)
  5160. if test yes,no = "$GCC,$with_gnu_ld"; then
  5161. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
  5162. else
  5163. _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
  5164. fi
  5165. if test no = "$with_gnu_ld"; then
  5166. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
  5167. _LT_TAGVAR(hardcode_libdir_separator, $1)=:
  5168. _LT_TAGVAR(hardcode_direct, $1)=yes
  5169. _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
  5170. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
  5171. # hardcode_minus_L: Not really in the search PATH,
  5172. # but as the default location of the library.
  5173. _LT_TAGVAR(hardcode_minus_L, $1)=yes
  5174. fi
  5175. ;;
  5176. hpux11*)
  5177. if test yes,no = "$GCC,$with_gnu_ld"; then
  5178. case $host_cpu in
  5179. hppa*64*)
  5180. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
  5181. ;;
  5182. ia64*)
  5183. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
  5184. ;;
  5185. *)
  5186. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
  5187. ;;
  5188. esac
  5189. else
  5190. case $host_cpu in
  5191. hppa*64*)
  5192. _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
  5193. ;;
  5194. ia64*)
  5195. _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
  5196. ;;
  5197. *)
  5198. m4_if($1, [], [
  5199. # Older versions of the 11.00 compiler do not understand -b yet
  5200. # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
  5201. _LT_LINKER_OPTION([if $CC understands -b],
  5202. _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b],
  5203. [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'],
  5204. [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])],
  5205. [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'])
  5206. ;;
  5207. esac
  5208. fi
  5209. if test no = "$with_gnu_ld"; then
  5210. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
  5211. _LT_TAGVAR(hardcode_libdir_separator, $1)=:
  5212. case $host_cpu in
  5213. hppa*64*|ia64*)
  5214. _LT_TAGVAR(hardcode_direct, $1)=no
  5215. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  5216. ;;
  5217. *)
  5218. _LT_TAGVAR(hardcode_direct, $1)=yes
  5219. _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
  5220. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
  5221. # hardcode_minus_L: Not really in the search PATH,
  5222. # but as the default location of the library.
  5223. _LT_TAGVAR(hardcode_minus_L, $1)=yes
  5224. ;;
  5225. esac
  5226. fi
  5227. ;;
  5228. irix5* | irix6* | nonstopux*)
  5229. if test yes = "$GCC"; then
  5230. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
  5231. # Try to use the -exported_symbol ld option, if it does not
  5232. # work, assume that -exports_file does not work either and
  5233. # implicitly export all symbols.
  5234. # This should be the same for all languages, so no per-tag cache variable.
  5235. AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol],
  5236. [lt_cv_irix_exported_symbol],
  5237. [save_LDFLAGS=$LDFLAGS
  5238. LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null"
  5239. AC_LINK_IFELSE(
  5240. [AC_LANG_SOURCE(
  5241. [AC_LANG_CASE([C], [[int foo (void) { return 0; }]],
  5242. [C++], [[int foo (void) { return 0; }]],
  5243. [Fortran 77], [[
  5244. subroutine foo
  5245. end]],
  5246. [Fortran], [[
  5247. subroutine foo
  5248. end]])])],
  5249. [lt_cv_irix_exported_symbol=yes],
  5250. [lt_cv_irix_exported_symbol=no])
  5251. LDFLAGS=$save_LDFLAGS])
  5252. if test yes = "$lt_cv_irix_exported_symbol"; then
  5253. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib'
  5254. fi
  5255. else
  5256. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
  5257. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib'
  5258. fi
  5259. _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
  5260. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
  5261. _LT_TAGVAR(hardcode_libdir_separator, $1)=:
  5262. _LT_TAGVAR(inherit_rpath, $1)=yes
  5263. _LT_TAGVAR(link_all_deplibs, $1)=yes
  5264. ;;
  5265. linux*)
  5266. case $cc_basename in
  5267. tcc*)
  5268. # Fabrice Bellard et al's Tiny C Compiler
  5269. _LT_TAGVAR(ld_shlibs, $1)=yes
  5270. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
  5271. ;;
  5272. esac
  5273. ;;
  5274. netbsd*)
  5275. if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
  5276. _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
  5277. else
  5278. _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
  5279. fi
  5280. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
  5281. _LT_TAGVAR(hardcode_direct, $1)=yes
  5282. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  5283. ;;
  5284. newsos6)
  5285. _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  5286. _LT_TAGVAR(hardcode_direct, $1)=yes
  5287. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
  5288. _LT_TAGVAR(hardcode_libdir_separator, $1)=:
  5289. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  5290. ;;
  5291. *nto* | *qnx*)
  5292. ;;
  5293. openbsd* | bitrig*)
  5294. if test -f /usr/libexec/ld.so; then
  5295. _LT_TAGVAR(hardcode_direct, $1)=yes
  5296. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  5297. _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
  5298. if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
  5299. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
  5300. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols'
  5301. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
  5302. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
  5303. else
  5304. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
  5305. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
  5306. fi
  5307. else
  5308. _LT_TAGVAR(ld_shlibs, $1)=no
  5309. fi
  5310. ;;
  5311. os2*)
  5312. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  5313. _LT_TAGVAR(hardcode_minus_L, $1)=yes
  5314. _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
  5315. shrext_cmds=.dll
  5316. _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
  5317. $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
  5318. $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
  5319. $ECHO EXPORTS >> $output_objdir/$libname.def~
  5320. emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
  5321. $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
  5322. emximp -o $lib $output_objdir/$libname.def'
  5323. _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
  5324. $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
  5325. $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
  5326. $ECHO EXPORTS >> $output_objdir/$libname.def~
  5327. prefix_cmds="$SED"~
  5328. if test EXPORTS = "`$SED 1q $export_symbols`"; then
  5329. prefix_cmds="$prefix_cmds -e 1d";
  5330. fi~
  5331. prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
  5332. cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
  5333. $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
  5334. emximp -o $lib $output_objdir/$libname.def'
  5335. _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
  5336. _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
  5337. _LT_TAGVAR(file_list_spec, $1)='@'
  5338. ;;
  5339. osf3*)
  5340. if test yes = "$GCC"; then
  5341. _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*'
  5342. _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
  5343. else
  5344. _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
  5345. _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
  5346. fi
  5347. _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
  5348. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
  5349. _LT_TAGVAR(hardcode_libdir_separator, $1)=:
  5350. ;;
  5351. osf4* | osf5*) # as osf3* with the addition of -msym flag
  5352. if test yes = "$GCC"; then
  5353. _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*'
  5354. _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
  5355. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
  5356. else
  5357. _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
  5358. _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
  5359. _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
  5360. $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp'
  5361. # Both c and cxx compiler support -rpath directly
  5362. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
  5363. fi
  5364. _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
  5365. _LT_TAGVAR(hardcode_libdir_separator, $1)=:
  5366. ;;
  5367. solaris*)
  5368. _LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
  5369. if test yes = "$GCC"; then
  5370. wlarc='$wl'
  5371. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
  5372. _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
  5373. $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
  5374. else
  5375. case `$CC -V 2>&1` in
  5376. *"Compilers 5.0"*)
  5377. wlarc=''
  5378. _LT_TAGVAR(archive_cmds, $1)='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags'
  5379. _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
  5380. $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
  5381. ;;
  5382. *)
  5383. wlarc='$wl'
  5384. _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags'
  5385. _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
  5386. $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
  5387. ;;
  5388. esac
  5389. fi
  5390. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
  5391. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  5392. case $host_os in
  5393. solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
  5394. *)
  5395. # The compiler driver will combine and reorder linker options,
  5396. # but understands '-z linker_flag'. GCC discards it without '$wl',
  5397. # but is careful enough not to reorder.
  5398. # Supported since Solaris 2.6 (maybe 2.5.1?)
  5399. if test yes = "$GCC"; then
  5400. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
  5401. else
  5402. _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
  5403. fi
  5404. ;;
  5405. esac
  5406. _LT_TAGVAR(link_all_deplibs, $1)=yes
  5407. ;;
  5408. sunos4*)
  5409. if test sequent = "$host_vendor"; then
  5410. # Use $CC to link under sequent, because it throws in some extra .o
  5411. # files that make .init and .fini sections work.
  5412. _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags'
  5413. else
  5414. _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
  5415. fi
  5416. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  5417. _LT_TAGVAR(hardcode_direct, $1)=yes
  5418. _LT_TAGVAR(hardcode_minus_L, $1)=yes
  5419. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  5420. ;;
  5421. sysv4)
  5422. case $host_vendor in
  5423. sni)
  5424. _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  5425. _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true???
  5426. ;;
  5427. siemens)
  5428. ## LD is ld it makes a PLAMLIB
  5429. ## CC just makes a GrossModule.
  5430. _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
  5431. _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
  5432. _LT_TAGVAR(hardcode_direct, $1)=no
  5433. ;;
  5434. motorola)
  5435. _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  5436. _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
  5437. ;;
  5438. esac
  5439. runpath_var='LD_RUN_PATH'
  5440. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  5441. ;;
  5442. sysv4.3*)
  5443. _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  5444. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  5445. _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
  5446. ;;
  5447. sysv4*MP*)
  5448. if test -d /usr/nec; then
  5449. _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  5450. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  5451. runpath_var=LD_RUN_PATH
  5452. hardcode_runpath_var=yes
  5453. _LT_TAGVAR(ld_shlibs, $1)=yes
  5454. fi
  5455. ;;
  5456. sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
  5457. _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text'
  5458. _LT_TAGVAR(archive_cmds_need_lc, $1)=no
  5459. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  5460. runpath_var='LD_RUN_PATH'
  5461. if test yes = "$GCC"; then
  5462. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  5463. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  5464. else
  5465. _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  5466. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  5467. fi
  5468. ;;
  5469. sysv5* | sco3.2v5* | sco5v6*)
  5470. # Note: We CANNOT use -z defs as we might desire, because we do not
  5471. # link with -lc, and that would cause any symbols used from libc to
  5472. # always be unresolved, which means just about no library would
  5473. # ever link correctly. If we're not using GNU ld we use -z text
  5474. # though, which does catch some bad symbols but isn't as heavy-handed
  5475. # as -z defs.
  5476. _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text'
  5477. _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs'
  5478. _LT_TAGVAR(archive_cmds_need_lc, $1)=no
  5479. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  5480. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir'
  5481. _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
  5482. _LT_TAGVAR(link_all_deplibs, $1)=yes
  5483. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport'
  5484. runpath_var='LD_RUN_PATH'
  5485. if test yes = "$GCC"; then
  5486. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  5487. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  5488. else
  5489. _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  5490. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  5491. fi
  5492. ;;
  5493. uts4*)
  5494. _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  5495. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  5496. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  5497. ;;
  5498. *)
  5499. _LT_TAGVAR(ld_shlibs, $1)=no
  5500. ;;
  5501. esac
  5502. if test sni = "$host_vendor"; then
  5503. case $host in
  5504. sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
  5505. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Blargedynsym'
  5506. ;;
  5507. esac
  5508. fi
  5509. fi
  5510. ])
  5511. AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
  5512. test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no
  5513. _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld
  5514. _LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl
  5515. _LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl
  5516. _LT_DECL([], [extract_expsyms_cmds], [2],
  5517. [The commands to extract the exported symbol list from a shared archive])
  5518. #
  5519. # Do we need to explicitly link libc?
  5520. #
  5521. case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in
  5522. x|xyes)
  5523. # Assume -lc should be added
  5524. _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
  5525. if test yes,yes = "$GCC,$enable_shared"; then
  5526. case $_LT_TAGVAR(archive_cmds, $1) in
  5527. *'~'*)
  5528. # FIXME: we may have to deal with multi-command sequences.
  5529. ;;
  5530. '$CC '*)
  5531. # Test whether the compiler implicitly links with -lc since on some
  5532. # systems, -lgcc has to come before -lc. If gcc already passes -lc
  5533. # to ld, don't add -lc before -lgcc.
  5534. AC_CACHE_CHECK([whether -lc should be explicitly linked in],
  5535. [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1),
  5536. [$RM conftest*
  5537. echo "$lt_simple_compile_test_code" > conftest.$ac_ext
  5538. if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
  5539. soname=conftest
  5540. lib=conftest
  5541. libobjs=conftest.$ac_objext
  5542. deplibs=
  5543. wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
  5544. pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
  5545. compiler_flags=-v
  5546. linker_flags=-v
  5547. verstring=
  5548. output_objdir=.
  5549. libname=conftest
  5550. lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
  5551. _LT_TAGVAR(allow_undefined_flag, $1)=
  5552. if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
  5553. then
  5554. lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no
  5555. else
  5556. lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
  5557. fi
  5558. _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
  5559. else
  5560. cat conftest.err 1>&5
  5561. fi
  5562. $RM conftest*
  5563. ])
  5564. _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)
  5565. ;;
  5566. esac
  5567. fi
  5568. ;;
  5569. esac
  5570. _LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0],
  5571. [Whether or not to add -lc for building shared libraries])
  5572. _LT_TAGDECL([allow_libtool_libs_with_static_runtimes],
  5573. [enable_shared_with_static_runtimes], [0],
  5574. [Whether or not to disallow shared libs when runtime libs are static])
  5575. _LT_TAGDECL([], [export_dynamic_flag_spec], [1],
  5576. [Compiler flag to allow reflexive dlopens])
  5577. _LT_TAGDECL([], [whole_archive_flag_spec], [1],
  5578. [Compiler flag to generate shared objects directly from archives])
  5579. _LT_TAGDECL([], [compiler_needs_object], [1],
  5580. [Whether the compiler copes with passing no objects directly])
  5581. _LT_TAGDECL([], [old_archive_from_new_cmds], [2],
  5582. [Create an old-style archive from a shared archive])
  5583. _LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2],
  5584. [Create a temporary old-style archive to link instead of a shared archive])
  5585. _LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive])
  5586. _LT_TAGDECL([], [archive_expsym_cmds], [2])
  5587. _LT_TAGDECL([], [module_cmds], [2],
  5588. [Commands used to build a loadable module if different from building
  5589. a shared archive.])
  5590. _LT_TAGDECL([], [module_expsym_cmds], [2])
  5591. _LT_TAGDECL([], [with_gnu_ld], [1],
  5592. [Whether we are building with GNU ld or not])
  5593. _LT_TAGDECL([], [allow_undefined_flag], [1],
  5594. [Flag that allows shared libraries with undefined symbols to be built])
  5595. _LT_TAGDECL([], [no_undefined_flag], [1],
  5596. [Flag that enforces no undefined symbols])
  5597. _LT_TAGDECL([], [hardcode_libdir_flag_spec], [1],
  5598. [Flag to hardcode $libdir into a binary during linking.
  5599. This must work even if $libdir does not exist])
  5600. _LT_TAGDECL([], [hardcode_libdir_separator], [1],
  5601. [Whether we need a single "-rpath" flag with a separated argument])
  5602. _LT_TAGDECL([], [hardcode_direct], [0],
  5603. [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes
  5604. DIR into the resulting binary])
  5605. _LT_TAGDECL([], [hardcode_direct_absolute], [0],
  5606. [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes
  5607. DIR into the resulting binary and the resulting library dependency is
  5608. "absolute", i.e impossible to change by setting $shlibpath_var if the
  5609. library is relocated])
  5610. _LT_TAGDECL([], [hardcode_minus_L], [0],
  5611. [Set to "yes" if using the -LDIR flag during linking hardcodes DIR
  5612. into the resulting binary])
  5613. _LT_TAGDECL([], [hardcode_shlibpath_var], [0],
  5614. [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
  5615. into the resulting binary])
  5616. _LT_TAGDECL([], [hardcode_automatic], [0],
  5617. [Set to "yes" if building a shared library automatically hardcodes DIR
  5618. into the library and all subsequent libraries and executables linked
  5619. against it])
  5620. _LT_TAGDECL([], [inherit_rpath], [0],
  5621. [Set to yes if linker adds runtime paths of dependent libraries
  5622. to runtime path list])
  5623. _LT_TAGDECL([], [link_all_deplibs], [0],
  5624. [Whether libtool must link a program against all its dependency libraries])
  5625. _LT_TAGDECL([], [always_export_symbols], [0],
  5626. [Set to "yes" if exported symbols are required])
  5627. _LT_TAGDECL([], [export_symbols_cmds], [2],
  5628. [The commands to list exported symbols])
  5629. _LT_TAGDECL([], [exclude_expsyms], [1],
  5630. [Symbols that should not be listed in the preloaded symbols])
  5631. _LT_TAGDECL([], [include_expsyms], [1],
  5632. [Symbols that must always be exported])
  5633. _LT_TAGDECL([], [prelink_cmds], [2],
  5634. [Commands necessary for linking programs (against libraries) with templates])
  5635. _LT_TAGDECL([], [postlink_cmds], [2],
  5636. [Commands necessary for finishing linking programs])
  5637. _LT_TAGDECL([], [file_list_spec], [1],
  5638. [Specify filename containing input files])
  5639. dnl FIXME: Not yet implemented
  5640. dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1],
  5641. dnl [Compiler flag to generate thread safe objects])
  5642. ])# _LT_LINKER_SHLIBS
  5643. # _LT_LANG_C_CONFIG([TAG])
  5644. # ------------------------
  5645. # Ensure that the configuration variables for a C compiler are suitably
  5646. # defined. These variables are subsequently used by _LT_CONFIG to write
  5647. # the compiler configuration to 'libtool'.
  5648. m4_defun([_LT_LANG_C_CONFIG],
  5649. [m4_require([_LT_DECL_EGREP])dnl
  5650. lt_save_CC=$CC
  5651. AC_LANG_PUSH(C)
  5652. # Source file extension for C test sources.
  5653. ac_ext=c
  5654. # Object file extension for compiled C test sources.
  5655. objext=o
  5656. _LT_TAGVAR(objext, $1)=$objext
  5657. # Code to be used in simple compile tests
  5658. lt_simple_compile_test_code="int some_variable = 0;"
  5659. # Code to be used in simple link tests
  5660. lt_simple_link_test_code='int main(){return(0);}'
  5661. _LT_TAG_COMPILER
  5662. # Save the default compiler, since it gets overwritten when the other
  5663. # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
  5664. compiler_DEFAULT=$CC
  5665. # save warnings/boilerplate of simple test code
  5666. _LT_COMPILER_BOILERPLATE
  5667. _LT_LINKER_BOILERPLATE
  5668. if test -n "$compiler"; then
  5669. _LT_COMPILER_NO_RTTI($1)
  5670. _LT_COMPILER_PIC($1)
  5671. _LT_COMPILER_C_O($1)
  5672. _LT_COMPILER_FILE_LOCKS($1)
  5673. _LT_LINKER_SHLIBS($1)
  5674. _LT_SYS_DYNAMIC_LINKER($1)
  5675. _LT_LINKER_HARDCODE_LIBPATH($1)
  5676. LT_SYS_DLOPEN_SELF
  5677. _LT_CMD_STRIPLIB
  5678. # Report what library types will actually be built
  5679. AC_MSG_CHECKING([if libtool supports shared libraries])
  5680. AC_MSG_RESULT([$can_build_shared])
  5681. AC_MSG_CHECKING([whether to build shared libraries])
  5682. test no = "$can_build_shared" && enable_shared=no
  5683. # On AIX, shared libraries and static libraries use the same namespace, and
  5684. # are all built from PIC.
  5685. case $host_os in
  5686. aix3*)
  5687. test yes = "$enable_shared" && enable_static=no
  5688. if test -n "$RANLIB"; then
  5689. archive_cmds="$archive_cmds~\$RANLIB \$lib"
  5690. postinstall_cmds='$RANLIB $lib'
  5691. fi
  5692. ;;
  5693. aix[[4-9]]*)
  5694. if test ia64 != "$host_cpu"; then
  5695. case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
  5696. yes,aix,yes) ;; # shared object as lib.so file only
  5697. yes,svr4,*) ;; # shared object as lib.so archive member only
  5698. yes,*) enable_static=no ;; # shared object in lib.a archive as well
  5699. esac
  5700. fi
  5701. ;;
  5702. esac
  5703. AC_MSG_RESULT([$enable_shared])
  5704. AC_MSG_CHECKING([whether to build static libraries])
  5705. # Make sure either enable_shared or enable_static is yes.
  5706. test yes = "$enable_shared" || enable_static=yes
  5707. AC_MSG_RESULT([$enable_static])
  5708. _LT_CONFIG($1)
  5709. fi
  5710. AC_LANG_POP
  5711. CC=$lt_save_CC
  5712. ])# _LT_LANG_C_CONFIG
  5713. # _LT_LANG_CXX_CONFIG([TAG])
  5714. # --------------------------
  5715. # Ensure that the configuration variables for a C++ compiler are suitably
  5716. # defined. These variables are subsequently used by _LT_CONFIG to write
  5717. # the compiler configuration to 'libtool'.
  5718. m4_defun([_LT_LANG_CXX_CONFIG],
  5719. [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
  5720. m4_require([_LT_DECL_EGREP])dnl
  5721. m4_require([_LT_PATH_MANIFEST_TOOL])dnl
  5722. if test -n "$CXX" && ( test no != "$CXX" &&
  5723. ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) ||
  5724. (test g++ != "$CXX"))); then
  5725. AC_PROG_CXXCPP
  5726. else
  5727. _lt_caught_CXX_error=yes
  5728. fi
  5729. AC_LANG_PUSH(C++)
  5730. _LT_TAGVAR(archive_cmds_need_lc, $1)=no
  5731. _LT_TAGVAR(allow_undefined_flag, $1)=
  5732. _LT_TAGVAR(always_export_symbols, $1)=no
  5733. _LT_TAGVAR(archive_expsym_cmds, $1)=
  5734. _LT_TAGVAR(compiler_needs_object, $1)=no
  5735. _LT_TAGVAR(export_dynamic_flag_spec, $1)=
  5736. _LT_TAGVAR(hardcode_direct, $1)=no
  5737. _LT_TAGVAR(hardcode_direct_absolute, $1)=no
  5738. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
  5739. _LT_TAGVAR(hardcode_libdir_separator, $1)=
  5740. _LT_TAGVAR(hardcode_minus_L, $1)=no
  5741. _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
  5742. _LT_TAGVAR(hardcode_automatic, $1)=no
  5743. _LT_TAGVAR(inherit_rpath, $1)=no
  5744. _LT_TAGVAR(module_cmds, $1)=
  5745. _LT_TAGVAR(module_expsym_cmds, $1)=
  5746. _LT_TAGVAR(link_all_deplibs, $1)=unknown
  5747. _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
  5748. _LT_TAGVAR(reload_flag, $1)=$reload_flag
  5749. _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
  5750. _LT_TAGVAR(no_undefined_flag, $1)=
  5751. _LT_TAGVAR(whole_archive_flag_spec, $1)=
  5752. _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
  5753. # Source file extension for C++ test sources.
  5754. ac_ext=cpp
  5755. # Object file extension for compiled C++ test sources.
  5756. objext=o
  5757. _LT_TAGVAR(objext, $1)=$objext
  5758. # No sense in running all these tests if we already determined that
  5759. # the CXX compiler isn't working. Some variables (like enable_shared)
  5760. # are currently assumed to apply to all compilers on this platform,
  5761. # and will be corrupted by setting them based on a non-working compiler.
  5762. if test yes != "$_lt_caught_CXX_error"; then
  5763. # Code to be used in simple compile tests
  5764. lt_simple_compile_test_code="int some_variable = 0;"
  5765. # Code to be used in simple link tests
  5766. lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
  5767. # ltmain only uses $CC for tagged configurations so make sure $CC is set.
  5768. _LT_TAG_COMPILER
  5769. # save warnings/boilerplate of simple test code
  5770. _LT_COMPILER_BOILERPLATE
  5771. _LT_LINKER_BOILERPLATE
  5772. # Allow CC to be a program name with arguments.
  5773. lt_save_CC=$CC
  5774. lt_save_CFLAGS=$CFLAGS
  5775. lt_save_LD=$LD
  5776. lt_save_GCC=$GCC
  5777. GCC=$GXX
  5778. lt_save_with_gnu_ld=$with_gnu_ld
  5779. lt_save_path_LD=$lt_cv_path_LD
  5780. if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
  5781. lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
  5782. else
  5783. $as_unset lt_cv_prog_gnu_ld
  5784. fi
  5785. if test -n "${lt_cv_path_LDCXX+set}"; then
  5786. lt_cv_path_LD=$lt_cv_path_LDCXX
  5787. else
  5788. $as_unset lt_cv_path_LD
  5789. fi
  5790. test -z "${LDCXX+set}" || LD=$LDCXX
  5791. CC=${CXX-"c++"}
  5792. CFLAGS=$CXXFLAGS
  5793. compiler=$CC
  5794. _LT_TAGVAR(compiler, $1)=$CC
  5795. _LT_CC_BASENAME([$compiler])
  5796. if test -n "$compiler"; then
  5797. # We don't want -fno-exception when compiling C++ code, so set the
  5798. # no_builtin_flag separately
  5799. if test yes = "$GXX"; then
  5800. _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
  5801. else
  5802. _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
  5803. fi
  5804. if test yes = "$GXX"; then
  5805. # Set up default GNU C++ configuration
  5806. LT_PATH_LD
  5807. # Check if GNU C++ uses GNU ld as the underlying linker, since the
  5808. # archiving commands below assume that GNU ld is being used.
  5809. if test yes = "$with_gnu_ld"; then
  5810. _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
  5811. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
  5812. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
  5813. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
  5814. # If archive_cmds runs LD, not CC, wlarc should be empty
  5815. # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
  5816. # investigate it a little bit more. (MM)
  5817. wlarc='$wl'
  5818. # ancient GNU ld didn't support --whole-archive et. al.
  5819. if eval "`$CC -print-prog-name=ld` --help 2>&1" |
  5820. $GREP 'no-whole-archive' > /dev/null; then
  5821. _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
  5822. else
  5823. _LT_TAGVAR(whole_archive_flag_spec, $1)=
  5824. fi
  5825. else
  5826. with_gnu_ld=no
  5827. wlarc=
  5828. # A generic and very simple default shared library creation
  5829. # command for GNU C++ for the case where it uses the native
  5830. # linker, instead of GNU ld. If possible, this setting should
  5831. # overridden to take advantage of the native linker features on
  5832. # the platform it is being used on.
  5833. _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
  5834. fi
  5835. # Commands to make compiler produce verbose output that lists
  5836. # what "hidden" libraries, object files and flags are used when
  5837. # linking a shared library.
  5838. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
  5839. else
  5840. GXX=no
  5841. with_gnu_ld=no
  5842. wlarc=
  5843. fi
  5844. # PORTME: fill in a description of your system's C++ link characteristics
  5845. AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
  5846. _LT_TAGVAR(ld_shlibs, $1)=yes
  5847. case $host_os in
  5848. aix3*)
  5849. # FIXME: insert proper C++ library support
  5850. _LT_TAGVAR(ld_shlibs, $1)=no
  5851. ;;
  5852. aix[[4-9]]*)
  5853. if test ia64 = "$host_cpu"; then
  5854. # On IA64, the linker does run time linking by default, so we don't
  5855. # have to do anything special.
  5856. aix_use_runtimelinking=no
  5857. exp_sym_flag='-Bexport'
  5858. no_entry_flag=
  5859. else
  5860. aix_use_runtimelinking=no
  5861. # Test if we are trying to use run time linking or normal
  5862. # AIX style linking. If -brtl is somewhere in LDFLAGS, we
  5863. # have runtime linking enabled, and use it for executables.
  5864. # For shared libraries, we enable/disable runtime linking
  5865. # depending on the kind of the shared library created -
  5866. # when "with_aix_soname,aix_use_runtimelinking" is:
  5867. # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables
  5868. # "aix,yes" lib.so shared, rtl:yes, for executables
  5869. # lib.a static archive
  5870. # "both,no" lib.so.V(shr.o) shared, rtl:yes
  5871. # lib.a(lib.so.V) shared, rtl:no, for executables
  5872. # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
  5873. # lib.a(lib.so.V) shared, rtl:no
  5874. # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables
  5875. # lib.a static archive
  5876. case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
  5877. for ld_flag in $LDFLAGS; do
  5878. case $ld_flag in
  5879. *-brtl*)
  5880. aix_use_runtimelinking=yes
  5881. break
  5882. ;;
  5883. esac
  5884. done
  5885. if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
  5886. # With aix-soname=svr4, we create the lib.so.V shared archives only,
  5887. # so we don't have lib.a shared libs to link our executables.
  5888. # We have to force runtime linking in this case.
  5889. aix_use_runtimelinking=yes
  5890. LDFLAGS="$LDFLAGS -Wl,-brtl"
  5891. fi
  5892. ;;
  5893. esac
  5894. exp_sym_flag='-bexport'
  5895. no_entry_flag='-bnoentry'
  5896. fi
  5897. # When large executables or shared objects are built, AIX ld can
  5898. # have problems creating the table of contents. If linking a library
  5899. # or program results in "error TOC overflow" add -mminimal-toc to
  5900. # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
  5901. # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
  5902. _LT_TAGVAR(archive_cmds, $1)=''
  5903. _LT_TAGVAR(hardcode_direct, $1)=yes
  5904. _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
  5905. _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
  5906. _LT_TAGVAR(link_all_deplibs, $1)=yes
  5907. _LT_TAGVAR(file_list_spec, $1)='$wl-f,'
  5908. case $with_aix_soname,$aix_use_runtimelinking in
  5909. aix,*) ;; # no import file
  5910. svr4,* | *,yes) # use import file
  5911. # The Import File defines what to hardcode.
  5912. _LT_TAGVAR(hardcode_direct, $1)=no
  5913. _LT_TAGVAR(hardcode_direct_absolute, $1)=no
  5914. ;;
  5915. esac
  5916. if test yes = "$GXX"; then
  5917. case $host_os in aix4.[[012]]|aix4.[[012]].*)
  5918. # We only want to do this on AIX 4.2 and lower, the check
  5919. # below for broken collect2 doesn't work under 4.3+
  5920. collect2name=`$CC -print-prog-name=collect2`
  5921. if test -f "$collect2name" &&
  5922. strings "$collect2name" | $GREP resolve_lib_name >/dev/null
  5923. then
  5924. # We have reworked collect2
  5925. :
  5926. else
  5927. # We have old collect2
  5928. _LT_TAGVAR(hardcode_direct, $1)=unsupported
  5929. # It fails to find uninstalled libraries when the uninstalled
  5930. # path is not listed in the libpath. Setting hardcode_minus_L
  5931. # to unsupported forces relinking
  5932. _LT_TAGVAR(hardcode_minus_L, $1)=yes
  5933. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  5934. _LT_TAGVAR(hardcode_libdir_separator, $1)=
  5935. fi
  5936. esac
  5937. shared_flag='-shared'
  5938. if test yes = "$aix_use_runtimelinking"; then
  5939. shared_flag=$shared_flag' $wl-G'
  5940. fi
  5941. # Need to ensure runtime linking is disabled for the traditional
  5942. # shared library, or the linker may eventually find shared libraries
  5943. # /with/ Import File - we do not want to mix them.
  5944. shared_flag_aix='-shared'
  5945. shared_flag_svr4='-shared $wl-G'
  5946. else
  5947. # not using gcc
  5948. if test ia64 = "$host_cpu"; then
  5949. # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
  5950. # chokes on -Wl,-G. The following line is correct:
  5951. shared_flag='-G'
  5952. else
  5953. if test yes = "$aix_use_runtimelinking"; then
  5954. shared_flag='$wl-G'
  5955. else
  5956. shared_flag='$wl-bM:SRE'
  5957. fi
  5958. shared_flag_aix='$wl-bM:SRE'
  5959. shared_flag_svr4='$wl-G'
  5960. fi
  5961. fi
  5962. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall'
  5963. # It seems that -bexpall does not export symbols beginning with
  5964. # underscore (_), so it is better to generate a list of symbols to
  5965. # export.
  5966. _LT_TAGVAR(always_export_symbols, $1)=yes
  5967. if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
  5968. # Warning - without using the other runtime loading flags (-brtl),
  5969. # -berok will link without error, but may produce a broken library.
  5970. # The "-G" linker flag allows undefined symbols.
  5971. _LT_TAGVAR(no_undefined_flag, $1)='-bernotok'
  5972. # Determine the default libpath from the value encoded in an empty
  5973. # executable.
  5974. _LT_SYS_MODULE_PATH_AIX([$1])
  5975. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath"
  5976. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag
  5977. else
  5978. if test ia64 = "$host_cpu"; then
  5979. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib'
  5980. _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
  5981. _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols"
  5982. else
  5983. # Determine the default libpath from the value encoded in an
  5984. # empty executable.
  5985. _LT_SYS_MODULE_PATH_AIX([$1])
  5986. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath"
  5987. # Warning - without using the other run time loading flags,
  5988. # -berok will link without error, but may produce a broken library.
  5989. _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok'
  5990. _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok'
  5991. if test yes = "$with_gnu_ld"; then
  5992. # We only use this code for GNU lds that support --whole-archive.
  5993. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive'
  5994. else
  5995. # Exported symbols can be pulled into shared objects from archives
  5996. _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
  5997. fi
  5998. _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
  5999. _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
  6000. # -brtl affects multiple linker settings, -berok does not and is overridden later
  6001. compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`'
  6002. if test svr4 != "$with_aix_soname"; then
  6003. # This is similar to how AIX traditionally builds its shared
  6004. # libraries. Need -bnortl late, we may have -brtl in LDFLAGS.
  6005. _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname'
  6006. fi
  6007. if test aix != "$with_aix_soname"; then
  6008. _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp'
  6009. else
  6010. # used by -dlpreopen to get the symbols
  6011. _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir'
  6012. fi
  6013. _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d'
  6014. fi
  6015. fi
  6016. ;;
  6017. beos*)
  6018. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
  6019. _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
  6020. # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
  6021. # support --undefined. This deserves some investigation. FIXME
  6022. _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
  6023. else
  6024. _LT_TAGVAR(ld_shlibs, $1)=no
  6025. fi
  6026. ;;
  6027. chorus*)
  6028. case $cc_basename in
  6029. *)
  6030. # FIXME: insert proper C++ library support
  6031. _LT_TAGVAR(ld_shlibs, $1)=no
  6032. ;;
  6033. esac
  6034. ;;
  6035. cygwin* | mingw* | pw32* | cegcc*)
  6036. case $GXX,$cc_basename in
  6037. ,cl* | no,cl* | ,icl* | no,icl*)
  6038. # Native MSVC or ICC
  6039. # hardcode_libdir_flag_spec is actually meaningless, as there is
  6040. # no search path for DLLs.
  6041. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
  6042. _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
  6043. _LT_TAGVAR(always_export_symbols, $1)=yes
  6044. _LT_TAGVAR(file_list_spec, $1)='@'
  6045. # Tell ltmain to make .lib files, not .a files.
  6046. libext=lib
  6047. # Tell ltmain to make .dll files, not .so files.
  6048. shrext_cmds=.dll
  6049. # FIXME: Setting linknames here is a bad hack.
  6050. _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
  6051. _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then
  6052. cp "$export_symbols" "$output_objdir/$soname.def";
  6053. echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
  6054. else
  6055. $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
  6056. fi~
  6057. $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
  6058. linknames='
  6059. # The linker will not automatically build a static lib if we build a DLL.
  6060. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
  6061. _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
  6062. # Don't use ranlib
  6063. _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
  6064. _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
  6065. lt_tool_outputfile="@TOOL_OUTPUT@"~
  6066. case $lt_outputfile in
  6067. *.exe|*.EXE) ;;
  6068. *)
  6069. lt_outputfile=$lt_outputfile.exe
  6070. lt_tool_outputfile=$lt_tool_outputfile.exe
  6071. ;;
  6072. esac~
  6073. func_to_tool_file "$lt_outputfile"~
  6074. if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
  6075. $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
  6076. $RM "$lt_outputfile.manifest";
  6077. fi'
  6078. ;;
  6079. *)
  6080. # g++
  6081. # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
  6082. # as there is no search path for DLLs.
  6083. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  6084. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols'
  6085. _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
  6086. _LT_TAGVAR(always_export_symbols, $1)=no
  6087. _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
  6088. if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
  6089. _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
  6090. # If the export-symbols file already is a .def file, use it as
  6091. # is; otherwise, prepend EXPORTS...
  6092. _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then
  6093. cp $export_symbols $output_objdir/$soname.def;
  6094. else
  6095. echo EXPORTS > $output_objdir/$soname.def;
  6096. cat $export_symbols >> $output_objdir/$soname.def;
  6097. fi~
  6098. $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
  6099. else
  6100. _LT_TAGVAR(ld_shlibs, $1)=no
  6101. fi
  6102. ;;
  6103. esac
  6104. ;;
  6105. darwin* | rhapsody*)
  6106. _LT_DARWIN_LINKER_FEATURES($1)
  6107. ;;
  6108. os2*)
  6109. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  6110. _LT_TAGVAR(hardcode_minus_L, $1)=yes
  6111. _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
  6112. shrext_cmds=.dll
  6113. _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
  6114. $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
  6115. $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
  6116. $ECHO EXPORTS >> $output_objdir/$libname.def~
  6117. emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
  6118. $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
  6119. emximp -o $lib $output_objdir/$libname.def'
  6120. _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
  6121. $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
  6122. $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
  6123. $ECHO EXPORTS >> $output_objdir/$libname.def~
  6124. prefix_cmds="$SED"~
  6125. if test EXPORTS = "`$SED 1q $export_symbols`"; then
  6126. prefix_cmds="$prefix_cmds -e 1d";
  6127. fi~
  6128. prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
  6129. cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
  6130. $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
  6131. emximp -o $lib $output_objdir/$libname.def'
  6132. _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
  6133. _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
  6134. _LT_TAGVAR(file_list_spec, $1)='@'
  6135. ;;
  6136. dgux*)
  6137. case $cc_basename in
  6138. ec++*)
  6139. # FIXME: insert proper C++ library support
  6140. _LT_TAGVAR(ld_shlibs, $1)=no
  6141. ;;
  6142. ghcx*)
  6143. # Green Hills C++ Compiler
  6144. # FIXME: insert proper C++ library support
  6145. _LT_TAGVAR(ld_shlibs, $1)=no
  6146. ;;
  6147. *)
  6148. # FIXME: insert proper C++ library support
  6149. _LT_TAGVAR(ld_shlibs, $1)=no
  6150. ;;
  6151. esac
  6152. ;;
  6153. freebsd2.*)
  6154. # C++ shared libraries reported to be fairly broken before
  6155. # switch to ELF
  6156. _LT_TAGVAR(ld_shlibs, $1)=no
  6157. ;;
  6158. freebsd-elf*)
  6159. _LT_TAGVAR(archive_cmds_need_lc, $1)=no
  6160. ;;
  6161. freebsd* | dragonfly* | midnightbsd*)
  6162. # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
  6163. # conventions
  6164. _LT_TAGVAR(ld_shlibs, $1)=yes
  6165. ;;
  6166. haiku*)
  6167. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
  6168. _LT_TAGVAR(link_all_deplibs, $1)=yes
  6169. ;;
  6170. hpux9*)
  6171. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
  6172. _LT_TAGVAR(hardcode_libdir_separator, $1)=:
  6173. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
  6174. _LT_TAGVAR(hardcode_direct, $1)=yes
  6175. _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
  6176. # but as the default
  6177. # location of the library.
  6178. case $cc_basename in
  6179. CC*)
  6180. # FIXME: insert proper C++ library support
  6181. _LT_TAGVAR(ld_shlibs, $1)=no
  6182. ;;
  6183. aCC*)
  6184. _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
  6185. # Commands to make compiler produce verbose output that lists
  6186. # what "hidden" libraries, object files and flags are used when
  6187. # linking a shared library.
  6188. #
  6189. # There doesn't appear to be a way to prevent this compiler from
  6190. # explicitly linking system object files so we need to strip them
  6191. # from the output so that they don't get included in the library
  6192. # dependencies.
  6193. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
  6194. ;;
  6195. *)
  6196. if test yes = "$GXX"; then
  6197. _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
  6198. else
  6199. # FIXME: insert proper C++ library support
  6200. _LT_TAGVAR(ld_shlibs, $1)=no
  6201. fi
  6202. ;;
  6203. esac
  6204. ;;
  6205. hpux10*|hpux11*)
  6206. if test no = "$with_gnu_ld"; then
  6207. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
  6208. _LT_TAGVAR(hardcode_libdir_separator, $1)=:
  6209. case $host_cpu in
  6210. hppa*64*|ia64*)
  6211. ;;
  6212. *)
  6213. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
  6214. ;;
  6215. esac
  6216. fi
  6217. case $host_cpu in
  6218. hppa*64*|ia64*)
  6219. _LT_TAGVAR(hardcode_direct, $1)=no
  6220. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  6221. ;;
  6222. *)
  6223. _LT_TAGVAR(hardcode_direct, $1)=yes
  6224. _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
  6225. _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
  6226. # but as the default
  6227. # location of the library.
  6228. ;;
  6229. esac
  6230. case $cc_basename in
  6231. CC*)
  6232. # FIXME: insert proper C++ library support
  6233. _LT_TAGVAR(ld_shlibs, $1)=no
  6234. ;;
  6235. aCC*)
  6236. case $host_cpu in
  6237. hppa*64*)
  6238. _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  6239. ;;
  6240. ia64*)
  6241. _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  6242. ;;
  6243. *)
  6244. _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  6245. ;;
  6246. esac
  6247. # Commands to make compiler produce verbose output that lists
  6248. # what "hidden" libraries, object files and flags are used when
  6249. # linking a shared library.
  6250. #
  6251. # There doesn't appear to be a way to prevent this compiler from
  6252. # explicitly linking system object files so we need to strip them
  6253. # from the output so that they don't get included in the library
  6254. # dependencies.
  6255. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
  6256. ;;
  6257. *)
  6258. if test yes = "$GXX"; then
  6259. if test no = "$with_gnu_ld"; then
  6260. case $host_cpu in
  6261. hppa*64*)
  6262. _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  6263. ;;
  6264. ia64*)
  6265. _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  6266. ;;
  6267. *)
  6268. _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  6269. ;;
  6270. esac
  6271. fi
  6272. else
  6273. # FIXME: insert proper C++ library support
  6274. _LT_TAGVAR(ld_shlibs, $1)=no
  6275. fi
  6276. ;;
  6277. esac
  6278. ;;
  6279. interix[[3-9]]*)
  6280. _LT_TAGVAR(hardcode_direct, $1)=no
  6281. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  6282. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
  6283. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
  6284. # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
  6285. # Instead, shared libraries are loaded at an image base (0x10000000 by
  6286. # default) and relocated if they conflict, which is a slow very memory
  6287. # consuming and fragmenting process. To avoid this, we pick a random,
  6288. # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
  6289. # time. Moving up from 0x10000000 also allows more sbrk(2) space.
  6290. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
  6291. _LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
  6292. ;;
  6293. irix5* | irix6*)
  6294. case $cc_basename in
  6295. CC*)
  6296. # SGI C++
  6297. _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
  6298. # Archives containing C++ object files must be created using
  6299. # "CC -ar", where "CC" is the IRIX C++ compiler. This is
  6300. # necessary to make sure instantiated templates are included
  6301. # in the archive.
  6302. _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
  6303. ;;
  6304. *)
  6305. if test yes = "$GXX"; then
  6306. if test no = "$with_gnu_ld"; then
  6307. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
  6308. else
  6309. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib'
  6310. fi
  6311. fi
  6312. _LT_TAGVAR(link_all_deplibs, $1)=yes
  6313. ;;
  6314. esac
  6315. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
  6316. _LT_TAGVAR(hardcode_libdir_separator, $1)=:
  6317. _LT_TAGVAR(inherit_rpath, $1)=yes
  6318. ;;
  6319. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
  6320. case $cc_basename in
  6321. KCC*)
  6322. # Kuck and Associates, Inc. (KAI) C++ Compiler
  6323. # KCC will only create a shared library if the output file
  6324. # ends with ".so" (or ".sl" for HP-UX), so rename the library
  6325. # to its proper name (with version) after linking.
  6326. _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
  6327. _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib'
  6328. # Commands to make compiler produce verbose output that lists
  6329. # what "hidden" libraries, object files and flags are used when
  6330. # linking a shared library.
  6331. #
  6332. # There doesn't appear to be a way to prevent this compiler from
  6333. # explicitly linking system object files so we need to strip them
  6334. # from the output so that they don't get included in the library
  6335. # dependencies.
  6336. output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
  6337. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
  6338. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
  6339. # Archives containing C++ object files must be created using
  6340. # "CC -Bstatic", where "CC" is the KAI C++ compiler.
  6341. _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
  6342. ;;
  6343. icpc* | ecpc* )
  6344. # Intel C++
  6345. with_gnu_ld=yes
  6346. # version 8.0 and above of icpc choke on multiply defined symbols
  6347. # if we add $predep_objects and $postdep_objects, however 7.1 and
  6348. # earlier do not add the objects themselves.
  6349. case `$CC -V 2>&1` in
  6350. *"Version 7."*)
  6351. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
  6352. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
  6353. ;;
  6354. *) # Version 8.0 or newer
  6355. tmp_idyn=
  6356. case $host_cpu in
  6357. ia64*) tmp_idyn=' -i_dynamic';;
  6358. esac
  6359. _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
  6360. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
  6361. ;;
  6362. esac
  6363. _LT_TAGVAR(archive_cmds_need_lc, $1)=no
  6364. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
  6365. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
  6366. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive'
  6367. ;;
  6368. pgCC* | pgcpp*)
  6369. # Portland Group C++ compiler
  6370. case `$CC -V` in
  6371. *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*)
  6372. _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
  6373. rm -rf $tpldir~
  6374. $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
  6375. compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
  6376. _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
  6377. rm -rf $tpldir~
  6378. $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
  6379. $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
  6380. $RANLIB $oldlib'
  6381. _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
  6382. rm -rf $tpldir~
  6383. $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
  6384. $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
  6385. _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
  6386. rm -rf $tpldir~
  6387. $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
  6388. $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
  6389. ;;
  6390. *) # Version 6 and above use weak symbols
  6391. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
  6392. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
  6393. ;;
  6394. esac
  6395. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl--rpath $wl$libdir'
  6396. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
  6397. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
  6398. ;;
  6399. cxx*)
  6400. # Compaq C++
  6401. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
  6402. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols'
  6403. runpath_var=LD_RUN_PATH
  6404. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
  6405. _LT_TAGVAR(hardcode_libdir_separator, $1)=:
  6406. # Commands to make compiler produce verbose output that lists
  6407. # what "hidden" libraries, object files and flags are used when
  6408. # linking a shared library.
  6409. #
  6410. # There doesn't appear to be a way to prevent this compiler from
  6411. # explicitly linking system object files so we need to strip them
  6412. # from the output so that they don't get included in the library
  6413. # dependencies.
  6414. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed'
  6415. ;;
  6416. xl* | mpixl* | bgxl*)
  6417. # IBM XL 8.0 on PPC, with GNU ld
  6418. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
  6419. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
  6420. _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
  6421. if test yes = "$supports_anon_versioning"; then
  6422. _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
  6423. cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
  6424. echo "local: *; };" >> $output_objdir/$libname.ver~
  6425. $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
  6426. fi
  6427. ;;
  6428. *)
  6429. case `$CC -V 2>&1 | $SED 5q` in
  6430. *Sun\ C*)
  6431. # Sun C++ 5.9
  6432. _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
  6433. _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  6434. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols'
  6435. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
  6436. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
  6437. _LT_TAGVAR(compiler_needs_object, $1)=yes
  6438. # Not sure whether something based on
  6439. # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
  6440. # would be better.
  6441. output_verbose_link_cmd='func_echo_all'
  6442. # Archives containing C++ object files must be created using
  6443. # "CC -xar", where "CC" is the Sun C++ compiler. This is
  6444. # necessary to make sure instantiated templates are included
  6445. # in the archive.
  6446. _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
  6447. ;;
  6448. esac
  6449. ;;
  6450. esac
  6451. ;;
  6452. lynxos*)
  6453. # FIXME: insert proper C++ library support
  6454. _LT_TAGVAR(ld_shlibs, $1)=no
  6455. ;;
  6456. m88k*)
  6457. # FIXME: insert proper C++ library support
  6458. _LT_TAGVAR(ld_shlibs, $1)=no
  6459. ;;
  6460. mvs*)
  6461. case $cc_basename in
  6462. cxx*)
  6463. # FIXME: insert proper C++ library support
  6464. _LT_TAGVAR(ld_shlibs, $1)=no
  6465. ;;
  6466. *)
  6467. # FIXME: insert proper C++ library support
  6468. _LT_TAGVAR(ld_shlibs, $1)=no
  6469. ;;
  6470. esac
  6471. ;;
  6472. netbsd*)
  6473. if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
  6474. _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
  6475. wlarc=
  6476. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
  6477. _LT_TAGVAR(hardcode_direct, $1)=yes
  6478. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  6479. fi
  6480. # Workaround some broken pre-1.5 toolchains
  6481. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
  6482. ;;
  6483. *nto* | *qnx*)
  6484. _LT_TAGVAR(ld_shlibs, $1)=yes
  6485. ;;
  6486. openbsd* | bitrig*)
  6487. if test -f /usr/libexec/ld.so; then
  6488. _LT_TAGVAR(hardcode_direct, $1)=yes
  6489. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  6490. _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
  6491. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
  6492. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
  6493. if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then
  6494. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib'
  6495. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
  6496. _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
  6497. fi
  6498. output_verbose_link_cmd=func_echo_all
  6499. else
  6500. _LT_TAGVAR(ld_shlibs, $1)=no
  6501. fi
  6502. ;;
  6503. osf3* | osf4* | osf5*)
  6504. case $cc_basename in
  6505. KCC*)
  6506. # Kuck and Associates, Inc. (KAI) C++ Compiler
  6507. # KCC will only create a shared library if the output file
  6508. # ends with ".so" (or ".sl" for HP-UX), so rename the library
  6509. # to its proper name (with version) after linking.
  6510. _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
  6511. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
  6512. _LT_TAGVAR(hardcode_libdir_separator, $1)=:
  6513. # Archives containing C++ object files must be created using
  6514. # the KAI C++ compiler.
  6515. case $host in
  6516. osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;;
  6517. *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;;
  6518. esac
  6519. ;;
  6520. RCC*)
  6521. # Rational C++ 2.4.1
  6522. # FIXME: insert proper C++ library support
  6523. _LT_TAGVAR(ld_shlibs, $1)=no
  6524. ;;
  6525. cxx*)
  6526. case $host in
  6527. osf3*)
  6528. _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*'
  6529. _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
  6530. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
  6531. ;;
  6532. *)
  6533. _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
  6534. _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
  6535. _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
  6536. echo "-hidden">> $lib.exp~
  6537. $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~
  6538. $RM $lib.exp'
  6539. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
  6540. ;;
  6541. esac
  6542. _LT_TAGVAR(hardcode_libdir_separator, $1)=:
  6543. # Commands to make compiler produce verbose output that lists
  6544. # what "hidden" libraries, object files and flags are used when
  6545. # linking a shared library.
  6546. #
  6547. # There doesn't appear to be a way to prevent this compiler from
  6548. # explicitly linking system object files so we need to strip them
  6549. # from the output so that they don't get included in the library
  6550. # dependencies.
  6551. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
  6552. ;;
  6553. *)
  6554. if test yes,no = "$GXX,$with_gnu_ld"; then
  6555. _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*'
  6556. case $host in
  6557. osf3*)
  6558. _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
  6559. ;;
  6560. *)
  6561. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
  6562. ;;
  6563. esac
  6564. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
  6565. _LT_TAGVAR(hardcode_libdir_separator, $1)=:
  6566. # Commands to make compiler produce verbose output that lists
  6567. # what "hidden" libraries, object files and flags are used when
  6568. # linking a shared library.
  6569. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
  6570. else
  6571. # FIXME: insert proper C++ library support
  6572. _LT_TAGVAR(ld_shlibs, $1)=no
  6573. fi
  6574. ;;
  6575. esac
  6576. ;;
  6577. psos*)
  6578. # FIXME: insert proper C++ library support
  6579. _LT_TAGVAR(ld_shlibs, $1)=no
  6580. ;;
  6581. sunos4*)
  6582. case $cc_basename in
  6583. CC*)
  6584. # Sun C++ 4.x
  6585. # FIXME: insert proper C++ library support
  6586. _LT_TAGVAR(ld_shlibs, $1)=no
  6587. ;;
  6588. lcc*)
  6589. # Lucid
  6590. # FIXME: insert proper C++ library support
  6591. _LT_TAGVAR(ld_shlibs, $1)=no
  6592. ;;
  6593. *)
  6594. # FIXME: insert proper C++ library support
  6595. _LT_TAGVAR(ld_shlibs, $1)=no
  6596. ;;
  6597. esac
  6598. ;;
  6599. solaris*)
  6600. case $cc_basename in
  6601. CC* | sunCC*)
  6602. # Sun C++ 4.2, 5.x and Centerline C++
  6603. _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
  6604. _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
  6605. _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  6606. _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
  6607. $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
  6608. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
  6609. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  6610. case $host_os in
  6611. solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
  6612. *)
  6613. # The compiler driver will combine and reorder linker options,
  6614. # but understands '-z linker_flag'.
  6615. # Supported since Solaris 2.6 (maybe 2.5.1?)
  6616. _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
  6617. ;;
  6618. esac
  6619. _LT_TAGVAR(link_all_deplibs, $1)=yes
  6620. output_verbose_link_cmd='func_echo_all'
  6621. # Archives containing C++ object files must be created using
  6622. # "CC -xar", where "CC" is the Sun C++ compiler. This is
  6623. # necessary to make sure instantiated templates are included
  6624. # in the archive.
  6625. _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
  6626. ;;
  6627. gcx*)
  6628. # Green Hills C++ Compiler
  6629. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib'
  6630. # The C++ compiler must be used to create the archive.
  6631. _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
  6632. ;;
  6633. *)
  6634. # GNU C++ compiler with Solaris linker
  6635. if test yes,no = "$GXX,$with_gnu_ld"; then
  6636. _LT_TAGVAR(no_undefined_flag, $1)=' $wl-z ${wl}defs'
  6637. if $CC --version | $GREP -v '^2\.7' > /dev/null; then
  6638. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib'
  6639. _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
  6640. $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
  6641. # Commands to make compiler produce verbose output that lists
  6642. # what "hidden" libraries, object files and flags are used when
  6643. # linking a shared library.
  6644. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
  6645. else
  6646. # g++ 2.7 appears to require '-G' NOT '-shared' on this
  6647. # platform.
  6648. _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib'
  6649. _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
  6650. $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
  6651. # Commands to make compiler produce verbose output that lists
  6652. # what "hidden" libraries, object files and flags are used when
  6653. # linking a shared library.
  6654. output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
  6655. fi
  6656. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir'
  6657. case $host_os in
  6658. solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
  6659. *)
  6660. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
  6661. ;;
  6662. esac
  6663. fi
  6664. ;;
  6665. esac
  6666. ;;
  6667. sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
  6668. _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text'
  6669. _LT_TAGVAR(archive_cmds_need_lc, $1)=no
  6670. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  6671. runpath_var='LD_RUN_PATH'
  6672. case $cc_basename in
  6673. CC*)
  6674. _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  6675. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  6676. ;;
  6677. *)
  6678. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  6679. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  6680. ;;
  6681. esac
  6682. ;;
  6683. sysv5* | sco3.2v5* | sco5v6*)
  6684. # Note: We CANNOT use -z defs as we might desire, because we do not
  6685. # link with -lc, and that would cause any symbols used from libc to
  6686. # always be unresolved, which means just about no library would
  6687. # ever link correctly. If we're not using GNU ld we use -z text
  6688. # though, which does catch some bad symbols but isn't as heavy-handed
  6689. # as -z defs.
  6690. _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text'
  6691. _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs'
  6692. _LT_TAGVAR(archive_cmds_need_lc, $1)=no
  6693. _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
  6694. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir'
  6695. _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
  6696. _LT_TAGVAR(link_all_deplibs, $1)=yes
  6697. _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport'
  6698. runpath_var='LD_RUN_PATH'
  6699. case $cc_basename in
  6700. CC*)
  6701. _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  6702. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  6703. _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~
  6704. '"$_LT_TAGVAR(old_archive_cmds, $1)"
  6705. _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~
  6706. '"$_LT_TAGVAR(reload_cmds, $1)"
  6707. ;;
  6708. *)
  6709. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  6710. _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  6711. ;;
  6712. esac
  6713. ;;
  6714. tandem*)
  6715. case $cc_basename in
  6716. NCC*)
  6717. # NonStop-UX NCC 3.20
  6718. # FIXME: insert proper C++ library support
  6719. _LT_TAGVAR(ld_shlibs, $1)=no
  6720. ;;
  6721. *)
  6722. # FIXME: insert proper C++ library support
  6723. _LT_TAGVAR(ld_shlibs, $1)=no
  6724. ;;
  6725. esac
  6726. ;;
  6727. vxworks*)
  6728. # FIXME: insert proper C++ library support
  6729. _LT_TAGVAR(ld_shlibs, $1)=no
  6730. ;;
  6731. *)
  6732. # FIXME: insert proper C++ library support
  6733. _LT_TAGVAR(ld_shlibs, $1)=no
  6734. ;;
  6735. esac
  6736. AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
  6737. test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no
  6738. _LT_TAGVAR(GCC, $1)=$GXX
  6739. _LT_TAGVAR(LD, $1)=$LD
  6740. ## CAVEAT EMPTOR:
  6741. ## There is no encapsulation within the following macros, do not change
  6742. ## the running order or otherwise move them around unless you know exactly
  6743. ## what you are doing...
  6744. _LT_SYS_HIDDEN_LIBDEPS($1)
  6745. _LT_COMPILER_PIC($1)
  6746. _LT_COMPILER_C_O($1)
  6747. _LT_COMPILER_FILE_LOCKS($1)
  6748. _LT_LINKER_SHLIBS($1)
  6749. _LT_SYS_DYNAMIC_LINKER($1)
  6750. _LT_LINKER_HARDCODE_LIBPATH($1)
  6751. _LT_CONFIG($1)
  6752. fi # test -n "$compiler"
  6753. CC=$lt_save_CC
  6754. CFLAGS=$lt_save_CFLAGS
  6755. LDCXX=$LD
  6756. LD=$lt_save_LD
  6757. GCC=$lt_save_GCC
  6758. with_gnu_ld=$lt_save_with_gnu_ld
  6759. lt_cv_path_LDCXX=$lt_cv_path_LD
  6760. lt_cv_path_LD=$lt_save_path_LD
  6761. lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
  6762. lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
  6763. fi # test yes != "$_lt_caught_CXX_error"
  6764. AC_LANG_POP
  6765. ])# _LT_LANG_CXX_CONFIG
  6766. # _LT_FUNC_STRIPNAME_CNF
  6767. # ----------------------
  6768. # func_stripname_cnf prefix suffix name
  6769. # strip PREFIX and SUFFIX off of NAME.
  6770. # PREFIX and SUFFIX must not contain globbing or regex special
  6771. # characters, hashes, percent signs, but SUFFIX may contain a leading
  6772. # dot (in which case that matches only a dot).
  6773. #
  6774. # This function is identical to the (non-XSI) version of func_stripname,
  6775. # except this one can be used by m4 code that may be executed by configure,
  6776. # rather than the libtool script.
  6777. m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl
  6778. AC_REQUIRE([_LT_DECL_SED])
  6779. AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])
  6780. func_stripname_cnf ()
  6781. {
  6782. case @S|@2 in
  6783. .*) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%\\\\@S|@2\$%%"`;;
  6784. *) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%@S|@2\$%%"`;;
  6785. esac
  6786. } # func_stripname_cnf
  6787. ])# _LT_FUNC_STRIPNAME_CNF
  6788. # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
  6789. # ---------------------------------
  6790. # Figure out "hidden" library dependencies from verbose
  6791. # compiler output when linking a shared library.
  6792. # Parse the compiler output and extract the necessary
  6793. # objects, libraries and library flags.
  6794. m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
  6795. [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
  6796. AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl
  6797. # Dependencies to place before and after the object being linked:
  6798. _LT_TAGVAR(predep_objects, $1)=
  6799. _LT_TAGVAR(postdep_objects, $1)=
  6800. _LT_TAGVAR(predeps, $1)=
  6801. _LT_TAGVAR(postdeps, $1)=
  6802. _LT_TAGVAR(compiler_lib_search_path, $1)=
  6803. dnl we can't use the lt_simple_compile_test_code here,
  6804. dnl because it contains code intended for an executable,
  6805. dnl not a library. It's possible we should let each
  6806. dnl tag define a new lt_????_link_test_code variable,
  6807. dnl but it's only used here...
  6808. m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF
  6809. int a;
  6810. void foo (void) { a = 0; }
  6811. _LT_EOF
  6812. ], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF
  6813. class Foo
  6814. {
  6815. public:
  6816. Foo (void) { a = 0; }
  6817. private:
  6818. int a;
  6819. };
  6820. _LT_EOF
  6821. ], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF
  6822. subroutine foo
  6823. implicit none
  6824. integer*4 a
  6825. a=0
  6826. return
  6827. end
  6828. _LT_EOF
  6829. ], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF
  6830. subroutine foo
  6831. implicit none
  6832. integer a
  6833. a=0
  6834. return
  6835. end
  6836. _LT_EOF
  6837. ], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF
  6838. public class foo {
  6839. private int a;
  6840. public void bar (void) {
  6841. a = 0;
  6842. }
  6843. };
  6844. _LT_EOF
  6845. ], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF
  6846. package foo
  6847. func foo() {
  6848. }
  6849. _LT_EOF
  6850. ])
  6851. _lt_libdeps_save_CFLAGS=$CFLAGS
  6852. case "$CC $CFLAGS " in #(
  6853. *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
  6854. *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
  6855. *\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;;
  6856. esac
  6857. dnl Parse the compiler output and extract the necessary
  6858. dnl objects, libraries and library flags.
  6859. if AC_TRY_EVAL(ac_compile); then
  6860. # Parse the compiler output and extract the necessary
  6861. # objects, libraries and library flags.
  6862. # Sentinel used to keep track of whether or not we are before
  6863. # the conftest object file.
  6864. pre_test_object_deps_done=no
  6865. for p in `eval "$output_verbose_link_cmd"`; do
  6866. case $prev$p in
  6867. -L* | -R* | -l*)
  6868. # Some compilers place space between "-{L,R}" and the path.
  6869. # Remove the space.
  6870. if test x-L = "$p" ||
  6871. test x-R = "$p"; then
  6872. prev=$p
  6873. continue
  6874. fi
  6875. # Expand the sysroot to ease extracting the directories later.
  6876. if test -z "$prev"; then
  6877. case $p in
  6878. -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
  6879. -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
  6880. -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
  6881. esac
  6882. fi
  6883. case $p in
  6884. =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
  6885. esac
  6886. if test no = "$pre_test_object_deps_done"; then
  6887. case $prev in
  6888. -L | -R)
  6889. # Internal compiler library paths should come after those
  6890. # provided the user. The postdeps already come after the
  6891. # user supplied libs so there is no need to process them.
  6892. if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then
  6893. _LT_TAGVAR(compiler_lib_search_path, $1)=$prev$p
  6894. else
  6895. _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} $prev$p"
  6896. fi
  6897. ;;
  6898. # The "-l" case would never come before the object being
  6899. # linked, so don't bother handling this case.
  6900. esac
  6901. else
  6902. if test -z "$_LT_TAGVAR(postdeps, $1)"; then
  6903. _LT_TAGVAR(postdeps, $1)=$prev$p
  6904. else
  6905. _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} $prev$p"
  6906. fi
  6907. fi
  6908. prev=
  6909. ;;
  6910. *.lto.$objext) ;; # Ignore GCC LTO objects
  6911. *.$objext)
  6912. # This assumes that the test object file only shows up
  6913. # once in the compiler output.
  6914. if test "$p" = "conftest.$objext"; then
  6915. pre_test_object_deps_done=yes
  6916. continue
  6917. fi
  6918. if test no = "$pre_test_object_deps_done"; then
  6919. if test -z "$_LT_TAGVAR(predep_objects, $1)"; then
  6920. _LT_TAGVAR(predep_objects, $1)=$p
  6921. else
  6922. _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p"
  6923. fi
  6924. else
  6925. if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then
  6926. _LT_TAGVAR(postdep_objects, $1)=$p
  6927. else
  6928. _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p"
  6929. fi
  6930. fi
  6931. ;;
  6932. *) ;; # Ignore the rest.
  6933. esac
  6934. done
  6935. # Clean up.
  6936. rm -f a.out a.exe
  6937. else
  6938. echo "libtool.m4: error: problem compiling $1 test program"
  6939. fi
  6940. $RM -f confest.$objext
  6941. CFLAGS=$_lt_libdeps_save_CFLAGS
  6942. # PORTME: override above test on systems where it is broken
  6943. m4_if([$1], [CXX],
  6944. [case $host_os in
  6945. interix[[3-9]]*)
  6946. # Interix 3.5 installs completely hosed .la files for C++, so rather than
  6947. # hack all around it, let's just trust "g++" to DTRT.
  6948. _LT_TAGVAR(predep_objects,$1)=
  6949. _LT_TAGVAR(postdep_objects,$1)=
  6950. _LT_TAGVAR(postdeps,$1)=
  6951. ;;
  6952. esac
  6953. ])
  6954. case " $_LT_TAGVAR(postdeps, $1) " in
  6955. *" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;;
  6956. esac
  6957. _LT_TAGVAR(compiler_lib_search_dirs, $1)=
  6958. if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then
  6959. _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | $SED -e 's! -L! !g' -e 's!^ !!'`
  6960. fi
  6961. _LT_TAGDECL([], [compiler_lib_search_dirs], [1],
  6962. [The directories searched by this compiler when creating a shared library])
  6963. _LT_TAGDECL([], [predep_objects], [1],
  6964. [Dependencies to place before and after the objects being linked to
  6965. create a shared library])
  6966. _LT_TAGDECL([], [postdep_objects], [1])
  6967. _LT_TAGDECL([], [predeps], [1])
  6968. _LT_TAGDECL([], [postdeps], [1])
  6969. _LT_TAGDECL([], [compiler_lib_search_path], [1],
  6970. [The library search path used internally by the compiler when linking
  6971. a shared library])
  6972. ])# _LT_SYS_HIDDEN_LIBDEPS
  6973. # _LT_LANG_F77_CONFIG([TAG])
  6974. # --------------------------
  6975. # Ensure that the configuration variables for a Fortran 77 compiler are
  6976. # suitably defined. These variables are subsequently used by _LT_CONFIG
  6977. # to write the compiler configuration to 'libtool'.
  6978. m4_defun([_LT_LANG_F77_CONFIG],
  6979. [AC_LANG_PUSH(Fortran 77)
  6980. if test -z "$F77" || test no = "$F77"; then
  6981. _lt_disable_F77=yes
  6982. fi
  6983. _LT_TAGVAR(archive_cmds_need_lc, $1)=no
  6984. _LT_TAGVAR(allow_undefined_flag, $1)=
  6985. _LT_TAGVAR(always_export_symbols, $1)=no
  6986. _LT_TAGVAR(archive_expsym_cmds, $1)=
  6987. _LT_TAGVAR(export_dynamic_flag_spec, $1)=
  6988. _LT_TAGVAR(hardcode_direct, $1)=no
  6989. _LT_TAGVAR(hardcode_direct_absolute, $1)=no
  6990. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
  6991. _LT_TAGVAR(hardcode_libdir_separator, $1)=
  6992. _LT_TAGVAR(hardcode_minus_L, $1)=no
  6993. _LT_TAGVAR(hardcode_automatic, $1)=no
  6994. _LT_TAGVAR(inherit_rpath, $1)=no
  6995. _LT_TAGVAR(module_cmds, $1)=
  6996. _LT_TAGVAR(module_expsym_cmds, $1)=
  6997. _LT_TAGVAR(link_all_deplibs, $1)=unknown
  6998. _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
  6999. _LT_TAGVAR(reload_flag, $1)=$reload_flag
  7000. _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
  7001. _LT_TAGVAR(no_undefined_flag, $1)=
  7002. _LT_TAGVAR(whole_archive_flag_spec, $1)=
  7003. _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
  7004. # Source file extension for f77 test sources.
  7005. ac_ext=f
  7006. # Object file extension for compiled f77 test sources.
  7007. objext=o
  7008. _LT_TAGVAR(objext, $1)=$objext
  7009. # No sense in running all these tests if we already determined that
  7010. # the F77 compiler isn't working. Some variables (like enable_shared)
  7011. # are currently assumed to apply to all compilers on this platform,
  7012. # and will be corrupted by setting them based on a non-working compiler.
  7013. if test yes != "$_lt_disable_F77"; then
  7014. # Code to be used in simple compile tests
  7015. lt_simple_compile_test_code="\
  7016. subroutine t
  7017. return
  7018. end
  7019. "
  7020. # Code to be used in simple link tests
  7021. lt_simple_link_test_code="\
  7022. program t
  7023. end
  7024. "
  7025. # ltmain only uses $CC for tagged configurations so make sure $CC is set.
  7026. _LT_TAG_COMPILER
  7027. # save warnings/boilerplate of simple test code
  7028. _LT_COMPILER_BOILERPLATE
  7029. _LT_LINKER_BOILERPLATE
  7030. # Allow CC to be a program name with arguments.
  7031. lt_save_CC=$CC
  7032. lt_save_GCC=$GCC
  7033. lt_save_CFLAGS=$CFLAGS
  7034. CC=${F77-"f77"}
  7035. CFLAGS=$FFLAGS
  7036. compiler=$CC
  7037. _LT_TAGVAR(compiler, $1)=$CC
  7038. _LT_CC_BASENAME([$compiler])
  7039. GCC=$G77
  7040. if test -n "$compiler"; then
  7041. AC_MSG_CHECKING([if libtool supports shared libraries])
  7042. AC_MSG_RESULT([$can_build_shared])
  7043. AC_MSG_CHECKING([whether to build shared libraries])
  7044. test no = "$can_build_shared" && enable_shared=no
  7045. # On AIX, shared libraries and static libraries use the same namespace, and
  7046. # are all built from PIC.
  7047. case $host_os in
  7048. aix3*)
  7049. test yes = "$enable_shared" && enable_static=no
  7050. if test -n "$RANLIB"; then
  7051. archive_cmds="$archive_cmds~\$RANLIB \$lib"
  7052. postinstall_cmds='$RANLIB $lib'
  7053. fi
  7054. ;;
  7055. aix[[4-9]]*)
  7056. if test ia64 != "$host_cpu"; then
  7057. case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
  7058. yes,aix,yes) ;; # shared object as lib.so file only
  7059. yes,svr4,*) ;; # shared object as lib.so archive member only
  7060. yes,*) enable_static=no ;; # shared object in lib.a archive as well
  7061. esac
  7062. fi
  7063. ;;
  7064. esac
  7065. AC_MSG_RESULT([$enable_shared])
  7066. AC_MSG_CHECKING([whether to build static libraries])
  7067. # Make sure either enable_shared or enable_static is yes.
  7068. test yes = "$enable_shared" || enable_static=yes
  7069. AC_MSG_RESULT([$enable_static])
  7070. _LT_TAGVAR(GCC, $1)=$G77
  7071. _LT_TAGVAR(LD, $1)=$LD
  7072. ## CAVEAT EMPTOR:
  7073. ## There is no encapsulation within the following macros, do not change
  7074. ## the running order or otherwise move them around unless you know exactly
  7075. ## what you are doing...
  7076. _LT_COMPILER_PIC($1)
  7077. _LT_COMPILER_C_O($1)
  7078. _LT_COMPILER_FILE_LOCKS($1)
  7079. _LT_LINKER_SHLIBS($1)
  7080. _LT_SYS_DYNAMIC_LINKER($1)
  7081. _LT_LINKER_HARDCODE_LIBPATH($1)
  7082. _LT_CONFIG($1)
  7083. fi # test -n "$compiler"
  7084. GCC=$lt_save_GCC
  7085. CC=$lt_save_CC
  7086. CFLAGS=$lt_save_CFLAGS
  7087. fi # test yes != "$_lt_disable_F77"
  7088. AC_LANG_POP
  7089. ])# _LT_LANG_F77_CONFIG
  7090. # _LT_LANG_FC_CONFIG([TAG])
  7091. # -------------------------
  7092. # Ensure that the configuration variables for a Fortran compiler are
  7093. # suitably defined. These variables are subsequently used by _LT_CONFIG
  7094. # to write the compiler configuration to 'libtool'.
  7095. m4_defun([_LT_LANG_FC_CONFIG],
  7096. [AC_LANG_PUSH(Fortran)
  7097. if test -z "$FC" || test no = "$FC"; then
  7098. _lt_disable_FC=yes
  7099. fi
  7100. _LT_TAGVAR(archive_cmds_need_lc, $1)=no
  7101. _LT_TAGVAR(allow_undefined_flag, $1)=
  7102. _LT_TAGVAR(always_export_symbols, $1)=no
  7103. _LT_TAGVAR(archive_expsym_cmds, $1)=
  7104. _LT_TAGVAR(export_dynamic_flag_spec, $1)=
  7105. _LT_TAGVAR(hardcode_direct, $1)=no
  7106. _LT_TAGVAR(hardcode_direct_absolute, $1)=no
  7107. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
  7108. _LT_TAGVAR(hardcode_libdir_separator, $1)=
  7109. _LT_TAGVAR(hardcode_minus_L, $1)=no
  7110. _LT_TAGVAR(hardcode_automatic, $1)=no
  7111. _LT_TAGVAR(inherit_rpath, $1)=no
  7112. _LT_TAGVAR(module_cmds, $1)=
  7113. _LT_TAGVAR(module_expsym_cmds, $1)=
  7114. _LT_TAGVAR(link_all_deplibs, $1)=unknown
  7115. _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
  7116. _LT_TAGVAR(reload_flag, $1)=$reload_flag
  7117. _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
  7118. _LT_TAGVAR(no_undefined_flag, $1)=
  7119. _LT_TAGVAR(whole_archive_flag_spec, $1)=
  7120. _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
  7121. # Source file extension for fc test sources.
  7122. ac_ext=${ac_fc_srcext-f}
  7123. # Object file extension for compiled fc test sources.
  7124. objext=o
  7125. _LT_TAGVAR(objext, $1)=$objext
  7126. # No sense in running all these tests if we already determined that
  7127. # the FC compiler isn't working. Some variables (like enable_shared)
  7128. # are currently assumed to apply to all compilers on this platform,
  7129. # and will be corrupted by setting them based on a non-working compiler.
  7130. if test yes != "$_lt_disable_FC"; then
  7131. # Code to be used in simple compile tests
  7132. lt_simple_compile_test_code="\
  7133. subroutine t
  7134. return
  7135. end
  7136. "
  7137. # Code to be used in simple link tests
  7138. lt_simple_link_test_code="\
  7139. program t
  7140. end
  7141. "
  7142. # ltmain only uses $CC for tagged configurations so make sure $CC is set.
  7143. _LT_TAG_COMPILER
  7144. # save warnings/boilerplate of simple test code
  7145. _LT_COMPILER_BOILERPLATE
  7146. _LT_LINKER_BOILERPLATE
  7147. # Allow CC to be a program name with arguments.
  7148. lt_save_CC=$CC
  7149. lt_save_GCC=$GCC
  7150. lt_save_CFLAGS=$CFLAGS
  7151. CC=${FC-"f95"}
  7152. CFLAGS=$FCFLAGS
  7153. compiler=$CC
  7154. GCC=$ac_cv_fc_compiler_gnu
  7155. _LT_TAGVAR(compiler, $1)=$CC
  7156. _LT_CC_BASENAME([$compiler])
  7157. if test -n "$compiler"; then
  7158. AC_MSG_CHECKING([if libtool supports shared libraries])
  7159. AC_MSG_RESULT([$can_build_shared])
  7160. AC_MSG_CHECKING([whether to build shared libraries])
  7161. test no = "$can_build_shared" && enable_shared=no
  7162. # On AIX, shared libraries and static libraries use the same namespace, and
  7163. # are all built from PIC.
  7164. case $host_os in
  7165. aix3*)
  7166. test yes = "$enable_shared" && enable_static=no
  7167. if test -n "$RANLIB"; then
  7168. archive_cmds="$archive_cmds~\$RANLIB \$lib"
  7169. postinstall_cmds='$RANLIB $lib'
  7170. fi
  7171. ;;
  7172. aix[[4-9]]*)
  7173. if test ia64 != "$host_cpu"; then
  7174. case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
  7175. yes,aix,yes) ;; # shared object as lib.so file only
  7176. yes,svr4,*) ;; # shared object as lib.so archive member only
  7177. yes,*) enable_static=no ;; # shared object in lib.a archive as well
  7178. esac
  7179. fi
  7180. ;;
  7181. esac
  7182. AC_MSG_RESULT([$enable_shared])
  7183. AC_MSG_CHECKING([whether to build static libraries])
  7184. # Make sure either enable_shared or enable_static is yes.
  7185. test yes = "$enable_shared" || enable_static=yes
  7186. AC_MSG_RESULT([$enable_static])
  7187. _LT_TAGVAR(GCC, $1)=$ac_cv_fc_compiler_gnu
  7188. _LT_TAGVAR(LD, $1)=$LD
  7189. ## CAVEAT EMPTOR:
  7190. ## There is no encapsulation within the following macros, do not change
  7191. ## the running order or otherwise move them around unless you know exactly
  7192. ## what you are doing...
  7193. _LT_SYS_HIDDEN_LIBDEPS($1)
  7194. _LT_COMPILER_PIC($1)
  7195. _LT_COMPILER_C_O($1)
  7196. _LT_COMPILER_FILE_LOCKS($1)
  7197. _LT_LINKER_SHLIBS($1)
  7198. _LT_SYS_DYNAMIC_LINKER($1)
  7199. _LT_LINKER_HARDCODE_LIBPATH($1)
  7200. _LT_CONFIG($1)
  7201. fi # test -n "$compiler"
  7202. GCC=$lt_save_GCC
  7203. CC=$lt_save_CC
  7204. CFLAGS=$lt_save_CFLAGS
  7205. fi # test yes != "$_lt_disable_FC"
  7206. AC_LANG_POP
  7207. ])# _LT_LANG_FC_CONFIG
  7208. # _LT_LANG_GCJ_CONFIG([TAG])
  7209. # --------------------------
  7210. # Ensure that the configuration variables for the GNU Java Compiler compiler
  7211. # are suitably defined. These variables are subsequently used by _LT_CONFIG
  7212. # to write the compiler configuration to 'libtool'.
  7213. m4_defun([_LT_LANG_GCJ_CONFIG],
  7214. [AC_REQUIRE([LT_PROG_GCJ])dnl
  7215. AC_LANG_SAVE
  7216. # Source file extension for Java test sources.
  7217. ac_ext=java
  7218. # Object file extension for compiled Java test sources.
  7219. objext=o
  7220. _LT_TAGVAR(objext, $1)=$objext
  7221. # Code to be used in simple compile tests
  7222. lt_simple_compile_test_code="class foo {}"
  7223. # Code to be used in simple link tests
  7224. lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
  7225. # ltmain only uses $CC for tagged configurations so make sure $CC is set.
  7226. _LT_TAG_COMPILER
  7227. # save warnings/boilerplate of simple test code
  7228. _LT_COMPILER_BOILERPLATE
  7229. _LT_LINKER_BOILERPLATE
  7230. # Allow CC to be a program name with arguments.
  7231. lt_save_CC=$CC
  7232. lt_save_CFLAGS=$CFLAGS
  7233. lt_save_GCC=$GCC
  7234. GCC=yes
  7235. CC=${GCJ-"gcj"}
  7236. CFLAGS=$GCJFLAGS
  7237. compiler=$CC
  7238. _LT_TAGVAR(compiler, $1)=$CC
  7239. _LT_TAGVAR(LD, $1)=$LD
  7240. _LT_CC_BASENAME([$compiler])
  7241. # GCJ did not exist at the time GCC didn't implicitly link libc in.
  7242. _LT_TAGVAR(archive_cmds_need_lc, $1)=no
  7243. _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
  7244. _LT_TAGVAR(reload_flag, $1)=$reload_flag
  7245. _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
  7246. if test -n "$compiler"; then
  7247. _LT_COMPILER_NO_RTTI($1)
  7248. _LT_COMPILER_PIC($1)
  7249. _LT_COMPILER_C_O($1)
  7250. _LT_COMPILER_FILE_LOCKS($1)
  7251. _LT_LINKER_SHLIBS($1)
  7252. _LT_LINKER_HARDCODE_LIBPATH($1)
  7253. _LT_CONFIG($1)
  7254. fi
  7255. AC_LANG_RESTORE
  7256. GCC=$lt_save_GCC
  7257. CC=$lt_save_CC
  7258. CFLAGS=$lt_save_CFLAGS
  7259. ])# _LT_LANG_GCJ_CONFIG
  7260. # _LT_LANG_GO_CONFIG([TAG])
  7261. # --------------------------
  7262. # Ensure that the configuration variables for the GNU Go compiler
  7263. # are suitably defined. These variables are subsequently used by _LT_CONFIG
  7264. # to write the compiler configuration to 'libtool'.
  7265. m4_defun([_LT_LANG_GO_CONFIG],
  7266. [AC_REQUIRE([LT_PROG_GO])dnl
  7267. AC_LANG_SAVE
  7268. # Source file extension for Go test sources.
  7269. ac_ext=go
  7270. # Object file extension for compiled Go test sources.
  7271. objext=o
  7272. _LT_TAGVAR(objext, $1)=$objext
  7273. # Code to be used in simple compile tests
  7274. lt_simple_compile_test_code="package main; func main() { }"
  7275. # Code to be used in simple link tests
  7276. lt_simple_link_test_code='package main; func main() { }'
  7277. # ltmain only uses $CC for tagged configurations so make sure $CC is set.
  7278. _LT_TAG_COMPILER
  7279. # save warnings/boilerplate of simple test code
  7280. _LT_COMPILER_BOILERPLATE
  7281. _LT_LINKER_BOILERPLATE
  7282. # Allow CC to be a program name with arguments.
  7283. lt_save_CC=$CC
  7284. lt_save_CFLAGS=$CFLAGS
  7285. lt_save_GCC=$GCC
  7286. GCC=yes
  7287. CC=${GOC-"gccgo"}
  7288. CFLAGS=$GOFLAGS
  7289. compiler=$CC
  7290. _LT_TAGVAR(compiler, $1)=$CC
  7291. _LT_TAGVAR(LD, $1)=$LD
  7292. _LT_CC_BASENAME([$compiler])
  7293. # Go did not exist at the time GCC didn't implicitly link libc in.
  7294. _LT_TAGVAR(archive_cmds_need_lc, $1)=no
  7295. _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
  7296. _LT_TAGVAR(reload_flag, $1)=$reload_flag
  7297. _LT_TAGVAR(reload_cmds, $1)=$reload_cmds
  7298. if test -n "$compiler"; then
  7299. _LT_COMPILER_NO_RTTI($1)
  7300. _LT_COMPILER_PIC($1)
  7301. _LT_COMPILER_C_O($1)
  7302. _LT_COMPILER_FILE_LOCKS($1)
  7303. _LT_LINKER_SHLIBS($1)
  7304. _LT_LINKER_HARDCODE_LIBPATH($1)
  7305. _LT_CONFIG($1)
  7306. fi
  7307. AC_LANG_RESTORE
  7308. GCC=$lt_save_GCC
  7309. CC=$lt_save_CC
  7310. CFLAGS=$lt_save_CFLAGS
  7311. ])# _LT_LANG_GO_CONFIG
  7312. # _LT_LANG_RC_CONFIG([TAG])
  7313. # -------------------------
  7314. # Ensure that the configuration variables for the Windows resource compiler
  7315. # are suitably defined. These variables are subsequently used by _LT_CONFIG
  7316. # to write the compiler configuration to 'libtool'.
  7317. m4_defun([_LT_LANG_RC_CONFIG],
  7318. [AC_REQUIRE([LT_PROG_RC])dnl
  7319. AC_LANG_SAVE
  7320. # Source file extension for RC test sources.
  7321. ac_ext=rc
  7322. # Object file extension for compiled RC test sources.
  7323. objext=o
  7324. _LT_TAGVAR(objext, $1)=$objext
  7325. # Code to be used in simple compile tests
  7326. lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
  7327. # Code to be used in simple link tests
  7328. lt_simple_link_test_code=$lt_simple_compile_test_code
  7329. # ltmain only uses $CC for tagged configurations so make sure $CC is set.
  7330. _LT_TAG_COMPILER
  7331. # save warnings/boilerplate of simple test code
  7332. _LT_COMPILER_BOILERPLATE
  7333. _LT_LINKER_BOILERPLATE
  7334. # Allow CC to be a program name with arguments.
  7335. lt_save_CC=$CC
  7336. lt_save_CFLAGS=$CFLAGS
  7337. lt_save_GCC=$GCC
  7338. GCC=
  7339. CC=${RC-"windres"}
  7340. CFLAGS=
  7341. compiler=$CC
  7342. _LT_TAGVAR(compiler, $1)=$CC
  7343. _LT_CC_BASENAME([$compiler])
  7344. _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
  7345. if test -n "$compiler"; then
  7346. :
  7347. _LT_CONFIG($1)
  7348. fi
  7349. GCC=$lt_save_GCC
  7350. AC_LANG_RESTORE
  7351. CC=$lt_save_CC
  7352. CFLAGS=$lt_save_CFLAGS
  7353. ])# _LT_LANG_RC_CONFIG
  7354. # LT_PROG_GCJ
  7355. # -----------
  7356. AC_DEFUN([LT_PROG_GCJ],
  7357. [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ],
  7358. [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ],
  7359. [AC_CHECK_TOOL(GCJ, gcj,)
  7360. test set = "${GCJFLAGS+set}" || GCJFLAGS="-g -O2"
  7361. AC_SUBST(GCJFLAGS)])])[]dnl
  7362. ])
  7363. # Old name:
  7364. AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ])
  7365. dnl aclocal-1.4 backwards compatibility:
  7366. dnl AC_DEFUN([LT_AC_PROG_GCJ], [])
  7367. # LT_PROG_GO
  7368. # ----------
  7369. AC_DEFUN([LT_PROG_GO],
  7370. [AC_CHECK_TOOL(GOC, gccgo,)
  7371. ])
  7372. # LT_PROG_RC
  7373. # ----------
  7374. AC_DEFUN([LT_PROG_RC],
  7375. [AC_CHECK_TOOL(RC, windres,)
  7376. ])
  7377. # Old name:
  7378. AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC])
  7379. dnl aclocal-1.4 backwards compatibility:
  7380. dnl AC_DEFUN([LT_AC_PROG_RC], [])
  7381. # _LT_DECL_EGREP
  7382. # --------------
  7383. # If we don't have a new enough Autoconf to choose the best grep
  7384. # available, choose the one first in the user's PATH.
  7385. m4_defun([_LT_DECL_EGREP],
  7386. [AC_REQUIRE([AC_PROG_EGREP])dnl
  7387. AC_REQUIRE([AC_PROG_FGREP])dnl
  7388. test -z "$GREP" && GREP=grep
  7389. _LT_DECL([], [GREP], [1], [A grep program that handles long lines])
  7390. _LT_DECL([], [EGREP], [1], [An ERE matcher])
  7391. _LT_DECL([], [FGREP], [1], [A literal string matcher])
  7392. dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too
  7393. AC_SUBST([GREP])
  7394. ])
  7395. # _LT_DECL_OBJDUMP
  7396. # --------------
  7397. # If we don't have a new enough Autoconf to choose the best objdump
  7398. # available, choose the one first in the user's PATH.
  7399. m4_defun([_LT_DECL_OBJDUMP],
  7400. [AC_CHECK_TOOL(OBJDUMP, objdump, false)
  7401. test -z "$OBJDUMP" && OBJDUMP=objdump
  7402. _LT_DECL([], [OBJDUMP], [1], [An object symbol dumper])
  7403. AC_SUBST([OBJDUMP])
  7404. ])
  7405. # _LT_DECL_DLLTOOL
  7406. # ----------------
  7407. # Ensure DLLTOOL variable is set.
  7408. m4_defun([_LT_DECL_DLLTOOL],
  7409. [AC_CHECK_TOOL(DLLTOOL, dlltool, false)
  7410. test -z "$DLLTOOL" && DLLTOOL=dlltool
  7411. _LT_DECL([], [DLLTOOL], [1], [DLL creation program])
  7412. AC_SUBST([DLLTOOL])
  7413. ])
  7414. # _LT_DECL_FILECMD
  7415. # ----------------
  7416. # Check for a file(cmd) program that can be used to detect file type and magic
  7417. m4_defun([_LT_DECL_FILECMD],
  7418. [AC_CHECK_TOOL([FILECMD], [file], [:])
  7419. _LT_DECL([], [FILECMD], [1], [A file(cmd) program that detects file types])
  7420. ])# _LD_DECL_FILECMD
  7421. # _LT_DECL_SED
  7422. # ------------
  7423. # Check for a fully-functional sed program, that truncates
  7424. # as few characters as possible. Prefer GNU sed if found.
  7425. m4_defun([_LT_DECL_SED],
  7426. [AC_PROG_SED
  7427. test -z "$SED" && SED=sed
  7428. Xsed="$SED -e 1s/^X//"
  7429. _LT_DECL([], [SED], [1], [A sed program that does not truncate output])
  7430. _LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"],
  7431. [Sed that helps us avoid accidentally triggering echo(1) options like -n])
  7432. ])# _LT_DECL_SED
  7433. m4_ifndef([AC_PROG_SED], [
  7434. # NOTE: This macro has been submitted for inclusion into #
  7435. # GNU Autoconf as AC_PROG_SED. When it is available in #
  7436. # a released version of Autoconf we should remove this #
  7437. # macro and use it instead. #
  7438. m4_defun([AC_PROG_SED],
  7439. [AC_MSG_CHECKING([for a sed that does not truncate output])
  7440. AC_CACHE_VAL(lt_cv_path_SED,
  7441. [# Loop through the user's path and test for sed and gsed.
  7442. # Then use that list of sed's as ones to test for truncation.
  7443. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  7444. for as_dir in $PATH
  7445. do
  7446. IFS=$as_save_IFS
  7447. test -z "$as_dir" && as_dir=.
  7448. for lt_ac_prog in sed gsed; do
  7449. for ac_exec_ext in '' $ac_executable_extensions; do
  7450. if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
  7451. lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
  7452. fi
  7453. done
  7454. done
  7455. done
  7456. IFS=$as_save_IFS
  7457. lt_ac_max=0
  7458. lt_ac_count=0
  7459. # Add /usr/xpg4/bin/sed as it is typically found on Solaris
  7460. # along with /bin/sed that truncates output.
  7461. for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
  7462. test ! -f "$lt_ac_sed" && continue
  7463. cat /dev/null > conftest.in
  7464. lt_ac_count=0
  7465. echo $ECHO_N "0123456789$ECHO_C" >conftest.in
  7466. # Check for GNU sed and select it if it is found.
  7467. if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
  7468. lt_cv_path_SED=$lt_ac_sed
  7469. break
  7470. fi
  7471. while true; do
  7472. cat conftest.in conftest.in >conftest.tmp
  7473. mv conftest.tmp conftest.in
  7474. cp conftest.in conftest.nl
  7475. echo >>conftest.nl
  7476. $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
  7477. cmp -s conftest.out conftest.nl || break
  7478. # 10000 chars as input seems more than enough
  7479. test 10 -lt "$lt_ac_count" && break
  7480. lt_ac_count=`expr $lt_ac_count + 1`
  7481. if test "$lt_ac_count" -gt "$lt_ac_max"; then
  7482. lt_ac_max=$lt_ac_count
  7483. lt_cv_path_SED=$lt_ac_sed
  7484. fi
  7485. done
  7486. done
  7487. ])
  7488. SED=$lt_cv_path_SED
  7489. AC_SUBST([SED])
  7490. AC_MSG_RESULT([$SED])
  7491. ])#AC_PROG_SED
  7492. ])#m4_ifndef
  7493. # Old name:
  7494. AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED])
  7495. dnl aclocal-1.4 backwards compatibility:
  7496. dnl AC_DEFUN([LT_AC_PROG_SED], [])
  7497. # _LT_CHECK_SHELL_FEATURES
  7498. # ------------------------
  7499. # Find out whether the shell is Bourne or XSI compatible,
  7500. # or has some other useful features.
  7501. m4_defun([_LT_CHECK_SHELL_FEATURES],
  7502. [if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
  7503. lt_unset=unset
  7504. else
  7505. lt_unset=false
  7506. fi
  7507. _LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl
  7508. # test EBCDIC or ASCII
  7509. case `echo X|tr X '\101'` in
  7510. A) # ASCII based system
  7511. # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
  7512. lt_SP2NL='tr \040 \012'
  7513. lt_NL2SP='tr \015\012 \040\040'
  7514. ;;
  7515. *) # EBCDIC based system
  7516. lt_SP2NL='tr \100 \n'
  7517. lt_NL2SP='tr \r\n \100\100'
  7518. ;;
  7519. esac
  7520. _LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl
  7521. _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
  7522. ])# _LT_CHECK_SHELL_FEATURES
  7523. # _LT_PATH_CONVERSION_FUNCTIONS
  7524. # -----------------------------
  7525. # Determine what file name conversion functions should be used by
  7526. # func_to_host_file (and, implicitly, by func_to_host_path). These are needed
  7527. # for certain cross-compile configurations and native mingw.
  7528. m4_defun([_LT_PATH_CONVERSION_FUNCTIONS],
  7529. [AC_REQUIRE([AC_CANONICAL_HOST])dnl
  7530. AC_REQUIRE([AC_CANONICAL_BUILD])dnl
  7531. AC_MSG_CHECKING([how to convert $build file names to $host format])
  7532. AC_CACHE_VAL(lt_cv_to_host_file_cmd,
  7533. [case $host in
  7534. *-*-mingw* )
  7535. case $build in
  7536. *-*-mingw* ) # actually msys
  7537. lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
  7538. ;;
  7539. *-*-cygwin* )
  7540. lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
  7541. ;;
  7542. * ) # otherwise, assume *nix
  7543. lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
  7544. ;;
  7545. esac
  7546. ;;
  7547. *-*-cygwin* )
  7548. case $build in
  7549. *-*-mingw* ) # actually msys
  7550. lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
  7551. ;;
  7552. *-*-cygwin* )
  7553. lt_cv_to_host_file_cmd=func_convert_file_noop
  7554. ;;
  7555. * ) # otherwise, assume *nix
  7556. lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
  7557. ;;
  7558. esac
  7559. ;;
  7560. * ) # unhandled hosts (and "normal" native builds)
  7561. lt_cv_to_host_file_cmd=func_convert_file_noop
  7562. ;;
  7563. esac
  7564. ])
  7565. to_host_file_cmd=$lt_cv_to_host_file_cmd
  7566. AC_MSG_RESULT([$lt_cv_to_host_file_cmd])
  7567. _LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd],
  7568. [0], [convert $build file names to $host format])dnl
  7569. AC_MSG_CHECKING([how to convert $build file names to toolchain format])
  7570. AC_CACHE_VAL(lt_cv_to_tool_file_cmd,
  7571. [#assume ordinary cross tools, or native build.
  7572. lt_cv_to_tool_file_cmd=func_convert_file_noop
  7573. case $host in
  7574. *-*-mingw* )
  7575. case $build in
  7576. *-*-mingw* ) # actually msys
  7577. lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
  7578. ;;
  7579. esac
  7580. ;;
  7581. esac
  7582. ])
  7583. to_tool_file_cmd=$lt_cv_to_tool_file_cmd
  7584. AC_MSG_RESULT([$lt_cv_to_tool_file_cmd])
  7585. _LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd],
  7586. [0], [convert $build files to toolchain format])dnl
  7587. ])# _LT_PATH_CONVERSION_FUNCTIONS
  7588. # Helper functions for option handling. -*- Autoconf -*-
  7589. #
  7590. # Copyright (C) 2004-2005, 2007-2009, 2011-2019, 2021-2022 Free
  7591. # Software Foundation, Inc.
  7592. # Written by Gary V. Vaughan, 2004
  7593. #
  7594. # This file is free software; the Free Software Foundation gives
  7595. # unlimited permission to copy and/or distribute it, with or without
  7596. # modifications, as long as this notice is preserved.
  7597. # serial 8 ltoptions.m4
  7598. # This is to help aclocal find these macros, as it can't see m4_define.
  7599. AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
  7600. # _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME)
  7601. # ------------------------------------------
  7602. m4_define([_LT_MANGLE_OPTION],
  7603. [[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])])
  7604. # _LT_SET_OPTION(MACRO-NAME, OPTION-NAME)
  7605. # ---------------------------------------
  7606. # Set option OPTION-NAME for macro MACRO-NAME, and if there is a
  7607. # matching handler defined, dispatch to it. Other OPTION-NAMEs are
  7608. # saved as a flag.
  7609. m4_define([_LT_SET_OPTION],
  7610. [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl
  7611. m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]),
  7612. _LT_MANGLE_DEFUN([$1], [$2]),
  7613. [m4_warning([Unknown $1 option '$2'])])[]dnl
  7614. ])
  7615. # _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET])
  7616. # ------------------------------------------------------------
  7617. # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
  7618. m4_define([_LT_IF_OPTION],
  7619. [m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])])
  7620. # _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET)
  7621. # -------------------------------------------------------
  7622. # Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME
  7623. # are set.
  7624. m4_define([_LT_UNLESS_OPTIONS],
  7625. [m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
  7626. [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option),
  7627. [m4_define([$0_found])])])[]dnl
  7628. m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3
  7629. ])[]dnl
  7630. ])
  7631. # _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST)
  7632. # ----------------------------------------
  7633. # OPTION-LIST is a space-separated list of Libtool options associated
  7634. # with MACRO-NAME. If any OPTION has a matching handler declared with
  7635. # LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about
  7636. # the unknown option and exit.
  7637. m4_defun([_LT_SET_OPTIONS],
  7638. [# Set options
  7639. m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
  7640. [_LT_SET_OPTION([$1], _LT_Option)])
  7641. m4_if([$1],[LT_INIT],[
  7642. dnl
  7643. dnl Simply set some default values (i.e off) if boolean options were not
  7644. dnl specified:
  7645. _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no
  7646. ])
  7647. _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no
  7648. ])
  7649. dnl
  7650. dnl If no reference was made to various pairs of opposing options, then
  7651. dnl we run the default mode handler for the pair. For example, if neither
  7652. dnl 'shared' nor 'disable-shared' was passed, we enable building of shared
  7653. dnl archives by default:
  7654. _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED])
  7655. _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC])
  7656. _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC])
  7657. _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install],
  7658. [_LT_ENABLE_FAST_INSTALL])
  7659. _LT_UNLESS_OPTIONS([LT_INIT], [aix-soname=aix aix-soname=both aix-soname=svr4],
  7660. [_LT_WITH_AIX_SONAME([aix])])
  7661. ])
  7662. ])# _LT_SET_OPTIONS
  7663. # _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME)
  7664. # -----------------------------------------
  7665. m4_define([_LT_MANGLE_DEFUN],
  7666. [[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])])
  7667. # LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE)
  7668. # -----------------------------------------------
  7669. m4_define([LT_OPTION_DEFINE],
  7670. [m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl
  7671. ])# LT_OPTION_DEFINE
  7672. # dlopen
  7673. # ------
  7674. LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes
  7675. ])
  7676. AU_DEFUN([AC_LIBTOOL_DLOPEN],
  7677. [_LT_SET_OPTION([LT_INIT], [dlopen])
  7678. AC_DIAGNOSE([obsolete],
  7679. [$0: Remove this warning and the call to _LT_SET_OPTION when you
  7680. put the 'dlopen' option into LT_INIT's first parameter.])
  7681. ])
  7682. dnl aclocal-1.4 backwards compatibility:
  7683. dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], [])
  7684. # win32-dll
  7685. # ---------
  7686. # Declare package support for building win32 dll's.
  7687. LT_OPTION_DEFINE([LT_INIT], [win32-dll],
  7688. [enable_win32_dll=yes
  7689. case $host in
  7690. *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
  7691. AC_CHECK_TOOL(AS, as, false)
  7692. AC_CHECK_TOOL(DLLTOOL, dlltool, false)
  7693. AC_CHECK_TOOL(OBJDUMP, objdump, false)
  7694. ;;
  7695. esac
  7696. test -z "$AS" && AS=as
  7697. _LT_DECL([], [AS], [1], [Assembler program])dnl
  7698. test -z "$DLLTOOL" && DLLTOOL=dlltool
  7699. _LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl
  7700. test -z "$OBJDUMP" && OBJDUMP=objdump
  7701. _LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl
  7702. ])# win32-dll
  7703. AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
  7704. [AC_REQUIRE([AC_CANONICAL_HOST])dnl
  7705. _LT_SET_OPTION([LT_INIT], [win32-dll])
  7706. AC_DIAGNOSE([obsolete],
  7707. [$0: Remove this warning and the call to _LT_SET_OPTION when you
  7708. put the 'win32-dll' option into LT_INIT's first parameter.])
  7709. ])
  7710. dnl aclocal-1.4 backwards compatibility:
  7711. dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [])
  7712. # _LT_ENABLE_SHARED([DEFAULT])
  7713. # ----------------------------
  7714. # implement the --enable-shared flag, and supports the 'shared' and
  7715. # 'disable-shared' LT_INIT options.
  7716. # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'.
  7717. m4_define([_LT_ENABLE_SHARED],
  7718. [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl
  7719. AC_ARG_ENABLE([shared],
  7720. [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
  7721. [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])],
  7722. [p=${PACKAGE-default}
  7723. case $enableval in
  7724. yes) enable_shared=yes ;;
  7725. no) enable_shared=no ;;
  7726. *)
  7727. enable_shared=no
  7728. # Look at the argument we got. We use all the common list separators.
  7729. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
  7730. for pkg in $enableval; do
  7731. IFS=$lt_save_ifs
  7732. if test "X$pkg" = "X$p"; then
  7733. enable_shared=yes
  7734. fi
  7735. done
  7736. IFS=$lt_save_ifs
  7737. ;;
  7738. esac],
  7739. [enable_shared=]_LT_ENABLE_SHARED_DEFAULT)
  7740. _LT_DECL([build_libtool_libs], [enable_shared], [0],
  7741. [Whether or not to build shared libraries])
  7742. ])# _LT_ENABLE_SHARED
  7743. LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])])
  7744. LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])])
  7745. # Old names:
  7746. AC_DEFUN([AC_ENABLE_SHARED],
  7747. [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared])
  7748. ])
  7749. AC_DEFUN([AC_DISABLE_SHARED],
  7750. [_LT_SET_OPTION([LT_INIT], [disable-shared])
  7751. ])
  7752. AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
  7753. AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
  7754. dnl aclocal-1.4 backwards compatibility:
  7755. dnl AC_DEFUN([AM_ENABLE_SHARED], [])
  7756. dnl AC_DEFUN([AM_DISABLE_SHARED], [])
  7757. # _LT_ENABLE_STATIC([DEFAULT])
  7758. # ----------------------------
  7759. # implement the --enable-static flag, and support the 'static' and
  7760. # 'disable-static' LT_INIT options.
  7761. # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'.
  7762. m4_define([_LT_ENABLE_STATIC],
  7763. [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl
  7764. AC_ARG_ENABLE([static],
  7765. [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@],
  7766. [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])],
  7767. [p=${PACKAGE-default}
  7768. case $enableval in
  7769. yes) enable_static=yes ;;
  7770. no) enable_static=no ;;
  7771. *)
  7772. enable_static=no
  7773. # Look at the argument we got. We use all the common list separators.
  7774. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
  7775. for pkg in $enableval; do
  7776. IFS=$lt_save_ifs
  7777. if test "X$pkg" = "X$p"; then
  7778. enable_static=yes
  7779. fi
  7780. done
  7781. IFS=$lt_save_ifs
  7782. ;;
  7783. esac],
  7784. [enable_static=]_LT_ENABLE_STATIC_DEFAULT)
  7785. _LT_DECL([build_old_libs], [enable_static], [0],
  7786. [Whether or not to build static libraries])
  7787. ])# _LT_ENABLE_STATIC
  7788. LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])])
  7789. LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])])
  7790. # Old names:
  7791. AC_DEFUN([AC_ENABLE_STATIC],
  7792. [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static])
  7793. ])
  7794. AC_DEFUN([AC_DISABLE_STATIC],
  7795. [_LT_SET_OPTION([LT_INIT], [disable-static])
  7796. ])
  7797. AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
  7798. AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
  7799. dnl aclocal-1.4 backwards compatibility:
  7800. dnl AC_DEFUN([AM_ENABLE_STATIC], [])
  7801. dnl AC_DEFUN([AM_DISABLE_STATIC], [])
  7802. # _LT_ENABLE_FAST_INSTALL([DEFAULT])
  7803. # ----------------------------------
  7804. # implement the --enable-fast-install flag, and support the 'fast-install'
  7805. # and 'disable-fast-install' LT_INIT options.
  7806. # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'.
  7807. m4_define([_LT_ENABLE_FAST_INSTALL],
  7808. [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl
  7809. AC_ARG_ENABLE([fast-install],
  7810. [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
  7811. [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
  7812. [p=${PACKAGE-default}
  7813. case $enableval in
  7814. yes) enable_fast_install=yes ;;
  7815. no) enable_fast_install=no ;;
  7816. *)
  7817. enable_fast_install=no
  7818. # Look at the argument we got. We use all the common list separators.
  7819. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
  7820. for pkg in $enableval; do
  7821. IFS=$lt_save_ifs
  7822. if test "X$pkg" = "X$p"; then
  7823. enable_fast_install=yes
  7824. fi
  7825. done
  7826. IFS=$lt_save_ifs
  7827. ;;
  7828. esac],
  7829. [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT)
  7830. _LT_DECL([fast_install], [enable_fast_install], [0],
  7831. [Whether or not to optimize for fast installation])dnl
  7832. ])# _LT_ENABLE_FAST_INSTALL
  7833. LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])])
  7834. LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])])
  7835. # Old names:
  7836. AU_DEFUN([AC_ENABLE_FAST_INSTALL],
  7837. [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install])
  7838. AC_DIAGNOSE([obsolete],
  7839. [$0: Remove this warning and the call to _LT_SET_OPTION when you put
  7840. the 'fast-install' option into LT_INIT's first parameter.])
  7841. ])
  7842. AU_DEFUN([AC_DISABLE_FAST_INSTALL],
  7843. [_LT_SET_OPTION([LT_INIT], [disable-fast-install])
  7844. AC_DIAGNOSE([obsolete],
  7845. [$0: Remove this warning and the call to _LT_SET_OPTION when you put
  7846. the 'disable-fast-install' option into LT_INIT's first parameter.])
  7847. ])
  7848. dnl aclocal-1.4 backwards compatibility:
  7849. dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], [])
  7850. dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
  7851. # _LT_WITH_AIX_SONAME([DEFAULT])
  7852. # ----------------------------------
  7853. # implement the --with-aix-soname flag, and support the `aix-soname=aix'
  7854. # and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT
  7855. # is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'.
  7856. m4_define([_LT_WITH_AIX_SONAME],
  7857. [m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl
  7858. shared_archive_member_spec=
  7859. case $host,$enable_shared in
  7860. power*-*-aix[[5-9]]*,yes)
  7861. AC_MSG_CHECKING([which variant of shared library versioning to provide])
  7862. AC_ARG_WITH([aix-soname],
  7863. [AS_HELP_STRING([--with-aix-soname=aix|svr4|both],
  7864. [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])],
  7865. [case $withval in
  7866. aix|svr4|both)
  7867. ;;
  7868. *)
  7869. AC_MSG_ERROR([Unknown argument to --with-aix-soname])
  7870. ;;
  7871. esac
  7872. lt_cv_with_aix_soname=$with_aix_soname],
  7873. [AC_CACHE_VAL([lt_cv_with_aix_soname],
  7874. [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT)
  7875. with_aix_soname=$lt_cv_with_aix_soname])
  7876. AC_MSG_RESULT([$with_aix_soname])
  7877. if test aix != "$with_aix_soname"; then
  7878. # For the AIX way of multilib, we name the shared archive member
  7879. # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o',
  7880. # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File.
  7881. # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag,
  7882. # the AIX toolchain works better with OBJECT_MODE set (default 32).
  7883. if test 64 = "${OBJECT_MODE-32}"; then
  7884. shared_archive_member_spec=shr_64
  7885. else
  7886. shared_archive_member_spec=shr
  7887. fi
  7888. fi
  7889. ;;
  7890. *)
  7891. with_aix_soname=aix
  7892. ;;
  7893. esac
  7894. _LT_DECL([], [shared_archive_member_spec], [0],
  7895. [Shared archive member basename, for filename based shared library versioning on AIX])dnl
  7896. ])# _LT_WITH_AIX_SONAME
  7897. LT_OPTION_DEFINE([LT_INIT], [aix-soname=aix], [_LT_WITH_AIX_SONAME([aix])])
  7898. LT_OPTION_DEFINE([LT_INIT], [aix-soname=both], [_LT_WITH_AIX_SONAME([both])])
  7899. LT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])])
  7900. # _LT_WITH_PIC([MODE])
  7901. # --------------------
  7902. # implement the --with-pic flag, and support the 'pic-only' and 'no-pic'
  7903. # LT_INIT options.
  7904. # MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'.
  7905. m4_define([_LT_WITH_PIC],
  7906. [AC_ARG_WITH([pic],
  7907. [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@],
  7908. [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
  7909. [lt_p=${PACKAGE-default}
  7910. case $withval in
  7911. yes|no) pic_mode=$withval ;;
  7912. *)
  7913. pic_mode=default
  7914. # Look at the argument we got. We use all the common list separators.
  7915. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
  7916. for lt_pkg in $withval; do
  7917. IFS=$lt_save_ifs
  7918. if test "X$lt_pkg" = "X$lt_p"; then
  7919. pic_mode=yes
  7920. fi
  7921. done
  7922. IFS=$lt_save_ifs
  7923. ;;
  7924. esac],
  7925. [pic_mode=m4_default([$1], [default])])
  7926. _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
  7927. ])# _LT_WITH_PIC
  7928. LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])])
  7929. LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])])
  7930. # Old name:
  7931. AU_DEFUN([AC_LIBTOOL_PICMODE],
  7932. [_LT_SET_OPTION([LT_INIT], [pic-only])
  7933. AC_DIAGNOSE([obsolete],
  7934. [$0: Remove this warning and the call to _LT_SET_OPTION when you
  7935. put the 'pic-only' option into LT_INIT's first parameter.])
  7936. ])
  7937. dnl aclocal-1.4 backwards compatibility:
  7938. dnl AC_DEFUN([AC_LIBTOOL_PICMODE], [])
  7939. m4_define([_LTDL_MODE], [])
  7940. LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive],
  7941. [m4_define([_LTDL_MODE], [nonrecursive])])
  7942. LT_OPTION_DEFINE([LTDL_INIT], [recursive],
  7943. [m4_define([_LTDL_MODE], [recursive])])
  7944. LT_OPTION_DEFINE([LTDL_INIT], [subproject],
  7945. [m4_define([_LTDL_MODE], [subproject])])
  7946. m4_define([_LTDL_TYPE], [])
  7947. LT_OPTION_DEFINE([LTDL_INIT], [installable],
  7948. [m4_define([_LTDL_TYPE], [installable])])
  7949. LT_OPTION_DEFINE([LTDL_INIT], [convenience],
  7950. [m4_define([_LTDL_TYPE], [convenience])])
  7951. # ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*-
  7952. #
  7953. # Copyright (C) 2004-2005, 2007-2008, 2011-2019, 2021-2022 Free Software
  7954. # Foundation, Inc.
  7955. # Written by Gary V. Vaughan, 2004
  7956. #
  7957. # This file is free software; the Free Software Foundation gives
  7958. # unlimited permission to copy and/or distribute it, with or without
  7959. # modifications, as long as this notice is preserved.
  7960. # serial 6 ltsugar.m4
  7961. # This is to help aclocal find these macros, as it can't see m4_define.
  7962. AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])])
  7963. # lt_join(SEP, ARG1, [ARG2...])
  7964. # -----------------------------
  7965. # Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their
  7966. # associated separator.
  7967. # Needed until we can rely on m4_join from Autoconf 2.62, since all earlier
  7968. # versions in m4sugar had bugs.
  7969. m4_define([lt_join],
  7970. [m4_if([$#], [1], [],
  7971. [$#], [2], [[$2]],
  7972. [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])])
  7973. m4_define([_lt_join],
  7974. [m4_if([$#$2], [2], [],
  7975. [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])])
  7976. # lt_car(LIST)
  7977. # lt_cdr(LIST)
  7978. # ------------
  7979. # Manipulate m4 lists.
  7980. # These macros are necessary as long as will still need to support
  7981. # Autoconf-2.59, which quotes differently.
  7982. m4_define([lt_car], [[$1]])
  7983. m4_define([lt_cdr],
  7984. [m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
  7985. [$#], 1, [],
  7986. [m4_dquote(m4_shift($@))])])
  7987. m4_define([lt_unquote], $1)
  7988. # lt_append(MACRO-NAME, STRING, [SEPARATOR])
  7989. # ------------------------------------------
  7990. # Redefine MACRO-NAME to hold its former content plus 'SEPARATOR''STRING'.
  7991. # Note that neither SEPARATOR nor STRING are expanded; they are appended
  7992. # to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked).
  7993. # No SEPARATOR is output if MACRO-NAME was previously undefined (different
  7994. # than defined and empty).
  7995. #
  7996. # This macro is needed until we can rely on Autoconf 2.62, since earlier
  7997. # versions of m4sugar mistakenly expanded SEPARATOR but not STRING.
  7998. m4_define([lt_append],
  7999. [m4_define([$1],
  8000. m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])])
  8001. # lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...])
  8002. # ----------------------------------------------------------
  8003. # Produce a SEP delimited list of all paired combinations of elements of
  8004. # PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list
  8005. # has the form PREFIXmINFIXSUFFIXn.
  8006. # Needed until we can rely on m4_combine added in Autoconf 2.62.
  8007. m4_define([lt_combine],
  8008. [m4_if(m4_eval([$# > 3]), [1],
  8009. [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl
  8010. [[m4_foreach([_Lt_prefix], [$2],
  8011. [m4_foreach([_Lt_suffix],
  8012. ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[,
  8013. [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])])
  8014. # lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ])
  8015. # -----------------------------------------------------------------------
  8016. # Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited
  8017. # by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ.
  8018. m4_define([lt_if_append_uniq],
  8019. [m4_ifdef([$1],
  8020. [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1],
  8021. [lt_append([$1], [$2], [$3])$4],
  8022. [$5])],
  8023. [lt_append([$1], [$2], [$3])$4])])
  8024. # lt_dict_add(DICT, KEY, VALUE)
  8025. # -----------------------------
  8026. m4_define([lt_dict_add],
  8027. [m4_define([$1($2)], [$3])])
  8028. # lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE)
  8029. # --------------------------------------------
  8030. m4_define([lt_dict_add_subkey],
  8031. [m4_define([$1($2:$3)], [$4])])
  8032. # lt_dict_fetch(DICT, KEY, [SUBKEY])
  8033. # ----------------------------------
  8034. m4_define([lt_dict_fetch],
  8035. [m4_ifval([$3],
  8036. m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]),
  8037. m4_ifdef([$1($2)], [m4_defn([$1($2)])]))])
  8038. # lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE])
  8039. # -----------------------------------------------------------------
  8040. m4_define([lt_if_dict_fetch],
  8041. [m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4],
  8042. [$5],
  8043. [$6])])
  8044. # lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...])
  8045. # --------------------------------------------------------------
  8046. m4_define([lt_dict_filter],
  8047. [m4_if([$5], [], [],
  8048. [lt_join(m4_quote(m4_default([$4], [[, ]])),
  8049. lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]),
  8050. [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl
  8051. ])
  8052. # ltversion.m4 -- version numbers -*- Autoconf -*-
  8053. #
  8054. # Copyright (C) 2004, 2011-2019, 2021-2022 Free Software Foundation,
  8055. # Inc.
  8056. # Written by Scott James Remnant, 2004
  8057. #
  8058. # This file is free software; the Free Software Foundation gives
  8059. # unlimited permission to copy and/or distribute it, with or without
  8060. # modifications, as long as this notice is preserved.
  8061. # @configure_input@
  8062. # serial 4245 ltversion.m4
  8063. # This file is part of GNU Libtool
  8064. m4_define([LT_PACKAGE_VERSION], [2.4.7])
  8065. m4_define([LT_PACKAGE_REVISION], [2.4.7])
  8066. AC_DEFUN([LTVERSION_VERSION],
  8067. [macro_version='2.4.7'
  8068. macro_revision='2.4.7'
  8069. _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
  8070. _LT_DECL(, macro_revision, 0)
  8071. ])
  8072. # lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*-
  8073. #
  8074. # Copyright (C) 2004-2005, 2007, 2009, 2011-2019, 2021-2022 Free
  8075. # Software Foundation, Inc.
  8076. # Written by Scott James Remnant, 2004.
  8077. #
  8078. # This file is free software; the Free Software Foundation gives
  8079. # unlimited permission to copy and/or distribute it, with or without
  8080. # modifications, as long as this notice is preserved.
  8081. # serial 5 lt~obsolete.m4
  8082. # These exist entirely to fool aclocal when bootstrapping libtool.
  8083. #
  8084. # In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN),
  8085. # which have later been changed to m4_define as they aren't part of the
  8086. # exported API, or moved to Autoconf or Automake where they belong.
  8087. #
  8088. # The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN
  8089. # in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us
  8090. # using a macro with the same name in our local m4/libtool.m4 it'll
  8091. # pull the old libtool.m4 in (it doesn't see our shiny new m4_define
  8092. # and doesn't know about Autoconf macros at all.)
  8093. #
  8094. # So we provide this file, which has a silly filename so it's always
  8095. # included after everything else. This provides aclocal with the
  8096. # AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything
  8097. # because those macros already exist, or will be overwritten later.
  8098. # We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6.
  8099. #
  8100. # Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here.
  8101. # Yes, that means every name once taken will need to remain here until
  8102. # we give up compatibility with versions before 1.7, at which point
  8103. # we need to keep only those names which we still refer to.
  8104. # This is to help aclocal find these macros, as it can't see m4_define.
  8105. AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])])
  8106. m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])])
  8107. m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])])
  8108. m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])])
  8109. m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])])
  8110. m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])])
  8111. m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])])
  8112. m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])])
  8113. m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])])
  8114. m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])])
  8115. m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])])
  8116. m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])])
  8117. m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])])
  8118. m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])])
  8119. m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])])
  8120. m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])])
  8121. m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])])
  8122. m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])])
  8123. m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])])
  8124. m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])])
  8125. m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])])
  8126. m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])])
  8127. m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])])
  8128. m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])])
  8129. m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])])
  8130. m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])])
  8131. m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])])
  8132. m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])])
  8133. m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])])
  8134. m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])])
  8135. m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])])
  8136. m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])])
  8137. m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])])
  8138. m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])])
  8139. m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])])
  8140. m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])])
  8141. m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])])
  8142. m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])])
  8143. m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])])
  8144. m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])])
  8145. m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])])
  8146. m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])])
  8147. m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])])
  8148. m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])])
  8149. m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])])
  8150. m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])])
  8151. m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])])
  8152. m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])])
  8153. m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])])
  8154. m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])])
  8155. m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])])
  8156. m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])])
  8157. m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])])
  8158. m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])])
  8159. m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])])
  8160. m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])])
  8161. m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])])
  8162. m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])])
  8163. m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])])
  8164. m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])])
  8165. m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])])
  8166. m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])])
  8167. # Copyright (C) 2002-2021 Free Software Foundation, Inc.
  8168. #
  8169. # This file is free software; the Free Software Foundation
  8170. # gives unlimited permission to copy and/or distribute it,
  8171. # with or without modifications, as long as this notice is preserved.
  8172. # AM_AUTOMAKE_VERSION(VERSION)
  8173. # ----------------------------
  8174. # Automake X.Y traces this macro to ensure aclocal.m4 has been
  8175. # generated from the m4 files accompanying Automake X.Y.
  8176. # (This private macro should not be called outside this file.)
  8177. AC_DEFUN([AM_AUTOMAKE_VERSION],
  8178. [am__api_version='1.16'
  8179. dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
  8180. dnl require some minimum version. Point them to the right macro.
  8181. m4_if([$1], [1.16.5], [],
  8182. [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
  8183. ])
  8184. # _AM_AUTOCONF_VERSION(VERSION)
  8185. # -----------------------------
  8186. # aclocal traces this macro to find the Autoconf version.
  8187. # This is a private macro too. Using m4_define simplifies
  8188. # the logic in aclocal, which can simply ignore this definition.
  8189. m4_define([_AM_AUTOCONF_VERSION], [])
  8190. # AM_SET_CURRENT_AUTOMAKE_VERSION
  8191. # -------------------------------
  8192. # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
  8193. # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
  8194. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
  8195. [AM_AUTOMAKE_VERSION([1.16.5])dnl
  8196. m4_ifndef([AC_AUTOCONF_VERSION],
  8197. [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
  8198. _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
  8199. # Copyright (C) 2011-2021 Free Software Foundation, Inc.
  8200. #
  8201. # This file is free software; the Free Software Foundation
  8202. # gives unlimited permission to copy and/or distribute it,
  8203. # with or without modifications, as long as this notice is preserved.
  8204. # AM_PROG_AR([ACT-IF-FAIL])
  8205. # -------------------------
  8206. # Try to determine the archiver interface, and trigger the ar-lib wrapper
  8207. # if it is needed. If the detection of archiver interface fails, run
  8208. # ACT-IF-FAIL (default is to abort configure with a proper error message).
  8209. AC_DEFUN([AM_PROG_AR],
  8210. [AC_BEFORE([$0], [LT_INIT])dnl
  8211. AC_BEFORE([$0], [AC_PROG_LIBTOOL])dnl
  8212. AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
  8213. AC_REQUIRE_AUX_FILE([ar-lib])dnl
  8214. AC_CHECK_TOOLS([AR], [ar lib "link -lib"], [false])
  8215. : ${AR=ar}
  8216. AC_CACHE_CHECK([the archiver ($AR) interface], [am_cv_ar_interface],
  8217. [AC_LANG_PUSH([C])
  8218. am_cv_ar_interface=ar
  8219. AC_COMPILE_IFELSE([AC_LANG_SOURCE([[int some_variable = 0;]])],
  8220. [am_ar_try='$AR cru libconftest.a conftest.$ac_objext >&AS_MESSAGE_LOG_FD'
  8221. AC_TRY_EVAL([am_ar_try])
  8222. if test "$ac_status" -eq 0; then
  8223. am_cv_ar_interface=ar
  8224. else
  8225. am_ar_try='$AR -NOLOGO -OUT:conftest.lib conftest.$ac_objext >&AS_MESSAGE_LOG_FD'
  8226. AC_TRY_EVAL([am_ar_try])
  8227. if test "$ac_status" -eq 0; then
  8228. am_cv_ar_interface=lib
  8229. else
  8230. am_cv_ar_interface=unknown
  8231. fi
  8232. fi
  8233. rm -f conftest.lib libconftest.a
  8234. ])
  8235. AC_LANG_POP([C])])
  8236. case $am_cv_ar_interface in
  8237. ar)
  8238. ;;
  8239. lib)
  8240. # Microsoft lib, so override with the ar-lib wrapper script.
  8241. # FIXME: It is wrong to rewrite AR.
  8242. # But if we don't then we get into trouble of one sort or another.
  8243. # A longer-term fix would be to have automake use am__AR in this case,
  8244. # and then we could set am__AR="$am_aux_dir/ar-lib \$(AR)" or something
  8245. # similar.
  8246. AR="$am_aux_dir/ar-lib $AR"
  8247. ;;
  8248. unknown)
  8249. m4_default([$1],
  8250. [AC_MSG_ERROR([could not determine $AR interface])])
  8251. ;;
  8252. esac
  8253. AC_SUBST([AR])dnl
  8254. ])
  8255. # AM_AUX_DIR_EXPAND -*- Autoconf -*-
  8256. # Copyright (C) 2001-2021 Free Software Foundation, Inc.
  8257. #
  8258. # This file is free software; the Free Software Foundation
  8259. # gives unlimited permission to copy and/or distribute it,
  8260. # with or without modifications, as long as this notice is preserved.
  8261. # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
  8262. # $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to
  8263. # '$srcdir', '$srcdir/..', or '$srcdir/../..'.
  8264. #
  8265. # Of course, Automake must honor this variable whenever it calls a
  8266. # tool from the auxiliary directory. The problem is that $srcdir (and
  8267. # therefore $ac_aux_dir as well) can be either absolute or relative,
  8268. # depending on how configure is run. This is pretty annoying, since
  8269. # it makes $ac_aux_dir quite unusable in subdirectories: in the top
  8270. # source directory, any form will work fine, but in subdirectories a
  8271. # relative path needs to be adjusted first.
  8272. #
  8273. # $ac_aux_dir/missing
  8274. # fails when called from a subdirectory if $ac_aux_dir is relative
  8275. # $top_srcdir/$ac_aux_dir/missing
  8276. # fails if $ac_aux_dir is absolute,
  8277. # fails when called from a subdirectory in a VPATH build with
  8278. # a relative $ac_aux_dir
  8279. #
  8280. # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
  8281. # are both prefixed by $srcdir. In an in-source build this is usually
  8282. # harmless because $srcdir is '.', but things will broke when you
  8283. # start a VPATH build or use an absolute $srcdir.
  8284. #
  8285. # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
  8286. # iff we strip the leading $srcdir from $ac_aux_dir. That would be:
  8287. # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
  8288. # and then we would define $MISSING as
  8289. # MISSING="\${SHELL} $am_aux_dir/missing"
  8290. # This will work as long as MISSING is not called from configure, because
  8291. # unfortunately $(top_srcdir) has no meaning in configure.
  8292. # However there are other variables, like CC, which are often used in
  8293. # configure, and could therefore not use this "fixed" $ac_aux_dir.
  8294. #
  8295. # Another solution, used here, is to always expand $ac_aux_dir to an
  8296. # absolute PATH. The drawback is that using absolute paths prevent a
  8297. # configured tree to be moved without reconfiguration.
  8298. AC_DEFUN([AM_AUX_DIR_EXPAND],
  8299. [AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
  8300. # Expand $ac_aux_dir to an absolute path.
  8301. am_aux_dir=`cd "$ac_aux_dir" && pwd`
  8302. ])
  8303. # AM_CONDITIONAL -*- Autoconf -*-
  8304. # Copyright (C) 1997-2021 Free Software Foundation, Inc.
  8305. #
  8306. # This file is free software; the Free Software Foundation
  8307. # gives unlimited permission to copy and/or distribute it,
  8308. # with or without modifications, as long as this notice is preserved.
  8309. # AM_CONDITIONAL(NAME, SHELL-CONDITION)
  8310. # -------------------------------------
  8311. # Define a conditional.
  8312. AC_DEFUN([AM_CONDITIONAL],
  8313. [AC_PREREQ([2.52])dnl
  8314. m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
  8315. [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
  8316. AC_SUBST([$1_TRUE])dnl
  8317. AC_SUBST([$1_FALSE])dnl
  8318. _AM_SUBST_NOTMAKE([$1_TRUE])dnl
  8319. _AM_SUBST_NOTMAKE([$1_FALSE])dnl
  8320. m4_define([_AM_COND_VALUE_$1], [$2])dnl
  8321. if $2; then
  8322. $1_TRUE=
  8323. $1_FALSE='#'
  8324. else
  8325. $1_TRUE='#'
  8326. $1_FALSE=
  8327. fi
  8328. AC_CONFIG_COMMANDS_PRE(
  8329. [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
  8330. AC_MSG_ERROR([[conditional "$1" was never defined.
  8331. Usually this means the macro was only invoked conditionally.]])
  8332. fi])])
  8333. # Copyright (C) 1999-2021 Free Software Foundation, Inc.
  8334. #
  8335. # This file is free software; the Free Software Foundation
  8336. # gives unlimited permission to copy and/or distribute it,
  8337. # with or without modifications, as long as this notice is preserved.
  8338. # There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be
  8339. # written in clear, in which case automake, when reading aclocal.m4,
  8340. # will think it sees a *use*, and therefore will trigger all it's
  8341. # C support machinery. Also note that it means that autoscan, seeing
  8342. # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
  8343. # _AM_DEPENDENCIES(NAME)
  8344. # ----------------------
  8345. # See how the compiler implements dependency checking.
  8346. # NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC".
  8347. # We try a few techniques and use that to set a single cache variable.
  8348. #
  8349. # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
  8350. # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
  8351. # dependency, and given that the user is not expected to run this macro,
  8352. # just rely on AC_PROG_CC.
  8353. AC_DEFUN([_AM_DEPENDENCIES],
  8354. [AC_REQUIRE([AM_SET_DEPDIR])dnl
  8355. AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
  8356. AC_REQUIRE([AM_MAKE_INCLUDE])dnl
  8357. AC_REQUIRE([AM_DEP_TRACK])dnl
  8358. m4_if([$1], [CC], [depcc="$CC" am_compiler_list=],
  8359. [$1], [CXX], [depcc="$CXX" am_compiler_list=],
  8360. [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
  8361. [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'],
  8362. [$1], [UPC], [depcc="$UPC" am_compiler_list=],
  8363. [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
  8364. [depcc="$$1" am_compiler_list=])
  8365. AC_CACHE_CHECK([dependency style of $depcc],
  8366. [am_cv_$1_dependencies_compiler_type],
  8367. [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
  8368. # We make a subdir and do the tests there. Otherwise we can end up
  8369. # making bogus files that we don't know about and never remove. For
  8370. # instance it was reported that on HP-UX the gcc test will end up
  8371. # making a dummy file named 'D' -- because '-MD' means "put the output
  8372. # in D".
  8373. rm -rf conftest.dir
  8374. mkdir conftest.dir
  8375. # Copy depcomp to subdir because otherwise we won't find it if we're
  8376. # using a relative directory.
  8377. cp "$am_depcomp" conftest.dir
  8378. cd conftest.dir
  8379. # We will build objects and dependencies in a subdirectory because
  8380. # it helps to detect inapplicable dependency modes. For instance
  8381. # both Tru64's cc and ICC support -MD to output dependencies as a
  8382. # side effect of compilation, but ICC will put the dependencies in
  8383. # the current directory while Tru64 will put them in the object
  8384. # directory.
  8385. mkdir sub
  8386. am_cv_$1_dependencies_compiler_type=none
  8387. if test "$am_compiler_list" = ""; then
  8388. am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
  8389. fi
  8390. am__universal=false
  8391. m4_case([$1], [CC],
  8392. [case " $depcc " in #(
  8393. *\ -arch\ *\ -arch\ *) am__universal=true ;;
  8394. esac],
  8395. [CXX],
  8396. [case " $depcc " in #(
  8397. *\ -arch\ *\ -arch\ *) am__universal=true ;;
  8398. esac])
  8399. for depmode in $am_compiler_list; do
  8400. # Setup a source with many dependencies, because some compilers
  8401. # like to wrap large dependency lists on column 80 (with \), and
  8402. # we should not choose a depcomp mode which is confused by this.
  8403. #
  8404. # We need to recreate these files for each test, as the compiler may
  8405. # overwrite some of them when testing with obscure command lines.
  8406. # This happens at least with the AIX C compiler.
  8407. : > sub/conftest.c
  8408. for i in 1 2 3 4 5 6; do
  8409. echo '#include "conftst'$i'.h"' >> sub/conftest.c
  8410. # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
  8411. # Solaris 10 /bin/sh.
  8412. echo '/* dummy */' > sub/conftst$i.h
  8413. done
  8414. echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
  8415. # We check with '-c' and '-o' for the sake of the "dashmstdout"
  8416. # mode. It turns out that the SunPro C++ compiler does not properly
  8417. # handle '-M -o', and we need to detect this. Also, some Intel
  8418. # versions had trouble with output in subdirs.
  8419. am__obj=sub/conftest.${OBJEXT-o}
  8420. am__minus_obj="-o $am__obj"
  8421. case $depmode in
  8422. gcc)
  8423. # This depmode causes a compiler race in universal mode.
  8424. test "$am__universal" = false || continue
  8425. ;;
  8426. nosideeffect)
  8427. # After this tag, mechanisms are not by side-effect, so they'll
  8428. # only be used when explicitly requested.
  8429. if test "x$enable_dependency_tracking" = xyes; then
  8430. continue
  8431. else
  8432. break
  8433. fi
  8434. ;;
  8435. msvc7 | msvc7msys | msvisualcpp | msvcmsys)
  8436. # This compiler won't grok '-c -o', but also, the minuso test has
  8437. # not run yet. These depmodes are late enough in the game, and
  8438. # so weak that their functioning should not be impacted.
  8439. am__obj=conftest.${OBJEXT-o}
  8440. am__minus_obj=
  8441. ;;
  8442. none) break ;;
  8443. esac
  8444. if depmode=$depmode \
  8445. source=sub/conftest.c object=$am__obj \
  8446. depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
  8447. $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
  8448. >/dev/null 2>conftest.err &&
  8449. grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
  8450. grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
  8451. grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
  8452. ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
  8453. # icc doesn't choke on unknown options, it will just issue warnings
  8454. # or remarks (even with -Werror). So we grep stderr for any message
  8455. # that says an option was ignored or not supported.
  8456. # When given -MP, icc 7.0 and 7.1 complain thusly:
  8457. # icc: Command line warning: ignoring option '-M'; no argument required
  8458. # The diagnosis changed in icc 8.0:
  8459. # icc: Command line remark: option '-MP' not supported
  8460. if (grep 'ignoring option' conftest.err ||
  8461. grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
  8462. am_cv_$1_dependencies_compiler_type=$depmode
  8463. break
  8464. fi
  8465. fi
  8466. done
  8467. cd ..
  8468. rm -rf conftest.dir
  8469. else
  8470. am_cv_$1_dependencies_compiler_type=none
  8471. fi
  8472. ])
  8473. AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
  8474. AM_CONDITIONAL([am__fastdep$1], [
  8475. test "x$enable_dependency_tracking" != xno \
  8476. && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
  8477. ])
  8478. # AM_SET_DEPDIR
  8479. # -------------
  8480. # Choose a directory name for dependency files.
  8481. # This macro is AC_REQUIREd in _AM_DEPENDENCIES.
  8482. AC_DEFUN([AM_SET_DEPDIR],
  8483. [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
  8484. AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
  8485. ])
  8486. # AM_DEP_TRACK
  8487. # ------------
  8488. AC_DEFUN([AM_DEP_TRACK],
  8489. [AC_ARG_ENABLE([dependency-tracking], [dnl
  8490. AS_HELP_STRING(
  8491. [--enable-dependency-tracking],
  8492. [do not reject slow dependency extractors])
  8493. AS_HELP_STRING(
  8494. [--disable-dependency-tracking],
  8495. [speeds up one-time build])])
  8496. if test "x$enable_dependency_tracking" != xno; then
  8497. am_depcomp="$ac_aux_dir/depcomp"
  8498. AMDEPBACKSLASH='\'
  8499. am__nodep='_no'
  8500. fi
  8501. AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
  8502. AC_SUBST([AMDEPBACKSLASH])dnl
  8503. _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
  8504. AC_SUBST([am__nodep])dnl
  8505. _AM_SUBST_NOTMAKE([am__nodep])dnl
  8506. ])
  8507. # Generate code to set up dependency tracking. -*- Autoconf -*-
  8508. # Copyright (C) 1999-2021 Free Software Foundation, Inc.
  8509. #
  8510. # This file is free software; the Free Software Foundation
  8511. # gives unlimited permission to copy and/or distribute it,
  8512. # with or without modifications, as long as this notice is preserved.
  8513. # _AM_OUTPUT_DEPENDENCY_COMMANDS
  8514. # ------------------------------
  8515. AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
  8516. [{
  8517. # Older Autoconf quotes --file arguments for eval, but not when files
  8518. # are listed without --file. Let's play safe and only enable the eval
  8519. # if we detect the quoting.
  8520. # TODO: see whether this extra hack can be removed once we start
  8521. # requiring Autoconf 2.70 or later.
  8522. AS_CASE([$CONFIG_FILES],
  8523. [*\'*], [eval set x "$CONFIG_FILES"],
  8524. [*], [set x $CONFIG_FILES])
  8525. shift
  8526. # Used to flag and report bootstrapping failures.
  8527. am_rc=0
  8528. for am_mf
  8529. do
  8530. # Strip MF so we end up with the name of the file.
  8531. am_mf=`AS_ECHO(["$am_mf"]) | sed -e 's/:.*$//'`
  8532. # Check whether this is an Automake generated Makefile which includes
  8533. # dependency-tracking related rules and includes.
  8534. # Grep'ing the whole file directly is not great: AIX grep has a line
  8535. # limit of 2048, but all sed's we know have understand at least 4000.
  8536. sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \
  8537. || continue
  8538. am_dirpart=`AS_DIRNAME(["$am_mf"])`
  8539. am_filepart=`AS_BASENAME(["$am_mf"])`
  8540. AM_RUN_LOG([cd "$am_dirpart" \
  8541. && sed -e '/# am--include-marker/d' "$am_filepart" \
  8542. | $MAKE -f - am--depfiles]) || am_rc=$?
  8543. done
  8544. if test $am_rc -ne 0; then
  8545. AC_MSG_FAILURE([Something went wrong bootstrapping makefile fragments
  8546. for automatic dependency tracking. If GNU make was not used, consider
  8547. re-running the configure script with MAKE="gmake" (or whatever is
  8548. necessary). You can also try re-running configure with the
  8549. '--disable-dependency-tracking' option to at least be able to build
  8550. the package (albeit without support for automatic dependency tracking).])
  8551. fi
  8552. AS_UNSET([am_dirpart])
  8553. AS_UNSET([am_filepart])
  8554. AS_UNSET([am_mf])
  8555. AS_UNSET([am_rc])
  8556. rm -f conftest-deps.mk
  8557. }
  8558. ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
  8559. # AM_OUTPUT_DEPENDENCY_COMMANDS
  8560. # -----------------------------
  8561. # This macro should only be invoked once -- use via AC_REQUIRE.
  8562. #
  8563. # This code is only required when automatic dependency tracking is enabled.
  8564. # This creates each '.Po' and '.Plo' makefile fragment that we'll need in
  8565. # order to bootstrap the dependency handling code.
  8566. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
  8567. [AC_CONFIG_COMMANDS([depfiles],
  8568. [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
  8569. [AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"])])
  8570. # Do all the work for Automake. -*- Autoconf -*-
  8571. # Copyright (C) 1996-2021 Free Software Foundation, Inc.
  8572. #
  8573. # This file is free software; the Free Software Foundation
  8574. # gives unlimited permission to copy and/or distribute it,
  8575. # with or without modifications, as long as this notice is preserved.
  8576. # This macro actually does too much. Some checks are only needed if
  8577. # your package does certain things. But this isn't really a big deal.
  8578. dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O.
  8579. m4_define([AC_PROG_CC],
  8580. m4_defn([AC_PROG_CC])
  8581. [_AM_PROG_CC_C_O
  8582. ])
  8583. # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
  8584. # AM_INIT_AUTOMAKE([OPTIONS])
  8585. # -----------------------------------------------
  8586. # The call with PACKAGE and VERSION arguments is the old style
  8587. # call (pre autoconf-2.50), which is being phased out. PACKAGE
  8588. # and VERSION should now be passed to AC_INIT and removed from
  8589. # the call to AM_INIT_AUTOMAKE.
  8590. # We support both call styles for the transition. After
  8591. # the next Automake release, Autoconf can make the AC_INIT
  8592. # arguments mandatory, and then we can depend on a new Autoconf
  8593. # release and drop the old call support.
  8594. AC_DEFUN([AM_INIT_AUTOMAKE],
  8595. [AC_PREREQ([2.65])dnl
  8596. m4_ifdef([_$0_ALREADY_INIT],
  8597. [m4_fatal([$0 expanded multiple times
  8598. ]m4_defn([_$0_ALREADY_INIT]))],
  8599. [m4_define([_$0_ALREADY_INIT], m4_expansion_stack)])dnl
  8600. dnl Autoconf wants to disallow AM_ names. We explicitly allow
  8601. dnl the ones we care about.
  8602. m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
  8603. AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
  8604. AC_REQUIRE([AC_PROG_INSTALL])dnl
  8605. if test "`cd $srcdir && pwd`" != "`pwd`"; then
  8606. # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
  8607. # is not polluted with repeated "-I."
  8608. AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
  8609. # test to see if srcdir already configured
  8610. if test -f $srcdir/config.status; then
  8611. AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
  8612. fi
  8613. fi
  8614. # test whether we have cygpath
  8615. if test -z "$CYGPATH_W"; then
  8616. if (cygpath --version) >/dev/null 2>/dev/null; then
  8617. CYGPATH_W='cygpath -w'
  8618. else
  8619. CYGPATH_W=echo
  8620. fi
  8621. fi
  8622. AC_SUBST([CYGPATH_W])
  8623. # Define the identity of the package.
  8624. dnl Distinguish between old-style and new-style calls.
  8625. m4_ifval([$2],
  8626. [AC_DIAGNOSE([obsolete],
  8627. [$0: two- and three-arguments forms are deprecated.])
  8628. m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
  8629. AC_SUBST([PACKAGE], [$1])dnl
  8630. AC_SUBST([VERSION], [$2])],
  8631. [_AM_SET_OPTIONS([$1])dnl
  8632. dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
  8633. m4_if(
  8634. m4_ifset([AC_PACKAGE_NAME], [ok]):m4_ifset([AC_PACKAGE_VERSION], [ok]),
  8635. [ok:ok],,
  8636. [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
  8637. AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
  8638. AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
  8639. _AM_IF_OPTION([no-define],,
  8640. [AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package])
  8641. AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl
  8642. # Some tools Automake needs.
  8643. AC_REQUIRE([AM_SANITY_CHECK])dnl
  8644. AC_REQUIRE([AC_ARG_PROGRAM])dnl
  8645. AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}])
  8646. AM_MISSING_PROG([AUTOCONF], [autoconf])
  8647. AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}])
  8648. AM_MISSING_PROG([AUTOHEADER], [autoheader])
  8649. AM_MISSING_PROG([MAKEINFO], [makeinfo])
  8650. AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
  8651. AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
  8652. AC_REQUIRE([AC_PROG_MKDIR_P])dnl
  8653. # For better backward compatibility. To be removed once Automake 1.9.x
  8654. # dies out for good. For more background, see:
  8655. # <https://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
  8656. # <https://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
  8657. AC_SUBST([mkdir_p], ['$(MKDIR_P)'])
  8658. # We need awk for the "check" target (and possibly the TAP driver). The
  8659. # system "awk" is bad on some platforms.
  8660. AC_REQUIRE([AC_PROG_AWK])dnl
  8661. AC_REQUIRE([AC_PROG_MAKE_SET])dnl
  8662. AC_REQUIRE([AM_SET_LEADING_DOT])dnl
  8663. _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
  8664. [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
  8665. [_AM_PROG_TAR([v7])])])
  8666. _AM_IF_OPTION([no-dependencies],,
  8667. [AC_PROVIDE_IFELSE([AC_PROG_CC],
  8668. [_AM_DEPENDENCIES([CC])],
  8669. [m4_define([AC_PROG_CC],
  8670. m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl
  8671. AC_PROVIDE_IFELSE([AC_PROG_CXX],
  8672. [_AM_DEPENDENCIES([CXX])],
  8673. [m4_define([AC_PROG_CXX],
  8674. m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl
  8675. AC_PROVIDE_IFELSE([AC_PROG_OBJC],
  8676. [_AM_DEPENDENCIES([OBJC])],
  8677. [m4_define([AC_PROG_OBJC],
  8678. m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl
  8679. AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
  8680. [_AM_DEPENDENCIES([OBJCXX])],
  8681. [m4_define([AC_PROG_OBJCXX],
  8682. m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl
  8683. ])
  8684. # Variables for tags utilities; see am/tags.am
  8685. if test -z "$CTAGS"; then
  8686. CTAGS=ctags
  8687. fi
  8688. AC_SUBST([CTAGS])
  8689. if test -z "$ETAGS"; then
  8690. ETAGS=etags
  8691. fi
  8692. AC_SUBST([ETAGS])
  8693. if test -z "$CSCOPE"; then
  8694. CSCOPE=cscope
  8695. fi
  8696. AC_SUBST([CSCOPE])
  8697. AC_REQUIRE([AM_SILENT_RULES])dnl
  8698. dnl The testsuite driver may need to know about EXEEXT, so add the
  8699. dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This
  8700. dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below.
  8701. AC_CONFIG_COMMANDS_PRE(dnl
  8702. [m4_provide_if([_AM_COMPILER_EXEEXT],
  8703. [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
  8704. # POSIX will say in a future version that running "rm -f" with no argument
  8705. # is OK; and we want to be able to make that assumption in our Makefile
  8706. # recipes. So use an aggressive probe to check that the usage we want is
  8707. # actually supported "in the wild" to an acceptable degree.
  8708. # See automake bug#10828.
  8709. # To make any issue more visible, cause the running configure to be aborted
  8710. # by default if the 'rm' program in use doesn't match our expectations; the
  8711. # user can still override this though.
  8712. if rm -f && rm -fr && rm -rf; then : OK; else
  8713. cat >&2 <<'END'
  8714. Oops!
  8715. Your 'rm' program seems unable to run without file operands specified
  8716. on the command line, even when the '-f' option is present. This is contrary
  8717. to the behaviour of most rm programs out there, and not conforming with
  8718. the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
  8719. Please tell bug-automake@gnu.org about your system, including the value
  8720. of your $PATH and any error possibly output before this message. This
  8721. can help us improve future automake versions.
  8722. END
  8723. if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
  8724. echo 'Configuration will proceed anyway, since you have set the' >&2
  8725. echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
  8726. echo >&2
  8727. else
  8728. cat >&2 <<'END'
  8729. Aborting the configuration process, to ensure you take notice of the issue.
  8730. You can download and install GNU coreutils to get an 'rm' implementation
  8731. that behaves properly: <https://www.gnu.org/software/coreutils/>.
  8732. If you want to complete the configuration process using your problematic
  8733. 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
  8734. to "yes", and re-run configure.
  8735. END
  8736. AC_MSG_ERROR([Your 'rm' program is bad, sorry.])
  8737. fi
  8738. fi
  8739. dnl The trailing newline in this macro's definition is deliberate, for
  8740. dnl backward compatibility and to allow trailing 'dnl'-style comments
  8741. dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841.
  8742. ])
  8743. dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not
  8744. dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
  8745. dnl mangled by Autoconf and run in a shell conditional statement.
  8746. m4_define([_AC_COMPILER_EXEEXT],
  8747. m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
  8748. # When config.status generates a header, we must update the stamp-h file.
  8749. # This file resides in the same directory as the config header
  8750. # that is generated. The stamp files are numbered to have different names.
  8751. # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
  8752. # loop where config.status creates the headers, so we can generate
  8753. # our stamp files there.
  8754. AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
  8755. [# Compute $1's index in $config_headers.
  8756. _am_arg=$1
  8757. _am_stamp_count=1
  8758. for _am_header in $config_headers :; do
  8759. case $_am_header in
  8760. $_am_arg | $_am_arg:* )
  8761. break ;;
  8762. * )
  8763. _am_stamp_count=`expr $_am_stamp_count + 1` ;;
  8764. esac
  8765. done
  8766. echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
  8767. # Copyright (C) 2001-2021 Free Software Foundation, Inc.
  8768. #
  8769. # This file is free software; the Free Software Foundation
  8770. # gives unlimited permission to copy and/or distribute it,
  8771. # with or without modifications, as long as this notice is preserved.
  8772. # AM_PROG_INSTALL_SH
  8773. # ------------------
  8774. # Define $install_sh.
  8775. AC_DEFUN([AM_PROG_INSTALL_SH],
  8776. [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
  8777. if test x"${install_sh+set}" != xset; then
  8778. case $am_aux_dir in
  8779. *\ * | *\ *)
  8780. install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
  8781. *)
  8782. install_sh="\${SHELL} $am_aux_dir/install-sh"
  8783. esac
  8784. fi
  8785. AC_SUBST([install_sh])])
  8786. # Copyright (C) 2003-2021 Free Software Foundation, Inc.
  8787. #
  8788. # This file is free software; the Free Software Foundation
  8789. # gives unlimited permission to copy and/or distribute it,
  8790. # with or without modifications, as long as this notice is preserved.
  8791. # Check whether the underlying file-system supports filenames
  8792. # with a leading dot. For instance MS-DOS doesn't.
  8793. AC_DEFUN([AM_SET_LEADING_DOT],
  8794. [rm -rf .tst 2>/dev/null
  8795. mkdir .tst 2>/dev/null
  8796. if test -d .tst; then
  8797. am__leading_dot=.
  8798. else
  8799. am__leading_dot=_
  8800. fi
  8801. rmdir .tst 2>/dev/null
  8802. AC_SUBST([am__leading_dot])])
  8803. # Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
  8804. # From Jim Meyering
  8805. # Copyright (C) 1996-2021 Free Software Foundation, Inc.
  8806. #
  8807. # This file is free software; the Free Software Foundation
  8808. # gives unlimited permission to copy and/or distribute it,
  8809. # with or without modifications, as long as this notice is preserved.
  8810. # AM_MAINTAINER_MODE([DEFAULT-MODE])
  8811. # ----------------------------------
  8812. # Control maintainer-specific portions of Makefiles.
  8813. # Default is to disable them, unless 'enable' is passed literally.
  8814. # For symmetry, 'disable' may be passed as well. Anyway, the user
  8815. # can override the default with the --enable/--disable switch.
  8816. AC_DEFUN([AM_MAINTAINER_MODE],
  8817. [m4_case(m4_default([$1], [disable]),
  8818. [enable], [m4_define([am_maintainer_other], [disable])],
  8819. [disable], [m4_define([am_maintainer_other], [enable])],
  8820. [m4_define([am_maintainer_other], [enable])
  8821. m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])])
  8822. AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
  8823. dnl maintainer-mode's default is 'disable' unless 'enable' is passed
  8824. AC_ARG_ENABLE([maintainer-mode],
  8825. [AS_HELP_STRING([--]am_maintainer_other[-maintainer-mode],
  8826. am_maintainer_other[ make rules and dependencies not useful
  8827. (and sometimes confusing) to the casual installer])],
  8828. [USE_MAINTAINER_MODE=$enableval],
  8829. [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes]))
  8830. AC_MSG_RESULT([$USE_MAINTAINER_MODE])
  8831. AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes])
  8832. MAINT=$MAINTAINER_MODE_TRUE
  8833. AC_SUBST([MAINT])dnl
  8834. ]
  8835. )
  8836. # Check to see how 'make' treats includes. -*- Autoconf -*-
  8837. # Copyright (C) 2001-2021 Free Software Foundation, Inc.
  8838. #
  8839. # This file is free software; the Free Software Foundation
  8840. # gives unlimited permission to copy and/or distribute it,
  8841. # with or without modifications, as long as this notice is preserved.
  8842. # AM_MAKE_INCLUDE()
  8843. # -----------------
  8844. # Check whether make has an 'include' directive that can support all
  8845. # the idioms we need for our automatic dependency tracking code.
  8846. AC_DEFUN([AM_MAKE_INCLUDE],
  8847. [AC_MSG_CHECKING([whether ${MAKE-make} supports the include directive])
  8848. cat > confinc.mk << 'END'
  8849. am__doit:
  8850. @echo this is the am__doit target >confinc.out
  8851. .PHONY: am__doit
  8852. END
  8853. am__include="#"
  8854. am__quote=
  8855. # BSD make does it like this.
  8856. echo '.include "confinc.mk" # ignored' > confmf.BSD
  8857. # Other make implementations (GNU, Solaris 10, AIX) do it like this.
  8858. echo 'include confinc.mk # ignored' > confmf.GNU
  8859. _am_result=no
  8860. for s in GNU BSD; do
  8861. AM_RUN_LOG([${MAKE-make} -f confmf.$s && cat confinc.out])
  8862. AS_CASE([$?:`cat confinc.out 2>/dev/null`],
  8863. ['0:this is the am__doit target'],
  8864. [AS_CASE([$s],
  8865. [BSD], [am__include='.include' am__quote='"'],
  8866. [am__include='include' am__quote=''])])
  8867. if test "$am__include" != "#"; then
  8868. _am_result="yes ($s style)"
  8869. break
  8870. fi
  8871. done
  8872. rm -f confinc.* confmf.*
  8873. AC_MSG_RESULT([${_am_result}])
  8874. AC_SUBST([am__include])])
  8875. AC_SUBST([am__quote])])
  8876. # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
  8877. # Copyright (C) 1997-2021 Free Software Foundation, Inc.
  8878. #
  8879. # This file is free software; the Free Software Foundation
  8880. # gives unlimited permission to copy and/or distribute it,
  8881. # with or without modifications, as long as this notice is preserved.
  8882. # AM_MISSING_PROG(NAME, PROGRAM)
  8883. # ------------------------------
  8884. AC_DEFUN([AM_MISSING_PROG],
  8885. [AC_REQUIRE([AM_MISSING_HAS_RUN])
  8886. $1=${$1-"${am_missing_run}$2"}
  8887. AC_SUBST($1)])
  8888. # AM_MISSING_HAS_RUN
  8889. # ------------------
  8890. # Define MISSING if not defined so far and test if it is modern enough.
  8891. # If it is, set am_missing_run to use it, otherwise, to nothing.
  8892. AC_DEFUN([AM_MISSING_HAS_RUN],
  8893. [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
  8894. AC_REQUIRE_AUX_FILE([missing])dnl
  8895. if test x"${MISSING+set}" != xset; then
  8896. MISSING="\${SHELL} '$am_aux_dir/missing'"
  8897. fi
  8898. # Use eval to expand $SHELL
  8899. if eval "$MISSING --is-lightweight"; then
  8900. am_missing_run="$MISSING "
  8901. else
  8902. am_missing_run=
  8903. AC_MSG_WARN(['missing' script is too old or missing])
  8904. fi
  8905. ])
  8906. # Helper functions for option handling. -*- Autoconf -*-
  8907. # Copyright (C) 2001-2021 Free Software Foundation, Inc.
  8908. #
  8909. # This file is free software; the Free Software Foundation
  8910. # gives unlimited permission to copy and/or distribute it,
  8911. # with or without modifications, as long as this notice is preserved.
  8912. # _AM_MANGLE_OPTION(NAME)
  8913. # -----------------------
  8914. AC_DEFUN([_AM_MANGLE_OPTION],
  8915. [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
  8916. # _AM_SET_OPTION(NAME)
  8917. # --------------------
  8918. # Set option NAME. Presently that only means defining a flag for this option.
  8919. AC_DEFUN([_AM_SET_OPTION],
  8920. [m4_define(_AM_MANGLE_OPTION([$1]), [1])])
  8921. # _AM_SET_OPTIONS(OPTIONS)
  8922. # ------------------------
  8923. # OPTIONS is a space-separated list of Automake options.
  8924. AC_DEFUN([_AM_SET_OPTIONS],
  8925. [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
  8926. # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
  8927. # -------------------------------------------
  8928. # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
  8929. AC_DEFUN([_AM_IF_OPTION],
  8930. [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
  8931. # Copyright (C) 1999-2021 Free Software Foundation, Inc.
  8932. #
  8933. # This file is free software; the Free Software Foundation
  8934. # gives unlimited permission to copy and/or distribute it,
  8935. # with or without modifications, as long as this notice is preserved.
  8936. # _AM_PROG_CC_C_O
  8937. # ---------------
  8938. # Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC
  8939. # to automatically call this.
  8940. AC_DEFUN([_AM_PROG_CC_C_O],
  8941. [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
  8942. AC_REQUIRE_AUX_FILE([compile])dnl
  8943. AC_LANG_PUSH([C])dnl
  8944. AC_CACHE_CHECK(
  8945. [whether $CC understands -c and -o together],
  8946. [am_cv_prog_cc_c_o],
  8947. [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])])
  8948. # Make sure it works both with $CC and with simple cc.
  8949. # Following AC_PROG_CC_C_O, we do the test twice because some
  8950. # compilers refuse to overwrite an existing .o file with -o,
  8951. # though they will create one.
  8952. am_cv_prog_cc_c_o=yes
  8953. for am_i in 1 2; do
  8954. if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \
  8955. && test -f conftest2.$ac_objext; then
  8956. : OK
  8957. else
  8958. am_cv_prog_cc_c_o=no
  8959. break
  8960. fi
  8961. done
  8962. rm -f core conftest*
  8963. unset am_i])
  8964. if test "$am_cv_prog_cc_c_o" != yes; then
  8965. # Losing compiler, so override with the script.
  8966. # FIXME: It is wrong to rewrite CC.
  8967. # But if we don't then we get into trouble of one sort or another.
  8968. # A longer-term fix would be to have automake use am__CC in this case,
  8969. # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
  8970. CC="$am_aux_dir/compile $CC"
  8971. fi
  8972. AC_LANG_POP([C])])
  8973. # For backward compatibility.
  8974. AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
  8975. # Copyright (C) 2001-2021 Free Software Foundation, Inc.
  8976. #
  8977. # This file is free software; the Free Software Foundation
  8978. # gives unlimited permission to copy and/or distribute it,
  8979. # with or without modifications, as long as this notice is preserved.
  8980. # AM_RUN_LOG(COMMAND)
  8981. # -------------------
  8982. # Run COMMAND, save the exit status in ac_status, and log it.
  8983. # (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
  8984. AC_DEFUN([AM_RUN_LOG],
  8985. [{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
  8986. ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
  8987. ac_status=$?
  8988. echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
  8989. (exit $ac_status); }])
  8990. # Check to make sure that the build environment is sane. -*- Autoconf -*-
  8991. # Copyright (C) 1996-2021 Free Software Foundation, Inc.
  8992. #
  8993. # This file is free software; the Free Software Foundation
  8994. # gives unlimited permission to copy and/or distribute it,
  8995. # with or without modifications, as long as this notice is preserved.
  8996. # AM_SANITY_CHECK
  8997. # ---------------
  8998. AC_DEFUN([AM_SANITY_CHECK],
  8999. [AC_MSG_CHECKING([whether build environment is sane])
  9000. # Reject unsafe characters in $srcdir or the absolute working directory
  9001. # name. Accept space and tab only in the latter.
  9002. am_lf='
  9003. '
  9004. case `pwd` in
  9005. *[[\\\"\#\$\&\'\`$am_lf]]*)
  9006. AC_MSG_ERROR([unsafe absolute working directory name]);;
  9007. esac
  9008. case $srcdir in
  9009. *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*)
  9010. AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);;
  9011. esac
  9012. # Do 'set' in a subshell so we don't clobber the current shell's
  9013. # arguments. Must try -L first in case configure is actually a
  9014. # symlink; some systems play weird games with the mod time of symlinks
  9015. # (eg FreeBSD returns the mod time of the symlink's containing
  9016. # directory).
  9017. if (
  9018. am_has_slept=no
  9019. for am_try in 1 2; do
  9020. echo "timestamp, slept: $am_has_slept" > conftest.file
  9021. set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
  9022. if test "$[*]" = "X"; then
  9023. # -L didn't work.
  9024. set X `ls -t "$srcdir/configure" conftest.file`
  9025. fi
  9026. if test "$[*]" != "X $srcdir/configure conftest.file" \
  9027. && test "$[*]" != "X conftest.file $srcdir/configure"; then
  9028. # If neither matched, then we have a broken ls. This can happen
  9029. # if, for instance, CONFIG_SHELL is bash and it inherits a
  9030. # broken ls alias from the environment. This has actually
  9031. # happened. Such a system could not be considered "sane".
  9032. AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
  9033. alias in your environment])
  9034. fi
  9035. if test "$[2]" = conftest.file || test $am_try -eq 2; then
  9036. break
  9037. fi
  9038. # Just in case.
  9039. sleep 1
  9040. am_has_slept=yes
  9041. done
  9042. test "$[2]" = conftest.file
  9043. )
  9044. then
  9045. # Ok.
  9046. :
  9047. else
  9048. AC_MSG_ERROR([newly created file is older than distributed files!
  9049. Check your system clock])
  9050. fi
  9051. AC_MSG_RESULT([yes])
  9052. # If we didn't sleep, we still need to ensure time stamps of config.status and
  9053. # generated files are strictly newer.
  9054. am_sleep_pid=
  9055. if grep 'slept: no' conftest.file >/dev/null 2>&1; then
  9056. ( sleep 1 ) &
  9057. am_sleep_pid=$!
  9058. fi
  9059. AC_CONFIG_COMMANDS_PRE(
  9060. [AC_MSG_CHECKING([that generated files are newer than configure])
  9061. if test -n "$am_sleep_pid"; then
  9062. # Hide warnings about reused PIDs.
  9063. wait $am_sleep_pid 2>/dev/null
  9064. fi
  9065. AC_MSG_RESULT([done])])
  9066. rm -f conftest.file
  9067. ])
  9068. # Copyright (C) 2009-2021 Free Software Foundation, Inc.
  9069. #
  9070. # This file is free software; the Free Software Foundation
  9071. # gives unlimited permission to copy and/or distribute it,
  9072. # with or without modifications, as long as this notice is preserved.
  9073. # AM_SILENT_RULES([DEFAULT])
  9074. # --------------------------
  9075. # Enable less verbose build rules; with the default set to DEFAULT
  9076. # ("yes" being less verbose, "no" or empty being verbose).
  9077. AC_DEFUN([AM_SILENT_RULES],
  9078. [AC_ARG_ENABLE([silent-rules], [dnl
  9079. AS_HELP_STRING(
  9080. [--enable-silent-rules],
  9081. [less verbose build output (undo: "make V=1")])
  9082. AS_HELP_STRING(
  9083. [--disable-silent-rules],
  9084. [verbose build output (undo: "make V=0")])dnl
  9085. ])
  9086. case $enable_silent_rules in @%:@ (((
  9087. yes) AM_DEFAULT_VERBOSITY=0;;
  9088. no) AM_DEFAULT_VERBOSITY=1;;
  9089. *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
  9090. esac
  9091. dnl
  9092. dnl A few 'make' implementations (e.g., NonStop OS and NextStep)
  9093. dnl do not support nested variable expansions.
  9094. dnl See automake bug#9928 and bug#10237.
  9095. am_make=${MAKE-make}
  9096. AC_CACHE_CHECK([whether $am_make supports nested variables],
  9097. [am_cv_make_support_nested_variables],
  9098. [if AS_ECHO([['TRUE=$(BAR$(V))
  9099. BAR0=false
  9100. BAR1=true
  9101. V=1
  9102. am__doit:
  9103. @$(TRUE)
  9104. .PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then
  9105. am_cv_make_support_nested_variables=yes
  9106. else
  9107. am_cv_make_support_nested_variables=no
  9108. fi])
  9109. if test $am_cv_make_support_nested_variables = yes; then
  9110. dnl Using '$V' instead of '$(V)' breaks IRIX make.
  9111. AM_V='$(V)'
  9112. AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
  9113. else
  9114. AM_V=$AM_DEFAULT_VERBOSITY
  9115. AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
  9116. fi
  9117. AC_SUBST([AM_V])dnl
  9118. AM_SUBST_NOTMAKE([AM_V])dnl
  9119. AC_SUBST([AM_DEFAULT_V])dnl
  9120. AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl
  9121. AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
  9122. AM_BACKSLASH='\'
  9123. AC_SUBST([AM_BACKSLASH])dnl
  9124. _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
  9125. ])
  9126. # Copyright (C) 2001-2021 Free Software Foundation, Inc.
  9127. #
  9128. # This file is free software; the Free Software Foundation
  9129. # gives unlimited permission to copy and/or distribute it,
  9130. # with or without modifications, as long as this notice is preserved.
  9131. # AM_PROG_INSTALL_STRIP
  9132. # ---------------------
  9133. # One issue with vendor 'install' (even GNU) is that you can't
  9134. # specify the program used to strip binaries. This is especially
  9135. # annoying in cross-compiling environments, where the build's strip
  9136. # is unlikely to handle the host's binaries.
  9137. # Fortunately install-sh will honor a STRIPPROG variable, so we
  9138. # always use install-sh in "make install-strip", and initialize
  9139. # STRIPPROG with the value of the STRIP variable (set by the user).
  9140. AC_DEFUN([AM_PROG_INSTALL_STRIP],
  9141. [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
  9142. # Installed binaries are usually stripped using 'strip' when the user
  9143. # run "make install-strip". However 'strip' might not be the right
  9144. # tool to use in cross-compilation environments, therefore Automake
  9145. # will honor the 'STRIP' environment variable to overrule this program.
  9146. dnl Don't test for $cross_compiling = yes, because it might be 'maybe'.
  9147. if test "$cross_compiling" != no; then
  9148. AC_CHECK_TOOL([STRIP], [strip], :)
  9149. fi
  9150. INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
  9151. AC_SUBST([INSTALL_STRIP_PROGRAM])])
  9152. # Copyright (C) 2006-2021 Free Software Foundation, Inc.
  9153. #
  9154. # This file is free software; the Free Software Foundation
  9155. # gives unlimited permission to copy and/or distribute it,
  9156. # with or without modifications, as long as this notice is preserved.
  9157. # _AM_SUBST_NOTMAKE(VARIABLE)
  9158. # ---------------------------
  9159. # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
  9160. # This macro is traced by Automake.
  9161. AC_DEFUN([_AM_SUBST_NOTMAKE])
  9162. # AM_SUBST_NOTMAKE(VARIABLE)
  9163. # --------------------------
  9164. # Public sister of _AM_SUBST_NOTMAKE.
  9165. AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
  9166. # Check how to create a tarball. -*- Autoconf -*-
  9167. # Copyright (C) 2004-2021 Free Software Foundation, Inc.
  9168. #
  9169. # This file is free software; the Free Software Foundation
  9170. # gives unlimited permission to copy and/or distribute it,
  9171. # with or without modifications, as long as this notice is preserved.
  9172. # _AM_PROG_TAR(FORMAT)
  9173. # --------------------
  9174. # Check how to create a tarball in format FORMAT.
  9175. # FORMAT should be one of 'v7', 'ustar', or 'pax'.
  9176. #
  9177. # Substitute a variable $(am__tar) that is a command
  9178. # writing to stdout a FORMAT-tarball containing the directory
  9179. # $tardir.
  9180. # tardir=directory && $(am__tar) > result.tar
  9181. #
  9182. # Substitute a variable $(am__untar) that extract such
  9183. # a tarball read from stdin.
  9184. # $(am__untar) < result.tar
  9185. #
  9186. AC_DEFUN([_AM_PROG_TAR],
  9187. [# Always define AMTAR for backward compatibility. Yes, it's still used
  9188. # in the wild :-( We should find a proper way to deprecate it ...
  9189. AC_SUBST([AMTAR], ['$${TAR-tar}'])
  9190. # We'll loop over all known methods to create a tar archive until one works.
  9191. _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
  9192. m4_if([$1], [v7],
  9193. [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
  9194. [m4_case([$1],
  9195. [ustar],
  9196. [# The POSIX 1988 'ustar' format is defined with fixed-size fields.
  9197. # There is notably a 21 bits limit for the UID and the GID. In fact,
  9198. # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343
  9199. # and bug#13588).
  9200. am_max_uid=2097151 # 2^21 - 1
  9201. am_max_gid=$am_max_uid
  9202. # The $UID and $GID variables are not portable, so we need to resort
  9203. # to the POSIX-mandated id(1) utility. Errors in the 'id' calls
  9204. # below are definitely unexpected, so allow the users to see them
  9205. # (that is, avoid stderr redirection).
  9206. am_uid=`id -u || echo unknown`
  9207. am_gid=`id -g || echo unknown`
  9208. AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format])
  9209. if test $am_uid -le $am_max_uid; then
  9210. AC_MSG_RESULT([yes])
  9211. else
  9212. AC_MSG_RESULT([no])
  9213. _am_tools=none
  9214. fi
  9215. AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format])
  9216. if test $am_gid -le $am_max_gid; then
  9217. AC_MSG_RESULT([yes])
  9218. else
  9219. AC_MSG_RESULT([no])
  9220. _am_tools=none
  9221. fi],
  9222. [pax],
  9223. [],
  9224. [m4_fatal([Unknown tar format])])
  9225. AC_MSG_CHECKING([how to create a $1 tar archive])
  9226. # Go ahead even if we have the value already cached. We do so because we
  9227. # need to set the values for the 'am__tar' and 'am__untar' variables.
  9228. _am_tools=${am_cv_prog_tar_$1-$_am_tools}
  9229. for _am_tool in $_am_tools; do
  9230. case $_am_tool in
  9231. gnutar)
  9232. for _am_tar in tar gnutar gtar; do
  9233. AM_RUN_LOG([$_am_tar --version]) && break
  9234. done
  9235. am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
  9236. am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
  9237. am__untar="$_am_tar -xf -"
  9238. ;;
  9239. plaintar)
  9240. # Must skip GNU tar: if it does not support --format= it doesn't create
  9241. # ustar tarball either.
  9242. (tar --version) >/dev/null 2>&1 && continue
  9243. am__tar='tar chf - "$$tardir"'
  9244. am__tar_='tar chf - "$tardir"'
  9245. am__untar='tar xf -'
  9246. ;;
  9247. pax)
  9248. am__tar='pax -L -x $1 -w "$$tardir"'
  9249. am__tar_='pax -L -x $1 -w "$tardir"'
  9250. am__untar='pax -r'
  9251. ;;
  9252. cpio)
  9253. am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
  9254. am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
  9255. am__untar='cpio -i -H $1 -d'
  9256. ;;
  9257. none)
  9258. am__tar=false
  9259. am__tar_=false
  9260. am__untar=false
  9261. ;;
  9262. esac
  9263. # If the value was cached, stop now. We just wanted to have am__tar
  9264. # and am__untar set.
  9265. test -n "${am_cv_prog_tar_$1}" && break
  9266. # tar/untar a dummy directory, and stop if the command works.
  9267. rm -rf conftest.dir
  9268. mkdir conftest.dir
  9269. echo GrepMe > conftest.dir/file
  9270. AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
  9271. rm -rf conftest.dir
  9272. if test -s conftest.tar; then
  9273. AM_RUN_LOG([$am__untar <conftest.tar])
  9274. AM_RUN_LOG([cat conftest.dir/file])
  9275. grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
  9276. fi
  9277. done
  9278. rm -rf conftest.dir
  9279. AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
  9280. AC_MSG_RESULT([$am_cv_prog_tar_$1])])
  9281. AC_SUBST([am__tar])
  9282. AC_SUBST([am__untar])
  9283. ]) # _AM_PROG_TAR