aclocal.m4 261 KB

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