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

aclocal.m4 308KB

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