libtool.m4 226 KB

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