A C standard library for sh3eb-elf.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

libtool.m4 258KB

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