aclocal.m4 260 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428
  1. # generated automatically by aclocal 1.10 -*- Autoconf -*-
  2. # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
  3. # 2005, 2006 Free Software Foundation, Inc.
  4. # This file is free software; the Free Software Foundation
  5. # gives unlimited permission to copy and/or distribute it,
  6. # with or without modifications, as long as this notice is preserved.
  7. # This program is distributed in the hope that it will be useful,
  8. # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
  9. # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
  10. # PARTICULAR PURPOSE.
  11. m4_if(m4_PACKAGE_VERSION, [2.61],,
  12. [m4_fatal([this file was generated for autoconf 2.61.
  13. You have another version of autoconf. If you want to use that,
  14. you should regenerate the build system entirely.], [63])])
  15. # Copyright (C) 2002, 2003, 2005, 2006 Free Software Foundation, Inc.
  16. #
  17. # This file is free software; the Free Software Foundation
  18. # gives unlimited permission to copy and/or distribute it,
  19. # with or without modifications, as long as this notice is preserved.
  20. # AM_AUTOMAKE_VERSION(VERSION)
  21. # ----------------------------
  22. # Automake X.Y traces this macro to ensure aclocal.m4 has been
  23. # generated from the m4 files accompanying Automake X.Y.
  24. # (This private macro should not be called outside this file.)
  25. AC_DEFUN([AM_AUTOMAKE_VERSION],
  26. [am__api_version='1.10'
  27. dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
  28. dnl require some minimum version. Point them to the right macro.
  29. m4_if([$1], [1.10], [],
  30. [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
  31. ])
  32. # _AM_AUTOCONF_VERSION(VERSION)
  33. # -----------------------------
  34. # aclocal traces this macro to find the Autoconf version.
  35. # This is a private macro too. Using m4_define simplifies
  36. # the logic in aclocal, which can simply ignore this definition.
  37. m4_define([_AM_AUTOCONF_VERSION], [])
  38. # AM_SET_CURRENT_AUTOMAKE_VERSION
  39. # -------------------------------
  40. # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
  41. # This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
  42. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
  43. [AM_AUTOMAKE_VERSION([1.10])dnl
  44. _AM_AUTOCONF_VERSION(m4_PACKAGE_VERSION)])
  45. # AM_AUX_DIR_EXPAND -*- Autoconf -*-
  46. # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
  47. #
  48. # This file is free software; the Free Software Foundation
  49. # gives unlimited permission to copy and/or distribute it,
  50. # with or without modifications, as long as this notice is preserved.
  51. # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
  52. # $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
  53. # `$srcdir', `$srcdir/..', or `$srcdir/../..'.
  54. #
  55. # Of course, Automake must honor this variable whenever it calls a
  56. # tool from the auxiliary directory. The problem is that $srcdir (and
  57. # therefore $ac_aux_dir as well) can be either absolute or relative,
  58. # depending on how configure is run. This is pretty annoying, since
  59. # it makes $ac_aux_dir quite unusable in subdirectories: in the top
  60. # source directory, any form will work fine, but in subdirectories a
  61. # relative path needs to be adjusted first.
  62. #
  63. # $ac_aux_dir/missing
  64. # fails when called from a subdirectory if $ac_aux_dir is relative
  65. # $top_srcdir/$ac_aux_dir/missing
  66. # fails if $ac_aux_dir is absolute,
  67. # fails when called from a subdirectory in a VPATH build with
  68. # a relative $ac_aux_dir
  69. #
  70. # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
  71. # are both prefixed by $srcdir. In an in-source build this is usually
  72. # harmless because $srcdir is `.', but things will broke when you
  73. # start a VPATH build or use an absolute $srcdir.
  74. #
  75. # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
  76. # iff we strip the leading $srcdir from $ac_aux_dir. That would be:
  77. # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
  78. # and then we would define $MISSING as
  79. # MISSING="\${SHELL} $am_aux_dir/missing"
  80. # This will work as long as MISSING is not called from configure, because
  81. # unfortunately $(top_srcdir) has no meaning in configure.
  82. # However there are other variables, like CC, which are often used in
  83. # configure, and could therefore not use this "fixed" $ac_aux_dir.
  84. #
  85. # Another solution, used here, is to always expand $ac_aux_dir to an
  86. # absolute PATH. The drawback is that using absolute paths prevent a
  87. # configured tree to be moved without reconfiguration.
  88. AC_DEFUN([AM_AUX_DIR_EXPAND],
  89. [dnl Rely on autoconf to set up CDPATH properly.
  90. AC_PREREQ([2.50])dnl
  91. # expand $ac_aux_dir to an absolute path
  92. am_aux_dir=`cd $ac_aux_dir && pwd`
  93. ])
  94. # AM_CONDITIONAL -*- Autoconf -*-
  95. # Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006
  96. # Free Software Foundation, Inc.
  97. #
  98. # This file is free software; the Free Software Foundation
  99. # gives unlimited permission to copy and/or distribute it,
  100. # with or without modifications, as long as this notice is preserved.
  101. # serial 8
  102. # AM_CONDITIONAL(NAME, SHELL-CONDITION)
  103. # -------------------------------------
  104. # Define a conditional.
  105. AC_DEFUN([AM_CONDITIONAL],
  106. [AC_PREREQ(2.52)dnl
  107. ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
  108. [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
  109. AC_SUBST([$1_TRUE])dnl
  110. AC_SUBST([$1_FALSE])dnl
  111. _AM_SUBST_NOTMAKE([$1_TRUE])dnl
  112. _AM_SUBST_NOTMAKE([$1_FALSE])dnl
  113. if $2; then
  114. $1_TRUE=
  115. $1_FALSE='#'
  116. else
  117. $1_TRUE='#'
  118. $1_FALSE=
  119. fi
  120. AC_CONFIG_COMMANDS_PRE(
  121. [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
  122. AC_MSG_ERROR([[conditional "$1" was never defined.
  123. Usually this means the macro was only invoked conditionally.]])
  124. fi])])
  125. # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
  126. # Free Software Foundation, Inc.
  127. #
  128. # This file is free software; the Free Software Foundation
  129. # gives unlimited permission to copy and/or distribute it,
  130. # with or without modifications, as long as this notice is preserved.
  131. # serial 9
  132. # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
  133. # written in clear, in which case automake, when reading aclocal.m4,
  134. # will think it sees a *use*, and therefore will trigger all it's
  135. # C support machinery. Also note that it means that autoscan, seeing
  136. # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
  137. # _AM_DEPENDENCIES(NAME)
  138. # ----------------------
  139. # See how the compiler implements dependency checking.
  140. # NAME is "CC", "CXX", "GCJ", or "OBJC".
  141. # We try a few techniques and use that to set a single cache variable.
  142. #
  143. # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
  144. # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
  145. # dependency, and given that the user is not expected to run this macro,
  146. # just rely on AC_PROG_CC.
  147. AC_DEFUN([_AM_DEPENDENCIES],
  148. [AC_REQUIRE([AM_SET_DEPDIR])dnl
  149. AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
  150. AC_REQUIRE([AM_MAKE_INCLUDE])dnl
  151. AC_REQUIRE([AM_DEP_TRACK])dnl
  152. ifelse([$1], CC, [depcc="$CC" am_compiler_list=],
  153. [$1], CXX, [depcc="$CXX" am_compiler_list=],
  154. [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
  155. [$1], UPC, [depcc="$UPC" am_compiler_list=],
  156. [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
  157. [depcc="$$1" am_compiler_list=])
  158. AC_CACHE_CHECK([dependency style of $depcc],
  159. [am_cv_$1_dependencies_compiler_type],
  160. [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
  161. # We make a subdir and do the tests there. Otherwise we can end up
  162. # making bogus files that we don't know about and never remove. For
  163. # instance it was reported that on HP-UX the gcc test will end up
  164. # making a dummy file named `D' -- because `-MD' means `put the output
  165. # in D'.
  166. mkdir conftest.dir
  167. # Copy depcomp to subdir because otherwise we won't find it if we're
  168. # using a relative directory.
  169. cp "$am_depcomp" conftest.dir
  170. cd conftest.dir
  171. # We will build objects and dependencies in a subdirectory because
  172. # it helps to detect inapplicable dependency modes. For instance
  173. # both Tru64's cc and ICC support -MD to output dependencies as a
  174. # side effect of compilation, but ICC will put the dependencies in
  175. # the current directory while Tru64 will put them in the object
  176. # directory.
  177. mkdir sub
  178. am_cv_$1_dependencies_compiler_type=none
  179. if test "$am_compiler_list" = ""; then
  180. am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
  181. fi
  182. for depmode in $am_compiler_list; do
  183. # Setup a source with many dependencies, because some compilers
  184. # like to wrap large dependency lists on column 80 (with \), and
  185. # we should not choose a depcomp mode which is confused by this.
  186. #
  187. # We need to recreate these files for each test, as the compiler may
  188. # overwrite some of them when testing with obscure command lines.
  189. # This happens at least with the AIX C compiler.
  190. : > sub/conftest.c
  191. for i in 1 2 3 4 5 6; do
  192. echo '#include "conftst'$i'.h"' >> sub/conftest.c
  193. # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
  194. # Solaris 8's {/usr,}/bin/sh.
  195. touch sub/conftst$i.h
  196. done
  197. echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
  198. case $depmode in
  199. nosideeffect)
  200. # after this tag, mechanisms are not by side-effect, so they'll
  201. # only be used when explicitly requested
  202. if test "x$enable_dependency_tracking" = xyes; then
  203. continue
  204. else
  205. break
  206. fi
  207. ;;
  208. none) break ;;
  209. esac
  210. # We check with `-c' and `-o' for the sake of the "dashmstdout"
  211. # mode. It turns out that the SunPro C++ compiler does not properly
  212. # handle `-M -o', and we need to detect this.
  213. if depmode=$depmode \
  214. source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
  215. depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
  216. $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
  217. >/dev/null 2>conftest.err &&
  218. grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
  219. grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
  220. grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
  221. ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
  222. # icc doesn't choke on unknown options, it will just issue warnings
  223. # or remarks (even with -Werror). So we grep stderr for any message
  224. # that says an option was ignored or not supported.
  225. # When given -MP, icc 7.0 and 7.1 complain thusly:
  226. # icc: Command line warning: ignoring option '-M'; no argument required
  227. # The diagnosis changed in icc 8.0:
  228. # icc: Command line remark: option '-MP' not supported
  229. if (grep 'ignoring option' conftest.err ||
  230. grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
  231. am_cv_$1_dependencies_compiler_type=$depmode
  232. break
  233. fi
  234. fi
  235. done
  236. cd ..
  237. rm -rf conftest.dir
  238. else
  239. am_cv_$1_dependencies_compiler_type=none
  240. fi
  241. ])
  242. AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
  243. AM_CONDITIONAL([am__fastdep$1], [
  244. test "x$enable_dependency_tracking" != xno \
  245. && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
  246. ])
  247. # AM_SET_DEPDIR
  248. # -------------
  249. # Choose a directory name for dependency files.
  250. # This macro is AC_REQUIREd in _AM_DEPENDENCIES
  251. AC_DEFUN([AM_SET_DEPDIR],
  252. [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
  253. AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
  254. ])
  255. # AM_DEP_TRACK
  256. # ------------
  257. AC_DEFUN([AM_DEP_TRACK],
  258. [AC_ARG_ENABLE(dependency-tracking,
  259. [ --disable-dependency-tracking speeds up one-time build
  260. --enable-dependency-tracking do not reject slow dependency extractors])
  261. if test "x$enable_dependency_tracking" != xno; then
  262. am_depcomp="$ac_aux_dir/depcomp"
  263. AMDEPBACKSLASH='\'
  264. fi
  265. AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
  266. AC_SUBST([AMDEPBACKSLASH])dnl
  267. _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
  268. ])
  269. # Generate code to set up dependency tracking. -*- Autoconf -*-
  270. # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005
  271. # Free Software Foundation, Inc.
  272. #
  273. # This file is free software; the Free Software Foundation
  274. # gives unlimited permission to copy and/or distribute it,
  275. # with or without modifications, as long as this notice is preserved.
  276. #serial 3
  277. # _AM_OUTPUT_DEPENDENCY_COMMANDS
  278. # ------------------------------
  279. AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
  280. [for mf in $CONFIG_FILES; do
  281. # Strip MF so we end up with the name of the file.
  282. mf=`echo "$mf" | sed -e 's/:.*$//'`
  283. # Check whether this is an Automake generated Makefile or not.
  284. # We used to match only the files named `Makefile.in', but
  285. # some people rename them; so instead we look at the file content.
  286. # Grep'ing the first line is not enough: some people post-process
  287. # each Makefile.in and add a new line on top of each file to say so.
  288. # Grep'ing the whole file is not good either: AIX grep has a line
  289. # limit of 2048, but all sed's we know have understand at least 4000.
  290. if sed 10q "$mf" | grep '^#.*generated by automake' > /dev/null 2>&1; then
  291. dirpart=`AS_DIRNAME("$mf")`
  292. else
  293. continue
  294. fi
  295. # Extract the definition of DEPDIR, am__include, and am__quote
  296. # from the Makefile without running `make'.
  297. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
  298. test -z "$DEPDIR" && continue
  299. am__include=`sed -n 's/^am__include = //p' < "$mf"`
  300. test -z "am__include" && continue
  301. am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
  302. # When using ansi2knr, U may be empty or an underscore; expand it
  303. U=`sed -n 's/^U = //p' < "$mf"`
  304. # Find all dependency output files, they are included files with
  305. # $(DEPDIR) in their names. We invoke sed twice because it is the
  306. # simplest approach to changing $(DEPDIR) to its actual value in the
  307. # expansion.
  308. for file in `sed -n "
  309. s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
  310. sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
  311. # Make sure the directory exists.
  312. test -f "$dirpart/$file" && continue
  313. fdir=`AS_DIRNAME(["$file"])`
  314. AS_MKDIR_P([$dirpart/$fdir])
  315. # echo "creating $dirpart/$file"
  316. echo '# dummy' > "$dirpart/$file"
  317. done
  318. done
  319. ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
  320. # AM_OUTPUT_DEPENDENCY_COMMANDS
  321. # -----------------------------
  322. # This macro should only be invoked once -- use via AC_REQUIRE.
  323. #
  324. # This code is only required when automatic dependency tracking
  325. # is enabled. FIXME. This creates each `.P' file that we will
  326. # need in order to bootstrap the dependency handling code.
  327. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
  328. [AC_CONFIG_COMMANDS([depfiles],
  329. [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
  330. [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
  331. ])
  332. # Do all the work for Automake. -*- Autoconf -*-
  333. # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
  334. # 2005, 2006 Free Software Foundation, Inc.
  335. #
  336. # This file is free software; the Free Software Foundation
  337. # gives unlimited permission to copy and/or distribute it,
  338. # with or without modifications, as long as this notice is preserved.
  339. # serial 12
  340. # This macro actually does too much. Some checks are only needed if
  341. # your package does certain things. But this isn't really a big deal.
  342. # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
  343. # AM_INIT_AUTOMAKE([OPTIONS])
  344. # -----------------------------------------------
  345. # The call with PACKAGE and VERSION arguments is the old style
  346. # call (pre autoconf-2.50), which is being phased out. PACKAGE
  347. # and VERSION should now be passed to AC_INIT and removed from
  348. # the call to AM_INIT_AUTOMAKE.
  349. # We support both call styles for the transition. After
  350. # the next Automake release, Autoconf can make the AC_INIT
  351. # arguments mandatory, and then we can depend on a new Autoconf
  352. # release and drop the old call support.
  353. AC_DEFUN([AM_INIT_AUTOMAKE],
  354. [AC_PREREQ([2.60])dnl
  355. dnl Autoconf wants to disallow AM_ names. We explicitly allow
  356. dnl the ones we care about.
  357. m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
  358. AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
  359. AC_REQUIRE([AC_PROG_INSTALL])dnl
  360. if test "`cd $srcdir && pwd`" != "`pwd`"; then
  361. # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
  362. # is not polluted with repeated "-I."
  363. AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
  364. # test to see if srcdir already configured
  365. if test -f $srcdir/config.status; then
  366. AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
  367. fi
  368. fi
  369. # test whether we have cygpath
  370. if test -z "$CYGPATH_W"; then
  371. if (cygpath --version) >/dev/null 2>/dev/null; then
  372. CYGPATH_W='cygpath -w'
  373. else
  374. CYGPATH_W=echo
  375. fi
  376. fi
  377. AC_SUBST([CYGPATH_W])
  378. # Define the identity of the package.
  379. dnl Distinguish between old-style and new-style calls.
  380. m4_ifval([$2],
  381. [m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
  382. AC_SUBST([PACKAGE], [$1])dnl
  383. AC_SUBST([VERSION], [$2])],
  384. [_AM_SET_OPTIONS([$1])dnl
  385. dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
  386. m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,,
  387. [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
  388. AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
  389. AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
  390. _AM_IF_OPTION([no-define],,
  391. [AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
  392. AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
  393. # Some tools Automake needs.
  394. AC_REQUIRE([AM_SANITY_CHECK])dnl
  395. AC_REQUIRE([AC_ARG_PROGRAM])dnl
  396. AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
  397. AM_MISSING_PROG(AUTOCONF, autoconf)
  398. AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
  399. AM_MISSING_PROG(AUTOHEADER, autoheader)
  400. AM_MISSING_PROG(MAKEINFO, makeinfo)
  401. AM_PROG_INSTALL_SH
  402. AM_PROG_INSTALL_STRIP
  403. AC_REQUIRE([AM_PROG_MKDIR_P])dnl
  404. # We need awk for the "check" target. The system "awk" is bad on
  405. # some platforms.
  406. AC_REQUIRE([AC_PROG_AWK])dnl
  407. AC_REQUIRE([AC_PROG_MAKE_SET])dnl
  408. AC_REQUIRE([AM_SET_LEADING_DOT])dnl
  409. _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
  410. [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
  411. [_AM_PROG_TAR([v7])])])
  412. _AM_IF_OPTION([no-dependencies],,
  413. [AC_PROVIDE_IFELSE([AC_PROG_CC],
  414. [_AM_DEPENDENCIES(CC)],
  415. [define([AC_PROG_CC],
  416. defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
  417. AC_PROVIDE_IFELSE([AC_PROG_CXX],
  418. [_AM_DEPENDENCIES(CXX)],
  419. [define([AC_PROG_CXX],
  420. defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
  421. AC_PROVIDE_IFELSE([AC_PROG_OBJC],
  422. [_AM_DEPENDENCIES(OBJC)],
  423. [define([AC_PROG_OBJC],
  424. defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
  425. ])
  426. ])
  427. # When config.status generates a header, we must update the stamp-h file.
  428. # This file resides in the same directory as the config header
  429. # that is generated. The stamp files are numbered to have different names.
  430. # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
  431. # loop where config.status creates the headers, so we can generate
  432. # our stamp files there.
  433. AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
  434. [# Compute $1's index in $config_headers.
  435. _am_stamp_count=1
  436. for _am_header in $config_headers :; do
  437. case $_am_header in
  438. $1 | $1:* )
  439. break ;;
  440. * )
  441. _am_stamp_count=`expr $_am_stamp_count + 1` ;;
  442. esac
  443. done
  444. echo "timestamp for $1" >`AS_DIRNAME([$1])`/stamp-h[]$_am_stamp_count])
  445. # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
  446. #
  447. # This file is free software; the Free Software Foundation
  448. # gives unlimited permission to copy and/or distribute it,
  449. # with or without modifications, as long as this notice is preserved.
  450. # AM_PROG_INSTALL_SH
  451. # ------------------
  452. # Define $install_sh.
  453. AC_DEFUN([AM_PROG_INSTALL_SH],
  454. [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
  455. install_sh=${install_sh-"\$(SHELL) $am_aux_dir/install-sh"}
  456. AC_SUBST(install_sh)])
  457. # Copyright (C) 2003, 2005 Free Software Foundation, Inc.
  458. #
  459. # This file is free software; the Free Software Foundation
  460. # gives unlimited permission to copy and/or distribute it,
  461. # with or without modifications, as long as this notice is preserved.
  462. # serial 2
  463. # Check whether the underlying file-system supports filenames
  464. # with a leading dot. For instance MS-DOS doesn't.
  465. AC_DEFUN([AM_SET_LEADING_DOT],
  466. [rm -rf .tst 2>/dev/null
  467. mkdir .tst 2>/dev/null
  468. if test -d .tst; then
  469. am__leading_dot=.
  470. else
  471. am__leading_dot=_
  472. fi
  473. rmdir .tst 2>/dev/null
  474. AC_SUBST([am__leading_dot])])
  475. # Check to see how 'make' treats includes. -*- Autoconf -*-
  476. # Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc.
  477. #
  478. # This file is free software; the Free Software Foundation
  479. # gives unlimited permission to copy and/or distribute it,
  480. # with or without modifications, as long as this notice is preserved.
  481. # serial 3
  482. # AM_MAKE_INCLUDE()
  483. # -----------------
  484. # Check to see how make treats includes.
  485. AC_DEFUN([AM_MAKE_INCLUDE],
  486. [am_make=${MAKE-make}
  487. cat > confinc << 'END'
  488. am__doit:
  489. @echo done
  490. .PHONY: am__doit
  491. END
  492. # If we don't find an include directive, just comment out the code.
  493. AC_MSG_CHECKING([for style of include used by $am_make])
  494. am__include="#"
  495. am__quote=
  496. _am_result=none
  497. # First try GNU make style include.
  498. echo "include confinc" > confmf
  499. # We grep out `Entering directory' and `Leaving directory'
  500. # messages which can occur if `w' ends up in MAKEFLAGS.
  501. # In particular we don't look at `^make:' because GNU make might
  502. # be invoked under some other name (usually "gmake"), in which
  503. # case it prints its new name instead of `make'.
  504. if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
  505. am__include=include
  506. am__quote=
  507. _am_result=GNU
  508. fi
  509. # Now try BSD make style include.
  510. if test "$am__include" = "#"; then
  511. echo '.include "confinc"' > confmf
  512. if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
  513. am__include=.include
  514. am__quote="\""
  515. _am_result=BSD
  516. fi
  517. fi
  518. AC_SUBST([am__include])
  519. AC_SUBST([am__quote])
  520. AC_MSG_RESULT([$_am_result])
  521. rm -f confinc confmf
  522. ])
  523. # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
  524. # Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005
  525. # Free Software Foundation, Inc.
  526. #
  527. # This file is free software; the Free Software Foundation
  528. # gives unlimited permission to copy and/or distribute it,
  529. # with or without modifications, as long as this notice is preserved.
  530. # serial 5
  531. # AM_MISSING_PROG(NAME, PROGRAM)
  532. # ------------------------------
  533. AC_DEFUN([AM_MISSING_PROG],
  534. [AC_REQUIRE([AM_MISSING_HAS_RUN])
  535. $1=${$1-"${am_missing_run}$2"}
  536. AC_SUBST($1)])
  537. # AM_MISSING_HAS_RUN
  538. # ------------------
  539. # Define MISSING if not defined so far and test if it supports --run.
  540. # If it does, set am_missing_run to use it, otherwise, to nothing.
  541. AC_DEFUN([AM_MISSING_HAS_RUN],
  542. [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
  543. AC_REQUIRE_AUX_FILE([missing])dnl
  544. test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
  545. # Use eval to expand $SHELL
  546. if eval "$MISSING --run true"; then
  547. am_missing_run="$MISSING --run "
  548. else
  549. am_missing_run=
  550. AC_MSG_WARN([`missing' script is too old or missing])
  551. fi
  552. ])
  553. # Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
  554. #
  555. # This file is free software; the Free Software Foundation
  556. # gives unlimited permission to copy and/or distribute it,
  557. # with or without modifications, as long as this notice is preserved.
  558. # AM_PROG_MKDIR_P
  559. # ---------------
  560. # Check for `mkdir -p'.
  561. AC_DEFUN([AM_PROG_MKDIR_P],
  562. [AC_PREREQ([2.60])dnl
  563. AC_REQUIRE([AC_PROG_MKDIR_P])dnl
  564. dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P,
  565. dnl while keeping a definition of mkdir_p for backward compatibility.
  566. dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile.
  567. dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of
  568. dnl Makefile.ins that do not define MKDIR_P, so we do our own
  569. dnl adjustment using top_builddir (which is defined more often than
  570. dnl MKDIR_P).
  571. AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl
  572. case $mkdir_p in
  573. [[\\/$]]* | ?:[[\\/]]*) ;;
  574. */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
  575. esac
  576. ])
  577. # Helper functions for option handling. -*- Autoconf -*-
  578. # Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc.
  579. #
  580. # This file is free software; the Free Software Foundation
  581. # gives unlimited permission to copy and/or distribute it,
  582. # with or without modifications, as long as this notice is preserved.
  583. # serial 3
  584. # _AM_MANGLE_OPTION(NAME)
  585. # -----------------------
  586. AC_DEFUN([_AM_MANGLE_OPTION],
  587. [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
  588. # _AM_SET_OPTION(NAME)
  589. # ------------------------------
  590. # Set option NAME. Presently that only means defining a flag for this option.
  591. AC_DEFUN([_AM_SET_OPTION],
  592. [m4_define(_AM_MANGLE_OPTION([$1]), 1)])
  593. # _AM_SET_OPTIONS(OPTIONS)
  594. # ----------------------------------
  595. # OPTIONS is a space-separated list of Automake options.
  596. AC_DEFUN([_AM_SET_OPTIONS],
  597. [AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
  598. # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
  599. # -------------------------------------------
  600. # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
  601. AC_DEFUN([_AM_IF_OPTION],
  602. [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
  603. # Check to make sure that the build environment is sane. -*- Autoconf -*-
  604. # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005
  605. # Free Software Foundation, Inc.
  606. #
  607. # This file is free software; the Free Software Foundation
  608. # gives unlimited permission to copy and/or distribute it,
  609. # with or without modifications, as long as this notice is preserved.
  610. # serial 4
  611. # AM_SANITY_CHECK
  612. # ---------------
  613. AC_DEFUN([AM_SANITY_CHECK],
  614. [AC_MSG_CHECKING([whether build environment is sane])
  615. # Just in case
  616. sleep 1
  617. echo timestamp > conftest.file
  618. # Do `set' in a subshell so we don't clobber the current shell's
  619. # arguments. Must try -L first in case configure is actually a
  620. # symlink; some systems play weird games with the mod time of symlinks
  621. # (eg FreeBSD returns the mod time of the symlink's containing
  622. # directory).
  623. if (
  624. set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
  625. if test "$[*]" = "X"; then
  626. # -L didn't work.
  627. set X `ls -t $srcdir/configure conftest.file`
  628. fi
  629. rm -f conftest.file
  630. if test "$[*]" != "X $srcdir/configure conftest.file" \
  631. && test "$[*]" != "X conftest.file $srcdir/configure"; then
  632. # If neither matched, then we have a broken ls. This can happen
  633. # if, for instance, CONFIG_SHELL is bash and it inherits a
  634. # broken ls alias from the environment. This has actually
  635. # happened. Such a system could not be considered "sane".
  636. AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
  637. alias in your environment])
  638. fi
  639. test "$[2]" = conftest.file
  640. )
  641. then
  642. # Ok.
  643. :
  644. else
  645. AC_MSG_ERROR([newly created file is older than distributed files!
  646. Check your system clock])
  647. fi
  648. AC_MSG_RESULT(yes)])
  649. # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
  650. #
  651. # This file is free software; the Free Software Foundation
  652. # gives unlimited permission to copy and/or distribute it,
  653. # with or without modifications, as long as this notice is preserved.
  654. # AM_PROG_INSTALL_STRIP
  655. # ---------------------
  656. # One issue with vendor `install' (even GNU) is that you can't
  657. # specify the program used to strip binaries. This is especially
  658. # annoying in cross-compiling environments, where the build's strip
  659. # is unlikely to handle the host's binaries.
  660. # Fortunately install-sh will honor a STRIPPROG variable, so we
  661. # always use install-sh in `make install-strip', and initialize
  662. # STRIPPROG with the value of the STRIP variable (set by the user).
  663. AC_DEFUN([AM_PROG_INSTALL_STRIP],
  664. [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
  665. # Installed binaries are usually stripped using `strip' when the user
  666. # run `make install-strip'. However `strip' might not be the right
  667. # tool to use in cross-compilation environments, therefore Automake
  668. # will honor the `STRIP' environment variable to overrule this program.
  669. dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
  670. if test "$cross_compiling" != no; then
  671. AC_CHECK_TOOL([STRIP], [strip], :)
  672. fi
  673. INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
  674. AC_SUBST([INSTALL_STRIP_PROGRAM])])
  675. # Copyright (C) 2006 Free Software Foundation, Inc.
  676. #
  677. # This file is free software; the Free Software Foundation
  678. # gives unlimited permission to copy and/or distribute it,
  679. # with or without modifications, as long as this notice is preserved.
  680. # _AM_SUBST_NOTMAKE(VARIABLE)
  681. # ---------------------------
  682. # Prevent Automake from outputing VARIABLE = @VARIABLE@ in Makefile.in.
  683. # This macro is traced by Automake.
  684. AC_DEFUN([_AM_SUBST_NOTMAKE])
  685. # Check how to create a tarball. -*- Autoconf -*-
  686. # Copyright (C) 2004, 2005 Free Software Foundation, Inc.
  687. #
  688. # This file is free software; the Free Software Foundation
  689. # gives unlimited permission to copy and/or distribute it,
  690. # with or without modifications, as long as this notice is preserved.
  691. # serial 2
  692. # _AM_PROG_TAR(FORMAT)
  693. # --------------------
  694. # Check how to create a tarball in format FORMAT.
  695. # FORMAT should be one of `v7', `ustar', or `pax'.
  696. #
  697. # Substitute a variable $(am__tar) that is a command
  698. # writing to stdout a FORMAT-tarball containing the directory
  699. # $tardir.
  700. # tardir=directory && $(am__tar) > result.tar
  701. #
  702. # Substitute a variable $(am__untar) that extract such
  703. # a tarball read from stdin.
  704. # $(am__untar) < result.tar
  705. AC_DEFUN([_AM_PROG_TAR],
  706. [# Always define AMTAR for backward compatibility.
  707. AM_MISSING_PROG([AMTAR], [tar])
  708. m4_if([$1], [v7],
  709. [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'],
  710. [m4_case([$1], [ustar],, [pax],,
  711. [m4_fatal([Unknown tar format])])
  712. AC_MSG_CHECKING([how to create a $1 tar archive])
  713. # Loop over all known methods to create a tar archive until one works.
  714. _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
  715. _am_tools=${am_cv_prog_tar_$1-$_am_tools}
  716. # Do not fold the above two line into one, because Tru64 sh and
  717. # Solaris sh will not grok spaces in the rhs of `-'.
  718. for _am_tool in $_am_tools
  719. do
  720. case $_am_tool in
  721. gnutar)
  722. for _am_tar in tar gnutar gtar;
  723. do
  724. AM_RUN_LOG([$_am_tar --version]) && break
  725. done
  726. am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
  727. am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
  728. am__untar="$_am_tar -xf -"
  729. ;;
  730. plaintar)
  731. # Must skip GNU tar: if it does not support --format= it doesn't create
  732. # ustar tarball either.
  733. (tar --version) >/dev/null 2>&1 && continue
  734. am__tar='tar chf - "$$tardir"'
  735. am__tar_='tar chf - "$tardir"'
  736. am__untar='tar xf -'
  737. ;;
  738. pax)
  739. am__tar='pax -L -x $1 -w "$$tardir"'
  740. am__tar_='pax -L -x $1 -w "$tardir"'
  741. am__untar='pax -r'
  742. ;;
  743. cpio)
  744. am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
  745. am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
  746. am__untar='cpio -i -H $1 -d'
  747. ;;
  748. none)
  749. am__tar=false
  750. am__tar_=false
  751. am__untar=false
  752. ;;
  753. esac
  754. # If the value was cached, stop now. We just wanted to have am__tar
  755. # and am__untar set.
  756. test -n "${am_cv_prog_tar_$1}" && break
  757. # tar/untar a dummy directory, and stop if the command works
  758. rm -rf conftest.dir
  759. mkdir conftest.dir
  760. echo GrepMe > conftest.dir/file
  761. AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
  762. rm -rf conftest.dir
  763. if test -s conftest.tar; then
  764. AM_RUN_LOG([$am__untar <conftest.tar])
  765. grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
  766. fi
  767. done
  768. rm -rf conftest.dir
  769. AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
  770. AC_MSG_RESULT([$am_cv_prog_tar_$1])])
  771. AC_SUBST([am__tar])
  772. AC_SUBST([am__untar])
  773. ]) # _AM_PROG_TAR
  774. # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
  775. # serial 51 AC_PROG_LIBTOOL
  776. # AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED)
  777. # -----------------------------------------------------------
  778. # If this macro is not defined by Autoconf, define it here.
  779. m4_ifdef([AC_PROVIDE_IFELSE],
  780. [],
  781. [m4_define([AC_PROVIDE_IFELSE],
  782. [m4_ifdef([AC_PROVIDE_$1],
  783. [$2], [$3])])])
  784. # AC_PROG_LIBTOOL
  785. # ---------------
  786. AC_DEFUN([AC_PROG_LIBTOOL],
  787. [AC_REQUIRE([_AC_PROG_LIBTOOL])dnl
  788. dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX
  789. dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX.
  790. AC_PROVIDE_IFELSE([AC_PROG_CXX],
  791. [AC_LIBTOOL_CXX],
  792. [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX
  793. ])])
  794. dnl And a similar setup for Fortran 77 support
  795. AC_PROVIDE_IFELSE([AC_PROG_F77],
  796. [AC_LIBTOOL_F77],
  797. [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77
  798. ])])
  799. dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly.
  800. dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run
  801. dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both.
  802. AC_PROVIDE_IFELSE([AC_PROG_GCJ],
  803. [AC_LIBTOOL_GCJ],
  804. [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
  805. [AC_LIBTOOL_GCJ],
  806. [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],
  807. [AC_LIBTOOL_GCJ],
  808. [ifdef([AC_PROG_GCJ],
  809. [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])
  810. ifdef([A][M_PROG_GCJ],
  811. [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])])
  812. ifdef([LT_AC_PROG_GCJ],
  813. [define([LT_AC_PROG_GCJ],
  814. defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])])
  815. ])])# AC_PROG_LIBTOOL
  816. # _AC_PROG_LIBTOOL
  817. # ----------------
  818. AC_DEFUN([_AC_PROG_LIBTOOL],
  819. [AC_REQUIRE([AC_LIBTOOL_SETUP])dnl
  820. AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl
  821. AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl
  822. AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl
  823. # This can be used to rebuild libtool when needed
  824. LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
  825. # Always use our own libtool.
  826. LIBTOOL='$(SHELL) $(top_builddir)/libtool'
  827. AC_SUBST(LIBTOOL)dnl
  828. # Prevent multiple expansion
  829. define([AC_PROG_LIBTOOL], [])
  830. ])# _AC_PROG_LIBTOOL
  831. # AC_LIBTOOL_SETUP
  832. # ----------------
  833. AC_DEFUN([AC_LIBTOOL_SETUP],
  834. [AC_PREREQ(2.50)dnl
  835. AC_REQUIRE([AC_ENABLE_SHARED])dnl
  836. AC_REQUIRE([AC_ENABLE_STATIC])dnl
  837. AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl
  838. AC_REQUIRE([AC_CANONICAL_HOST])dnl
  839. AC_REQUIRE([AC_CANONICAL_BUILD])dnl
  840. AC_REQUIRE([AC_PROG_CC])dnl
  841. AC_REQUIRE([AC_PROG_LD])dnl
  842. AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl
  843. AC_REQUIRE([AC_PROG_NM])dnl
  844. AC_REQUIRE([AC_PROG_LN_S])dnl
  845. AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl
  846. # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
  847. AC_REQUIRE([AC_OBJEXT])dnl
  848. AC_REQUIRE([AC_EXEEXT])dnl
  849. dnl
  850. AC_LIBTOOL_SYS_MAX_CMD_LEN
  851. AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
  852. AC_LIBTOOL_OBJDIR
  853. AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
  854. _LT_AC_PROG_ECHO_BACKSLASH
  855. case $host_os in
  856. aix3*)
  857. # AIX sometimes has problems with the GCC collect2 program. For some
  858. # reason, if we set the COLLECT_NAMES environment variable, the problems
  859. # vanish in a puff of smoke.
  860. if test "X${COLLECT_NAMES+set}" != Xset; then
  861. COLLECT_NAMES=
  862. export COLLECT_NAMES
  863. fi
  864. ;;
  865. esac
  866. # Sed substitution that helps us do robust quoting. It backslashifies
  867. # metacharacters that are still active within double-quoted strings.
  868. Xsed='sed -e 1s/^X//'
  869. [sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g']
  870. # Same as above, but do not quote variable references.
  871. [double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g']
  872. # Sed substitution to delay expansion of an escaped shell variable in a
  873. # double_quote_subst'ed string.
  874. delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
  875. # Sed substitution to avoid accidental globbing in evaled expressions
  876. no_glob_subst='s/\*/\\\*/g'
  877. # Constants:
  878. rm="rm -f"
  879. # Global variables:
  880. default_ofile=libtool
  881. can_build_shared=yes
  882. # All known linkers require a `.a' archive for static linking (except MSVC,
  883. # which needs '.lib').
  884. libext=a
  885. ltmain="$ac_aux_dir/ltmain.sh"
  886. ofile="$default_ofile"
  887. with_gnu_ld="$lt_cv_prog_gnu_ld"
  888. AC_CHECK_TOOL(AR, ar, false)
  889. AC_CHECK_TOOL(RANLIB, ranlib, :)
  890. AC_CHECK_TOOL(STRIP, strip, :)
  891. old_CC="$CC"
  892. old_CFLAGS="$CFLAGS"
  893. # Set sane defaults for various variables
  894. test -z "$AR" && AR=ar
  895. test -z "$AR_FLAGS" && AR_FLAGS=cru
  896. test -z "$AS" && AS=as
  897. test -z "$CC" && CC=cc
  898. test -z "$LTCC" && LTCC=$CC
  899. test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
  900. test -z "$DLLTOOL" && DLLTOOL=dlltool
  901. test -z "$LD" && LD=ld
  902. test -z "$LN_S" && LN_S="ln -s"
  903. test -z "$MAGIC_CMD" && MAGIC_CMD=file
  904. test -z "$NM" && NM=nm
  905. test -z "$SED" && SED=sed
  906. test -z "$OBJDUMP" && OBJDUMP=objdump
  907. test -z "$RANLIB" && RANLIB=:
  908. test -z "$STRIP" && STRIP=:
  909. test -z "$ac_objext" && ac_objext=o
  910. # Determine commands to create old-style static archives.
  911. old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
  912. old_postinstall_cmds='chmod 644 $oldlib'
  913. old_postuninstall_cmds=
  914. if test -n "$RANLIB"; then
  915. case $host_os in
  916. openbsd*)
  917. old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
  918. ;;
  919. *)
  920. old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
  921. ;;
  922. esac
  923. old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
  924. fi
  925. _LT_CC_BASENAME([$compiler])
  926. # Only perform the check for file, if the check method requires it
  927. case $deplibs_check_method in
  928. file_magic*)
  929. if test "$file_magic_cmd" = '$MAGIC_CMD'; then
  930. AC_PATH_MAGIC
  931. fi
  932. ;;
  933. esac
  934. AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no)
  935. AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
  936. enable_win32_dll=yes, enable_win32_dll=no)
  937. AC_ARG_ENABLE([libtool-lock],
  938. [AC_HELP_STRING([--disable-libtool-lock],
  939. [avoid locking (might break parallel builds)])])
  940. test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
  941. AC_ARG_WITH([pic],
  942. [AC_HELP_STRING([--with-pic],
  943. [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
  944. [pic_mode="$withval"],
  945. [pic_mode=default])
  946. test -z "$pic_mode" && pic_mode=default
  947. # Use C for the default configuration in the libtool script
  948. tagname=
  949. AC_LIBTOOL_LANG_C_CONFIG
  950. _LT_AC_TAGCONFIG
  951. ])# AC_LIBTOOL_SETUP
  952. # _LT_AC_SYS_COMPILER
  953. # -------------------
  954. AC_DEFUN([_LT_AC_SYS_COMPILER],
  955. [AC_REQUIRE([AC_PROG_CC])dnl
  956. # If no C compiler was specified, use CC.
  957. LTCC=${LTCC-"$CC"}
  958. # If no C compiler flags were specified, use CFLAGS.
  959. LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
  960. # Allow CC to be a program name with arguments.
  961. compiler=$CC
  962. ])# _LT_AC_SYS_COMPILER
  963. # _LT_CC_BASENAME(CC)
  964. # -------------------
  965. # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
  966. AC_DEFUN([_LT_CC_BASENAME],
  967. [for cc_temp in $1""; do
  968. case $cc_temp in
  969. compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
  970. distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
  971. \-*) ;;
  972. *) break;;
  973. esac
  974. done
  975. cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
  976. ])
  977. # _LT_COMPILER_BOILERPLATE
  978. # ------------------------
  979. # Check for compiler boilerplate output or warnings with
  980. # the simple compiler test code.
  981. AC_DEFUN([_LT_COMPILER_BOILERPLATE],
  982. [AC_REQUIRE([LT_AC_PROG_SED])dnl
  983. ac_outfile=conftest.$ac_objext
  984. echo "$lt_simple_compile_test_code" >conftest.$ac_ext
  985. eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
  986. _lt_compiler_boilerplate=`cat conftest.err`
  987. $rm conftest*
  988. ])# _LT_COMPILER_BOILERPLATE
  989. # _LT_LINKER_BOILERPLATE
  990. # ----------------------
  991. # Check for linker boilerplate output or warnings with
  992. # the simple link test code.
  993. AC_DEFUN([_LT_LINKER_BOILERPLATE],
  994. [AC_REQUIRE([LT_AC_PROG_SED])dnl
  995. ac_outfile=conftest.$ac_objext
  996. echo "$lt_simple_link_test_code" >conftest.$ac_ext
  997. eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
  998. _lt_linker_boilerplate=`cat conftest.err`
  999. $rm conftest*
  1000. ])# _LT_LINKER_BOILERPLATE
  1001. # _LT_AC_SYS_LIBPATH_AIX
  1002. # ----------------------
  1003. # Links a minimal program and checks the executable
  1004. # for the system default hardcoded library path. In most cases,
  1005. # this is /usr/lib:/lib, but when the MPI compilers are used
  1006. # the location of the communication and MPI libs are included too.
  1007. # If we don't find anything, use the default library path according
  1008. # to the aix ld manual.
  1009. AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX],
  1010. [AC_REQUIRE([LT_AC_PROG_SED])dnl
  1011. AC_LINK_IFELSE(AC_LANG_PROGRAM,[
  1012. lt_aix_libpath_sed='
  1013. /Import File Strings/,/^$/ {
  1014. /^0/ {
  1015. s/^0 *\(.*\)$/\1/
  1016. p
  1017. }
  1018. }'
  1019. aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
  1020. # Check for a 64-bit object if we didn't find anything.
  1021. if test -z "$aix_libpath"; then
  1022. aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
  1023. fi],[])
  1024. if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  1025. ])# _LT_AC_SYS_LIBPATH_AIX
  1026. # _LT_AC_SHELL_INIT(ARG)
  1027. # ----------------------
  1028. AC_DEFUN([_LT_AC_SHELL_INIT],
  1029. [ifdef([AC_DIVERSION_NOTICE],
  1030. [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
  1031. [AC_DIVERT_PUSH(NOTICE)])
  1032. $1
  1033. AC_DIVERT_POP
  1034. ])# _LT_AC_SHELL_INIT
  1035. # _LT_AC_PROG_ECHO_BACKSLASH
  1036. # --------------------------
  1037. # Add some code to the start of the generated configure script which
  1038. # will find an echo command which doesn't interpret backslashes.
  1039. AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH],
  1040. [_LT_AC_SHELL_INIT([
  1041. # Check that we are running under the correct shell.
  1042. SHELL=${CONFIG_SHELL-/bin/sh}
  1043. case X$ECHO in
  1044. X*--fallback-echo)
  1045. # Remove one level of quotation (which was required for Make).
  1046. ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
  1047. ;;
  1048. esac
  1049. echo=${ECHO-echo}
  1050. if test "X[$]1" = X--no-reexec; then
  1051. # Discard the --no-reexec flag, and continue.
  1052. shift
  1053. elif test "X[$]1" = X--fallback-echo; then
  1054. # Avoid inline document here, it may be left over
  1055. :
  1056. elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then
  1057. # Yippee, $echo works!
  1058. :
  1059. else
  1060. # Restart under the correct shell.
  1061. exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
  1062. fi
  1063. if test "X[$]1" = X--fallback-echo; then
  1064. # used as fallback echo
  1065. shift
  1066. cat <<EOF
  1067. [$]*
  1068. EOF
  1069. exit 0
  1070. fi
  1071. # The HP-UX ksh and POSIX shell print the target directory to stdout
  1072. # if CDPATH is set.
  1073. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
  1074. if test -z "$ECHO"; then
  1075. if test "X${echo_test_string+set}" != Xset; then
  1076. # find a string as large as possible, as long as the shell can cope with it
  1077. for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
  1078. # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
  1079. if (echo_test_string=`eval $cmd`) 2>/dev/null &&
  1080. echo_test_string=`eval $cmd` &&
  1081. (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
  1082. then
  1083. break
  1084. fi
  1085. done
  1086. fi
  1087. if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
  1088. echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
  1089. test "X$echo_testing_string" = "X$echo_test_string"; then
  1090. :
  1091. else
  1092. # The Solaris, AIX, and Digital Unix default echo programs unquote
  1093. # backslashes. This makes it impossible to quote backslashes using
  1094. # echo "$something" | sed 's/\\/\\\\/g'
  1095. #
  1096. # So, first we look for a working echo in the user's PATH.
  1097. lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
  1098. for dir in $PATH /usr/ucb; do
  1099. IFS="$lt_save_ifs"
  1100. if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
  1101. test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
  1102. echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
  1103. test "X$echo_testing_string" = "X$echo_test_string"; then
  1104. echo="$dir/echo"
  1105. break
  1106. fi
  1107. done
  1108. IFS="$lt_save_ifs"
  1109. if test "X$echo" = Xecho; then
  1110. # We didn't find a better echo, so look for alternatives.
  1111. if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
  1112. echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
  1113. test "X$echo_testing_string" = "X$echo_test_string"; then
  1114. # This shell has a builtin print -r that does the trick.
  1115. echo='print -r'
  1116. elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
  1117. test "X$CONFIG_SHELL" != X/bin/ksh; then
  1118. # If we have ksh, try running configure again with it.
  1119. ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
  1120. export ORIGINAL_CONFIG_SHELL
  1121. CONFIG_SHELL=/bin/ksh
  1122. export CONFIG_SHELL
  1123. exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
  1124. else
  1125. # Try using printf.
  1126. echo='printf %s\n'
  1127. if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
  1128. echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
  1129. test "X$echo_testing_string" = "X$echo_test_string"; then
  1130. # Cool, printf works
  1131. :
  1132. elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
  1133. test "X$echo_testing_string" = 'X\t' &&
  1134. echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
  1135. test "X$echo_testing_string" = "X$echo_test_string"; then
  1136. CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
  1137. export CONFIG_SHELL
  1138. SHELL="$CONFIG_SHELL"
  1139. export SHELL
  1140. echo="$CONFIG_SHELL [$]0 --fallback-echo"
  1141. elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
  1142. test "X$echo_testing_string" = 'X\t' &&
  1143. echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
  1144. test "X$echo_testing_string" = "X$echo_test_string"; then
  1145. echo="$CONFIG_SHELL [$]0 --fallback-echo"
  1146. else
  1147. # maybe with a smaller string...
  1148. prev=:
  1149. for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
  1150. if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
  1151. then
  1152. break
  1153. fi
  1154. prev="$cmd"
  1155. done
  1156. if test "$prev" != 'sed 50q "[$]0"'; then
  1157. echo_test_string=`eval $prev`
  1158. export echo_test_string
  1159. exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
  1160. else
  1161. # Oops. We lost completely, so just stick with echo.
  1162. echo=echo
  1163. fi
  1164. fi
  1165. fi
  1166. fi
  1167. fi
  1168. fi
  1169. # Copy echo and quote the copy suitably for passing to libtool from
  1170. # the Makefile, instead of quoting the original, which is used later.
  1171. ECHO=$echo
  1172. if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
  1173. ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
  1174. fi
  1175. AC_SUBST(ECHO)
  1176. ])])# _LT_AC_PROG_ECHO_BACKSLASH
  1177. # _LT_AC_LOCK
  1178. # -----------
  1179. AC_DEFUN([_LT_AC_LOCK],
  1180. [AC_ARG_ENABLE([libtool-lock],
  1181. [AC_HELP_STRING([--disable-libtool-lock],
  1182. [avoid locking (might break parallel builds)])])
  1183. test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
  1184. # Some flags need to be propagated to the compiler or linker for good
  1185. # libtool support.
  1186. case $host in
  1187. ia64-*-hpux*)
  1188. # Find out which ABI we are using.
  1189. echo 'int i;' > conftest.$ac_ext
  1190. if AC_TRY_EVAL(ac_compile); then
  1191. case `/usr/bin/file conftest.$ac_objext` in
  1192. *ELF-32*)
  1193. HPUX_IA64_MODE="32"
  1194. ;;
  1195. *ELF-64*)
  1196. HPUX_IA64_MODE="64"
  1197. ;;
  1198. esac
  1199. fi
  1200. rm -rf conftest*
  1201. ;;
  1202. *-*-irix6*)
  1203. # Find out which ABI we are using.
  1204. echo '[#]line __oline__ "configure"' > conftest.$ac_ext
  1205. if AC_TRY_EVAL(ac_compile); then
  1206. if test "$lt_cv_prog_gnu_ld" = yes; then
  1207. case `/usr/bin/file conftest.$ac_objext` in
  1208. *32-bit*)
  1209. LD="${LD-ld} -melf32bsmip"
  1210. ;;
  1211. *N32*)
  1212. LD="${LD-ld} -melf32bmipn32"
  1213. ;;
  1214. *64-bit*)
  1215. LD="${LD-ld} -melf64bmip"
  1216. ;;
  1217. esac
  1218. else
  1219. case `/usr/bin/file conftest.$ac_objext` in
  1220. *32-bit*)
  1221. LD="${LD-ld} -32"
  1222. ;;
  1223. *N32*)
  1224. LD="${LD-ld} -n32"
  1225. ;;
  1226. *64-bit*)
  1227. LD="${LD-ld} -64"
  1228. ;;
  1229. esac
  1230. fi
  1231. fi
  1232. rm -rf conftest*
  1233. ;;
  1234. x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
  1235. s390*-*linux*|sparc*-*linux*)
  1236. # Find out which ABI we are using.
  1237. echo 'int i;' > conftest.$ac_ext
  1238. if AC_TRY_EVAL(ac_compile); then
  1239. case `/usr/bin/file conftest.o` in
  1240. *32-bit*)
  1241. case $host in
  1242. x86_64-*kfreebsd*-gnu)
  1243. LD="${LD-ld} -m elf_i386_fbsd"
  1244. ;;
  1245. x86_64-*linux*)
  1246. LD="${LD-ld} -m elf_i386"
  1247. ;;
  1248. ppc64-*linux*|powerpc64-*linux*)
  1249. LD="${LD-ld} -m elf32ppclinux"
  1250. ;;
  1251. s390x-*linux*)
  1252. LD="${LD-ld} -m elf_s390"
  1253. ;;
  1254. sparc64-*linux*)
  1255. LD="${LD-ld} -m elf32_sparc"
  1256. ;;
  1257. esac
  1258. ;;
  1259. *64-bit*)
  1260. case $host in
  1261. x86_64-*kfreebsd*-gnu)
  1262. LD="${LD-ld} -m elf_x86_64_fbsd"
  1263. ;;
  1264. x86_64-*linux*)
  1265. LD="${LD-ld} -m elf_x86_64"
  1266. ;;
  1267. ppc*-*linux*|powerpc*-*linux*)
  1268. LD="${LD-ld} -m elf64ppc"
  1269. ;;
  1270. s390*-*linux*)
  1271. LD="${LD-ld} -m elf64_s390"
  1272. ;;
  1273. sparc*-*linux*)
  1274. LD="${LD-ld} -m elf64_sparc"
  1275. ;;
  1276. esac
  1277. ;;
  1278. esac
  1279. fi
  1280. rm -rf conftest*
  1281. ;;
  1282. *-*-sco3.2v5*)
  1283. # On SCO OpenServer 5, we need -belf to get full-featured binaries.
  1284. SAVE_CFLAGS="$CFLAGS"
  1285. CFLAGS="$CFLAGS -belf"
  1286. AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
  1287. [AC_LANG_PUSH(C)
  1288. AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
  1289. AC_LANG_POP])
  1290. if test x"$lt_cv_cc_needs_belf" != x"yes"; then
  1291. # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
  1292. CFLAGS="$SAVE_CFLAGS"
  1293. fi
  1294. ;;
  1295. sparc*-*solaris*)
  1296. # Find out which ABI we are using.
  1297. echo 'int i;' > conftest.$ac_ext
  1298. if AC_TRY_EVAL(ac_compile); then
  1299. case `/usr/bin/file conftest.o` in
  1300. *64-bit*)
  1301. case $lt_cv_prog_gnu_ld in
  1302. yes*) LD="${LD-ld} -m elf64_sparc" ;;
  1303. *) LD="${LD-ld} -64" ;;
  1304. esac
  1305. ;;
  1306. esac
  1307. fi
  1308. rm -rf conftest*
  1309. ;;
  1310. AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
  1311. [*-*-cygwin* | *-*-mingw* | *-*-pw32*)
  1312. AC_CHECK_TOOL(DLLTOOL, dlltool, false)
  1313. AC_CHECK_TOOL(AS, as, false)
  1314. AC_CHECK_TOOL(OBJDUMP, objdump, false)
  1315. ;;
  1316. ])
  1317. esac
  1318. need_locks="$enable_libtool_lock"
  1319. ])# _LT_AC_LOCK
  1320. # AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
  1321. # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
  1322. # ----------------------------------------------------------------
  1323. # Check whether the given compiler option works
  1324. AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION],
  1325. [AC_REQUIRE([LT_AC_PROG_SED])
  1326. AC_CACHE_CHECK([$1], [$2],
  1327. [$2=no
  1328. ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
  1329. echo "$lt_simple_compile_test_code" > conftest.$ac_ext
  1330. lt_compiler_flag="$3"
  1331. # Insert the option either (1) after the last *FLAGS variable, or
  1332. # (2) before a word containing "conftest.", or (3) at the end.
  1333. # Note that $ac_compile itself does not contain backslashes and begins
  1334. # with a dollar sign (not a hyphen), so the echo should work correctly.
  1335. # The option is referenced via a variable to avoid confusing sed.
  1336. lt_compile=`echo "$ac_compile" | $SED \
  1337. -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
  1338. -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
  1339. -e 's:$: $lt_compiler_flag:'`
  1340. (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
  1341. (eval "$lt_compile" 2>conftest.err)
  1342. ac_status=$?
  1343. cat conftest.err >&AS_MESSAGE_LOG_FD
  1344. echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
  1345. if (exit $ac_status) && test -s "$ac_outfile"; then
  1346. # The compiler can only warn and ignore the option if not recognized
  1347. # So say no if there are warnings other than the usual output.
  1348. $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
  1349. $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
  1350. if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
  1351. $2=yes
  1352. fi
  1353. fi
  1354. $rm conftest*
  1355. ])
  1356. if test x"[$]$2" = xyes; then
  1357. ifelse([$5], , :, [$5])
  1358. else
  1359. ifelse([$6], , :, [$6])
  1360. fi
  1361. ])# AC_LIBTOOL_COMPILER_OPTION
  1362. # AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
  1363. # [ACTION-SUCCESS], [ACTION-FAILURE])
  1364. # ------------------------------------------------------------
  1365. # Check whether the given compiler option works
  1366. AC_DEFUN([AC_LIBTOOL_LINKER_OPTION],
  1367. [AC_REQUIRE([LT_AC_PROG_SED])dnl
  1368. AC_CACHE_CHECK([$1], [$2],
  1369. [$2=no
  1370. save_LDFLAGS="$LDFLAGS"
  1371. LDFLAGS="$LDFLAGS $3"
  1372. echo "$lt_simple_link_test_code" > conftest.$ac_ext
  1373. if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
  1374. # The linker can only warn and ignore the option if not recognized
  1375. # So say no if there are warnings
  1376. if test -s conftest.err; then
  1377. # Append any errors to the config.log.
  1378. cat conftest.err 1>&AS_MESSAGE_LOG_FD
  1379. $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
  1380. $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
  1381. if diff conftest.exp conftest.er2 >/dev/null; then
  1382. $2=yes
  1383. fi
  1384. else
  1385. $2=yes
  1386. fi
  1387. fi
  1388. $rm conftest*
  1389. LDFLAGS="$save_LDFLAGS"
  1390. ])
  1391. if test x"[$]$2" = xyes; then
  1392. ifelse([$4], , :, [$4])
  1393. else
  1394. ifelse([$5], , :, [$5])
  1395. fi
  1396. ])# AC_LIBTOOL_LINKER_OPTION
  1397. # AC_LIBTOOL_SYS_MAX_CMD_LEN
  1398. # --------------------------
  1399. AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN],
  1400. [# find the maximum length of command line arguments
  1401. AC_MSG_CHECKING([the maximum length of command line arguments])
  1402. AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
  1403. i=0
  1404. teststring="ABCD"
  1405. case $build_os in
  1406. msdosdjgpp*)
  1407. # On DJGPP, this test can blow up pretty badly due to problems in libc
  1408. # (any single argument exceeding 2000 bytes causes a buffer overrun
  1409. # during glob expansion). Even if it were fixed, the result of this
  1410. # check would be larger than it should be.
  1411. lt_cv_sys_max_cmd_len=12288; # 12K is about right
  1412. ;;
  1413. gnu*)
  1414. # Under GNU Hurd, this test is not required because there is
  1415. # no limit to the length of command line arguments.
  1416. # Libtool will interpret -1 as no limit whatsoever
  1417. lt_cv_sys_max_cmd_len=-1;
  1418. ;;
  1419. cygwin* | mingw*)
  1420. # On Win9x/ME, this test blows up -- it succeeds, but takes
  1421. # about 5 minutes as the teststring grows exponentially.
  1422. # Worse, since 9x/ME are not pre-emptively multitasking,
  1423. # you end up with a "frozen" computer, even though with patience
  1424. # the test eventually succeeds (with a max line length of 256k).
  1425. # Instead, let's just punt: use the minimum linelength reported by
  1426. # all of the supported platforms: 8192 (on NT/2K/XP).
  1427. lt_cv_sys_max_cmd_len=8192;
  1428. ;;
  1429. amigaos*)
  1430. # On AmigaOS with pdksh, this test takes hours, literally.
  1431. # So we just punt and use a minimum line length of 8192.
  1432. lt_cv_sys_max_cmd_len=8192;
  1433. ;;
  1434. netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
  1435. # This has been around since 386BSD, at least. Likely further.
  1436. if test -x /sbin/sysctl; then
  1437. lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
  1438. elif test -x /usr/sbin/sysctl; then
  1439. lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
  1440. else
  1441. lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
  1442. fi
  1443. # And add a safety zone
  1444. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
  1445. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
  1446. ;;
  1447. interix*)
  1448. # We know the value 262144 and hardcode it with a safety zone (like BSD)
  1449. lt_cv_sys_max_cmd_len=196608
  1450. ;;
  1451. osf*)
  1452. # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
  1453. # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
  1454. # nice to cause kernel panics so lets avoid the loop below.
  1455. # First set a reasonable default.
  1456. lt_cv_sys_max_cmd_len=16384
  1457. #
  1458. if test -x /sbin/sysconfig; then
  1459. case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
  1460. *1*) lt_cv_sys_max_cmd_len=-1 ;;
  1461. esac
  1462. fi
  1463. ;;
  1464. sco3.2v5*)
  1465. lt_cv_sys_max_cmd_len=102400
  1466. ;;
  1467. sysv5* | sco5v6* | sysv4.2uw2*)
  1468. kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
  1469. if test -n "$kargmax"; then
  1470. lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
  1471. else
  1472. lt_cv_sys_max_cmd_len=32768
  1473. fi
  1474. ;;
  1475. *)
  1476. lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
  1477. if test -n "$lt_cv_sys_max_cmd_len"; then
  1478. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
  1479. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
  1480. else
  1481. SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
  1482. while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \
  1483. = "XX$teststring") >/dev/null 2>&1 &&
  1484. new_result=`expr "X$teststring" : ".*" 2>&1` &&
  1485. lt_cv_sys_max_cmd_len=$new_result &&
  1486. test $i != 17 # 1/2 MB should be enough
  1487. do
  1488. i=`expr $i + 1`
  1489. teststring=$teststring$teststring
  1490. done
  1491. teststring=
  1492. # Add a significant safety factor because C++ compilers can tack on massive
  1493. # amounts of additional arguments before passing them to the linker.
  1494. # It appears as though 1/2 is a usable value.
  1495. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
  1496. fi
  1497. ;;
  1498. esac
  1499. ])
  1500. if test -n $lt_cv_sys_max_cmd_len ; then
  1501. AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
  1502. else
  1503. AC_MSG_RESULT(none)
  1504. fi
  1505. ])# AC_LIBTOOL_SYS_MAX_CMD_LEN
  1506. # _LT_AC_CHECK_DLFCN
  1507. # ------------------
  1508. AC_DEFUN([_LT_AC_CHECK_DLFCN],
  1509. [AC_CHECK_HEADERS(dlfcn.h)dnl
  1510. ])# _LT_AC_CHECK_DLFCN
  1511. # _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
  1512. # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
  1513. # ---------------------------------------------------------------------
  1514. AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF],
  1515. [AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
  1516. if test "$cross_compiling" = yes; then :
  1517. [$4]
  1518. else
  1519. lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
  1520. lt_status=$lt_dlunknown
  1521. cat > conftest.$ac_ext <<EOF
  1522. [#line __oline__ "configure"
  1523. #include "confdefs.h"
  1524. #if HAVE_DLFCN_H
  1525. #include <dlfcn.h>
  1526. #endif
  1527. #include <stdio.h>
  1528. #ifdef RTLD_GLOBAL
  1529. # define LT_DLGLOBAL RTLD_GLOBAL
  1530. #else
  1531. # ifdef DL_GLOBAL
  1532. # define LT_DLGLOBAL DL_GLOBAL
  1533. # else
  1534. # define LT_DLGLOBAL 0
  1535. # endif
  1536. #endif
  1537. /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
  1538. find out it does not work in some platform. */
  1539. #ifndef LT_DLLAZY_OR_NOW
  1540. # ifdef RTLD_LAZY
  1541. # define LT_DLLAZY_OR_NOW RTLD_LAZY
  1542. # else
  1543. # ifdef DL_LAZY
  1544. # define LT_DLLAZY_OR_NOW DL_LAZY
  1545. # else
  1546. # ifdef RTLD_NOW
  1547. # define LT_DLLAZY_OR_NOW RTLD_NOW
  1548. # else
  1549. # ifdef DL_NOW
  1550. # define LT_DLLAZY_OR_NOW DL_NOW
  1551. # else
  1552. # define LT_DLLAZY_OR_NOW 0
  1553. # endif
  1554. # endif
  1555. # endif
  1556. # endif
  1557. #endif
  1558. #ifdef __cplusplus
  1559. extern "C" void exit (int);
  1560. #endif
  1561. void fnord() { int i=42;}
  1562. int main ()
  1563. {
  1564. void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
  1565. int status = $lt_dlunknown;
  1566. if (self)
  1567. {
  1568. if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
  1569. else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
  1570. /* dlclose (self); */
  1571. }
  1572. else
  1573. puts (dlerror ());
  1574. exit (status);
  1575. }]
  1576. EOF
  1577. if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
  1578. (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
  1579. lt_status=$?
  1580. case x$lt_status in
  1581. x$lt_dlno_uscore) $1 ;;
  1582. x$lt_dlneed_uscore) $2 ;;
  1583. x$lt_dlunknown|x*) $3 ;;
  1584. esac
  1585. else :
  1586. # compilation failed
  1587. $3
  1588. fi
  1589. fi
  1590. rm -fr conftest*
  1591. ])# _LT_AC_TRY_DLOPEN_SELF
  1592. # AC_LIBTOOL_DLOPEN_SELF
  1593. # ----------------------
  1594. AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF],
  1595. [AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
  1596. if test "x$enable_dlopen" != xyes; then
  1597. enable_dlopen=unknown
  1598. enable_dlopen_self=unknown
  1599. enable_dlopen_self_static=unknown
  1600. else
  1601. lt_cv_dlopen=no
  1602. lt_cv_dlopen_libs=
  1603. case $host_os in
  1604. beos*)
  1605. lt_cv_dlopen="load_add_on"
  1606. lt_cv_dlopen_libs=
  1607. lt_cv_dlopen_self=yes
  1608. ;;
  1609. mingw* | pw32*)
  1610. lt_cv_dlopen="LoadLibrary"
  1611. lt_cv_dlopen_libs=
  1612. ;;
  1613. cygwin*)
  1614. lt_cv_dlopen="dlopen"
  1615. lt_cv_dlopen_libs=
  1616. ;;
  1617. darwin*)
  1618. # if libdl is installed we need to link against it
  1619. AC_CHECK_LIB([dl], [dlopen],
  1620. [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
  1621. lt_cv_dlopen="dyld"
  1622. lt_cv_dlopen_libs=
  1623. lt_cv_dlopen_self=yes
  1624. ])
  1625. ;;
  1626. *)
  1627. AC_CHECK_FUNC([shl_load],
  1628. [lt_cv_dlopen="shl_load"],
  1629. [AC_CHECK_LIB([dld], [shl_load],
  1630. [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"],
  1631. [AC_CHECK_FUNC([dlopen],
  1632. [lt_cv_dlopen="dlopen"],
  1633. [AC_CHECK_LIB([dl], [dlopen],
  1634. [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
  1635. [AC_CHECK_LIB([svld], [dlopen],
  1636. [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
  1637. [AC_CHECK_LIB([dld], [dld_link],
  1638. [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"])
  1639. ])
  1640. ])
  1641. ])
  1642. ])
  1643. ])
  1644. ;;
  1645. esac
  1646. if test "x$lt_cv_dlopen" != xno; then
  1647. enable_dlopen=yes
  1648. else
  1649. enable_dlopen=no
  1650. fi
  1651. case $lt_cv_dlopen in
  1652. dlopen)
  1653. save_CPPFLAGS="$CPPFLAGS"
  1654. test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
  1655. save_LDFLAGS="$LDFLAGS"
  1656. wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
  1657. save_LIBS="$LIBS"
  1658. LIBS="$lt_cv_dlopen_libs $LIBS"
  1659. AC_CACHE_CHECK([whether a program can dlopen itself],
  1660. lt_cv_dlopen_self, [dnl
  1661. _LT_AC_TRY_DLOPEN_SELF(
  1662. lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
  1663. lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
  1664. ])
  1665. if test "x$lt_cv_dlopen_self" = xyes; then
  1666. wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
  1667. AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
  1668. lt_cv_dlopen_self_static, [dnl
  1669. _LT_AC_TRY_DLOPEN_SELF(
  1670. lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
  1671. lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
  1672. ])
  1673. fi
  1674. CPPFLAGS="$save_CPPFLAGS"
  1675. LDFLAGS="$save_LDFLAGS"
  1676. LIBS="$save_LIBS"
  1677. ;;
  1678. esac
  1679. case $lt_cv_dlopen_self in
  1680. yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
  1681. *) enable_dlopen_self=unknown ;;
  1682. esac
  1683. case $lt_cv_dlopen_self_static in
  1684. yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
  1685. *) enable_dlopen_self_static=unknown ;;
  1686. esac
  1687. fi
  1688. ])# AC_LIBTOOL_DLOPEN_SELF
  1689. # AC_LIBTOOL_PROG_CC_C_O([TAGNAME])
  1690. # ---------------------------------
  1691. # Check to see if options -c and -o are simultaneously supported by compiler
  1692. AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O],
  1693. [AC_REQUIRE([LT_AC_PROG_SED])dnl
  1694. AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
  1695. AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
  1696. [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
  1697. [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
  1698. $rm -r conftest 2>/dev/null
  1699. mkdir conftest
  1700. cd conftest
  1701. mkdir out
  1702. echo "$lt_simple_compile_test_code" > conftest.$ac_ext
  1703. lt_compiler_flag="-o out/conftest2.$ac_objext"
  1704. # Insert the option either (1) after the last *FLAGS variable, or
  1705. # (2) before a word containing "conftest.", or (3) at the end.
  1706. # Note that $ac_compile itself does not contain backslashes and begins
  1707. # with a dollar sign (not a hyphen), so the echo should work correctly.
  1708. lt_compile=`echo "$ac_compile" | $SED \
  1709. -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
  1710. -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
  1711. -e 's:$: $lt_compiler_flag:'`
  1712. (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
  1713. (eval "$lt_compile" 2>out/conftest.err)
  1714. ac_status=$?
  1715. cat out/conftest.err >&AS_MESSAGE_LOG_FD
  1716. echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
  1717. if (exit $ac_status) && test -s out/conftest2.$ac_objext
  1718. then
  1719. # The compiler can only warn and ignore the option if not recognized
  1720. # So say no if there are warnings
  1721. $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
  1722. $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
  1723. if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
  1724. _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
  1725. fi
  1726. fi
  1727. chmod u+w . 2>&AS_MESSAGE_LOG_FD
  1728. $rm conftest*
  1729. # SGI C++ compiler will create directory out/ii_files/ for
  1730. # template instantiation
  1731. test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
  1732. $rm out/* && rmdir out
  1733. cd ..
  1734. rmdir conftest
  1735. $rm conftest*
  1736. ])
  1737. ])# AC_LIBTOOL_PROG_CC_C_O
  1738. # AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME])
  1739. # -----------------------------------------
  1740. # Check to see if we can do hard links to lock some files if needed
  1741. AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS],
  1742. [AC_REQUIRE([_LT_AC_LOCK])dnl
  1743. hard_links="nottested"
  1744. if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
  1745. # do not overwrite the value of need_locks provided by the user
  1746. AC_MSG_CHECKING([if we can lock with hard links])
  1747. hard_links=yes
  1748. $rm conftest*
  1749. ln conftest.a conftest.b 2>/dev/null && hard_links=no
  1750. touch conftest.a
  1751. ln conftest.a conftest.b 2>&5 || hard_links=no
  1752. ln conftest.a conftest.b 2>/dev/null && hard_links=no
  1753. AC_MSG_RESULT([$hard_links])
  1754. if test "$hard_links" = no; then
  1755. AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
  1756. need_locks=warn
  1757. fi
  1758. else
  1759. need_locks=no
  1760. fi
  1761. ])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS
  1762. # AC_LIBTOOL_OBJDIR
  1763. # -----------------
  1764. AC_DEFUN([AC_LIBTOOL_OBJDIR],
  1765. [AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
  1766. [rm -f .libs 2>/dev/null
  1767. mkdir .libs 2>/dev/null
  1768. if test -d .libs; then
  1769. lt_cv_objdir=.libs
  1770. else
  1771. # MS-DOS does not allow filenames that begin with a dot.
  1772. lt_cv_objdir=_libs
  1773. fi
  1774. rmdir .libs 2>/dev/null])
  1775. objdir=$lt_cv_objdir
  1776. ])# AC_LIBTOOL_OBJDIR
  1777. # AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME])
  1778. # ----------------------------------------------
  1779. # Check hardcoding attributes.
  1780. AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH],
  1781. [AC_MSG_CHECKING([how to hardcode library paths into programs])
  1782. _LT_AC_TAGVAR(hardcode_action, $1)=
  1783. if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \
  1784. test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \
  1785. test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
  1786. # We can hardcode non-existant directories.
  1787. if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no &&
  1788. # If the only mechanism to avoid hardcoding is shlibpath_var, we
  1789. # have to relink, otherwise we might link with an installed library
  1790. # when we should be linking with a yet-to-be-installed one
  1791. ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
  1792. test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then
  1793. # Linking always hardcodes the temporary library directory.
  1794. _LT_AC_TAGVAR(hardcode_action, $1)=relink
  1795. else
  1796. # We can link without hardcoding, and we can hardcode nonexisting dirs.
  1797. _LT_AC_TAGVAR(hardcode_action, $1)=immediate
  1798. fi
  1799. else
  1800. # We cannot hardcode anything, or else we can only hardcode existing
  1801. # directories.
  1802. _LT_AC_TAGVAR(hardcode_action, $1)=unsupported
  1803. fi
  1804. AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)])
  1805. if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then
  1806. # Fast installation is not supported
  1807. enable_fast_install=no
  1808. elif test "$shlibpath_overrides_runpath" = yes ||
  1809. test "$enable_shared" = no; then
  1810. # Fast installation is not necessary
  1811. enable_fast_install=needless
  1812. fi
  1813. ])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH
  1814. # AC_LIBTOOL_SYS_LIB_STRIP
  1815. # ------------------------
  1816. AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP],
  1817. [striplib=
  1818. old_striplib=
  1819. AC_MSG_CHECKING([whether stripping libraries is possible])
  1820. if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
  1821. test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
  1822. test -z "$striplib" && striplib="$STRIP --strip-unneeded"
  1823. AC_MSG_RESULT([yes])
  1824. else
  1825. # FIXME - insert some real tests, host_os isn't really good enough
  1826. case $host_os in
  1827. darwin*)
  1828. if test -n "$STRIP" ; then
  1829. striplib="$STRIP -x"
  1830. old_striplib="$STRIP -S"
  1831. AC_MSG_RESULT([yes])
  1832. else
  1833. AC_MSG_RESULT([no])
  1834. fi
  1835. ;;
  1836. *)
  1837. AC_MSG_RESULT([no])
  1838. ;;
  1839. esac
  1840. fi
  1841. ])# AC_LIBTOOL_SYS_LIB_STRIP
  1842. # AC_LIBTOOL_SYS_DYNAMIC_LINKER
  1843. # -----------------------------
  1844. # PORTME Fill in your ld.so characteristics
  1845. AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER],
  1846. [AC_REQUIRE([LT_AC_PROG_SED])dnl
  1847. AC_MSG_CHECKING([dynamic linker characteristics])
  1848. library_names_spec=
  1849. libname_spec='lib$name'
  1850. soname_spec=
  1851. shrext_cmds=".so"
  1852. postinstall_cmds=
  1853. postuninstall_cmds=
  1854. finish_cmds=
  1855. finish_eval=
  1856. shlibpath_var=
  1857. shlibpath_overrides_runpath=unknown
  1858. version_type=none
  1859. dynamic_linker="$host_os ld.so"
  1860. sys_lib_dlsearch_path_spec="/lib /usr/lib"
  1861. m4_if($1,[],[
  1862. if test "$GCC" = yes; then
  1863. case $host_os in
  1864. darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
  1865. *) lt_awk_arg="/^libraries:/" ;;
  1866. esac
  1867. lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
  1868. if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then
  1869. # if the path contains ";" then we assume it to be the separator
  1870. # otherwise default to the standard path separator (i.e. ":") - it is
  1871. # assumed that no part of a normal pathname contains ";" but that should
  1872. # okay in the real world where ";" in dirpaths is itself problematic.
  1873. lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'`
  1874. else
  1875. lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
  1876. fi
  1877. # Ok, now we have the path, separated by spaces, we can step through it
  1878. # and add multilib dir if necessary.
  1879. lt_tmp_lt_search_path_spec=
  1880. lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
  1881. for lt_sys_path in $lt_search_path_spec; do
  1882. if test -d "$lt_sys_path/$lt_multi_os_dir"; then
  1883. lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
  1884. else
  1885. test -d "$lt_sys_path" && \
  1886. lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
  1887. fi
  1888. done
  1889. lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk '
  1890. BEGIN {RS=" "; FS="/|\n";} {
  1891. lt_foo="";
  1892. lt_count=0;
  1893. for (lt_i = NF; lt_i > 0; lt_i--) {
  1894. if ($lt_i != "" && $lt_i != ".") {
  1895. if ($lt_i == "..") {
  1896. lt_count++;
  1897. } else {
  1898. if (lt_count == 0) {
  1899. lt_foo="/" $lt_i lt_foo;
  1900. } else {
  1901. lt_count--;
  1902. }
  1903. }
  1904. }
  1905. }
  1906. if (lt_foo != "") { lt_freq[[lt_foo]]++; }
  1907. if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
  1908. }'`
  1909. sys_lib_search_path_spec=`echo $lt_search_path_spec`
  1910. else
  1911. sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
  1912. fi])
  1913. need_lib_prefix=unknown
  1914. hardcode_into_libs=no
  1915. # when you set need_version to no, make sure it does not cause -set_version
  1916. # flags to be left without arguments
  1917. need_version=unknown
  1918. case $host_os in
  1919. aix3*)
  1920. version_type=linux
  1921. library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
  1922. shlibpath_var=LIBPATH
  1923. # AIX 3 has no versioning support, so we append a major version to the name.
  1924. soname_spec='${libname}${release}${shared_ext}$major'
  1925. ;;
  1926. aix4* | aix5*)
  1927. version_type=linux
  1928. need_lib_prefix=no
  1929. need_version=no
  1930. hardcode_into_libs=yes
  1931. if test "$host_cpu" = ia64; then
  1932. # AIX 5 supports IA64
  1933. library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
  1934. shlibpath_var=LD_LIBRARY_PATH
  1935. else
  1936. # With GCC up to 2.95.x, collect2 would create an import file
  1937. # for dependence libraries. The import file would start with
  1938. # the line `#! .'. This would cause the generated library to
  1939. # depend on `.', always an invalid library. This was fixed in
  1940. # development snapshots of GCC prior to 3.0.
  1941. case $host_os in
  1942. aix4 | aix4.[[01]] | aix4.[[01]].*)
  1943. if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
  1944. echo ' yes '
  1945. echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
  1946. :
  1947. else
  1948. can_build_shared=no
  1949. fi
  1950. ;;
  1951. esac
  1952. # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
  1953. # soname into executable. Probably we can add versioning support to
  1954. # collect2, so additional links can be useful in future.
  1955. if test "$aix_use_runtimelinking" = yes; then
  1956. # If using run time linking (on AIX 4.2 or later) use lib<name>.so
  1957. # instead of lib<name>.a to let people know that these are not
  1958. # typical AIX shared libraries.
  1959. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  1960. else
  1961. # We preserve .a as extension for shared libraries through AIX4.2
  1962. # and later when we are not doing run time linking.
  1963. library_names_spec='${libname}${release}.a $libname.a'
  1964. soname_spec='${libname}${release}${shared_ext}$major'
  1965. fi
  1966. shlibpath_var=LIBPATH
  1967. fi
  1968. ;;
  1969. amigaos*)
  1970. library_names_spec='$libname.ixlibrary $libname.a'
  1971. # Create ${libname}_ixlibrary.a entries in /sys/libs.
  1972. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $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'
  1973. ;;
  1974. beos*)
  1975. library_names_spec='${libname}${shared_ext}'
  1976. dynamic_linker="$host_os ld.so"
  1977. shlibpath_var=LIBRARY_PATH
  1978. ;;
  1979. bsdi[[45]]*)
  1980. version_type=linux
  1981. need_version=no
  1982. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  1983. soname_spec='${libname}${release}${shared_ext}$major'
  1984. finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
  1985. shlibpath_var=LD_LIBRARY_PATH
  1986. sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
  1987. sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
  1988. # the default ld.so.conf also contains /usr/contrib/lib and
  1989. # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
  1990. # libtool to hard-code these into programs
  1991. ;;
  1992. cygwin* | mingw* | pw32*)
  1993. version_type=windows
  1994. shrext_cmds=".dll"
  1995. need_version=no
  1996. need_lib_prefix=no
  1997. case $GCC,$host_os in
  1998. yes,cygwin* | yes,mingw* | yes,pw32*)
  1999. library_names_spec='$libname.dll.a'
  2000. # DLL is installed to $(libdir)/../bin by postinstall_cmds
  2001. postinstall_cmds='base_file=`basename \${file}`~
  2002. dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
  2003. dldir=$destdir/`dirname \$dlpath`~
  2004. test -d \$dldir || mkdir -p \$dldir~
  2005. $install_prog $dir/$dlname \$dldir/$dlname~
  2006. chmod a+x \$dldir/$dlname'
  2007. postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
  2008. dlpath=$dir/\$dldll~
  2009. $rm \$dlpath'
  2010. shlibpath_overrides_runpath=yes
  2011. case $host_os in
  2012. cygwin*)
  2013. # Cygwin DLLs use 'cyg' prefix rather than 'lib'
  2014. soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
  2015. sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
  2016. ;;
  2017. mingw*)
  2018. # MinGW DLLs use traditional 'lib' prefix
  2019. soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
  2020. sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
  2021. if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then
  2022. # It is most probably a Windows format PATH printed by
  2023. # mingw gcc, but we are running on Cygwin. Gcc prints its search
  2024. # path with ; separators, and with drive letters. We can handle the
  2025. # drive letters (cygwin fileutils understands them), so leave them,
  2026. # especially as we might pass files found there to a mingw objdump,
  2027. # which wouldn't understand a cygwinified path. Ahh.
  2028. sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
  2029. else
  2030. sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
  2031. fi
  2032. ;;
  2033. pw32*)
  2034. # pw32 DLLs use 'pw' prefix rather than 'lib'
  2035. library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
  2036. ;;
  2037. esac
  2038. ;;
  2039. *)
  2040. library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
  2041. ;;
  2042. esac
  2043. dynamic_linker='Win32 ld.exe'
  2044. # FIXME: first we should search . and the directory the executable is in
  2045. shlibpath_var=PATH
  2046. ;;
  2047. darwin* | rhapsody*)
  2048. dynamic_linker="$host_os dyld"
  2049. version_type=darwin
  2050. need_lib_prefix=no
  2051. need_version=no
  2052. library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
  2053. soname_spec='${libname}${release}${major}$shared_ext'
  2054. shlibpath_overrides_runpath=yes
  2055. shlibpath_var=DYLD_LIBRARY_PATH
  2056. shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
  2057. m4_if([$1], [],[
  2058. sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
  2059. sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
  2060. ;;
  2061. dgux*)
  2062. version_type=linux
  2063. need_lib_prefix=no
  2064. need_version=no
  2065. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
  2066. soname_spec='${libname}${release}${shared_ext}$major'
  2067. shlibpath_var=LD_LIBRARY_PATH
  2068. ;;
  2069. freebsd1*)
  2070. dynamic_linker=no
  2071. ;;
  2072. freebsd* | dragonfly*)
  2073. # DragonFly does not have aout. When/if they implement a new
  2074. # versioning mechanism, adjust this.
  2075. if test -x /usr/bin/objformat; then
  2076. objformat=`/usr/bin/objformat`
  2077. else
  2078. case $host_os in
  2079. freebsd[[123]]*) objformat=aout ;;
  2080. *) objformat=elf ;;
  2081. esac
  2082. fi
  2083. version_type=freebsd-$objformat
  2084. case $version_type in
  2085. freebsd-elf*)
  2086. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
  2087. need_version=no
  2088. need_lib_prefix=no
  2089. ;;
  2090. freebsd-*)
  2091. library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
  2092. need_version=yes
  2093. ;;
  2094. esac
  2095. shlibpath_var=LD_LIBRARY_PATH
  2096. case $host_os in
  2097. freebsd2*)
  2098. shlibpath_overrides_runpath=yes
  2099. ;;
  2100. freebsd3.[[01]]* | freebsdelf3.[[01]]*)
  2101. shlibpath_overrides_runpath=yes
  2102. hardcode_into_libs=yes
  2103. ;;
  2104. freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
  2105. freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
  2106. shlibpath_overrides_runpath=no
  2107. hardcode_into_libs=yes
  2108. ;;
  2109. *) # from 4.6 on, and DragonFly
  2110. shlibpath_overrides_runpath=yes
  2111. hardcode_into_libs=yes
  2112. ;;
  2113. esac
  2114. ;;
  2115. gnu*)
  2116. version_type=linux
  2117. need_lib_prefix=no
  2118. need_version=no
  2119. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
  2120. soname_spec='${libname}${release}${shared_ext}$major'
  2121. shlibpath_var=LD_LIBRARY_PATH
  2122. hardcode_into_libs=yes
  2123. ;;
  2124. hpux9* | hpux10* | hpux11*)
  2125. # Give a soname corresponding to the major version so that dld.sl refuses to
  2126. # link against other versions.
  2127. version_type=sunos
  2128. need_lib_prefix=no
  2129. need_version=no
  2130. case $host_cpu in
  2131. ia64*)
  2132. shrext_cmds='.so'
  2133. hardcode_into_libs=yes
  2134. dynamic_linker="$host_os dld.so"
  2135. shlibpath_var=LD_LIBRARY_PATH
  2136. shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
  2137. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  2138. soname_spec='${libname}${release}${shared_ext}$major'
  2139. if test "X$HPUX_IA64_MODE" = X32; then
  2140. sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
  2141. else
  2142. sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
  2143. fi
  2144. sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
  2145. ;;
  2146. hppa*64*)
  2147. shrext_cmds='.sl'
  2148. hardcode_into_libs=yes
  2149. dynamic_linker="$host_os dld.sl"
  2150. shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
  2151. shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
  2152. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  2153. soname_spec='${libname}${release}${shared_ext}$major'
  2154. sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
  2155. sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
  2156. ;;
  2157. *)
  2158. shrext_cmds='.sl'
  2159. dynamic_linker="$host_os dld.sl"
  2160. shlibpath_var=SHLIB_PATH
  2161. shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
  2162. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  2163. soname_spec='${libname}${release}${shared_ext}$major'
  2164. ;;
  2165. esac
  2166. # HP-UX runs *really* slowly unless shared libraries are mode 555.
  2167. postinstall_cmds='chmod 555 $lib'
  2168. ;;
  2169. interix[[3-9]]*)
  2170. version_type=linux
  2171. need_lib_prefix=no
  2172. need_version=no
  2173. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
  2174. soname_spec='${libname}${release}${shared_ext}$major'
  2175. dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
  2176. shlibpath_var=LD_LIBRARY_PATH
  2177. shlibpath_overrides_runpath=no
  2178. hardcode_into_libs=yes
  2179. ;;
  2180. irix5* | irix6* | nonstopux*)
  2181. case $host_os in
  2182. nonstopux*) version_type=nonstopux ;;
  2183. *)
  2184. if test "$lt_cv_prog_gnu_ld" = yes; then
  2185. version_type=linux
  2186. else
  2187. version_type=irix
  2188. fi ;;
  2189. esac
  2190. need_lib_prefix=no
  2191. need_version=no
  2192. soname_spec='${libname}${release}${shared_ext}$major'
  2193. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
  2194. case $host_os in
  2195. irix5* | nonstopux*)
  2196. libsuff= shlibsuff=
  2197. ;;
  2198. *)
  2199. case $LD in # libtool.m4 will add one of these switches to LD
  2200. *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
  2201. libsuff= shlibsuff= libmagic=32-bit;;
  2202. *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
  2203. libsuff=32 shlibsuff=N32 libmagic=N32;;
  2204. *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
  2205. libsuff=64 shlibsuff=64 libmagic=64-bit;;
  2206. *) libsuff= shlibsuff= libmagic=never-match;;
  2207. esac
  2208. ;;
  2209. esac
  2210. shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
  2211. shlibpath_overrides_runpath=no
  2212. sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
  2213. sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
  2214. hardcode_into_libs=yes
  2215. ;;
  2216. # No shared lib support for Linux oldld, aout, or coff.
  2217. linux*oldld* | linux*aout* | linux*coff*)
  2218. dynamic_linker=no
  2219. ;;
  2220. # This must be Linux ELF.
  2221. linux* | k*bsd*-gnu)
  2222. version_type=linux
  2223. need_lib_prefix=no
  2224. need_version=no
  2225. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  2226. soname_spec='${libname}${release}${shared_ext}$major'
  2227. finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
  2228. shlibpath_var=LD_LIBRARY_PATH
  2229. shlibpath_overrides_runpath=no
  2230. # This implies no fast_install, which is unacceptable.
  2231. # Some rework will be needed to allow for fast_install
  2232. # before this can be enabled.
  2233. hardcode_into_libs=yes
  2234. # Append ld.so.conf contents to the search path
  2235. if test -f /etc/ld.so.conf; then
  2236. 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;/^$/d' | tr '\n' ' '`
  2237. sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
  2238. fi
  2239. # We used to test for /lib/ld.so.1 and disable shared libraries on
  2240. # powerpc, because MkLinux only supported shared libraries with the
  2241. # GNU dynamic linker. Since this was broken with cross compilers,
  2242. # most powerpc-linux boxes support dynamic linking these days and
  2243. # people can always --disable-shared, the test was removed, and we
  2244. # assume the GNU/Linux dynamic linker is in use.
  2245. dynamic_linker='GNU/Linux ld.so'
  2246. ;;
  2247. netbsd*)
  2248. version_type=sunos
  2249. need_lib_prefix=no
  2250. need_version=no
  2251. if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
  2252. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
  2253. finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
  2254. dynamic_linker='NetBSD (a.out) ld.so'
  2255. else
  2256. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
  2257. soname_spec='${libname}${release}${shared_ext}$major'
  2258. dynamic_linker='NetBSD ld.elf_so'
  2259. fi
  2260. shlibpath_var=LD_LIBRARY_PATH
  2261. shlibpath_overrides_runpath=yes
  2262. hardcode_into_libs=yes
  2263. ;;
  2264. newsos6)
  2265. version_type=linux
  2266. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  2267. shlibpath_var=LD_LIBRARY_PATH
  2268. shlibpath_overrides_runpath=yes
  2269. ;;
  2270. nto-qnx*)
  2271. version_type=linux
  2272. need_lib_prefix=no
  2273. need_version=no
  2274. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  2275. soname_spec='${libname}${release}${shared_ext}$major'
  2276. shlibpath_var=LD_LIBRARY_PATH
  2277. shlibpath_overrides_runpath=yes
  2278. ;;
  2279. openbsd*)
  2280. version_type=sunos
  2281. sys_lib_dlsearch_path_spec="/usr/lib"
  2282. need_lib_prefix=no
  2283. # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
  2284. case $host_os in
  2285. openbsd3.3 | openbsd3.3.*) need_version=yes ;;
  2286. *) need_version=no ;;
  2287. esac
  2288. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
  2289. finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
  2290. shlibpath_var=LD_LIBRARY_PATH
  2291. if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
  2292. case $host_os in
  2293. openbsd2.[[89]] | openbsd2.[[89]].*)
  2294. shlibpath_overrides_runpath=no
  2295. ;;
  2296. *)
  2297. shlibpath_overrides_runpath=yes
  2298. ;;
  2299. esac
  2300. else
  2301. shlibpath_overrides_runpath=yes
  2302. fi
  2303. ;;
  2304. os2*)
  2305. libname_spec='$name'
  2306. shrext_cmds=".dll"
  2307. need_lib_prefix=no
  2308. library_names_spec='$libname${shared_ext} $libname.a'
  2309. dynamic_linker='OS/2 ld.exe'
  2310. shlibpath_var=LIBPATH
  2311. ;;
  2312. osf3* | osf4* | osf5*)
  2313. version_type=osf
  2314. need_lib_prefix=no
  2315. need_version=no
  2316. soname_spec='${libname}${release}${shared_ext}$major'
  2317. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  2318. shlibpath_var=LD_LIBRARY_PATH
  2319. sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
  2320. sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
  2321. ;;
  2322. rdos*)
  2323. dynamic_linker=no
  2324. ;;
  2325. solaris*)
  2326. version_type=linux
  2327. need_lib_prefix=no
  2328. need_version=no
  2329. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  2330. soname_spec='${libname}${release}${shared_ext}$major'
  2331. shlibpath_var=LD_LIBRARY_PATH
  2332. shlibpath_overrides_runpath=yes
  2333. hardcode_into_libs=yes
  2334. # ldd complains unless libraries are executable
  2335. postinstall_cmds='chmod +x $lib'
  2336. ;;
  2337. sunos4*)
  2338. version_type=sunos
  2339. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
  2340. finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
  2341. shlibpath_var=LD_LIBRARY_PATH
  2342. shlibpath_overrides_runpath=yes
  2343. if test "$with_gnu_ld" = yes; then
  2344. need_lib_prefix=no
  2345. fi
  2346. need_version=yes
  2347. ;;
  2348. sysv4 | sysv4.3*)
  2349. version_type=linux
  2350. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  2351. soname_spec='${libname}${release}${shared_ext}$major'
  2352. shlibpath_var=LD_LIBRARY_PATH
  2353. case $host_vendor in
  2354. sni)
  2355. shlibpath_overrides_runpath=no
  2356. need_lib_prefix=no
  2357. export_dynamic_flag_spec='${wl}-Blargedynsym'
  2358. runpath_var=LD_RUN_PATH
  2359. ;;
  2360. siemens)
  2361. need_lib_prefix=no
  2362. ;;
  2363. motorola)
  2364. need_lib_prefix=no
  2365. need_version=no
  2366. shlibpath_overrides_runpath=no
  2367. sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
  2368. ;;
  2369. esac
  2370. ;;
  2371. sysv4*MP*)
  2372. if test -d /usr/nec ;then
  2373. version_type=linux
  2374. library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
  2375. soname_spec='$libname${shared_ext}.$major'
  2376. shlibpath_var=LD_LIBRARY_PATH
  2377. fi
  2378. ;;
  2379. sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
  2380. version_type=freebsd-elf
  2381. need_lib_prefix=no
  2382. need_version=no
  2383. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
  2384. soname_spec='${libname}${release}${shared_ext}$major'
  2385. shlibpath_var=LD_LIBRARY_PATH
  2386. hardcode_into_libs=yes
  2387. if test "$with_gnu_ld" = yes; then
  2388. sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
  2389. shlibpath_overrides_runpath=no
  2390. else
  2391. sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
  2392. shlibpath_overrides_runpath=yes
  2393. case $host_os in
  2394. sco3.2v5*)
  2395. sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
  2396. ;;
  2397. esac
  2398. fi
  2399. sys_lib_dlsearch_path_spec='/usr/lib'
  2400. ;;
  2401. uts4*)
  2402. version_type=linux
  2403. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
  2404. soname_spec='${libname}${release}${shared_ext}$major'
  2405. shlibpath_var=LD_LIBRARY_PATH
  2406. ;;
  2407. *)
  2408. dynamic_linker=no
  2409. ;;
  2410. esac
  2411. AC_MSG_RESULT([$dynamic_linker])
  2412. test "$dynamic_linker" = no && can_build_shared=no
  2413. variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
  2414. if test "$GCC" = yes; then
  2415. variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
  2416. fi
  2417. ])# AC_LIBTOOL_SYS_DYNAMIC_LINKER
  2418. # _LT_AC_TAGCONFIG
  2419. # ----------------
  2420. AC_DEFUN([_LT_AC_TAGCONFIG],
  2421. [AC_REQUIRE([LT_AC_PROG_SED])dnl
  2422. AC_ARG_WITH([tags],
  2423. [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@],
  2424. [include additional configurations @<:@automatic@:>@])],
  2425. [tagnames="$withval"])
  2426. if test -f "$ltmain" && test -n "$tagnames"; then
  2427. if test ! -f "${ofile}"; then
  2428. AC_MSG_WARN([output file `$ofile' does not exist])
  2429. fi
  2430. if test -z "$LTCC"; then
  2431. eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
  2432. if test -z "$LTCC"; then
  2433. AC_MSG_WARN([output file `$ofile' does not look like a libtool script])
  2434. else
  2435. AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile'])
  2436. fi
  2437. fi
  2438. if test -z "$LTCFLAGS"; then
  2439. eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`"
  2440. fi
  2441. # Extract list of available tagged configurations in $ofile.
  2442. # Note that this assumes the entire list is on one line.
  2443. available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
  2444. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
  2445. for tagname in $tagnames; do
  2446. IFS="$lt_save_ifs"
  2447. # Check whether tagname contains only valid characters
  2448. case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in
  2449. "") ;;
  2450. *) AC_MSG_ERROR([invalid tag name: $tagname])
  2451. ;;
  2452. esac
  2453. if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
  2454. then
  2455. AC_MSG_ERROR([tag name \"$tagname\" already exists])
  2456. fi
  2457. # Update the list of available tags.
  2458. if test -n "$tagname"; then
  2459. echo appending configuration tag \"$tagname\" to $ofile
  2460. case $tagname in
  2461. CXX)
  2462. if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
  2463. ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
  2464. (test "X$CXX" != "Xg++"))) ; then
  2465. AC_LIBTOOL_LANG_CXX_CONFIG
  2466. else
  2467. tagname=""
  2468. fi
  2469. ;;
  2470. F77)
  2471. if test -n "$F77" && test "X$F77" != "Xno"; then
  2472. AC_LIBTOOL_LANG_F77_CONFIG
  2473. else
  2474. tagname=""
  2475. fi
  2476. ;;
  2477. GCJ)
  2478. if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
  2479. AC_LIBTOOL_LANG_GCJ_CONFIG
  2480. else
  2481. tagname=""
  2482. fi
  2483. ;;
  2484. RC)
  2485. AC_LIBTOOL_LANG_RC_CONFIG
  2486. ;;
  2487. *)
  2488. AC_MSG_ERROR([Unsupported tag name: $tagname])
  2489. ;;
  2490. esac
  2491. # Append the new tag name to the list of available tags.
  2492. if test -n "$tagname" ; then
  2493. available_tags="$available_tags $tagname"
  2494. fi
  2495. fi
  2496. done
  2497. IFS="$lt_save_ifs"
  2498. # Now substitute the updated list of available tags.
  2499. if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
  2500. mv "${ofile}T" "$ofile"
  2501. chmod +x "$ofile"
  2502. else
  2503. rm -f "${ofile}T"
  2504. AC_MSG_ERROR([unable to update list of available tagged configurations.])
  2505. fi
  2506. fi
  2507. ])# _LT_AC_TAGCONFIG
  2508. # AC_LIBTOOL_DLOPEN
  2509. # -----------------
  2510. # enable checks for dlopen support
  2511. AC_DEFUN([AC_LIBTOOL_DLOPEN],
  2512. [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])
  2513. ])# AC_LIBTOOL_DLOPEN
  2514. # AC_LIBTOOL_WIN32_DLL
  2515. # --------------------
  2516. # declare package support for building win32 DLLs
  2517. AC_DEFUN([AC_LIBTOOL_WIN32_DLL],
  2518. [AC_BEFORE([$0], [AC_LIBTOOL_SETUP])
  2519. ])# AC_LIBTOOL_WIN32_DLL
  2520. # AC_ENABLE_SHARED([DEFAULT])
  2521. # ---------------------------
  2522. # implement the --enable-shared flag
  2523. # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
  2524. AC_DEFUN([AC_ENABLE_SHARED],
  2525. [define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
  2526. AC_ARG_ENABLE([shared],
  2527. [AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
  2528. [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])],
  2529. [p=${PACKAGE-default}
  2530. case $enableval in
  2531. yes) enable_shared=yes ;;
  2532. no) enable_shared=no ;;
  2533. *)
  2534. enable_shared=no
  2535. # Look at the argument we got. We use all the common list separators.
  2536. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
  2537. for pkg in $enableval; do
  2538. IFS="$lt_save_ifs"
  2539. if test "X$pkg" = "X$p"; then
  2540. enable_shared=yes
  2541. fi
  2542. done
  2543. IFS="$lt_save_ifs"
  2544. ;;
  2545. esac],
  2546. [enable_shared=]AC_ENABLE_SHARED_DEFAULT)
  2547. ])# AC_ENABLE_SHARED
  2548. # AC_DISABLE_SHARED
  2549. # -----------------
  2550. # set the default shared flag to --disable-shared
  2551. AC_DEFUN([AC_DISABLE_SHARED],
  2552. [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
  2553. AC_ENABLE_SHARED(no)
  2554. ])# AC_DISABLE_SHARED
  2555. # AC_ENABLE_STATIC([DEFAULT])
  2556. # ---------------------------
  2557. # implement the --enable-static flag
  2558. # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
  2559. AC_DEFUN([AC_ENABLE_STATIC],
  2560. [define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
  2561. AC_ARG_ENABLE([static],
  2562. [AC_HELP_STRING([--enable-static@<:@=PKGS@:>@],
  2563. [build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])],
  2564. [p=${PACKAGE-default}
  2565. case $enableval in
  2566. yes) enable_static=yes ;;
  2567. no) enable_static=no ;;
  2568. *)
  2569. enable_static=no
  2570. # Look at the argument we got. We use all the common list separators.
  2571. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
  2572. for pkg in $enableval; do
  2573. IFS="$lt_save_ifs"
  2574. if test "X$pkg" = "X$p"; then
  2575. enable_static=yes
  2576. fi
  2577. done
  2578. IFS="$lt_save_ifs"
  2579. ;;
  2580. esac],
  2581. [enable_static=]AC_ENABLE_STATIC_DEFAULT)
  2582. ])# AC_ENABLE_STATIC
  2583. # AC_DISABLE_STATIC
  2584. # -----------------
  2585. # set the default static flag to --disable-static
  2586. AC_DEFUN([AC_DISABLE_STATIC],
  2587. [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
  2588. AC_ENABLE_STATIC(no)
  2589. ])# AC_DISABLE_STATIC
  2590. # AC_ENABLE_FAST_INSTALL([DEFAULT])
  2591. # ---------------------------------
  2592. # implement the --enable-fast-install flag
  2593. # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
  2594. AC_DEFUN([AC_ENABLE_FAST_INSTALL],
  2595. [define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
  2596. AC_ARG_ENABLE([fast-install],
  2597. [AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
  2598. [optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
  2599. [p=${PACKAGE-default}
  2600. case $enableval in
  2601. yes) enable_fast_install=yes ;;
  2602. no) enable_fast_install=no ;;
  2603. *)
  2604. enable_fast_install=no
  2605. # Look at the argument we got. We use all the common list separators.
  2606. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
  2607. for pkg in $enableval; do
  2608. IFS="$lt_save_ifs"
  2609. if test "X$pkg" = "X$p"; then
  2610. enable_fast_install=yes
  2611. fi
  2612. done
  2613. IFS="$lt_save_ifs"
  2614. ;;
  2615. esac],
  2616. [enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT)
  2617. ])# AC_ENABLE_FAST_INSTALL
  2618. # AC_DISABLE_FAST_INSTALL
  2619. # -----------------------
  2620. # set the default to --disable-fast-install
  2621. AC_DEFUN([AC_DISABLE_FAST_INSTALL],
  2622. [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
  2623. AC_ENABLE_FAST_INSTALL(no)
  2624. ])# AC_DISABLE_FAST_INSTALL
  2625. # AC_LIBTOOL_PICMODE([MODE])
  2626. # --------------------------
  2627. # implement the --with-pic flag
  2628. # MODE is either `yes' or `no'. If omitted, it defaults to `both'.
  2629. AC_DEFUN([AC_LIBTOOL_PICMODE],
  2630. [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
  2631. pic_mode=ifelse($#,1,$1,default)
  2632. ])# AC_LIBTOOL_PICMODE
  2633. # AC_PROG_EGREP
  2634. # -------------
  2635. # This is predefined starting with Autoconf 2.54, so this conditional
  2636. # definition can be removed once we require Autoconf 2.54 or later.
  2637. m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP],
  2638. [AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep],
  2639. [if echo a | (grep -E '(a|b)') >/dev/null 2>&1
  2640. then ac_cv_prog_egrep='grep -E'
  2641. else ac_cv_prog_egrep='egrep'
  2642. fi])
  2643. EGREP=$ac_cv_prog_egrep
  2644. AC_SUBST([EGREP])
  2645. ])])
  2646. # AC_PATH_TOOL_PREFIX
  2647. # -------------------
  2648. # find a file program which can recognize shared library
  2649. AC_DEFUN([AC_PATH_TOOL_PREFIX],
  2650. [AC_REQUIRE([AC_PROG_EGREP])dnl
  2651. AC_MSG_CHECKING([for $1])
  2652. AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
  2653. [case $MAGIC_CMD in
  2654. [[\\/*] | ?:[\\/]*])
  2655. lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
  2656. ;;
  2657. *)
  2658. lt_save_MAGIC_CMD="$MAGIC_CMD"
  2659. lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
  2660. dnl $ac_dummy forces splitting on constant user-supplied paths.
  2661. dnl POSIX.2 word splitting is done only on the output of word expansions,
  2662. dnl not every word. This closes a longstanding sh security hole.
  2663. ac_dummy="ifelse([$2], , $PATH, [$2])"
  2664. for ac_dir in $ac_dummy; do
  2665. IFS="$lt_save_ifs"
  2666. test -z "$ac_dir" && ac_dir=.
  2667. if test -f $ac_dir/$1; then
  2668. lt_cv_path_MAGIC_CMD="$ac_dir/$1"
  2669. if test -n "$file_magic_test_file"; then
  2670. case $deplibs_check_method in
  2671. "file_magic "*)
  2672. file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
  2673. MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
  2674. if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
  2675. $EGREP "$file_magic_regex" > /dev/null; then
  2676. :
  2677. else
  2678. cat <<EOF 1>&2
  2679. *** Warning: the command libtool uses to detect shared libraries,
  2680. *** $file_magic_cmd, produces output that libtool cannot recognize.
  2681. *** The result is that libtool may fail to recognize shared libraries
  2682. *** as such. This will affect the creation of libtool libraries that
  2683. *** depend on shared libraries, but programs linked with such libtool
  2684. *** libraries will work regardless of this problem. Nevertheless, you
  2685. *** may want to report the problem to your system manager and/or to
  2686. *** bug-libtool@gnu.org
  2687. EOF
  2688. fi ;;
  2689. esac
  2690. fi
  2691. break
  2692. fi
  2693. done
  2694. IFS="$lt_save_ifs"
  2695. MAGIC_CMD="$lt_save_MAGIC_CMD"
  2696. ;;
  2697. esac])
  2698. MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
  2699. if test -n "$MAGIC_CMD"; then
  2700. AC_MSG_RESULT($MAGIC_CMD)
  2701. else
  2702. AC_MSG_RESULT(no)
  2703. fi
  2704. ])# AC_PATH_TOOL_PREFIX
  2705. # AC_PATH_MAGIC
  2706. # -------------
  2707. # find a file program which can recognize a shared library
  2708. AC_DEFUN([AC_PATH_MAGIC],
  2709. [AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
  2710. if test -z "$lt_cv_path_MAGIC_CMD"; then
  2711. if test -n "$ac_tool_prefix"; then
  2712. AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
  2713. else
  2714. MAGIC_CMD=:
  2715. fi
  2716. fi
  2717. ])# AC_PATH_MAGIC
  2718. # AC_PROG_LD
  2719. # ----------
  2720. # find the pathname to the GNU or non-GNU linker
  2721. AC_DEFUN([AC_PROG_LD],
  2722. [AC_ARG_WITH([gnu-ld],
  2723. [AC_HELP_STRING([--with-gnu-ld],
  2724. [assume the C compiler uses GNU ld @<:@default=no@:>@])],
  2725. [test "$withval" = no || with_gnu_ld=yes],
  2726. [with_gnu_ld=no])
  2727. AC_REQUIRE([LT_AC_PROG_SED])dnl
  2728. AC_REQUIRE([AC_PROG_CC])dnl
  2729. AC_REQUIRE([AC_CANONICAL_HOST])dnl
  2730. AC_REQUIRE([AC_CANONICAL_BUILD])dnl
  2731. ac_prog=ld
  2732. if test "$GCC" = yes; then
  2733. # Check if gcc -print-prog-name=ld gives a path.
  2734. AC_MSG_CHECKING([for ld used by $CC])
  2735. case $host in
  2736. *-*-mingw*)
  2737. # gcc leaves a trailing carriage return which upsets mingw
  2738. ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
  2739. *)
  2740. ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
  2741. esac
  2742. case $ac_prog in
  2743. # Accept absolute paths.
  2744. [[\\/]]* | ?:[[\\/]]*)
  2745. re_direlt='/[[^/]][[^/]]*/\.\./'
  2746. # Canonicalize the pathname of ld
  2747. ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
  2748. while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
  2749. ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
  2750. done
  2751. test -z "$LD" && LD="$ac_prog"
  2752. ;;
  2753. "")
  2754. # If it fails, then pretend we aren't using GCC.
  2755. ac_prog=ld
  2756. ;;
  2757. *)
  2758. # If it is relative, then search for the first ld in PATH.
  2759. with_gnu_ld=unknown
  2760. ;;
  2761. esac
  2762. elif test "$with_gnu_ld" = yes; then
  2763. AC_MSG_CHECKING([for GNU ld])
  2764. else
  2765. AC_MSG_CHECKING([for non-GNU ld])
  2766. fi
  2767. AC_CACHE_VAL(lt_cv_path_LD,
  2768. [if test -z "$LD"; then
  2769. lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
  2770. for ac_dir in $PATH; do
  2771. IFS="$lt_save_ifs"
  2772. test -z "$ac_dir" && ac_dir=.
  2773. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
  2774. lt_cv_path_LD="$ac_dir/$ac_prog"
  2775. # Check to see if the program is GNU ld. I'd rather use --version,
  2776. # but apparently some variants of GNU ld only accept -v.
  2777. # Break only if it was the GNU/non-GNU ld that we prefer.
  2778. case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
  2779. *GNU* | *'with BFD'*)
  2780. test "$with_gnu_ld" != no && break
  2781. ;;
  2782. *)
  2783. test "$with_gnu_ld" != yes && break
  2784. ;;
  2785. esac
  2786. fi
  2787. done
  2788. IFS="$lt_save_ifs"
  2789. else
  2790. lt_cv_path_LD="$LD" # Let the user override the test with a path.
  2791. fi])
  2792. LD="$lt_cv_path_LD"
  2793. if test -n "$LD"; then
  2794. AC_MSG_RESULT($LD)
  2795. else
  2796. AC_MSG_RESULT(no)
  2797. fi
  2798. test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
  2799. AC_PROG_LD_GNU
  2800. ])# AC_PROG_LD
  2801. # AC_PROG_LD_GNU
  2802. # --------------
  2803. AC_DEFUN([AC_PROG_LD_GNU],
  2804. [AC_REQUIRE([AC_PROG_EGREP])dnl
  2805. AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
  2806. [# I'd rather use --version here, but apparently some GNU lds only accept -v.
  2807. case `$LD -v 2>&1 </dev/null` in
  2808. *GNU* | *'with BFD'*)
  2809. lt_cv_prog_gnu_ld=yes
  2810. ;;
  2811. *)
  2812. lt_cv_prog_gnu_ld=no
  2813. ;;
  2814. esac])
  2815. with_gnu_ld=$lt_cv_prog_gnu_ld
  2816. ])# AC_PROG_LD_GNU
  2817. # AC_PROG_LD_RELOAD_FLAG
  2818. # ----------------------
  2819. # find reload flag for linker
  2820. # -- PORTME Some linkers may need a different reload flag.
  2821. AC_DEFUN([AC_PROG_LD_RELOAD_FLAG],
  2822. [AC_CACHE_CHECK([for $LD option to reload object files],
  2823. lt_cv_ld_reload_flag,
  2824. [lt_cv_ld_reload_flag='-r'])
  2825. reload_flag=$lt_cv_ld_reload_flag
  2826. case $reload_flag in
  2827. "" | " "*) ;;
  2828. *) reload_flag=" $reload_flag" ;;
  2829. esac
  2830. reload_cmds='$LD$reload_flag -o $output$reload_objs'
  2831. case $host_os in
  2832. darwin*)
  2833. if test "$GCC" = yes; then
  2834. reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
  2835. else
  2836. reload_cmds='$LD$reload_flag -o $output$reload_objs'
  2837. fi
  2838. ;;
  2839. esac
  2840. ])# AC_PROG_LD_RELOAD_FLAG
  2841. # AC_DEPLIBS_CHECK_METHOD
  2842. # -----------------------
  2843. # how to check for library dependencies
  2844. # -- PORTME fill in with the dynamic library characteristics
  2845. AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
  2846. [AC_CACHE_CHECK([how to recognize dependent libraries],
  2847. lt_cv_deplibs_check_method,
  2848. [lt_cv_file_magic_cmd='$MAGIC_CMD'
  2849. lt_cv_file_magic_test_file=
  2850. lt_cv_deplibs_check_method='unknown'
  2851. # Need to set the preceding variable on all platforms that support
  2852. # interlibrary dependencies.
  2853. # 'none' -- dependencies not supported.
  2854. # `unknown' -- same as none, but documents that we really don't know.
  2855. # 'pass_all' -- all dependencies passed with no checks.
  2856. # 'test_compile' -- check by making test program.
  2857. # 'file_magic [[regex]]' -- check by looking for files in library path
  2858. # which responds to the $file_magic_cmd with a given extended regex.
  2859. # If you have `file' or equivalent on your system and you're not sure
  2860. # whether `pass_all' will *always* work, you probably want this one.
  2861. case $host_os in
  2862. aix4* | aix5*)
  2863. lt_cv_deplibs_check_method=pass_all
  2864. ;;
  2865. beos*)
  2866. lt_cv_deplibs_check_method=pass_all
  2867. ;;
  2868. bsdi[[45]]*)
  2869. lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
  2870. lt_cv_file_magic_cmd='/usr/bin/file -L'
  2871. lt_cv_file_magic_test_file=/shlib/libc.so
  2872. ;;
  2873. cygwin*)
  2874. # func_win32_libid is a shell function defined in ltmain.sh
  2875. lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
  2876. lt_cv_file_magic_cmd='func_win32_libid'
  2877. ;;
  2878. mingw* | pw32*)
  2879. # Base MSYS/MinGW do not provide the 'file' command needed by
  2880. # func_win32_libid shell function, so use a weaker test based on 'objdump',
  2881. # unless we find 'file', for example because we are cross-compiling.
  2882. if ( file / ) >/dev/null 2>&1; then
  2883. lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
  2884. lt_cv_file_magic_cmd='func_win32_libid'
  2885. else
  2886. lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
  2887. lt_cv_file_magic_cmd='$OBJDUMP -f'
  2888. fi
  2889. ;;
  2890. darwin* | rhapsody*)
  2891. lt_cv_deplibs_check_method=pass_all
  2892. ;;
  2893. freebsd* | dragonfly*)
  2894. if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
  2895. case $host_cpu in
  2896. i*86 )
  2897. # Not sure whether the presence of OpenBSD here was a mistake.
  2898. # Let's accept both of them until this is cleared up.
  2899. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
  2900. lt_cv_file_magic_cmd=/usr/bin/file
  2901. lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
  2902. ;;
  2903. esac
  2904. else
  2905. lt_cv_deplibs_check_method=pass_all
  2906. fi
  2907. ;;
  2908. gnu*)
  2909. lt_cv_deplibs_check_method=pass_all
  2910. ;;
  2911. hpux10.20* | hpux11*)
  2912. lt_cv_file_magic_cmd=/usr/bin/file
  2913. case $host_cpu in
  2914. ia64*)
  2915. lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
  2916. lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
  2917. ;;
  2918. hppa*64*)
  2919. [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]']
  2920. lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
  2921. ;;
  2922. *)
  2923. lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
  2924. lt_cv_file_magic_test_file=/usr/lib/libc.sl
  2925. ;;
  2926. esac
  2927. ;;
  2928. interix[[3-9]]*)
  2929. # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
  2930. lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
  2931. ;;
  2932. irix5* | irix6* | nonstopux*)
  2933. case $LD in
  2934. *-32|*"-32 ") libmagic=32-bit;;
  2935. *-n32|*"-n32 ") libmagic=N32;;
  2936. *-64|*"-64 ") libmagic=64-bit;;
  2937. *) libmagic=never-match;;
  2938. esac
  2939. lt_cv_deplibs_check_method=pass_all
  2940. ;;
  2941. # This must be Linux ELF.
  2942. linux* | k*bsd*-gnu)
  2943. lt_cv_deplibs_check_method=pass_all
  2944. ;;
  2945. netbsd*)
  2946. if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
  2947. lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
  2948. else
  2949. lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
  2950. fi
  2951. ;;
  2952. newos6*)
  2953. lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
  2954. lt_cv_file_magic_cmd=/usr/bin/file
  2955. lt_cv_file_magic_test_file=/usr/lib/libnls.so
  2956. ;;
  2957. nto-qnx*)
  2958. lt_cv_deplibs_check_method=unknown
  2959. ;;
  2960. openbsd*)
  2961. if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
  2962. lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
  2963. else
  2964. lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
  2965. fi
  2966. ;;
  2967. osf3* | osf4* | osf5*)
  2968. lt_cv_deplibs_check_method=pass_all
  2969. ;;
  2970. rdos*)
  2971. lt_cv_deplibs_check_method=pass_all
  2972. ;;
  2973. solaris*)
  2974. lt_cv_deplibs_check_method=pass_all
  2975. ;;
  2976. sysv4 | sysv4.3*)
  2977. case $host_vendor in
  2978. motorola)
  2979. 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]]'
  2980. lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
  2981. ;;
  2982. ncr)
  2983. lt_cv_deplibs_check_method=pass_all
  2984. ;;
  2985. sequent)
  2986. lt_cv_file_magic_cmd='/bin/file'
  2987. lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
  2988. ;;
  2989. sni)
  2990. lt_cv_file_magic_cmd='/bin/file'
  2991. lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
  2992. lt_cv_file_magic_test_file=/lib/libc.so
  2993. ;;
  2994. siemens)
  2995. lt_cv_deplibs_check_method=pass_all
  2996. ;;
  2997. pc)
  2998. lt_cv_deplibs_check_method=pass_all
  2999. ;;
  3000. esac
  3001. ;;
  3002. sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
  3003. lt_cv_deplibs_check_method=pass_all
  3004. ;;
  3005. esac
  3006. ])
  3007. file_magic_cmd=$lt_cv_file_magic_cmd
  3008. deplibs_check_method=$lt_cv_deplibs_check_method
  3009. test -z "$deplibs_check_method" && deplibs_check_method=unknown
  3010. ])# AC_DEPLIBS_CHECK_METHOD
  3011. # AC_PROG_NM
  3012. # ----------
  3013. # find the pathname to a BSD-compatible name lister
  3014. AC_DEFUN([AC_PROG_NM],
  3015. [AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM,
  3016. [if test -n "$NM"; then
  3017. # Let the user override the test.
  3018. lt_cv_path_NM="$NM"
  3019. else
  3020. lt_nm_to_check="${ac_tool_prefix}nm"
  3021. if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
  3022. lt_nm_to_check="$lt_nm_to_check nm"
  3023. fi
  3024. for lt_tmp_nm in $lt_nm_to_check; do
  3025. lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
  3026. for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
  3027. IFS="$lt_save_ifs"
  3028. test -z "$ac_dir" && ac_dir=.
  3029. tmp_nm="$ac_dir/$lt_tmp_nm"
  3030. if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
  3031. # Check to see if the nm accepts a BSD-compat flag.
  3032. # Adding the `sed 1q' prevents false positives on HP-UX, which says:
  3033. # nm: unknown option "B" ignored
  3034. # Tru64's nm complains that /dev/null is an invalid object file
  3035. case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
  3036. */dev/null* | *'Invalid file or object type'*)
  3037. lt_cv_path_NM="$tmp_nm -B"
  3038. break
  3039. ;;
  3040. *)
  3041. case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
  3042. */dev/null*)
  3043. lt_cv_path_NM="$tmp_nm -p"
  3044. break
  3045. ;;
  3046. *)
  3047. lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
  3048. continue # so that we can try to find one that supports BSD flags
  3049. ;;
  3050. esac
  3051. ;;
  3052. esac
  3053. fi
  3054. done
  3055. IFS="$lt_save_ifs"
  3056. done
  3057. test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
  3058. fi])
  3059. NM="$lt_cv_path_NM"
  3060. ])# AC_PROG_NM
  3061. # AC_CHECK_LIBM
  3062. # -------------
  3063. # check for math library
  3064. AC_DEFUN([AC_CHECK_LIBM],
  3065. [AC_REQUIRE([AC_CANONICAL_HOST])dnl
  3066. LIBM=
  3067. case $host in
  3068. *-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
  3069. # These system don't have libm, or don't need it
  3070. ;;
  3071. *-ncr-sysv4.3*)
  3072. AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
  3073. AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
  3074. ;;
  3075. *)
  3076. AC_CHECK_LIB(m, cos, LIBM="-lm")
  3077. ;;
  3078. esac
  3079. ])# AC_CHECK_LIBM
  3080. # AC_LIBLTDL_CONVENIENCE([DIRECTORY])
  3081. # -----------------------------------
  3082. # sets LIBLTDL to the link flags for the libltdl convenience library and
  3083. # LTDLINCL to the include flags for the libltdl header and adds
  3084. # --enable-ltdl-convenience to the configure arguments. Note that
  3085. # AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided,
  3086. # it is assumed to be `libltdl'. LIBLTDL will be prefixed with
  3087. # '${top_builddir}/' and LTDLINCL will be prefixed with '${top_srcdir}/'
  3088. # (note the single quotes!). If your package is not flat and you're not
  3089. # using automake, define top_builddir and top_srcdir appropriately in
  3090. # the Makefiles.
  3091. AC_DEFUN([AC_LIBLTDL_CONVENIENCE],
  3092. [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
  3093. case $enable_ltdl_convenience in
  3094. no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;;
  3095. "") enable_ltdl_convenience=yes
  3096. ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
  3097. esac
  3098. LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la
  3099. LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
  3100. # For backwards non-gettext consistent compatibility...
  3101. INCLTDL="$LTDLINCL"
  3102. ])# AC_LIBLTDL_CONVENIENCE
  3103. # AC_LIBLTDL_INSTALLABLE([DIRECTORY])
  3104. # -----------------------------------
  3105. # sets LIBLTDL to the link flags for the libltdl installable library and
  3106. # LTDLINCL to the include flags for the libltdl header and adds
  3107. # --enable-ltdl-install to the configure arguments. Note that
  3108. # AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided,
  3109. # and an installed libltdl is not found, it is assumed to be `libltdl'.
  3110. # LIBLTDL will be prefixed with '${top_builddir}/'# and LTDLINCL with
  3111. # '${top_srcdir}/' (note the single quotes!). If your package is not
  3112. # flat and you're not using automake, define top_builddir and top_srcdir
  3113. # appropriately in the Makefiles.
  3114. # In the future, this macro may have to be called after AC_PROG_LIBTOOL.
  3115. AC_DEFUN([AC_LIBLTDL_INSTALLABLE],
  3116. [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
  3117. AC_CHECK_LIB(ltdl, lt_dlinit,
  3118. [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no],
  3119. [if test x"$enable_ltdl_install" = xno; then
  3120. AC_MSG_WARN([libltdl not installed, but installation disabled])
  3121. else
  3122. enable_ltdl_install=yes
  3123. fi
  3124. ])
  3125. if test x"$enable_ltdl_install" = x"yes"; then
  3126. ac_configure_args="$ac_configure_args --enable-ltdl-install"
  3127. LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la
  3128. LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
  3129. else
  3130. ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
  3131. LIBLTDL="-lltdl"
  3132. LTDLINCL=
  3133. fi
  3134. # For backwards non-gettext consistent compatibility...
  3135. INCLTDL="$LTDLINCL"
  3136. ])# AC_LIBLTDL_INSTALLABLE
  3137. # AC_LIBTOOL_CXX
  3138. # --------------
  3139. # enable support for C++ libraries
  3140. AC_DEFUN([AC_LIBTOOL_CXX],
  3141. [AC_REQUIRE([_LT_AC_LANG_CXX])
  3142. ])# AC_LIBTOOL_CXX
  3143. # _LT_AC_LANG_CXX
  3144. # ---------------
  3145. AC_DEFUN([_LT_AC_LANG_CXX],
  3146. [AC_REQUIRE([AC_PROG_CXX])
  3147. AC_REQUIRE([_LT_AC_PROG_CXXCPP])
  3148. _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX])
  3149. ])# _LT_AC_LANG_CXX
  3150. # _LT_AC_PROG_CXXCPP
  3151. # ------------------
  3152. AC_DEFUN([_LT_AC_PROG_CXXCPP],
  3153. [
  3154. AC_REQUIRE([AC_PROG_CXX])
  3155. if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
  3156. ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
  3157. (test "X$CXX" != "Xg++"))) ; then
  3158. AC_PROG_CXXCPP
  3159. fi
  3160. ])# _LT_AC_PROG_CXXCPP
  3161. # AC_LIBTOOL_F77
  3162. # --------------
  3163. # enable support for Fortran 77 libraries
  3164. AC_DEFUN([AC_LIBTOOL_F77],
  3165. [AC_REQUIRE([_LT_AC_LANG_F77])
  3166. ])# AC_LIBTOOL_F77
  3167. # _LT_AC_LANG_F77
  3168. # ---------------
  3169. AC_DEFUN([_LT_AC_LANG_F77],
  3170. [AC_REQUIRE([AC_PROG_F77])
  3171. _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77])
  3172. ])# _LT_AC_LANG_F77
  3173. # AC_LIBTOOL_GCJ
  3174. # --------------
  3175. # enable support for GCJ libraries
  3176. AC_DEFUN([AC_LIBTOOL_GCJ],
  3177. [AC_REQUIRE([_LT_AC_LANG_GCJ])
  3178. ])# AC_LIBTOOL_GCJ
  3179. # _LT_AC_LANG_GCJ
  3180. # ---------------
  3181. AC_DEFUN([_LT_AC_LANG_GCJ],
  3182. [AC_PROVIDE_IFELSE([AC_PROG_GCJ],[],
  3183. [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[],
  3184. [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[],
  3185. [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])],
  3186. [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])],
  3187. [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])])
  3188. _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ])
  3189. ])# _LT_AC_LANG_GCJ
  3190. # AC_LIBTOOL_RC
  3191. # -------------
  3192. # enable support for Windows resource files
  3193. AC_DEFUN([AC_LIBTOOL_RC],
  3194. [AC_REQUIRE([LT_AC_PROG_RC])
  3195. _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC])
  3196. ])# AC_LIBTOOL_RC
  3197. # AC_LIBTOOL_LANG_C_CONFIG
  3198. # ------------------------
  3199. # Ensure that the configuration vars for the C compiler are
  3200. # suitably defined. Those variables are subsequently used by
  3201. # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
  3202. AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG])
  3203. AC_DEFUN([_LT_AC_LANG_C_CONFIG],
  3204. [lt_save_CC="$CC"
  3205. AC_LANG_PUSH(C)
  3206. # Source file extension for C test sources.
  3207. ac_ext=c
  3208. # Object file extension for compiled C test sources.
  3209. objext=o
  3210. _LT_AC_TAGVAR(objext, $1)=$objext
  3211. # Code to be used in simple compile tests
  3212. lt_simple_compile_test_code="int some_variable = 0;"
  3213. # Code to be used in simple link tests
  3214. lt_simple_link_test_code='int main(){return(0);}'
  3215. _LT_AC_SYS_COMPILER
  3216. # save warnings/boilerplate of simple test code
  3217. _LT_COMPILER_BOILERPLATE
  3218. _LT_LINKER_BOILERPLATE
  3219. AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
  3220. AC_LIBTOOL_PROG_COMPILER_PIC($1)
  3221. AC_LIBTOOL_PROG_CC_C_O($1)
  3222. AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
  3223. AC_LIBTOOL_PROG_LD_SHLIBS($1)
  3224. AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
  3225. AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
  3226. AC_LIBTOOL_SYS_LIB_STRIP
  3227. AC_LIBTOOL_DLOPEN_SELF
  3228. # Report which library types will actually be built
  3229. AC_MSG_CHECKING([if libtool supports shared libraries])
  3230. AC_MSG_RESULT([$can_build_shared])
  3231. AC_MSG_CHECKING([whether to build shared libraries])
  3232. test "$can_build_shared" = "no" && enable_shared=no
  3233. # On AIX, shared libraries and static libraries use the same namespace, and
  3234. # are all built from PIC.
  3235. case $host_os in
  3236. aix3*)
  3237. test "$enable_shared" = yes && enable_static=no
  3238. if test -n "$RANLIB"; then
  3239. archive_cmds="$archive_cmds~\$RANLIB \$lib"
  3240. postinstall_cmds='$RANLIB $lib'
  3241. fi
  3242. ;;
  3243. aix4* | aix5*)
  3244. if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
  3245. test "$enable_shared" = yes && enable_static=no
  3246. fi
  3247. ;;
  3248. esac
  3249. AC_MSG_RESULT([$enable_shared])
  3250. AC_MSG_CHECKING([whether to build static libraries])
  3251. # Make sure either enable_shared or enable_static is yes.
  3252. test "$enable_shared" = yes || enable_static=yes
  3253. AC_MSG_RESULT([$enable_static])
  3254. AC_LIBTOOL_CONFIG($1)
  3255. AC_LANG_POP
  3256. CC="$lt_save_CC"
  3257. ])# AC_LIBTOOL_LANG_C_CONFIG
  3258. # AC_LIBTOOL_LANG_CXX_CONFIG
  3259. # --------------------------
  3260. # Ensure that the configuration vars for the C compiler are
  3261. # suitably defined. Those variables are subsequently used by
  3262. # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
  3263. AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)])
  3264. AC_DEFUN([_LT_AC_LANG_CXX_CONFIG],
  3265. [AC_LANG_PUSH(C++)
  3266. AC_REQUIRE([AC_PROG_CXX])
  3267. AC_REQUIRE([_LT_AC_PROG_CXXCPP])
  3268. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
  3269. _LT_AC_TAGVAR(allow_undefined_flag, $1)=
  3270. _LT_AC_TAGVAR(always_export_symbols, $1)=no
  3271. _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
  3272. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
  3273. _LT_AC_TAGVAR(hardcode_direct, $1)=no
  3274. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
  3275. _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
  3276. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
  3277. _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
  3278. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
  3279. _LT_AC_TAGVAR(hardcode_automatic, $1)=no
  3280. _LT_AC_TAGVAR(module_cmds, $1)=
  3281. _LT_AC_TAGVAR(module_expsym_cmds, $1)=
  3282. _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
  3283. _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
  3284. _LT_AC_TAGVAR(no_undefined_flag, $1)=
  3285. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
  3286. _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
  3287. # Dependencies to place before and after the object being linked:
  3288. _LT_AC_TAGVAR(predep_objects, $1)=
  3289. _LT_AC_TAGVAR(postdep_objects, $1)=
  3290. _LT_AC_TAGVAR(predeps, $1)=
  3291. _LT_AC_TAGVAR(postdeps, $1)=
  3292. _LT_AC_TAGVAR(compiler_lib_search_path, $1)=
  3293. # Source file extension for C++ test sources.
  3294. ac_ext=cpp
  3295. # Object file extension for compiled C++ test sources.
  3296. objext=o
  3297. _LT_AC_TAGVAR(objext, $1)=$objext
  3298. # Code to be used in simple compile tests
  3299. lt_simple_compile_test_code="int some_variable = 0;"
  3300. # Code to be used in simple link tests
  3301. lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
  3302. # ltmain only uses $CC for tagged configurations so make sure $CC is set.
  3303. _LT_AC_SYS_COMPILER
  3304. # save warnings/boilerplate of simple test code
  3305. _LT_COMPILER_BOILERPLATE
  3306. _LT_LINKER_BOILERPLATE
  3307. # Allow CC to be a program name with arguments.
  3308. lt_save_CC=$CC
  3309. lt_save_LD=$LD
  3310. lt_save_GCC=$GCC
  3311. GCC=$GXX
  3312. lt_save_with_gnu_ld=$with_gnu_ld
  3313. lt_save_path_LD=$lt_cv_path_LD
  3314. if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
  3315. lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
  3316. else
  3317. $as_unset lt_cv_prog_gnu_ld
  3318. fi
  3319. if test -n "${lt_cv_path_LDCXX+set}"; then
  3320. lt_cv_path_LD=$lt_cv_path_LDCXX
  3321. else
  3322. $as_unset lt_cv_path_LD
  3323. fi
  3324. test -z "${LDCXX+set}" || LD=$LDCXX
  3325. CC=${CXX-"c++"}
  3326. compiler=$CC
  3327. _LT_AC_TAGVAR(compiler, $1)=$CC
  3328. _LT_CC_BASENAME([$compiler])
  3329. # We don't want -fno-exception wen compiling C++ code, so set the
  3330. # no_builtin_flag separately
  3331. if test "$GXX" = yes; then
  3332. _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
  3333. else
  3334. _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
  3335. fi
  3336. if test "$GXX" = yes; then
  3337. # Set up default GNU C++ configuration
  3338. AC_PROG_LD
  3339. # Check if GNU C++ uses GNU ld as the underlying linker, since the
  3340. # archiving commands below assume that GNU ld is being used.
  3341. if test "$with_gnu_ld" = yes; then
  3342. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
  3343. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
  3344. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
  3345. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
  3346. # If archive_cmds runs LD, not CC, wlarc should be empty
  3347. # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
  3348. # investigate it a little bit more. (MM)
  3349. wlarc='${wl}'
  3350. # ancient GNU ld didn't support --whole-archive et. al.
  3351. if eval "`$CC -print-prog-name=ld` --help 2>&1" | \
  3352. grep 'no-whole-archive' > /dev/null; then
  3353. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
  3354. else
  3355. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
  3356. fi
  3357. else
  3358. with_gnu_ld=no
  3359. wlarc=
  3360. # A generic and very simple default shared library creation
  3361. # command for GNU C++ for the case where it uses the native
  3362. # linker, instead of GNU ld. If possible, this setting should
  3363. # overridden to take advantage of the native linker features on
  3364. # the platform it is being used on.
  3365. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
  3366. fi
  3367. # Commands to make compiler produce verbose output that lists
  3368. # what "hidden" libraries, object files and flags are used when
  3369. # linking a shared library.
  3370. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
  3371. else
  3372. GXX=no
  3373. with_gnu_ld=no
  3374. wlarc=
  3375. fi
  3376. # PORTME: fill in a description of your system's C++ link characteristics
  3377. AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
  3378. _LT_AC_TAGVAR(ld_shlibs, $1)=yes
  3379. case $host_os in
  3380. aix3*)
  3381. # FIXME: insert proper C++ library support
  3382. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3383. ;;
  3384. aix4* | aix5*)
  3385. if test "$host_cpu" = ia64; then
  3386. # On IA64, the linker does run time linking by default, so we don't
  3387. # have to do anything special.
  3388. aix_use_runtimelinking=no
  3389. exp_sym_flag='-Bexport'
  3390. no_entry_flag=""
  3391. else
  3392. aix_use_runtimelinking=no
  3393. # Test if we are trying to use run time linking or normal
  3394. # AIX style linking. If -brtl is somewhere in LDFLAGS, we
  3395. # need to do runtime linking.
  3396. case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
  3397. for ld_flag in $LDFLAGS; do
  3398. case $ld_flag in
  3399. *-brtl*)
  3400. aix_use_runtimelinking=yes
  3401. break
  3402. ;;
  3403. esac
  3404. done
  3405. ;;
  3406. esac
  3407. exp_sym_flag='-bexport'
  3408. no_entry_flag='-bnoentry'
  3409. fi
  3410. # When large executables or shared objects are built, AIX ld can
  3411. # have problems creating the table of contents. If linking a library
  3412. # or program results in "error TOC overflow" add -mminimal-toc to
  3413. # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
  3414. # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
  3415. _LT_AC_TAGVAR(archive_cmds, $1)=''
  3416. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  3417. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
  3418. _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
  3419. if test "$GXX" = yes; then
  3420. case $host_os in aix4.[[012]]|aix4.[[012]].*)
  3421. # We only want to do this on AIX 4.2 and lower, the check
  3422. # below for broken collect2 doesn't work under 4.3+
  3423. collect2name=`${CC} -print-prog-name=collect2`
  3424. if test -f "$collect2name" && \
  3425. strings "$collect2name" | grep resolve_lib_name >/dev/null
  3426. then
  3427. # We have reworked collect2
  3428. :
  3429. else
  3430. # We have old collect2
  3431. _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
  3432. # It fails to find uninstalled libraries when the uninstalled
  3433. # path is not listed in the libpath. Setting hardcode_minus_L
  3434. # to unsupported forces relinking
  3435. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
  3436. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  3437. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
  3438. fi
  3439. ;;
  3440. esac
  3441. shared_flag='-shared'
  3442. if test "$aix_use_runtimelinking" = yes; then
  3443. shared_flag="$shared_flag "'${wl}-G'
  3444. fi
  3445. else
  3446. # not using gcc
  3447. if test "$host_cpu" = ia64; then
  3448. # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
  3449. # chokes on -Wl,-G. The following line is correct:
  3450. shared_flag='-G'
  3451. else
  3452. if test "$aix_use_runtimelinking" = yes; then
  3453. shared_flag='${wl}-G'
  3454. else
  3455. shared_flag='${wl}-bM:SRE'
  3456. fi
  3457. fi
  3458. fi
  3459. # It seems that -bexpall does not export symbols beginning with
  3460. # underscore (_), so it is better to generate a list of symbols to export.
  3461. _LT_AC_TAGVAR(always_export_symbols, $1)=yes
  3462. if test "$aix_use_runtimelinking" = yes; then
  3463. # Warning - without using the other runtime loading flags (-brtl),
  3464. # -berok will link without error, but may produce a broken library.
  3465. _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
  3466. # Determine the default libpath from the value encoded in an empty executable.
  3467. _LT_AC_SYS_LIBPATH_AIX
  3468. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
  3469. _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
  3470. else
  3471. if test "$host_cpu" = ia64; then
  3472. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
  3473. _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
  3474. _LT_AC_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"
  3475. else
  3476. # Determine the default libpath from the value encoded in an empty executable.
  3477. _LT_AC_SYS_LIBPATH_AIX
  3478. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
  3479. # Warning - without using the other run time loading flags,
  3480. # -berok will link without error, but may produce a broken library.
  3481. _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
  3482. _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
  3483. # Exported symbols can be pulled into shared objects from archives
  3484. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
  3485. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
  3486. # This is similar to how AIX traditionally builds its shared libraries.
  3487. _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
  3488. fi
  3489. fi
  3490. ;;
  3491. beos*)
  3492. if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
  3493. _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
  3494. # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
  3495. # support --undefined. This deserves some investigation. FIXME
  3496. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  3497. else
  3498. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3499. fi
  3500. ;;
  3501. chorus*)
  3502. case $cc_basename in
  3503. *)
  3504. # FIXME: insert proper C++ library support
  3505. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3506. ;;
  3507. esac
  3508. ;;
  3509. cygwin* | mingw* | pw32*)
  3510. # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
  3511. # as there is no search path for DLLs.
  3512. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  3513. _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
  3514. _LT_AC_TAGVAR(always_export_symbols, $1)=no
  3515. _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
  3516. if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
  3517. _LT_AC_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'
  3518. # If the export-symbols file already is a .def file (1st line
  3519. # is EXPORTS), use it as is; otherwise, prepend...
  3520. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
  3521. cp $export_symbols $output_objdir/$soname.def;
  3522. else
  3523. echo EXPORTS > $output_objdir/$soname.def;
  3524. cat $export_symbols >> $output_objdir/$soname.def;
  3525. fi~
  3526. $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'
  3527. else
  3528. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3529. fi
  3530. ;;
  3531. darwin* | rhapsody*)
  3532. case $host_os in
  3533. rhapsody* | darwin1.[[012]])
  3534. _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
  3535. ;;
  3536. *) # Darwin 1.3 on
  3537. if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
  3538. _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
  3539. else
  3540. case ${MACOSX_DEPLOYMENT_TARGET} in
  3541. 10.[[012]])
  3542. _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
  3543. ;;
  3544. 10.*)
  3545. _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
  3546. ;;
  3547. esac
  3548. fi
  3549. ;;
  3550. esac
  3551. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
  3552. _LT_AC_TAGVAR(hardcode_direct, $1)=no
  3553. _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
  3554. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
  3555. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
  3556. _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
  3557. if test "$GXX" = yes ; then
  3558. lt_int_apple_cc_single_mod=no
  3559. output_verbose_link_cmd='echo'
  3560. if $CC -dumpspecs 2>&1 | $EGREP 'single_module' >/dev/null ; then
  3561. lt_int_apple_cc_single_mod=yes
  3562. fi
  3563. if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
  3564. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
  3565. else
  3566. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
  3567. fi
  3568. _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
  3569. # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
  3570. if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
  3571. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
  3572. else
  3573. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
  3574. fi
  3575. _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
  3576. else
  3577. case $cc_basename in
  3578. xlc*)
  3579. output_verbose_link_cmd='echo'
  3580. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
  3581. _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
  3582. # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
  3583. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
  3584. _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
  3585. ;;
  3586. *)
  3587. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3588. ;;
  3589. esac
  3590. fi
  3591. ;;
  3592. dgux*)
  3593. case $cc_basename in
  3594. ec++*)
  3595. # FIXME: insert proper C++ library support
  3596. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3597. ;;
  3598. ghcx*)
  3599. # Green Hills C++ Compiler
  3600. # FIXME: insert proper C++ library support
  3601. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3602. ;;
  3603. *)
  3604. # FIXME: insert proper C++ library support
  3605. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3606. ;;
  3607. esac
  3608. ;;
  3609. freebsd[[12]]*)
  3610. # C++ shared libraries reported to be fairly broken before switch to ELF
  3611. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3612. ;;
  3613. freebsd-elf*)
  3614. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
  3615. ;;
  3616. freebsd* | dragonfly*)
  3617. # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
  3618. # conventions
  3619. _LT_AC_TAGVAR(ld_shlibs, $1)=yes
  3620. ;;
  3621. gnu*)
  3622. ;;
  3623. hpux9*)
  3624. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
  3625. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  3626. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
  3627. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  3628. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
  3629. # but as the default
  3630. # location of the library.
  3631. case $cc_basename in
  3632. CC*)
  3633. # FIXME: insert proper C++ library support
  3634. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3635. ;;
  3636. aCC*)
  3637. _LT_AC_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 $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
  3638. # Commands to make compiler produce verbose output that lists
  3639. # what "hidden" libraries, object files and flags are used when
  3640. # linking a shared library.
  3641. #
  3642. # There doesn't appear to be a way to prevent this compiler from
  3643. # explicitly linking system object files so we need to strip them
  3644. # from the output so that they don't get included in the library
  3645. # dependencies.
  3646. 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; echo $list'
  3647. ;;
  3648. *)
  3649. if test "$GXX" = yes; then
  3650. _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
  3651. else
  3652. # FIXME: insert proper C++ library support
  3653. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3654. fi
  3655. ;;
  3656. esac
  3657. ;;
  3658. hpux10*|hpux11*)
  3659. if test $with_gnu_ld = no; then
  3660. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
  3661. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  3662. case $host_cpu in
  3663. hppa*64*|ia64*) ;;
  3664. *)
  3665. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
  3666. ;;
  3667. esac
  3668. fi
  3669. case $host_cpu in
  3670. hppa*64*|ia64*)
  3671. _LT_AC_TAGVAR(hardcode_direct, $1)=no
  3672. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  3673. ;;
  3674. *)
  3675. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  3676. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
  3677. # but as the default
  3678. # location of the library.
  3679. ;;
  3680. esac
  3681. case $cc_basename in
  3682. CC*)
  3683. # FIXME: insert proper C++ library support
  3684. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3685. ;;
  3686. aCC*)
  3687. case $host_cpu in
  3688. hppa*64*)
  3689. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  3690. ;;
  3691. ia64*)
  3692. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  3693. ;;
  3694. *)
  3695. _LT_AC_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'
  3696. ;;
  3697. esac
  3698. # Commands to make compiler produce verbose output that lists
  3699. # what "hidden" libraries, object files and flags are used when
  3700. # linking a shared library.
  3701. #
  3702. # There doesn't appear to be a way to prevent this compiler from
  3703. # explicitly linking system object files so we need to strip them
  3704. # from the output so that they don't get included in the library
  3705. # dependencies.
  3706. 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; echo $list'
  3707. ;;
  3708. *)
  3709. if test "$GXX" = yes; then
  3710. if test $with_gnu_ld = no; then
  3711. case $host_cpu in
  3712. hppa*64*)
  3713. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  3714. ;;
  3715. ia64*)
  3716. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  3717. ;;
  3718. *)
  3719. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  3720. ;;
  3721. esac
  3722. fi
  3723. else
  3724. # FIXME: insert proper C++ library support
  3725. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3726. fi
  3727. ;;
  3728. esac
  3729. ;;
  3730. interix[[3-9]]*)
  3731. _LT_AC_TAGVAR(hardcode_direct, $1)=no
  3732. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  3733. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
  3734. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
  3735. # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
  3736. # Instead, shared libraries are loaded at an image base (0x10000000 by
  3737. # default) and relocated if they conflict, which is a slow very memory
  3738. # consuming and fragmenting process. To avoid this, we pick a random,
  3739. # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
  3740. # time. Moving up from 0x10000000 also allows more sbrk(2) space.
  3741. _LT_AC_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'
  3742. _LT_AC_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'
  3743. ;;
  3744. irix5* | irix6*)
  3745. case $cc_basename in
  3746. CC*)
  3747. # SGI C++
  3748. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
  3749. # Archives containing C++ object files must be created using
  3750. # "CC -ar", where "CC" is the IRIX C++ compiler. This is
  3751. # necessary to make sure instantiated templates are included
  3752. # in the archive.
  3753. _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
  3754. ;;
  3755. *)
  3756. if test "$GXX" = yes; then
  3757. if test "$with_gnu_ld" = no; then
  3758. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
  3759. else
  3760. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib'
  3761. fi
  3762. fi
  3763. _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
  3764. ;;
  3765. esac
  3766. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
  3767. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  3768. ;;
  3769. linux* | k*bsd*-gnu)
  3770. case $cc_basename in
  3771. KCC*)
  3772. # Kuck and Associates, Inc. (KAI) C++ Compiler
  3773. # KCC will only create a shared library if the output file
  3774. # ends with ".so" (or ".sl" for HP-UX), so rename the library
  3775. # to its proper name (with version) after linking.
  3776. _LT_AC_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'
  3777. _LT_AC_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'
  3778. # Commands to make compiler produce verbose output that lists
  3779. # what "hidden" libraries, object files and flags are used when
  3780. # linking a shared library.
  3781. #
  3782. # There doesn't appear to be a way to prevent this compiler from
  3783. # explicitly linking system object files so we need to strip them
  3784. # from the output so that they don't get included in the library
  3785. # dependencies.
  3786. 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; echo $list'
  3787. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir'
  3788. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
  3789. # Archives containing C++ object files must be created using
  3790. # "CC -Bstatic", where "CC" is the KAI C++ compiler.
  3791. _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
  3792. ;;
  3793. icpc*)
  3794. # Intel C++
  3795. with_gnu_ld=yes
  3796. # version 8.0 and above of icpc choke on multiply defined symbols
  3797. # if we add $predep_objects and $postdep_objects, however 7.1 and
  3798. # earlier do not add the objects themselves.
  3799. case `$CC -V 2>&1` in
  3800. *"Version 7."*)
  3801. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
  3802. _LT_AC_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'
  3803. ;;
  3804. *) # Version 8.0 or newer
  3805. tmp_idyn=
  3806. case $host_cpu in
  3807. ia64*) tmp_idyn=' -i_dynamic';;
  3808. esac
  3809. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  3810. _LT_AC_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'
  3811. ;;
  3812. esac
  3813. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
  3814. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
  3815. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
  3816. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
  3817. ;;
  3818. pgCC*)
  3819. # Portland Group C++ compiler
  3820. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
  3821. _LT_AC_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'
  3822. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
  3823. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
  3824. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
  3825. ;;
  3826. cxx*)
  3827. # Compaq C++
  3828. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
  3829. _LT_AC_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'
  3830. runpath_var=LD_RUN_PATH
  3831. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
  3832. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  3833. # Commands to make compiler produce verbose output that lists
  3834. # what "hidden" libraries, object files and flags are used when
  3835. # linking a shared library.
  3836. #
  3837. # There doesn't appear to be a way to prevent this compiler from
  3838. # explicitly linking system object files so we need to strip them
  3839. # from the output so that they don't get included in the library
  3840. # dependencies.
  3841. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $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; echo $list'
  3842. ;;
  3843. *)
  3844. case `$CC -V 2>&1 | sed 5q` in
  3845. *Sun\ C*)
  3846. # Sun C++ 5.9
  3847. _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
  3848. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  3849. _LT_AC_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'
  3850. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
  3851. _LT_AC_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; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
  3852. # Not sure whether something based on
  3853. # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
  3854. # would be better.
  3855. output_verbose_link_cmd='echo'
  3856. # Archives containing C++ object files must be created using
  3857. # "CC -xar", where "CC" is the Sun C++ compiler. This is
  3858. # necessary to make sure instantiated templates are included
  3859. # in the archive.
  3860. _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
  3861. ;;
  3862. esac
  3863. ;;
  3864. esac
  3865. ;;
  3866. lynxos*)
  3867. # FIXME: insert proper C++ library support
  3868. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3869. ;;
  3870. m88k*)
  3871. # FIXME: insert proper C++ library support
  3872. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3873. ;;
  3874. mvs*)
  3875. case $cc_basename in
  3876. cxx*)
  3877. # FIXME: insert proper C++ library support
  3878. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3879. ;;
  3880. *)
  3881. # FIXME: insert proper C++ library support
  3882. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3883. ;;
  3884. esac
  3885. ;;
  3886. netbsd*)
  3887. if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
  3888. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
  3889. wlarc=
  3890. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
  3891. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  3892. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  3893. fi
  3894. # Workaround some broken pre-1.5 toolchains
  3895. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
  3896. ;;
  3897. openbsd2*)
  3898. # C++ shared libraries are fairly broken
  3899. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3900. ;;
  3901. openbsd*)
  3902. if test -f /usr/libexec/ld.so; then
  3903. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  3904. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  3905. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
  3906. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
  3907. if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
  3908. _LT_AC_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'
  3909. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
  3910. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
  3911. fi
  3912. output_verbose_link_cmd='echo'
  3913. else
  3914. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3915. fi
  3916. ;;
  3917. osf3*)
  3918. case $cc_basename in
  3919. KCC*)
  3920. # Kuck and Associates, Inc. (KAI) C++ Compiler
  3921. # KCC will only create a shared library if the output file
  3922. # ends with ".so" (or ".sl" for HP-UX), so rename the library
  3923. # to its proper name (with version) after linking.
  3924. _LT_AC_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'
  3925. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
  3926. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  3927. # Archives containing C++ object files must be created using
  3928. # "CC -Bstatic", where "CC" is the KAI C++ compiler.
  3929. _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
  3930. ;;
  3931. RCC*)
  3932. # Rational C++ 2.4.1
  3933. # FIXME: insert proper C++ library support
  3934. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3935. ;;
  3936. cxx*)
  3937. _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
  3938. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
  3939. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
  3940. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  3941. # Commands to make compiler produce verbose output that lists
  3942. # what "hidden" libraries, object files and flags are used when
  3943. # linking a shared library.
  3944. #
  3945. # There doesn't appear to be a way to prevent this compiler from
  3946. # explicitly linking system object files so we need to strip them
  3947. # from the output so that they don't get included in the library
  3948. # dependencies.
  3949. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $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; echo $list'
  3950. ;;
  3951. *)
  3952. if test "$GXX" = yes && test "$with_gnu_ld" = no; then
  3953. _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
  3954. _LT_AC_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" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
  3955. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
  3956. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  3957. # Commands to make compiler produce verbose output that lists
  3958. # what "hidden" libraries, object files and flags are used when
  3959. # linking a shared library.
  3960. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
  3961. else
  3962. # FIXME: insert proper C++ library support
  3963. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3964. fi
  3965. ;;
  3966. esac
  3967. ;;
  3968. osf4* | osf5*)
  3969. case $cc_basename in
  3970. KCC*)
  3971. # Kuck and Associates, Inc. (KAI) C++ Compiler
  3972. # KCC will only create a shared library if the output file
  3973. # ends with ".so" (or ".sl" for HP-UX), so rename the library
  3974. # to its proper name (with version) after linking.
  3975. _LT_AC_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'
  3976. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
  3977. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  3978. # Archives containing C++ object files must be created using
  3979. # the KAI C++ compiler.
  3980. _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs'
  3981. ;;
  3982. RCC*)
  3983. # Rational C++ 2.4.1
  3984. # FIXME: insert proper C++ library support
  3985. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  3986. ;;
  3987. cxx*)
  3988. _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
  3989. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
  3990. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
  3991. echo "-hidden">> $lib.exp~
  3992. $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~
  3993. $rm $lib.exp'
  3994. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
  3995. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  3996. # Commands to make compiler produce verbose output that lists
  3997. # what "hidden" libraries, object files and flags are used when
  3998. # linking a shared library.
  3999. #
  4000. # There doesn't appear to be a way to prevent this compiler from
  4001. # explicitly linking system object files so we need to strip them
  4002. # from the output so that they don't get included in the library
  4003. # dependencies.
  4004. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $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; echo $list'
  4005. ;;
  4006. *)
  4007. if test "$GXX" = yes && test "$with_gnu_ld" = no; then
  4008. _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
  4009. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
  4010. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
  4011. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  4012. # Commands to make compiler produce verbose output that lists
  4013. # what "hidden" libraries, object files and flags are used when
  4014. # linking a shared library.
  4015. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
  4016. else
  4017. # FIXME: insert proper C++ library support
  4018. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  4019. fi
  4020. ;;
  4021. esac
  4022. ;;
  4023. psos*)
  4024. # FIXME: insert proper C++ library support
  4025. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  4026. ;;
  4027. sunos4*)
  4028. case $cc_basename in
  4029. CC*)
  4030. # Sun C++ 4.x
  4031. # FIXME: insert proper C++ library support
  4032. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  4033. ;;
  4034. lcc*)
  4035. # Lucid
  4036. # FIXME: insert proper C++ library support
  4037. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  4038. ;;
  4039. *)
  4040. # FIXME: insert proper C++ library support
  4041. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  4042. ;;
  4043. esac
  4044. ;;
  4045. solaris*)
  4046. case $cc_basename in
  4047. CC*)
  4048. # Sun C++ 4.2, 5.x and Centerline C++
  4049. _LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes
  4050. _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
  4051. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  4052. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
  4053. $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'
  4054. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
  4055. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  4056. case $host_os in
  4057. solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
  4058. *)
  4059. # The compiler driver will combine and reorder linker options,
  4060. # but understands `-z linker_flag'.
  4061. # Supported since Solaris 2.6 (maybe 2.5.1?)
  4062. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
  4063. ;;
  4064. esac
  4065. _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
  4066. output_verbose_link_cmd='echo'
  4067. # Archives containing C++ object files must be created using
  4068. # "CC -xar", where "CC" is the Sun C++ compiler. This is
  4069. # necessary to make sure instantiated templates are included
  4070. # in the archive.
  4071. _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
  4072. ;;
  4073. gcx*)
  4074. # Green Hills C++ Compiler
  4075. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
  4076. # The C++ compiler must be used to create the archive.
  4077. _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
  4078. ;;
  4079. *)
  4080. # GNU C++ compiler with Solaris linker
  4081. if test "$GXX" = yes && test "$with_gnu_ld" = no; then
  4082. _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
  4083. if $CC --version | grep -v '^2\.7' > /dev/null; then
  4084. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
  4085. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
  4086. $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
  4087. # Commands to make compiler produce verbose output that lists
  4088. # what "hidden" libraries, object files and flags are used when
  4089. # linking a shared library.
  4090. output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
  4091. else
  4092. # g++ 2.7 appears to require `-G' NOT `-shared' on this
  4093. # platform.
  4094. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
  4095. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
  4096. $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
  4097. # Commands to make compiler produce verbose output that lists
  4098. # what "hidden" libraries, object files and flags are used when
  4099. # linking a shared library.
  4100. output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
  4101. fi
  4102. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
  4103. case $host_os in
  4104. solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
  4105. *)
  4106. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
  4107. ;;
  4108. esac
  4109. fi
  4110. ;;
  4111. esac
  4112. ;;
  4113. sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
  4114. _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
  4115. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
  4116. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  4117. runpath_var='LD_RUN_PATH'
  4118. case $cc_basename in
  4119. CC*)
  4120. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  4121. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  4122. ;;
  4123. *)
  4124. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  4125. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  4126. ;;
  4127. esac
  4128. ;;
  4129. sysv5* | sco3.2v5* | sco5v6*)
  4130. # Note: We can NOT use -z defs as we might desire, because we do not
  4131. # link with -lc, and that would cause any symbols used from libc to
  4132. # always be unresolved, which means just about no library would
  4133. # ever link correctly. If we're not using GNU ld we use -z text
  4134. # though, which does catch some bad symbols but isn't as heavy-handed
  4135. # as -z defs.
  4136. # For security reasons, it is highly recommended that you always
  4137. # use absolute paths for naming shared libraries, and exclude the
  4138. # DT_RUNPATH tag from executables and libraries. But doing so
  4139. # requires that you compile everything twice, which is a pain.
  4140. # So that behaviour is only enabled if SCOABSPATH is set to a
  4141. # non-empty value in the environment. Most likely only useful for
  4142. # creating official distributions of packages.
  4143. # This is a hack until libtool officially supports absolute path
  4144. # names for shared libraries.
  4145. _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
  4146. _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
  4147. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
  4148. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  4149. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
  4150. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
  4151. _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
  4152. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
  4153. runpath_var='LD_RUN_PATH'
  4154. case $cc_basename in
  4155. CC*)
  4156. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
  4157. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
  4158. ;;
  4159. *)
  4160. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
  4161. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
  4162. ;;
  4163. esac
  4164. ;;
  4165. tandem*)
  4166. case $cc_basename in
  4167. NCC*)
  4168. # NonStop-UX NCC 3.20
  4169. # FIXME: insert proper C++ library support
  4170. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  4171. ;;
  4172. *)
  4173. # FIXME: insert proper C++ library support
  4174. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  4175. ;;
  4176. esac
  4177. ;;
  4178. vxworks*)
  4179. # FIXME: insert proper C++ library support
  4180. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  4181. ;;
  4182. *)
  4183. # FIXME: insert proper C++ library support
  4184. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  4185. ;;
  4186. esac
  4187. AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
  4188. test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
  4189. _LT_AC_TAGVAR(GCC, $1)="$GXX"
  4190. _LT_AC_TAGVAR(LD, $1)="$LD"
  4191. AC_LIBTOOL_POSTDEP_PREDEP($1)
  4192. AC_LIBTOOL_PROG_COMPILER_PIC($1)
  4193. AC_LIBTOOL_PROG_CC_C_O($1)
  4194. AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
  4195. AC_LIBTOOL_PROG_LD_SHLIBS($1)
  4196. AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
  4197. AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
  4198. AC_LIBTOOL_CONFIG($1)
  4199. AC_LANG_POP
  4200. CC=$lt_save_CC
  4201. LDCXX=$LD
  4202. LD=$lt_save_LD
  4203. GCC=$lt_save_GCC
  4204. with_gnu_ldcxx=$with_gnu_ld
  4205. with_gnu_ld=$lt_save_with_gnu_ld
  4206. lt_cv_path_LDCXX=$lt_cv_path_LD
  4207. lt_cv_path_LD=$lt_save_path_LD
  4208. lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
  4209. lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
  4210. ])# AC_LIBTOOL_LANG_CXX_CONFIG
  4211. # AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME])
  4212. # ------------------------------------
  4213. # Figure out "hidden" library dependencies from verbose
  4214. # compiler output when linking a shared library.
  4215. # Parse the compiler output and extract the necessary
  4216. # objects, libraries and library flags.
  4217. AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],[
  4218. dnl we can't use the lt_simple_compile_test_code here,
  4219. dnl because it contains code intended for an executable,
  4220. dnl not a library. It's possible we should let each
  4221. dnl tag define a new lt_????_link_test_code variable,
  4222. dnl but it's only used here...
  4223. ifelse([$1],[],[cat > conftest.$ac_ext <<EOF
  4224. int a;
  4225. void foo (void) { a = 0; }
  4226. EOF
  4227. ],[$1],[CXX],[cat > conftest.$ac_ext <<EOF
  4228. class Foo
  4229. {
  4230. public:
  4231. Foo (void) { a = 0; }
  4232. private:
  4233. int a;
  4234. };
  4235. EOF
  4236. ],[$1],[F77],[cat > conftest.$ac_ext <<EOF
  4237. subroutine foo
  4238. implicit none
  4239. integer*4 a
  4240. a=0
  4241. return
  4242. end
  4243. EOF
  4244. ],[$1],[GCJ],[cat > conftest.$ac_ext <<EOF
  4245. public class foo {
  4246. private int a;
  4247. public void bar (void) {
  4248. a = 0;
  4249. }
  4250. };
  4251. EOF
  4252. ])
  4253. dnl Parse the compiler output and extract the necessary
  4254. dnl objects, libraries and library flags.
  4255. if AC_TRY_EVAL(ac_compile); then
  4256. # Parse the compiler output and extract the necessary
  4257. # objects, libraries and library flags.
  4258. # Sentinel used to keep track of whether or not we are before
  4259. # the conftest object file.
  4260. pre_test_object_deps_done=no
  4261. # The `*' in the case matches for architectures that use `case' in
  4262. # $output_verbose_cmd can trigger glob expansion during the loop
  4263. # eval without this substitution.
  4264. output_verbose_link_cmd=`$echo "X$output_verbose_link_cmd" | $Xsed -e "$no_glob_subst"`
  4265. for p in `eval $output_verbose_link_cmd`; do
  4266. case $p in
  4267. -L* | -R* | -l*)
  4268. # Some compilers place space between "-{L,R}" and the path.
  4269. # Remove the space.
  4270. if test $p = "-L" \
  4271. || test $p = "-R"; then
  4272. prev=$p
  4273. continue
  4274. else
  4275. prev=
  4276. fi
  4277. if test "$pre_test_object_deps_done" = no; then
  4278. case $p in
  4279. -L* | -R*)
  4280. # Internal compiler library paths should come after those
  4281. # provided the user. The postdeps already come after the
  4282. # user supplied libs so there is no need to process them.
  4283. if test -z "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
  4284. _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
  4285. else
  4286. _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${_LT_AC_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
  4287. fi
  4288. ;;
  4289. # The "-l" case would never come before the object being
  4290. # linked, so don't bother handling this case.
  4291. esac
  4292. else
  4293. if test -z "$_LT_AC_TAGVAR(postdeps, $1)"; then
  4294. _LT_AC_TAGVAR(postdeps, $1)="${prev}${p}"
  4295. else
  4296. _LT_AC_TAGVAR(postdeps, $1)="${_LT_AC_TAGVAR(postdeps, $1)} ${prev}${p}"
  4297. fi
  4298. fi
  4299. ;;
  4300. *.$objext)
  4301. # This assumes that the test object file only shows up
  4302. # once in the compiler output.
  4303. if test "$p" = "conftest.$objext"; then
  4304. pre_test_object_deps_done=yes
  4305. continue
  4306. fi
  4307. if test "$pre_test_object_deps_done" = no; then
  4308. if test -z "$_LT_AC_TAGVAR(predep_objects, $1)"; then
  4309. _LT_AC_TAGVAR(predep_objects, $1)="$p"
  4310. else
  4311. _LT_AC_TAGVAR(predep_objects, $1)="$_LT_AC_TAGVAR(predep_objects, $1) $p"
  4312. fi
  4313. else
  4314. if test -z "$_LT_AC_TAGVAR(postdep_objects, $1)"; then
  4315. _LT_AC_TAGVAR(postdep_objects, $1)="$p"
  4316. else
  4317. _LT_AC_TAGVAR(postdep_objects, $1)="$_LT_AC_TAGVAR(postdep_objects, $1) $p"
  4318. fi
  4319. fi
  4320. ;;
  4321. *) ;; # Ignore the rest.
  4322. esac
  4323. done
  4324. # Clean up.
  4325. rm -f a.out a.exe
  4326. else
  4327. echo "libtool.m4: error: problem compiling $1 test program"
  4328. fi
  4329. $rm -f confest.$objext
  4330. # PORTME: override above test on systems where it is broken
  4331. ifelse([$1],[CXX],
  4332. [case $host_os in
  4333. interix[[3-9]]*)
  4334. # Interix 3.5 installs completely hosed .la files for C++, so rather than
  4335. # hack all around it, let's just trust "g++" to DTRT.
  4336. _LT_AC_TAGVAR(predep_objects,$1)=
  4337. _LT_AC_TAGVAR(postdep_objects,$1)=
  4338. _LT_AC_TAGVAR(postdeps,$1)=
  4339. ;;
  4340. linux*)
  4341. case `$CC -V 2>&1 | sed 5q` in
  4342. *Sun\ C*)
  4343. # Sun C++ 5.9
  4344. #
  4345. # The more standards-conforming stlport4 library is
  4346. # incompatible with the Cstd library. Avoid specifying
  4347. # it if it's in CXXFLAGS. Ignore libCrun as
  4348. # -library=stlport4 depends on it.
  4349. case " $CXX $CXXFLAGS " in
  4350. *" -library=stlport4 "*)
  4351. solaris_use_stlport4=yes
  4352. ;;
  4353. esac
  4354. if test "$solaris_use_stlport4" != yes; then
  4355. _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
  4356. fi
  4357. ;;
  4358. esac
  4359. ;;
  4360. solaris*)
  4361. case $cc_basename in
  4362. CC*)
  4363. # The more standards-conforming stlport4 library is
  4364. # incompatible with the Cstd library. Avoid specifying
  4365. # it if it's in CXXFLAGS. Ignore libCrun as
  4366. # -library=stlport4 depends on it.
  4367. case " $CXX $CXXFLAGS " in
  4368. *" -library=stlport4 "*)
  4369. solaris_use_stlport4=yes
  4370. ;;
  4371. esac
  4372. # Adding this requires a known-good setup of shared libraries for
  4373. # Sun compiler versions before 5.6, else PIC objects from an old
  4374. # archive will be linked into the output, leading to subtle bugs.
  4375. if test "$solaris_use_stlport4" != yes; then
  4376. _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
  4377. fi
  4378. ;;
  4379. esac
  4380. ;;
  4381. esac
  4382. ])
  4383. case " $_LT_AC_TAGVAR(postdeps, $1) " in
  4384. *" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;;
  4385. esac
  4386. ])# AC_LIBTOOL_POSTDEP_PREDEP
  4387. # AC_LIBTOOL_LANG_F77_CONFIG
  4388. # --------------------------
  4389. # Ensure that the configuration vars for the C compiler are
  4390. # suitably defined. Those variables are subsequently used by
  4391. # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
  4392. AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)])
  4393. AC_DEFUN([_LT_AC_LANG_F77_CONFIG],
  4394. [AC_REQUIRE([AC_PROG_F77])
  4395. AC_LANG_PUSH(Fortran 77)
  4396. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
  4397. _LT_AC_TAGVAR(allow_undefined_flag, $1)=
  4398. _LT_AC_TAGVAR(always_export_symbols, $1)=no
  4399. _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
  4400. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
  4401. _LT_AC_TAGVAR(hardcode_direct, $1)=no
  4402. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
  4403. _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
  4404. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
  4405. _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
  4406. _LT_AC_TAGVAR(hardcode_automatic, $1)=no
  4407. _LT_AC_TAGVAR(module_cmds, $1)=
  4408. _LT_AC_TAGVAR(module_expsym_cmds, $1)=
  4409. _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
  4410. _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
  4411. _LT_AC_TAGVAR(no_undefined_flag, $1)=
  4412. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
  4413. _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
  4414. # Source file extension for f77 test sources.
  4415. ac_ext=f
  4416. # Object file extension for compiled f77 test sources.
  4417. objext=o
  4418. _LT_AC_TAGVAR(objext, $1)=$objext
  4419. # Code to be used in simple compile tests
  4420. lt_simple_compile_test_code="\
  4421. subroutine t
  4422. return
  4423. end
  4424. "
  4425. # Code to be used in simple link tests
  4426. lt_simple_link_test_code="\
  4427. program t
  4428. end
  4429. "
  4430. # ltmain only uses $CC for tagged configurations so make sure $CC is set.
  4431. _LT_AC_SYS_COMPILER
  4432. # save warnings/boilerplate of simple test code
  4433. _LT_COMPILER_BOILERPLATE
  4434. _LT_LINKER_BOILERPLATE
  4435. # Allow CC to be a program name with arguments.
  4436. lt_save_CC="$CC"
  4437. CC=${F77-"f77"}
  4438. compiler=$CC
  4439. _LT_AC_TAGVAR(compiler, $1)=$CC
  4440. _LT_CC_BASENAME([$compiler])
  4441. AC_MSG_CHECKING([if libtool supports shared libraries])
  4442. AC_MSG_RESULT([$can_build_shared])
  4443. AC_MSG_CHECKING([whether to build shared libraries])
  4444. test "$can_build_shared" = "no" && enable_shared=no
  4445. # On AIX, shared libraries and static libraries use the same namespace, and
  4446. # are all built from PIC.
  4447. case $host_os in
  4448. aix3*)
  4449. test "$enable_shared" = yes && enable_static=no
  4450. if test -n "$RANLIB"; then
  4451. archive_cmds="$archive_cmds~\$RANLIB \$lib"
  4452. postinstall_cmds='$RANLIB $lib'
  4453. fi
  4454. ;;
  4455. aix4* | aix5*)
  4456. if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
  4457. test "$enable_shared" = yes && enable_static=no
  4458. fi
  4459. ;;
  4460. esac
  4461. AC_MSG_RESULT([$enable_shared])
  4462. AC_MSG_CHECKING([whether to build static libraries])
  4463. # Make sure either enable_shared or enable_static is yes.
  4464. test "$enable_shared" = yes || enable_static=yes
  4465. AC_MSG_RESULT([$enable_static])
  4466. _LT_AC_TAGVAR(GCC, $1)="$G77"
  4467. _LT_AC_TAGVAR(LD, $1)="$LD"
  4468. AC_LIBTOOL_PROG_COMPILER_PIC($1)
  4469. AC_LIBTOOL_PROG_CC_C_O($1)
  4470. AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
  4471. AC_LIBTOOL_PROG_LD_SHLIBS($1)
  4472. AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
  4473. AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
  4474. AC_LIBTOOL_CONFIG($1)
  4475. AC_LANG_POP
  4476. CC="$lt_save_CC"
  4477. ])# AC_LIBTOOL_LANG_F77_CONFIG
  4478. # AC_LIBTOOL_LANG_GCJ_CONFIG
  4479. # --------------------------
  4480. # Ensure that the configuration vars for the C compiler are
  4481. # suitably defined. Those variables are subsequently used by
  4482. # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
  4483. AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)])
  4484. AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG],
  4485. [AC_LANG_SAVE
  4486. # Source file extension for Java test sources.
  4487. ac_ext=java
  4488. # Object file extension for compiled Java test sources.
  4489. objext=o
  4490. _LT_AC_TAGVAR(objext, $1)=$objext
  4491. # Code to be used in simple compile tests
  4492. lt_simple_compile_test_code="class foo {}"
  4493. # Code to be used in simple link tests
  4494. lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
  4495. # ltmain only uses $CC for tagged configurations so make sure $CC is set.
  4496. _LT_AC_SYS_COMPILER
  4497. # save warnings/boilerplate of simple test code
  4498. _LT_COMPILER_BOILERPLATE
  4499. _LT_LINKER_BOILERPLATE
  4500. # Allow CC to be a program name with arguments.
  4501. lt_save_CC="$CC"
  4502. CC=${GCJ-"gcj"}
  4503. compiler=$CC
  4504. _LT_AC_TAGVAR(compiler, $1)=$CC
  4505. _LT_CC_BASENAME([$compiler])
  4506. # GCJ did not exist at the time GCC didn't implicitly link libc in.
  4507. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
  4508. _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
  4509. AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
  4510. AC_LIBTOOL_PROG_COMPILER_PIC($1)
  4511. AC_LIBTOOL_PROG_CC_C_O($1)
  4512. AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
  4513. AC_LIBTOOL_PROG_LD_SHLIBS($1)
  4514. AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
  4515. AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
  4516. AC_LIBTOOL_CONFIG($1)
  4517. AC_LANG_RESTORE
  4518. CC="$lt_save_CC"
  4519. ])# AC_LIBTOOL_LANG_GCJ_CONFIG
  4520. # AC_LIBTOOL_LANG_RC_CONFIG
  4521. # -------------------------
  4522. # Ensure that the configuration vars for the Windows resource compiler are
  4523. # suitably defined. Those variables are subsequently used by
  4524. # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
  4525. AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)])
  4526. AC_DEFUN([_LT_AC_LANG_RC_CONFIG],
  4527. [AC_LANG_SAVE
  4528. # Source file extension for RC test sources.
  4529. ac_ext=rc
  4530. # Object file extension for compiled RC test sources.
  4531. objext=o
  4532. _LT_AC_TAGVAR(objext, $1)=$objext
  4533. # Code to be used in simple compile tests
  4534. lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
  4535. # Code to be used in simple link tests
  4536. lt_simple_link_test_code="$lt_simple_compile_test_code"
  4537. # ltmain only uses $CC for tagged configurations so make sure $CC is set.
  4538. _LT_AC_SYS_COMPILER
  4539. # save warnings/boilerplate of simple test code
  4540. _LT_COMPILER_BOILERPLATE
  4541. _LT_LINKER_BOILERPLATE
  4542. # Allow CC to be a program name with arguments.
  4543. lt_save_CC="$CC"
  4544. CC=${RC-"windres"}
  4545. compiler=$CC
  4546. _LT_AC_TAGVAR(compiler, $1)=$CC
  4547. _LT_CC_BASENAME([$compiler])
  4548. _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
  4549. AC_LIBTOOL_CONFIG($1)
  4550. AC_LANG_RESTORE
  4551. CC="$lt_save_CC"
  4552. ])# AC_LIBTOOL_LANG_RC_CONFIG
  4553. # AC_LIBTOOL_CONFIG([TAGNAME])
  4554. # ----------------------------
  4555. # If TAGNAME is not passed, then create an initial libtool script
  4556. # with a default configuration from the untagged config vars. Otherwise
  4557. # add code to config.status for appending the configuration named by
  4558. # TAGNAME from the matching tagged config vars.
  4559. AC_DEFUN([AC_LIBTOOL_CONFIG],
  4560. [# The else clause should only fire when bootstrapping the
  4561. # libtool distribution, otherwise you forgot to ship ltmain.sh
  4562. # with your package, and you will get complaints that there are
  4563. # no rules to generate ltmain.sh.
  4564. if test -f "$ltmain"; then
  4565. # See if we are running on zsh, and set the options which allow our commands through
  4566. # without removal of \ escapes.
  4567. if test -n "${ZSH_VERSION+set}" ; then
  4568. setopt NO_GLOB_SUBST
  4569. fi
  4570. # Now quote all the things that may contain metacharacters while being
  4571. # careful not to overquote the AC_SUBSTed values. We take copies of the
  4572. # variables and quote the copies for generation of the libtool script.
  4573. for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
  4574. SED SHELL STRIP \
  4575. libname_spec library_names_spec soname_spec extract_expsyms_cmds \
  4576. old_striplib striplib file_magic_cmd finish_cmds finish_eval \
  4577. deplibs_check_method reload_flag reload_cmds need_locks \
  4578. lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
  4579. lt_cv_sys_global_symbol_to_c_name_address \
  4580. sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
  4581. old_postinstall_cmds old_postuninstall_cmds \
  4582. _LT_AC_TAGVAR(compiler, $1) \
  4583. _LT_AC_TAGVAR(CC, $1) \
  4584. _LT_AC_TAGVAR(LD, $1) \
  4585. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \
  4586. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \
  4587. _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \
  4588. _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \
  4589. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \
  4590. _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \
  4591. _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \
  4592. _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \
  4593. _LT_AC_TAGVAR(old_archive_cmds, $1) \
  4594. _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \
  4595. _LT_AC_TAGVAR(predep_objects, $1) \
  4596. _LT_AC_TAGVAR(postdep_objects, $1) \
  4597. _LT_AC_TAGVAR(predeps, $1) \
  4598. _LT_AC_TAGVAR(postdeps, $1) \
  4599. _LT_AC_TAGVAR(compiler_lib_search_path, $1) \
  4600. _LT_AC_TAGVAR(archive_cmds, $1) \
  4601. _LT_AC_TAGVAR(archive_expsym_cmds, $1) \
  4602. _LT_AC_TAGVAR(postinstall_cmds, $1) \
  4603. _LT_AC_TAGVAR(postuninstall_cmds, $1) \
  4604. _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \
  4605. _LT_AC_TAGVAR(allow_undefined_flag, $1) \
  4606. _LT_AC_TAGVAR(no_undefined_flag, $1) \
  4607. _LT_AC_TAGVAR(export_symbols_cmds, $1) \
  4608. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \
  4609. _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \
  4610. _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \
  4611. _LT_AC_TAGVAR(hardcode_automatic, $1) \
  4612. _LT_AC_TAGVAR(module_cmds, $1) \
  4613. _LT_AC_TAGVAR(module_expsym_cmds, $1) \
  4614. _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
  4615. _LT_AC_TAGVAR(fix_srcfile_path, $1) \
  4616. _LT_AC_TAGVAR(exclude_expsyms, $1) \
  4617. _LT_AC_TAGVAR(include_expsyms, $1); do
  4618. case $var in
  4619. _LT_AC_TAGVAR(old_archive_cmds, $1) | \
  4620. _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \
  4621. _LT_AC_TAGVAR(archive_cmds, $1) | \
  4622. _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \
  4623. _LT_AC_TAGVAR(module_cmds, $1) | \
  4624. _LT_AC_TAGVAR(module_expsym_cmds, $1) | \
  4625. _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \
  4626. _LT_AC_TAGVAR(export_symbols_cmds, $1) | \
  4627. extract_expsyms_cmds | reload_cmds | finish_cmds | \
  4628. postinstall_cmds | postuninstall_cmds | \
  4629. old_postinstall_cmds | old_postuninstall_cmds | \
  4630. sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
  4631. # Double-quote double-evaled strings.
  4632. eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
  4633. ;;
  4634. *)
  4635. eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
  4636. ;;
  4637. esac
  4638. done
  4639. case $lt_echo in
  4640. *'\[$]0 --fallback-echo"')
  4641. lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'`
  4642. ;;
  4643. esac
  4644. ifelse([$1], [],
  4645. [cfgfile="${ofile}T"
  4646. trap "$rm \"$cfgfile\"; exit 1" 1 2 15
  4647. $rm -f "$cfgfile"
  4648. AC_MSG_NOTICE([creating $ofile])],
  4649. [cfgfile="$ofile"])
  4650. cat <<__EOF__ >> "$cfgfile"
  4651. ifelse([$1], [],
  4652. [#! $SHELL
  4653. # `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
  4654. # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
  4655. # NOTE: Changes made to this file will be lost: look at ltmain.sh.
  4656. #
  4657. # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
  4658. # Free Software Foundation, Inc.
  4659. #
  4660. # This file is part of GNU Libtool:
  4661. # Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
  4662. #
  4663. # This program is free software; you can redistribute it and/or modify
  4664. # it under the terms of the GNU General Public License as published by
  4665. # the Free Software Foundation; either version 2 of the License, or
  4666. # (at your option) any later version.
  4667. #
  4668. # This program is distributed in the hope that it will be useful, but
  4669. # WITHOUT ANY WARRANTY; without even the implied warranty of
  4670. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  4671. # General Public License for more details.
  4672. #
  4673. # You should have received a copy of the GNU General Public License
  4674. # along with this program; if not, write to the Free Software
  4675. # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
  4676. #
  4677. # As a special exception to the GNU General Public License, if you
  4678. # distribute this file as part of a program that contains a
  4679. # configuration script generated by Autoconf, you may include it under
  4680. # the same distribution terms that you use for the rest of that program.
  4681. # A sed program that does not truncate output.
  4682. SED=$lt_SED
  4683. # Sed that helps us avoid accidentally triggering echo(1) options like -n.
  4684. Xsed="$SED -e 1s/^X//"
  4685. # The HP-UX ksh and POSIX shell print the target directory to stdout
  4686. # if CDPATH is set.
  4687. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
  4688. # The names of the tagged configurations supported by this script.
  4689. available_tags=
  4690. # ### BEGIN LIBTOOL CONFIG],
  4691. [# ### BEGIN LIBTOOL TAG CONFIG: $tagname])
  4692. # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
  4693. # Shell to use when invoking shell scripts.
  4694. SHELL=$lt_SHELL
  4695. # Whether or not to build shared libraries.
  4696. build_libtool_libs=$enable_shared
  4697. # Whether or not to build static libraries.
  4698. build_old_libs=$enable_static
  4699. # Whether or not to add -lc for building shared libraries.
  4700. build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)
  4701. # Whether or not to disallow shared libs when runtime libs are static
  4702. allow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)
  4703. # Whether or not to optimize for fast installation.
  4704. fast_install=$enable_fast_install
  4705. # The host system.
  4706. host_alias=$host_alias
  4707. host=$host
  4708. host_os=$host_os
  4709. # The build system.
  4710. build_alias=$build_alias
  4711. build=$build
  4712. build_os=$build_os
  4713. # An echo program that does not interpret backslashes.
  4714. echo=$lt_echo
  4715. # The archiver.
  4716. AR=$lt_AR
  4717. AR_FLAGS=$lt_AR_FLAGS
  4718. # A C compiler.
  4719. LTCC=$lt_LTCC
  4720. # LTCC compiler flags.
  4721. LTCFLAGS=$lt_LTCFLAGS
  4722. # A language-specific compiler.
  4723. CC=$lt_[]_LT_AC_TAGVAR(compiler, $1)
  4724. # Is the compiler the GNU C compiler?
  4725. with_gcc=$_LT_AC_TAGVAR(GCC, $1)
  4726. # An ERE matcher.
  4727. EGREP=$lt_EGREP
  4728. # The linker used to build libraries.
  4729. LD=$lt_[]_LT_AC_TAGVAR(LD, $1)
  4730. # Whether we need hard or soft links.
  4731. LN_S=$lt_LN_S
  4732. # A BSD-compatible nm program.
  4733. NM=$lt_NM
  4734. # A symbol stripping program
  4735. STRIP=$lt_STRIP
  4736. # Used to examine libraries when file_magic_cmd begins "file"
  4737. MAGIC_CMD=$MAGIC_CMD
  4738. # Used on cygwin: DLL creation program.
  4739. DLLTOOL="$DLLTOOL"
  4740. # Used on cygwin: object dumper.
  4741. OBJDUMP="$OBJDUMP"
  4742. # Used on cygwin: assembler.
  4743. AS="$AS"
  4744. # The name of the directory that contains temporary libtool files.
  4745. objdir=$objdir
  4746. # How to create reloadable object files.
  4747. reload_flag=$lt_reload_flag
  4748. reload_cmds=$lt_reload_cmds
  4749. # How to pass a linker flag through the compiler.
  4750. wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
  4751. # Object file suffix (normally "o").
  4752. objext="$ac_objext"
  4753. # Old archive suffix (normally "a").
  4754. libext="$libext"
  4755. # Shared library suffix (normally ".so").
  4756. shrext_cmds='$shrext_cmds'
  4757. # Executable file suffix (normally "").
  4758. exeext="$exeext"
  4759. # Additional compiler flags for building library objects.
  4760. pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
  4761. pic_mode=$pic_mode
  4762. # What is the maximum length of a command?
  4763. max_cmd_len=$lt_cv_sys_max_cmd_len
  4764. # Does compiler simultaneously support -c and -o options?
  4765. compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)
  4766. # Must we lock files when doing compilation?
  4767. need_locks=$lt_need_locks
  4768. # Do we need the lib prefix for modules?
  4769. need_lib_prefix=$need_lib_prefix
  4770. # Do we need a version for libraries?
  4771. need_version=$need_version
  4772. # Whether dlopen is supported.
  4773. dlopen_support=$enable_dlopen
  4774. # Whether dlopen of programs is supported.
  4775. dlopen_self=$enable_dlopen_self
  4776. # Whether dlopen of statically linked programs is supported.
  4777. dlopen_self_static=$enable_dlopen_self_static
  4778. # Compiler flag to prevent dynamic linking.
  4779. link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1)
  4780. # Compiler flag to turn off builtin functions.
  4781. no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)
  4782. # Compiler flag to allow reflexive dlopens.
  4783. export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)
  4784. # Compiler flag to generate shared objects directly from archives.
  4785. whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1)
  4786. # Compiler flag to generate thread-safe objects.
  4787. thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1)
  4788. # Library versioning type.
  4789. version_type=$version_type
  4790. # Format of library name prefix.
  4791. libname_spec=$lt_libname_spec
  4792. # List of archive names. First name is the real one, the rest are links.
  4793. # The last name is the one that the linker finds with -lNAME.
  4794. library_names_spec=$lt_library_names_spec
  4795. # The coded name of the library, if different from the real name.
  4796. soname_spec=$lt_soname_spec
  4797. # Commands used to build and install an old-style archive.
  4798. RANLIB=$lt_RANLIB
  4799. old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1)
  4800. old_postinstall_cmds=$lt_old_postinstall_cmds
  4801. old_postuninstall_cmds=$lt_old_postuninstall_cmds
  4802. # Create an old-style archive from a shared archive.
  4803. old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1)
  4804. # Create a temporary old-style archive to link instead of a shared archive.
  4805. old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)
  4806. # Commands used to build and install a shared archive.
  4807. archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1)
  4808. archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1)
  4809. postinstall_cmds=$lt_postinstall_cmds
  4810. postuninstall_cmds=$lt_postuninstall_cmds
  4811. # Commands used to build a loadable module (assumed same as above if empty)
  4812. module_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1)
  4813. module_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1)
  4814. # Commands to strip libraries.
  4815. old_striplib=$lt_old_striplib
  4816. striplib=$lt_striplib
  4817. # Dependencies to place before the objects being linked to create a
  4818. # shared library.
  4819. predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1)
  4820. # Dependencies to place after the objects being linked to create a
  4821. # shared library.
  4822. postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1)
  4823. # Dependencies to place before the objects being linked to create a
  4824. # shared library.
  4825. predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1)
  4826. # Dependencies to place after the objects being linked to create a
  4827. # shared library.
  4828. postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1)
  4829. # The library search path used internally by the compiler when linking
  4830. # a shared library.
  4831. compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1)
  4832. # Method to check whether dependent libraries are shared objects.
  4833. deplibs_check_method=$lt_deplibs_check_method
  4834. # Command to use when deplibs_check_method == file_magic.
  4835. file_magic_cmd=$lt_file_magic_cmd
  4836. # Flag that allows shared libraries with undefined symbols to be built.
  4837. allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1)
  4838. # Flag that forces no undefined symbols.
  4839. no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1)
  4840. # Commands used to finish a libtool library installation in a directory.
  4841. finish_cmds=$lt_finish_cmds
  4842. # Same as above, but a single script fragment to be evaled but not shown.
  4843. finish_eval=$lt_finish_eval
  4844. # Take the output of nm and produce a listing of raw symbols and C names.
  4845. global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
  4846. # Transform the output of nm in a proper C declaration
  4847. global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
  4848. # Transform the output of nm in a C name address pair
  4849. global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
  4850. # This is the shared library runtime path variable.
  4851. runpath_var=$runpath_var
  4852. # This is the shared library path variable.
  4853. shlibpath_var=$shlibpath_var
  4854. # Is shlibpath searched before the hard-coded library search path?
  4855. shlibpath_overrides_runpath=$shlibpath_overrides_runpath
  4856. # How to hardcode a shared library path into an executable.
  4857. hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1)
  4858. # Whether we should hardcode library paths into libraries.
  4859. hardcode_into_libs=$hardcode_into_libs
  4860. # Flag to hardcode \$libdir into a binary during linking.
  4861. # This must work even if \$libdir does not exist.
  4862. hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)
  4863. # If ld is used when linking, flag to hardcode \$libdir into
  4864. # a binary during linking. This must work even if \$libdir does
  4865. # not exist.
  4866. hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)
  4867. # Whether we need a single -rpath flag with a separated argument.
  4868. hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1)
  4869. # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
  4870. # resulting binary.
  4871. hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1)
  4872. # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
  4873. # resulting binary.
  4874. hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1)
  4875. # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
  4876. # the resulting binary.
  4877. hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)
  4878. # Set to yes if building a shared library automatically hardcodes DIR into the library
  4879. # and all subsequent libraries and executables linked against it.
  4880. hardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1)
  4881. # Variables whose values should be saved in libtool wrapper scripts and
  4882. # restored at relink time.
  4883. variables_saved_for_relink="$variables_saved_for_relink"
  4884. # Whether libtool must link a program against all its dependency libraries.
  4885. link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1)
  4886. # Compile-time system search path for libraries
  4887. sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
  4888. # Run-time system search path for libraries
  4889. sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
  4890. # Fix the shell variable \$srcfile for the compiler.
  4891. fix_srcfile_path=$lt_fix_srcfile_path
  4892. # Set to yes if exported symbols are required.
  4893. always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1)
  4894. # The commands to list exported symbols.
  4895. export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1)
  4896. # The commands to extract the exported symbol list from a shared archive.
  4897. extract_expsyms_cmds=$lt_extract_expsyms_cmds
  4898. # Symbols that should not be listed in the preloaded symbols.
  4899. exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1)
  4900. # Symbols that must always be exported.
  4901. include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1)
  4902. ifelse([$1],[],
  4903. [# ### END LIBTOOL CONFIG],
  4904. [# ### END LIBTOOL TAG CONFIG: $tagname])
  4905. __EOF__
  4906. ifelse([$1],[], [
  4907. case $host_os in
  4908. aix3*)
  4909. cat <<\EOF >> "$cfgfile"
  4910. # AIX sometimes has problems with the GCC collect2 program. For some
  4911. # reason, if we set the COLLECT_NAMES environment variable, the problems
  4912. # vanish in a puff of smoke.
  4913. if test "X${COLLECT_NAMES+set}" != Xset; then
  4914. COLLECT_NAMES=
  4915. export COLLECT_NAMES
  4916. fi
  4917. EOF
  4918. ;;
  4919. esac
  4920. # We use sed instead of cat because bash on DJGPP gets confused if
  4921. # if finds mixed CR/LF and LF-only lines. Since sed operates in
  4922. # text mode, it properly converts lines to CR/LF. This bash problem
  4923. # is reportedly fixed, but why not run on old versions too?
  4924. sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
  4925. mv -f "$cfgfile" "$ofile" || \
  4926. (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
  4927. chmod +x "$ofile"
  4928. ])
  4929. else
  4930. # If there is no Makefile yet, we rely on a make rule to execute
  4931. # `config.status --recheck' to rerun these tests and create the
  4932. # libtool script then.
  4933. ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
  4934. if test -f "$ltmain_in"; then
  4935. test -f Makefile && make "$ltmain"
  4936. fi
  4937. fi
  4938. ])# AC_LIBTOOL_CONFIG
  4939. # AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME])
  4940. # -------------------------------------------
  4941. AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI],
  4942. [AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
  4943. _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
  4944. if test "$GCC" = yes; then
  4945. _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
  4946. AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
  4947. lt_cv_prog_compiler_rtti_exceptions,
  4948. [-fno-rtti -fno-exceptions], [],
  4949. [_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
  4950. fi
  4951. ])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI
  4952. # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
  4953. # ---------------------------------
  4954. AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
  4955. [AC_REQUIRE([AC_CANONICAL_HOST])
  4956. AC_REQUIRE([LT_AC_PROG_SED])
  4957. AC_REQUIRE([AC_PROG_NM])
  4958. AC_REQUIRE([AC_OBJEXT])
  4959. # Check for command to grab the raw symbol name followed by C symbol from nm.
  4960. AC_MSG_CHECKING([command to parse $NM output from $compiler object])
  4961. AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
  4962. [
  4963. # These are sane defaults that work on at least a few old systems.
  4964. # [They come from Ultrix. What could be older than Ultrix?!! ;)]
  4965. # Character class describing NM global symbol codes.
  4966. symcode='[[BCDEGRST]]'
  4967. # Regexp to match symbols that can be accessed directly from C.
  4968. sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
  4969. # Transform an extracted symbol line into a proper C declaration
  4970. lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
  4971. # Transform an extracted symbol line into symbol name and symbol address
  4972. lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
  4973. # Define system-specific variables.
  4974. case $host_os in
  4975. aix*)
  4976. symcode='[[BCDT]]'
  4977. ;;
  4978. cygwin* | mingw* | pw32*)
  4979. symcode='[[ABCDGISTW]]'
  4980. ;;
  4981. hpux*) # Its linker distinguishes data from code symbols
  4982. if test "$host_cpu" = ia64; then
  4983. symcode='[[ABCDEGRST]]'
  4984. fi
  4985. lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
  4986. lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
  4987. ;;
  4988. linux* | k*bsd*-gnu)
  4989. if test "$host_cpu" = ia64; then
  4990. symcode='[[ABCDGIRSTW]]'
  4991. lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
  4992. lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
  4993. fi
  4994. ;;
  4995. irix* | nonstopux*)
  4996. symcode='[[BCDEGRST]]'
  4997. ;;
  4998. osf*)
  4999. symcode='[[BCDEGQRST]]'
  5000. ;;
  5001. solaris*)
  5002. symcode='[[BDRT]]'
  5003. ;;
  5004. sco3.2v5*)
  5005. symcode='[[DT]]'
  5006. ;;
  5007. sysv4.2uw2*)
  5008. symcode='[[DT]]'
  5009. ;;
  5010. sysv5* | sco5v6* | unixware* | OpenUNIX*)
  5011. symcode='[[ABDT]]'
  5012. ;;
  5013. sysv4)
  5014. symcode='[[DFNSTU]]'
  5015. ;;
  5016. esac
  5017. # Handle CRLF in mingw tool chain
  5018. opt_cr=
  5019. case $build_os in
  5020. mingw*)
  5021. opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
  5022. ;;
  5023. esac
  5024. # If we're using GNU nm, then use its standard symbol codes.
  5025. case `$NM -V 2>&1` in
  5026. *GNU* | *'with BFD'*)
  5027. symcode='[[ABCDGIRSTW]]' ;;
  5028. esac
  5029. # Try without a prefix undercore, then with it.
  5030. for ac_symprfx in "" "_"; do
  5031. # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
  5032. symxfrm="\\1 $ac_symprfx\\2 \\2"
  5033. # Write the raw and C identifiers.
  5034. lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
  5035. # Check to see that the pipe works correctly.
  5036. pipe_works=no
  5037. rm -f conftest*
  5038. cat > conftest.$ac_ext <<EOF
  5039. #ifdef __cplusplus
  5040. extern "C" {
  5041. #endif
  5042. char nm_test_var;
  5043. void nm_test_func(){}
  5044. #ifdef __cplusplus
  5045. }
  5046. #endif
  5047. int main(){nm_test_var='a';nm_test_func();return(0);}
  5048. EOF
  5049. if AC_TRY_EVAL(ac_compile); then
  5050. # Now try to grab the symbols.
  5051. nlist=conftest.nm
  5052. if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
  5053. # Try sorting and uniquifying the output.
  5054. if sort "$nlist" | uniq > "$nlist"T; then
  5055. mv -f "$nlist"T "$nlist"
  5056. else
  5057. rm -f "$nlist"T
  5058. fi
  5059. # Make sure that we snagged all the symbols we need.
  5060. if grep ' nm_test_var$' "$nlist" >/dev/null; then
  5061. if grep ' nm_test_func$' "$nlist" >/dev/null; then
  5062. cat <<EOF > conftest.$ac_ext
  5063. #ifdef __cplusplus
  5064. extern "C" {
  5065. #endif
  5066. EOF
  5067. # Now generate the symbol file.
  5068. eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
  5069. cat <<EOF >> conftest.$ac_ext
  5070. #if defined (__STDC__) && __STDC__
  5071. # define lt_ptr_t void *
  5072. #else
  5073. # define lt_ptr_t char *
  5074. # define const
  5075. #endif
  5076. /* The mapping between symbol names and symbols. */
  5077. const struct {
  5078. const char *name;
  5079. lt_ptr_t address;
  5080. }
  5081. lt_preloaded_symbols[[]] =
  5082. {
  5083. EOF
  5084. $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
  5085. cat <<\EOF >> conftest.$ac_ext
  5086. {0, (lt_ptr_t) 0}
  5087. };
  5088. #ifdef __cplusplus
  5089. }
  5090. #endif
  5091. EOF
  5092. # Now try linking the two files.
  5093. mv conftest.$ac_objext conftstm.$ac_objext
  5094. lt_save_LIBS="$LIBS"
  5095. lt_save_CFLAGS="$CFLAGS"
  5096. LIBS="conftstm.$ac_objext"
  5097. CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
  5098. if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
  5099. pipe_works=yes
  5100. fi
  5101. LIBS="$lt_save_LIBS"
  5102. CFLAGS="$lt_save_CFLAGS"
  5103. else
  5104. echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
  5105. fi
  5106. else
  5107. echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
  5108. fi
  5109. else
  5110. echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
  5111. fi
  5112. else
  5113. echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
  5114. cat conftest.$ac_ext >&5
  5115. fi
  5116. rm -f conftest* conftst*
  5117. # Do not use the global_symbol_pipe unless it works.
  5118. if test "$pipe_works" = yes; then
  5119. break
  5120. else
  5121. lt_cv_sys_global_symbol_pipe=
  5122. fi
  5123. done
  5124. ])
  5125. if test -z "$lt_cv_sys_global_symbol_pipe"; then
  5126. lt_cv_sys_global_symbol_to_cdecl=
  5127. fi
  5128. if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
  5129. AC_MSG_RESULT(failed)
  5130. else
  5131. AC_MSG_RESULT(ok)
  5132. fi
  5133. ]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
  5134. # AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME])
  5135. # ---------------------------------------
  5136. AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC],
  5137. [_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=
  5138. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
  5139. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)=
  5140. AC_MSG_CHECKING([for $compiler option to produce PIC])
  5141. ifelse([$1],[CXX],[
  5142. # C++ specific cases for pic, static, wl, etc.
  5143. if test "$GXX" = yes; then
  5144. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5145. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
  5146. case $host_os in
  5147. aix*)
  5148. # All AIX code is PIC.
  5149. if test "$host_cpu" = ia64; then
  5150. # AIX 5 now supports IA64 processor
  5151. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5152. fi
  5153. ;;
  5154. amigaos*)
  5155. # FIXME: we need at least 68020 code to build shared libraries, but
  5156. # adding the `-m68020' flag to GCC prevents building anything better,
  5157. # like `-m68040'.
  5158. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
  5159. ;;
  5160. beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
  5161. # PIC is the default for these OSes.
  5162. ;;
  5163. mingw* | cygwin* | os2* | pw32*)
  5164. # This hack is so that the source file can tell whether it is being
  5165. # built for inclusion in a dll (and should export symbols for example).
  5166. # Although the cygwin gcc ignores -fPIC, still need this for old-style
  5167. # (--disable-auto-import) libraries
  5168. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
  5169. ;;
  5170. darwin* | rhapsody*)
  5171. # PIC is the default on this platform
  5172. # Common symbols not allowed in MH_DYLIB files
  5173. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
  5174. ;;
  5175. *djgpp*)
  5176. # DJGPP does not support shared libraries at all
  5177. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
  5178. ;;
  5179. interix[[3-9]]*)
  5180. # Interix 3.x gcc -fpic/-fPIC options generate broken code.
  5181. # Instead, we relocate shared libraries at runtime.
  5182. ;;
  5183. sysv4*MP*)
  5184. if test -d /usr/nec; then
  5185. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
  5186. fi
  5187. ;;
  5188. hpux*)
  5189. # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
  5190. # not for PA HP-UX.
  5191. case $host_cpu in
  5192. hppa*64*|ia64*)
  5193. ;;
  5194. *)
  5195. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  5196. ;;
  5197. esac
  5198. ;;
  5199. *)
  5200. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  5201. ;;
  5202. esac
  5203. else
  5204. case $host_os in
  5205. aix4* | aix5*)
  5206. # All AIX code is PIC.
  5207. if test "$host_cpu" = ia64; then
  5208. # AIX 5 now supports IA64 processor
  5209. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5210. else
  5211. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
  5212. fi
  5213. ;;
  5214. chorus*)
  5215. case $cc_basename in
  5216. cxch68*)
  5217. # Green Hills C++ Compiler
  5218. # _LT_AC_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"
  5219. ;;
  5220. esac
  5221. ;;
  5222. darwin*)
  5223. # PIC is the default on this platform
  5224. # Common symbols not allowed in MH_DYLIB files
  5225. case $cc_basename in
  5226. xlc*)
  5227. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
  5228. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5229. ;;
  5230. esac
  5231. ;;
  5232. dgux*)
  5233. case $cc_basename in
  5234. ec++*)
  5235. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  5236. ;;
  5237. ghcx*)
  5238. # Green Hills C++ Compiler
  5239. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
  5240. ;;
  5241. *)
  5242. ;;
  5243. esac
  5244. ;;
  5245. freebsd* | dragonfly*)
  5246. # FreeBSD uses GNU C++
  5247. ;;
  5248. hpux9* | hpux10* | hpux11*)
  5249. case $cc_basename in
  5250. CC*)
  5251. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5252. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
  5253. if test "$host_cpu" != ia64; then
  5254. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
  5255. fi
  5256. ;;
  5257. aCC*)
  5258. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5259. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
  5260. case $host_cpu in
  5261. hppa*64*|ia64*)
  5262. # +Z the default
  5263. ;;
  5264. *)
  5265. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
  5266. ;;
  5267. esac
  5268. ;;
  5269. *)
  5270. ;;
  5271. esac
  5272. ;;
  5273. interix*)
  5274. # This is c89, which is MS Visual C++ (no shared libs)
  5275. # Anyone wants to do a port?
  5276. ;;
  5277. irix5* | irix6* | nonstopux*)
  5278. case $cc_basename in
  5279. CC*)
  5280. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5281. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
  5282. # CC pic flag -KPIC is the default.
  5283. ;;
  5284. *)
  5285. ;;
  5286. esac
  5287. ;;
  5288. linux* | k*bsd*-gnu)
  5289. case $cc_basename in
  5290. KCC*)
  5291. # KAI C++ Compiler
  5292. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
  5293. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  5294. ;;
  5295. icpc* | ecpc*)
  5296. # Intel C++
  5297. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5298. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  5299. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
  5300. ;;
  5301. pgCC*)
  5302. # Portland Group C++ compiler.
  5303. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5304. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
  5305. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5306. ;;
  5307. cxx*)
  5308. # Compaq C++
  5309. # Make sure the PIC flag is empty. It appears that all Alpha
  5310. # Linux and Compaq Tru64 Unix objects are PIC.
  5311. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
  5312. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
  5313. ;;
  5314. *)
  5315. case `$CC -V 2>&1 | sed 5q` in
  5316. *Sun\ C*)
  5317. # Sun C++ 5.9
  5318. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  5319. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5320. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
  5321. ;;
  5322. esac
  5323. ;;
  5324. esac
  5325. ;;
  5326. lynxos*)
  5327. ;;
  5328. m88k*)
  5329. ;;
  5330. mvs*)
  5331. case $cc_basename in
  5332. cxx*)
  5333. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
  5334. ;;
  5335. *)
  5336. ;;
  5337. esac
  5338. ;;
  5339. netbsd*)
  5340. ;;
  5341. osf3* | osf4* | osf5*)
  5342. case $cc_basename in
  5343. KCC*)
  5344. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
  5345. ;;
  5346. RCC*)
  5347. # Rational C++ 2.4.1
  5348. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
  5349. ;;
  5350. cxx*)
  5351. # Digital/Compaq C++
  5352. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5353. # Make sure the PIC flag is empty. It appears that all Alpha
  5354. # Linux and Compaq Tru64 Unix objects are PIC.
  5355. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
  5356. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
  5357. ;;
  5358. *)
  5359. ;;
  5360. esac
  5361. ;;
  5362. psos*)
  5363. ;;
  5364. solaris*)
  5365. case $cc_basename in
  5366. CC*)
  5367. # Sun C++ 4.2, 5.x and Centerline C++
  5368. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  5369. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5370. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
  5371. ;;
  5372. gcx*)
  5373. # Green Hills C++ Compiler
  5374. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
  5375. ;;
  5376. *)
  5377. ;;
  5378. esac
  5379. ;;
  5380. sunos4*)
  5381. case $cc_basename in
  5382. CC*)
  5383. # Sun C++ 4.x
  5384. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
  5385. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5386. ;;
  5387. lcc*)
  5388. # Lucid
  5389. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
  5390. ;;
  5391. *)
  5392. ;;
  5393. esac
  5394. ;;
  5395. tandem*)
  5396. case $cc_basename in
  5397. NCC*)
  5398. # NonStop-UX NCC 3.20
  5399. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  5400. ;;
  5401. *)
  5402. ;;
  5403. esac
  5404. ;;
  5405. sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
  5406. case $cc_basename in
  5407. CC*)
  5408. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5409. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  5410. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5411. ;;
  5412. esac
  5413. ;;
  5414. vxworks*)
  5415. ;;
  5416. *)
  5417. _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
  5418. ;;
  5419. esac
  5420. fi
  5421. ],
  5422. [
  5423. if test "$GCC" = yes; then
  5424. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5425. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
  5426. case $host_os in
  5427. aix*)
  5428. # All AIX code is PIC.
  5429. if test "$host_cpu" = ia64; then
  5430. # AIX 5 now supports IA64 processor
  5431. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5432. fi
  5433. ;;
  5434. amigaos*)
  5435. # FIXME: we need at least 68020 code to build shared libraries, but
  5436. # adding the `-m68020' flag to GCC prevents building anything better,
  5437. # like `-m68040'.
  5438. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
  5439. ;;
  5440. beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
  5441. # PIC is the default for these OSes.
  5442. ;;
  5443. mingw* | cygwin* | pw32* | os2*)
  5444. # This hack is so that the source file can tell whether it is being
  5445. # built for inclusion in a dll (and should export symbols for example).
  5446. # Although the cygwin gcc ignores -fPIC, still need this for old-style
  5447. # (--disable-auto-import) libraries
  5448. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
  5449. ;;
  5450. darwin* | rhapsody*)
  5451. # PIC is the default on this platform
  5452. # Common symbols not allowed in MH_DYLIB files
  5453. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
  5454. ;;
  5455. interix[[3-9]]*)
  5456. # Interix 3.x gcc -fpic/-fPIC options generate broken code.
  5457. # Instead, we relocate shared libraries at runtime.
  5458. ;;
  5459. msdosdjgpp*)
  5460. # Just because we use GCC doesn't mean we suddenly get shared libraries
  5461. # on systems that don't support them.
  5462. _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
  5463. enable_shared=no
  5464. ;;
  5465. sysv4*MP*)
  5466. if test -d /usr/nec; then
  5467. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
  5468. fi
  5469. ;;
  5470. hpux*)
  5471. # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
  5472. # not for PA HP-UX.
  5473. case $host_cpu in
  5474. hppa*64*|ia64*)
  5475. # +Z the default
  5476. ;;
  5477. *)
  5478. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  5479. ;;
  5480. esac
  5481. ;;
  5482. *)
  5483. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
  5484. ;;
  5485. esac
  5486. else
  5487. # PORTME Check for flag to pass linker flags through the system compiler.
  5488. case $host_os in
  5489. aix*)
  5490. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5491. if test "$host_cpu" = ia64; then
  5492. # AIX 5 now supports IA64 processor
  5493. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5494. else
  5495. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
  5496. fi
  5497. ;;
  5498. darwin*)
  5499. # PIC is the default on this platform
  5500. # Common symbols not allowed in MH_DYLIB files
  5501. case $cc_basename in
  5502. xlc*)
  5503. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
  5504. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5505. ;;
  5506. esac
  5507. ;;
  5508. mingw* | cygwin* | pw32* | os2*)
  5509. # This hack is so that the source file can tell whether it is being
  5510. # built for inclusion in a dll (and should export symbols for example).
  5511. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
  5512. ;;
  5513. hpux9* | hpux10* | hpux11*)
  5514. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5515. # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
  5516. # not for PA HP-UX.
  5517. case $host_cpu in
  5518. hppa*64*|ia64*)
  5519. # +Z the default
  5520. ;;
  5521. *)
  5522. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
  5523. ;;
  5524. esac
  5525. # Is there a better lt_prog_compiler_static that works with the bundled CC?
  5526. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
  5527. ;;
  5528. irix5* | irix6* | nonstopux*)
  5529. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5530. # PIC (with -KPIC) is the default.
  5531. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
  5532. ;;
  5533. newsos6)
  5534. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  5535. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5536. ;;
  5537. linux* | k*bsd*-gnu)
  5538. case $cc_basename in
  5539. icc* | ecc*)
  5540. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5541. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  5542. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
  5543. ;;
  5544. pgcc* | pgf77* | pgf90* | pgf95*)
  5545. # Portland Group compilers (*not* the Pentium gcc compiler,
  5546. # which looks to be a dead project)
  5547. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5548. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
  5549. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5550. ;;
  5551. ccc*)
  5552. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5553. # All Alpha code is PIC.
  5554. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
  5555. ;;
  5556. *)
  5557. case `$CC -V 2>&1 | sed 5q` in
  5558. *Sun\ C*)
  5559. # Sun C 5.9
  5560. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  5561. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5562. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5563. ;;
  5564. *Sun\ F*)
  5565. # Sun Fortran 8.3 passes all unrecognized flags to the linker
  5566. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  5567. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5568. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=''
  5569. ;;
  5570. esac
  5571. ;;
  5572. esac
  5573. ;;
  5574. osf3* | osf4* | osf5*)
  5575. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5576. # All OSF/1 code is PIC.
  5577. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
  5578. ;;
  5579. rdos*)
  5580. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
  5581. ;;
  5582. solaris*)
  5583. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  5584. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5585. case $cc_basename in
  5586. f77* | f90* | f95*)
  5587. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
  5588. *)
  5589. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
  5590. esac
  5591. ;;
  5592. sunos4*)
  5593. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
  5594. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
  5595. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5596. ;;
  5597. sysv4 | sysv4.2uw2* | sysv4.3*)
  5598. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5599. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  5600. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5601. ;;
  5602. sysv4*MP*)
  5603. if test -d /usr/nec ;then
  5604. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
  5605. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5606. fi
  5607. ;;
  5608. sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
  5609. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5610. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
  5611. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5612. ;;
  5613. unicos*)
  5614. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
  5615. _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
  5616. ;;
  5617. uts4*)
  5618. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
  5619. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
  5620. ;;
  5621. *)
  5622. _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
  5623. ;;
  5624. esac
  5625. fi
  5626. ])
  5627. AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)])
  5628. #
  5629. # Check to make sure the PIC flag actually works.
  5630. #
  5631. if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then
  5632. AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works],
  5633. _LT_AC_TAGVAR(lt_prog_compiler_pic_works, $1),
  5634. [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [],
  5635. [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in
  5636. "" | " "*) ;;
  5637. *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;;
  5638. esac],
  5639. [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
  5640. _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
  5641. fi
  5642. case $host_os in
  5643. # For platforms which do not support PIC, -DPIC is meaningless:
  5644. *djgpp*)
  5645. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
  5646. ;;
  5647. *)
  5648. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])"
  5649. ;;
  5650. esac
  5651. #
  5652. # Check to make sure the static flag actually works.
  5653. #
  5654. wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_AC_TAGVAR(lt_prog_compiler_static, $1)\"
  5655. AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
  5656. _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1),
  5657. $lt_tmp_static_flag,
  5658. [],
  5659. [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
  5660. ])
  5661. # AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME])
  5662. # ------------------------------------
  5663. # See if the linker supports building shared libraries.
  5664. AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS],
  5665. [AC_REQUIRE([LT_AC_PROG_SED])dnl
  5666. AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
  5667. ifelse([$1],[CXX],[
  5668. _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
  5669. case $host_os in
  5670. aix4* | aix5*)
  5671. # If we're using GNU nm, then we don't want the "-C" option.
  5672. # -C means demangle to AIX nm, but means don't demangle with GNU nm
  5673. if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
  5674. _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
  5675. else
  5676. _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
  5677. fi
  5678. ;;
  5679. pw32*)
  5680. _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
  5681. ;;
  5682. cygwin* | mingw*)
  5683. _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
  5684. ;;
  5685. *)
  5686. _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
  5687. ;;
  5688. esac
  5689. ],[
  5690. runpath_var=
  5691. _LT_AC_TAGVAR(allow_undefined_flag, $1)=
  5692. _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
  5693. _LT_AC_TAGVAR(archive_cmds, $1)=
  5694. _LT_AC_TAGVAR(archive_expsym_cmds, $1)=
  5695. _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)=
  5696. _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)=
  5697. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
  5698. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
  5699. _LT_AC_TAGVAR(thread_safe_flag_spec, $1)=
  5700. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
  5701. _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
  5702. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
  5703. _LT_AC_TAGVAR(hardcode_direct, $1)=no
  5704. _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
  5705. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
  5706. _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
  5707. _LT_AC_TAGVAR(hardcode_automatic, $1)=no
  5708. _LT_AC_TAGVAR(module_cmds, $1)=
  5709. _LT_AC_TAGVAR(module_expsym_cmds, $1)=
  5710. _LT_AC_TAGVAR(always_export_symbols, $1)=no
  5711. _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
  5712. # include_expsyms should be a list of space-separated symbols to be *always*
  5713. # included in the symbol list
  5714. _LT_AC_TAGVAR(include_expsyms, $1)=
  5715. # exclude_expsyms can be an extended regexp of symbols to exclude
  5716. # it will be wrapped by ` (' and `)$', so one must not match beginning or
  5717. # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
  5718. # as well as any symbol that contains `d'.
  5719. _LT_AC_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_"
  5720. # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
  5721. # platforms (ab)use it in PIC code, but their linkers get confused if
  5722. # the symbol is explicitly referenced. Since portable code cannot
  5723. # rely on this symbol name, it's probably fine to never include it in
  5724. # preloaded symbol tables.
  5725. extract_expsyms_cmds=
  5726. # Just being paranoid about ensuring that cc_basename is set.
  5727. _LT_CC_BASENAME([$compiler])
  5728. case $host_os in
  5729. cygwin* | mingw* | pw32*)
  5730. # FIXME: the MSVC++ port hasn't been tested in a loooong time
  5731. # When not using gcc, we currently assume that we are using
  5732. # Microsoft Visual C++.
  5733. if test "$GCC" != yes; then
  5734. with_gnu_ld=no
  5735. fi
  5736. ;;
  5737. interix*)
  5738. # we just hope/assume this is gcc and not c89 (= MSVC++)
  5739. with_gnu_ld=yes
  5740. ;;
  5741. openbsd*)
  5742. with_gnu_ld=no
  5743. ;;
  5744. esac
  5745. _LT_AC_TAGVAR(ld_shlibs, $1)=yes
  5746. if test "$with_gnu_ld" = yes; then
  5747. # If archive_cmds runs LD, not CC, wlarc should be empty
  5748. wlarc='${wl}'
  5749. # Set some defaults for GNU ld with shared library support. These
  5750. # are reset later if shared libraries are not supported. Putting them
  5751. # here allows them to be overridden if necessary.
  5752. runpath_var=LD_RUN_PATH
  5753. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
  5754. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
  5755. # ancient GNU ld didn't support --whole-archive et. al.
  5756. if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
  5757. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
  5758. else
  5759. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
  5760. fi
  5761. supports_anon_versioning=no
  5762. case `$LD -v 2>/dev/null` in
  5763. *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
  5764. *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
  5765. *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
  5766. *\ 2.11.*) ;; # other 2.11 versions
  5767. *) supports_anon_versioning=yes ;;
  5768. esac
  5769. # See if GNU ld supports shared libraries.
  5770. case $host_os in
  5771. aix3* | aix4* | aix5*)
  5772. # On AIX/PPC, the GNU linker is very broken
  5773. if test "$host_cpu" != ia64; then
  5774. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  5775. cat <<EOF 1>&2
  5776. *** Warning: the GNU linker, at least up to release 2.9.1, is reported
  5777. *** to be unable to reliably create shared libraries on AIX.
  5778. *** Therefore, libtool is disabling shared libraries support. If you
  5779. *** really care for shared libraries, you may want to modify your PATH
  5780. *** so that a non-GNU linker is found, and then restart.
  5781. EOF
  5782. fi
  5783. ;;
  5784. amigaos*)
  5785. _LT_AC_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)'
  5786. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  5787. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
  5788. # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
  5789. # that the semantics of dynamic libraries on AmigaOS, at least up
  5790. # to version 4, is to share data among multiple programs linked
  5791. # with the same dynamic library. Since this doesn't match the
  5792. # behavior of shared libraries on other platforms, we can't use
  5793. # them.
  5794. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  5795. ;;
  5796. beos*)
  5797. if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
  5798. _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
  5799. # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
  5800. # support --undefined. This deserves some investigation. FIXME
  5801. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  5802. else
  5803. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  5804. fi
  5805. ;;
  5806. cygwin* | mingw* | pw32*)
  5807. # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
  5808. # as there is no search path for DLLs.
  5809. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  5810. _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
  5811. _LT_AC_TAGVAR(always_export_symbols, $1)=no
  5812. _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
  5813. _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
  5814. if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
  5815. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
  5816. # If the export-symbols file already is a .def file (1st line
  5817. # is EXPORTS), use it as is; otherwise, prepend...
  5818. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
  5819. cp $export_symbols $output_objdir/$soname.def;
  5820. else
  5821. echo EXPORTS > $output_objdir/$soname.def;
  5822. cat $export_symbols >> $output_objdir/$soname.def;
  5823. fi~
  5824. $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
  5825. else
  5826. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  5827. fi
  5828. ;;
  5829. interix[[3-9]]*)
  5830. _LT_AC_TAGVAR(hardcode_direct, $1)=no
  5831. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  5832. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
  5833. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
  5834. # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
  5835. # Instead, shared libraries are loaded at an image base (0x10000000 by
  5836. # default) and relocated if they conflict, which is a slow very memory
  5837. # consuming and fragmenting process. To avoid this, we pick a random,
  5838. # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
  5839. # time. Moving up from 0x10000000 also allows more sbrk(2) space.
  5840. _LT_AC_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'
  5841. _LT_AC_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'
  5842. ;;
  5843. gnu* | linux* | k*bsd*-gnu)
  5844. if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
  5845. tmp_addflag=
  5846. case $cc_basename,$host_cpu in
  5847. pgcc*) # Portland Group C compiler
  5848. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
  5849. tmp_addflag=' $pic_flag'
  5850. ;;
  5851. pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers
  5852. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
  5853. tmp_addflag=' $pic_flag -Mnomain' ;;
  5854. ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
  5855. tmp_addflag=' -i_dynamic' ;;
  5856. efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
  5857. tmp_addflag=' -i_dynamic -nofor_main' ;;
  5858. ifc* | ifort*) # Intel Fortran compiler
  5859. tmp_addflag=' -nofor_main' ;;
  5860. esac
  5861. case `$CC -V 2>&1 | sed 5q` in
  5862. *Sun\ C*) # Sun C 5.9
  5863. _LT_AC_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; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
  5864. tmp_sharedflag='-G' ;;
  5865. *Sun\ F*) # Sun Fortran 8.3
  5866. tmp_sharedflag='-G' ;;
  5867. *)
  5868. tmp_sharedflag='-shared' ;;
  5869. esac
  5870. _LT_AC_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  5871. if test $supports_anon_versioning = yes; then
  5872. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~
  5873. cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
  5874. $echo "local: *; };" >> $output_objdir/$libname.ver~
  5875. $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
  5876. fi
  5877. else
  5878. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  5879. fi
  5880. ;;
  5881. netbsd*)
  5882. if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
  5883. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
  5884. wlarc=
  5885. else
  5886. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  5887. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
  5888. fi
  5889. ;;
  5890. solaris*)
  5891. if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
  5892. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  5893. cat <<EOF 1>&2
  5894. *** Warning: The releases 2.8.* of the GNU linker cannot reliably
  5895. *** create shared libraries on Solaris systems. Therefore, libtool
  5896. *** is disabling shared libraries support. We urge you to upgrade GNU
  5897. *** binutils to release 2.9.1 or newer. Another option is to modify
  5898. *** your PATH or compiler configuration so that the native linker is
  5899. *** used, and then restart.
  5900. EOF
  5901. elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
  5902. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  5903. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
  5904. else
  5905. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  5906. fi
  5907. ;;
  5908. sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
  5909. case `$LD -v 2>&1` in
  5910. *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
  5911. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  5912. cat <<_LT_EOF 1>&2
  5913. *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
  5914. *** reliably create shared libraries on SCO systems. Therefore, libtool
  5915. *** is disabling shared libraries support. We urge you to upgrade GNU
  5916. *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
  5917. *** your PATH or compiler configuration so that the native linker is
  5918. *** used, and then restart.
  5919. _LT_EOF
  5920. ;;
  5921. *)
  5922. if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
  5923. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
  5924. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib'
  5925. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib'
  5926. else
  5927. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  5928. fi
  5929. ;;
  5930. esac
  5931. ;;
  5932. sunos4*)
  5933. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
  5934. wlarc=
  5935. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  5936. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  5937. ;;
  5938. *)
  5939. if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
  5940. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  5941. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
  5942. else
  5943. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  5944. fi
  5945. ;;
  5946. esac
  5947. if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no; then
  5948. runpath_var=
  5949. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
  5950. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
  5951. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
  5952. fi
  5953. else
  5954. # PORTME fill in a description of your system's linker (not GNU ld)
  5955. case $host_os in
  5956. aix3*)
  5957. _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
  5958. _LT_AC_TAGVAR(always_export_symbols, $1)=yes
  5959. _LT_AC_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'
  5960. # Note: this linker hardcodes the directories in LIBPATH if there
  5961. # are no directories specified by -L.
  5962. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
  5963. if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
  5964. # Neither direct hardcoding nor static linking is supported with a
  5965. # broken collect2.
  5966. _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
  5967. fi
  5968. ;;
  5969. aix4* | aix5*)
  5970. if test "$host_cpu" = ia64; then
  5971. # On IA64, the linker does run time linking by default, so we don't
  5972. # have to do anything special.
  5973. aix_use_runtimelinking=no
  5974. exp_sym_flag='-Bexport'
  5975. no_entry_flag=""
  5976. else
  5977. # If we're using GNU nm, then we don't want the "-C" option.
  5978. # -C means demangle to AIX nm, but means don't demangle with GNU nm
  5979. if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
  5980. _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
  5981. else
  5982. _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
  5983. fi
  5984. aix_use_runtimelinking=no
  5985. # Test if we are trying to use run time linking or normal
  5986. # AIX style linking. If -brtl is somewhere in LDFLAGS, we
  5987. # need to do runtime linking.
  5988. case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
  5989. for ld_flag in $LDFLAGS; do
  5990. if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
  5991. aix_use_runtimelinking=yes
  5992. break
  5993. fi
  5994. done
  5995. ;;
  5996. esac
  5997. exp_sym_flag='-bexport'
  5998. no_entry_flag='-bnoentry'
  5999. fi
  6000. # When large executables or shared objects are built, AIX ld can
  6001. # have problems creating the table of contents. If linking a library
  6002. # or program results in "error TOC overflow" add -mminimal-toc to
  6003. # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
  6004. # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
  6005. _LT_AC_TAGVAR(archive_cmds, $1)=''
  6006. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  6007. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
  6008. _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
  6009. if test "$GCC" = yes; then
  6010. case $host_os in aix4.[[012]]|aix4.[[012]].*)
  6011. # We only want to do this on AIX 4.2 and lower, the check
  6012. # below for broken collect2 doesn't work under 4.3+
  6013. collect2name=`${CC} -print-prog-name=collect2`
  6014. if test -f "$collect2name" && \
  6015. strings "$collect2name" | grep resolve_lib_name >/dev/null
  6016. then
  6017. # We have reworked collect2
  6018. :
  6019. else
  6020. # We have old collect2
  6021. _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
  6022. # It fails to find uninstalled libraries when the uninstalled
  6023. # path is not listed in the libpath. Setting hardcode_minus_L
  6024. # to unsupported forces relinking
  6025. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
  6026. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  6027. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
  6028. fi
  6029. ;;
  6030. esac
  6031. shared_flag='-shared'
  6032. if test "$aix_use_runtimelinking" = yes; then
  6033. shared_flag="$shared_flag "'${wl}-G'
  6034. fi
  6035. else
  6036. # not using gcc
  6037. if test "$host_cpu" = ia64; then
  6038. # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
  6039. # chokes on -Wl,-G. The following line is correct:
  6040. shared_flag='-G'
  6041. else
  6042. if test "$aix_use_runtimelinking" = yes; then
  6043. shared_flag='${wl}-G'
  6044. else
  6045. shared_flag='${wl}-bM:SRE'
  6046. fi
  6047. fi
  6048. fi
  6049. # It seems that -bexpall does not export symbols beginning with
  6050. # underscore (_), so it is better to generate a list of symbols to export.
  6051. _LT_AC_TAGVAR(always_export_symbols, $1)=yes
  6052. if test "$aix_use_runtimelinking" = yes; then
  6053. # Warning - without using the other runtime loading flags (-brtl),
  6054. # -berok will link without error, but may produce a broken library.
  6055. _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
  6056. # Determine the default libpath from the value encoded in an empty executable.
  6057. _LT_AC_SYS_LIBPATH_AIX
  6058. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
  6059. _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
  6060. else
  6061. if test "$host_cpu" = ia64; then
  6062. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
  6063. _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
  6064. _LT_AC_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"
  6065. else
  6066. # Determine the default libpath from the value encoded in an empty executable.
  6067. _LT_AC_SYS_LIBPATH_AIX
  6068. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
  6069. # Warning - without using the other run time loading flags,
  6070. # -berok will link without error, but may produce a broken library.
  6071. _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
  6072. _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
  6073. # Exported symbols can be pulled into shared objects from archives
  6074. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
  6075. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
  6076. # This is similar to how AIX traditionally builds its shared libraries.
  6077. _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
  6078. fi
  6079. fi
  6080. ;;
  6081. amigaos*)
  6082. _LT_AC_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)'
  6083. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  6084. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
  6085. # see comment about different semantics on the GNU ld section
  6086. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  6087. ;;
  6088. bsdi[[45]]*)
  6089. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
  6090. ;;
  6091. cygwin* | mingw* | pw32*)
  6092. # When not using gcc, we currently assume that we are using
  6093. # Microsoft Visual C++.
  6094. # hardcode_libdir_flag_spec is actually meaningless, as there is
  6095. # no search path for DLLs.
  6096. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
  6097. _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
  6098. # Tell ltmain to make .lib files, not .a files.
  6099. libext=lib
  6100. # Tell ltmain to make .dll files, not .so files.
  6101. shrext_cmds=".dll"
  6102. # FIXME: Setting linknames here is a bad hack.
  6103. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
  6104. # The linker will automatically build a .lib file if we build a DLL.
  6105. _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true'
  6106. # FIXME: Should let the user specify the lib program.
  6107. _LT_AC_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
  6108. _LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
  6109. _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
  6110. ;;
  6111. darwin* | rhapsody*)
  6112. case $host_os in
  6113. rhapsody* | darwin1.[[012]])
  6114. _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
  6115. ;;
  6116. *) # Darwin 1.3 on
  6117. if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
  6118. _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
  6119. else
  6120. case ${MACOSX_DEPLOYMENT_TARGET} in
  6121. 10.[[012]])
  6122. _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
  6123. ;;
  6124. 10.*)
  6125. _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
  6126. ;;
  6127. esac
  6128. fi
  6129. ;;
  6130. esac
  6131. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
  6132. _LT_AC_TAGVAR(hardcode_direct, $1)=no
  6133. _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
  6134. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
  6135. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
  6136. _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
  6137. if test "$GCC" = yes ; then
  6138. output_verbose_link_cmd='echo'
  6139. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
  6140. _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
  6141. # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
  6142. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
  6143. _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
  6144. else
  6145. case $cc_basename in
  6146. xlc*)
  6147. output_verbose_link_cmd='echo'
  6148. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
  6149. _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
  6150. # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
  6151. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
  6152. _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
  6153. ;;
  6154. *)
  6155. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  6156. ;;
  6157. esac
  6158. fi
  6159. ;;
  6160. dgux*)
  6161. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  6162. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  6163. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  6164. ;;
  6165. freebsd1*)
  6166. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  6167. ;;
  6168. # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
  6169. # support. Future versions do this automatically, but an explicit c++rt0.o
  6170. # does not break anything, and helps significantly (at the cost of a little
  6171. # extra space).
  6172. freebsd2.2*)
  6173. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
  6174. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
  6175. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  6176. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  6177. ;;
  6178. # Unfortunately, older versions of FreeBSD 2 do not have this feature.
  6179. freebsd2*)
  6180. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
  6181. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  6182. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
  6183. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  6184. ;;
  6185. # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
  6186. freebsd* | dragonfly*)
  6187. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
  6188. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
  6189. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  6190. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  6191. ;;
  6192. hpux9*)
  6193. if test "$GCC" = yes; then
  6194. _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
  6195. else
  6196. _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
  6197. fi
  6198. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
  6199. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  6200. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  6201. # hardcode_minus_L: Not really in the search PATH,
  6202. # but as the default location of the library.
  6203. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
  6204. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
  6205. ;;
  6206. hpux10*)
  6207. if test "$GCC" = yes -a "$with_gnu_ld" = no; then
  6208. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
  6209. else
  6210. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
  6211. fi
  6212. if test "$with_gnu_ld" = no; then
  6213. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
  6214. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  6215. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  6216. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
  6217. # hardcode_minus_L: Not really in the search PATH,
  6218. # but as the default location of the library.
  6219. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
  6220. fi
  6221. ;;
  6222. hpux11*)
  6223. if test "$GCC" = yes -a "$with_gnu_ld" = no; then
  6224. case $host_cpu in
  6225. hppa*64*)
  6226. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  6227. ;;
  6228. ia64*)
  6229. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
  6230. ;;
  6231. *)
  6232. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
  6233. ;;
  6234. esac
  6235. else
  6236. case $host_cpu in
  6237. hppa*64*)
  6238. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  6239. ;;
  6240. ia64*)
  6241. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
  6242. ;;
  6243. *)
  6244. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
  6245. ;;
  6246. esac
  6247. fi
  6248. if test "$with_gnu_ld" = no; then
  6249. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
  6250. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  6251. case $host_cpu in
  6252. hppa*64*|ia64*)
  6253. _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
  6254. _LT_AC_TAGVAR(hardcode_direct, $1)=no
  6255. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  6256. ;;
  6257. *)
  6258. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  6259. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
  6260. # hardcode_minus_L: Not really in the search PATH,
  6261. # but as the default location of the library.
  6262. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
  6263. ;;
  6264. esac
  6265. fi
  6266. ;;
  6267. irix5* | irix6* | nonstopux*)
  6268. if test "$GCC" = yes; then
  6269. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
  6270. else
  6271. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
  6272. _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
  6273. fi
  6274. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
  6275. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  6276. _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
  6277. ;;
  6278. netbsd*)
  6279. if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
  6280. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
  6281. else
  6282. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
  6283. fi
  6284. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
  6285. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  6286. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  6287. ;;
  6288. newsos6)
  6289. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  6290. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  6291. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
  6292. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  6293. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  6294. ;;
  6295. openbsd*)
  6296. if test -f /usr/libexec/ld.so; then
  6297. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  6298. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  6299. if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
  6300. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
  6301. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
  6302. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
  6303. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
  6304. else
  6305. case $host_os in
  6306. openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
  6307. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
  6308. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
  6309. ;;
  6310. *)
  6311. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
  6312. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
  6313. ;;
  6314. esac
  6315. fi
  6316. else
  6317. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  6318. fi
  6319. ;;
  6320. os2*)
  6321. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  6322. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
  6323. _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
  6324. _LT_AC_TAGVAR(archive_cmds, $1)='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
  6325. _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
  6326. ;;
  6327. osf3*)
  6328. if test "$GCC" = yes; then
  6329. _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
  6330. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
  6331. else
  6332. _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
  6333. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
  6334. fi
  6335. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
  6336. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  6337. ;;
  6338. osf4* | osf5*) # as osf3* with the addition of -msym flag
  6339. if test "$GCC" = yes; then
  6340. _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
  6341. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
  6342. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
  6343. else
  6344. _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
  6345. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
  6346. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
  6347. $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp'
  6348. # Both c and cxx compiler support -rpath directly
  6349. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
  6350. fi
  6351. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
  6352. ;;
  6353. solaris*)
  6354. _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
  6355. if test "$GCC" = yes; then
  6356. wlarc='${wl}'
  6357. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  6358. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
  6359. $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
  6360. else
  6361. wlarc=''
  6362. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
  6363. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
  6364. $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
  6365. fi
  6366. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
  6367. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  6368. case $host_os in
  6369. solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
  6370. *)
  6371. # The compiler driver will combine and reorder linker options,
  6372. # but understands `-z linker_flag'. GCC discards it without `$wl',
  6373. # but is careful enough not to reorder.
  6374. # Supported since Solaris 2.6 (maybe 2.5.1?)
  6375. if test "$GCC" = yes; then
  6376. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
  6377. else
  6378. _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
  6379. fi
  6380. ;;
  6381. esac
  6382. _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
  6383. ;;
  6384. sunos4*)
  6385. if test "x$host_vendor" = xsequent; then
  6386. # Use $CC to link under sequent, because it throws in some extra .o
  6387. # files that make .init and .fini sections work.
  6388. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
  6389. else
  6390. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
  6391. fi
  6392. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  6393. _LT_AC_TAGVAR(hardcode_direct, $1)=yes
  6394. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
  6395. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  6396. ;;
  6397. sysv4)
  6398. case $host_vendor in
  6399. sni)
  6400. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  6401. _LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true???
  6402. ;;
  6403. siemens)
  6404. ## LD is ld it makes a PLAMLIB
  6405. ## CC just makes a GrossModule.
  6406. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
  6407. _LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
  6408. _LT_AC_TAGVAR(hardcode_direct, $1)=no
  6409. ;;
  6410. motorola)
  6411. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  6412. _LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
  6413. ;;
  6414. esac
  6415. runpath_var='LD_RUN_PATH'
  6416. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  6417. ;;
  6418. sysv4.3*)
  6419. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  6420. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  6421. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
  6422. ;;
  6423. sysv4*MP*)
  6424. if test -d /usr/nec; then
  6425. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  6426. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  6427. runpath_var=LD_RUN_PATH
  6428. hardcode_runpath_var=yes
  6429. _LT_AC_TAGVAR(ld_shlibs, $1)=yes
  6430. fi
  6431. ;;
  6432. sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
  6433. _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
  6434. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
  6435. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  6436. runpath_var='LD_RUN_PATH'
  6437. if test "$GCC" = yes; then
  6438. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  6439. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  6440. else
  6441. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  6442. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
  6443. fi
  6444. ;;
  6445. sysv5* | sco3.2v5* | sco5v6*)
  6446. # Note: We can NOT use -z defs as we might desire, because we do not
  6447. # link with -lc, and that would cause any symbols used from libc to
  6448. # always be unresolved, which means just about no library would
  6449. # ever link correctly. If we're not using GNU ld we use -z text
  6450. # though, which does catch some bad symbols but isn't as heavy-handed
  6451. # as -z defs.
  6452. _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
  6453. _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
  6454. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
  6455. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  6456. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
  6457. _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
  6458. _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
  6459. _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
  6460. runpath_var='LD_RUN_PATH'
  6461. if test "$GCC" = yes; then
  6462. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
  6463. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
  6464. else
  6465. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
  6466. _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
  6467. fi
  6468. ;;
  6469. uts4*)
  6470. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  6471. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
  6472. _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
  6473. ;;
  6474. *)
  6475. _LT_AC_TAGVAR(ld_shlibs, $1)=no
  6476. ;;
  6477. esac
  6478. fi
  6479. ])
  6480. AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
  6481. test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
  6482. #
  6483. # Do we need to explicitly link libc?
  6484. #
  6485. case "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in
  6486. x|xyes)
  6487. # Assume -lc should be added
  6488. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
  6489. if test "$enable_shared" = yes && test "$GCC" = yes; then
  6490. case $_LT_AC_TAGVAR(archive_cmds, $1) in
  6491. *'~'*)
  6492. # FIXME: we may have to deal with multi-command sequences.
  6493. ;;
  6494. '$CC '*)
  6495. # Test whether the compiler implicitly links with -lc since on some
  6496. # systems, -lgcc has to come before -lc. If gcc already passes -lc
  6497. # to ld, don't add -lc before -lgcc.
  6498. AC_MSG_CHECKING([whether -lc should be explicitly linked in])
  6499. $rm conftest*
  6500. echo "$lt_simple_compile_test_code" > conftest.$ac_ext
  6501. if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
  6502. soname=conftest
  6503. lib=conftest
  6504. libobjs=conftest.$ac_objext
  6505. deplibs=
  6506. wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
  6507. pic_flag=$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
  6508. compiler_flags=-v
  6509. linker_flags=-v
  6510. verstring=
  6511. output_objdir=.
  6512. libname=conftest
  6513. lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1)
  6514. _LT_AC_TAGVAR(allow_undefined_flag, $1)=
  6515. if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1)
  6516. then
  6517. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
  6518. else
  6519. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
  6520. fi
  6521. _LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
  6522. else
  6523. cat conftest.err 1>&5
  6524. fi
  6525. $rm conftest*
  6526. AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)])
  6527. ;;
  6528. esac
  6529. fi
  6530. ;;
  6531. esac
  6532. ])# AC_LIBTOOL_PROG_LD_SHLIBS
  6533. # _LT_AC_FILE_LTDLL_C
  6534. # -------------------
  6535. # Be careful that the start marker always follows a newline.
  6536. AC_DEFUN([_LT_AC_FILE_LTDLL_C], [
  6537. # /* ltdll.c starts here */
  6538. # #define WIN32_LEAN_AND_MEAN
  6539. # #include <windows.h>
  6540. # #undef WIN32_LEAN_AND_MEAN
  6541. # #include <stdio.h>
  6542. #
  6543. # #ifndef __CYGWIN__
  6544. # # ifdef __CYGWIN32__
  6545. # # define __CYGWIN__ __CYGWIN32__
  6546. # # endif
  6547. # #endif
  6548. #
  6549. # #ifdef __cplusplus
  6550. # extern "C" {
  6551. # #endif
  6552. # BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved);
  6553. # #ifdef __cplusplus
  6554. # }
  6555. # #endif
  6556. #
  6557. # #ifdef __CYGWIN__
  6558. # #include <cygwin/cygwin_dll.h>
  6559. # DECLARE_CYGWIN_DLL( DllMain );
  6560. # #endif
  6561. # HINSTANCE __hDllInstance_base;
  6562. #
  6563. # BOOL APIENTRY
  6564. # DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved)
  6565. # {
  6566. # __hDllInstance_base = hInst;
  6567. # return TRUE;
  6568. # }
  6569. # /* ltdll.c ends here */
  6570. ])# _LT_AC_FILE_LTDLL_C
  6571. # _LT_AC_TAGVAR(VARNAME, [TAGNAME])
  6572. # ---------------------------------
  6573. AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])])
  6574. # old names
  6575. AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL])
  6576. AC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
  6577. AC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
  6578. AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
  6579. AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
  6580. AC_DEFUN([AM_PROG_LD], [AC_PROG_LD])
  6581. AC_DEFUN([AM_PROG_NM], [AC_PROG_NM])
  6582. # This is just to silence aclocal about the macro not being used
  6583. ifelse([AC_DISABLE_FAST_INSTALL])
  6584. AC_DEFUN([LT_AC_PROG_GCJ],
  6585. [AC_CHECK_TOOL(GCJ, gcj, no)
  6586. test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
  6587. AC_SUBST(GCJFLAGS)
  6588. ])
  6589. AC_DEFUN([LT_AC_PROG_RC],
  6590. [AC_CHECK_TOOL(RC, windres, no)
  6591. ])
  6592. # Cheap backport of AS_EXECUTABLE_P and required macros
  6593. # from Autoconf 2.59; we should not use $as_executable_p directly.
  6594. # _AS_TEST_PREPARE
  6595. # ----------------
  6596. m4_ifndef([_AS_TEST_PREPARE],
  6597. [m4_defun([_AS_TEST_PREPARE],
  6598. [if test -x / >/dev/null 2>&1; then
  6599. as_executable_p='test -x'
  6600. else
  6601. as_executable_p='test -f'
  6602. fi
  6603. ])])# _AS_TEST_PREPARE
  6604. # AS_EXECUTABLE_P
  6605. # ---------------
  6606. # Check whether a file is executable.
  6607. m4_ifndef([AS_EXECUTABLE_P],
  6608. [m4_defun([AS_EXECUTABLE_P],
  6609. [AS_REQUIRE([_AS_TEST_PREPARE])dnl
  6610. $as_executable_p $1[]dnl
  6611. ])])# AS_EXECUTABLE_P
  6612. # NOTE: This macro has been submitted for inclusion into #
  6613. # GNU Autoconf as AC_PROG_SED. When it is available in #
  6614. # a released version of Autoconf we should remove this #
  6615. # macro and use it instead. #
  6616. # LT_AC_PROG_SED
  6617. # --------------
  6618. # Check for a fully-functional sed program, that truncates
  6619. # as few characters as possible. Prefer GNU sed if found.
  6620. AC_DEFUN([LT_AC_PROG_SED],
  6621. [AC_MSG_CHECKING([for a sed that does not truncate output])
  6622. AC_CACHE_VAL(lt_cv_path_SED,
  6623. [# Loop through the user's path and test for sed and gsed.
  6624. # Then use that list of sed's as ones to test for truncation.
  6625. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6626. for as_dir in $PATH
  6627. do
  6628. IFS=$as_save_IFS
  6629. test -z "$as_dir" && as_dir=.
  6630. for lt_ac_prog in sed gsed; do
  6631. for ac_exec_ext in '' $ac_executable_extensions; do
  6632. if AS_EXECUTABLE_P(["$as_dir/$lt_ac_prog$ac_exec_ext"]); then
  6633. lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
  6634. fi
  6635. done
  6636. done
  6637. done
  6638. IFS=$as_save_IFS
  6639. lt_ac_max=0
  6640. lt_ac_count=0
  6641. # Add /usr/xpg4/bin/sed as it is typically found on Solaris
  6642. # along with /bin/sed that truncates output.
  6643. for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
  6644. test ! -f $lt_ac_sed && continue
  6645. cat /dev/null > conftest.in
  6646. lt_ac_count=0
  6647. echo $ECHO_N "0123456789$ECHO_C" >conftest.in
  6648. # Check for GNU sed and select it if it is found.
  6649. if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
  6650. lt_cv_path_SED=$lt_ac_sed
  6651. break
  6652. fi
  6653. while true; do
  6654. cat conftest.in conftest.in >conftest.tmp
  6655. mv conftest.tmp conftest.in
  6656. cp conftest.in conftest.nl
  6657. echo >>conftest.nl
  6658. $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
  6659. cmp -s conftest.out conftest.nl || break
  6660. # 10000 chars as input seems more than enough
  6661. test $lt_ac_count -gt 10 && break
  6662. lt_ac_count=`expr $lt_ac_count + 1`
  6663. if test $lt_ac_count -gt $lt_ac_max; then
  6664. lt_ac_max=$lt_ac_count
  6665. lt_cv_path_SED=$lt_ac_sed
  6666. fi
  6667. done
  6668. done
  6669. ])
  6670. SED=$lt_cv_path_SED
  6671. AC_SUBST([SED])
  6672. AC_MSG_RESULT([$SED])
  6673. ])