configure 878 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192419341944195419641974198419942004201420242034204420542064207420842094210421142124213421442154216421742184219422042214222422342244225422642274228422942304231423242334234423542364237423842394240424142424243424442454246424742484249425042514252425342544255425642574258425942604261426242634264426542664267426842694270427142724273427442754276427742784279428042814282428342844285428642874288428942904291429242934294429542964297429842994300430143024303430443054306430743084309431043114312431343144315431643174318431943204321432243234324432543264327432843294330433143324333433443354336433743384339434043414342434343444345434643474348434943504351435243534354435543564357435843594360436143624363436443654366436743684369437043714372437343744375437643774378437943804381438243834384438543864387438843894390439143924393439443954396439743984399440044014402440344044405440644074408440944104411441244134414441544164417441844194420442144224423442444254426442744284429443044314432443344344435443644374438443944404441444244434444444544464447444844494450445144524453445444554456445744584459446044614462446344644465446644674468446944704471447244734474447544764477447844794480448144824483448444854486448744884489449044914492449344944495449644974498449945004501450245034504450545064507450845094510451145124513451445154516451745184519452045214522452345244525452645274528452945304531453245334534453545364537453845394540454145424543454445454546454745484549455045514552455345544555455645574558455945604561456245634564456545664567456845694570457145724573457445754576457745784579458045814582458345844585458645874588458945904591459245934594459545964597459845994600460146024603460446054606460746084609461046114612461346144615461646174618461946204621462246234624462546264627462846294630463146324633463446354636463746384639464046414642464346444645464646474648464946504651465246534654465546564657465846594660466146624663466446654666466746684669467046714672467346744675467646774678467946804681468246834684468546864687468846894690469146924693469446954696469746984699470047014702470347044705470647074708470947104711471247134714471547164717471847194720472147224723472447254726472747284729473047314732473347344735473647374738473947404741474247434744474547464747474847494750475147524753475447554756475747584759476047614762476347644765476647674768476947704771477247734774477547764777477847794780478147824783478447854786478747884789479047914792479347944795479647974798479948004801480248034804480548064807480848094810481148124813481448154816481748184819482048214822482348244825482648274828482948304831483248334834483548364837483848394840484148424843484448454846484748484849485048514852485348544855485648574858485948604861486248634864486548664867486848694870487148724873487448754876487748784879488048814882488348844885488648874888488948904891489248934894489548964897489848994900490149024903490449054906490749084909491049114912491349144915491649174918491949204921492249234924492549264927492849294930493149324933493449354936493749384939494049414942494349444945494649474948494949504951495249534954495549564957495849594960496149624963496449654966496749684969497049714972497349744975497649774978497949804981498249834984498549864987498849894990499149924993499449954996499749984999500050015002500350045005500650075008500950105011501250135014501550165017501850195020502150225023502450255026502750285029503050315032503350345035503650375038503950405041504250435044504550465047504850495050505150525053505450555056505750585059506050615062506350645065506650675068506950705071507250735074507550765077507850795080508150825083508450855086508750885089509050915092509350945095509650975098509951005101510251035104510551065107510851095110511151125113511451155116511751185119512051215122512351245125512651275128512951305131513251335134513551365137513851395140514151425143514451455146514751485149515051515152515351545155515651575158515951605161516251635164516551665167516851695170517151725173517451755176517751785179518051815182518351845185518651875188518951905191519251935194519551965197519851995200520152025203520452055206520752085209521052115212521352145215521652175218521952205221522252235224522552265227522852295230523152325233523452355236523752385239524052415242524352445245524652475248524952505251525252535254525552565257525852595260526152625263526452655266526752685269527052715272527352745275527652775278527952805281528252835284528552865287528852895290529152925293529452955296529752985299530053015302530353045305530653075308530953105311531253135314531553165317531853195320532153225323532453255326532753285329533053315332533353345335533653375338533953405341534253435344534553465347534853495350535153525353535453555356535753585359536053615362536353645365536653675368536953705371537253735374537553765377537853795380538153825383538453855386538753885389539053915392539353945395539653975398539954005401540254035404540554065407540854095410541154125413541454155416541754185419542054215422542354245425542654275428542954305431543254335434543554365437543854395440544154425443544454455446544754485449545054515452545354545455545654575458545954605461546254635464546554665467546854695470547154725473547454755476547754785479548054815482548354845485548654875488548954905491549254935494549554965497549854995500550155025503550455055506550755085509551055115512551355145515551655175518551955205521552255235524552555265527552855295530553155325533553455355536553755385539554055415542554355445545554655475548554955505551555255535554555555565557555855595560556155625563556455655566556755685569557055715572557355745575557655775578557955805581558255835584558555865587558855895590559155925593559455955596559755985599560056015602560356045605560656075608560956105611561256135614561556165617561856195620562156225623562456255626562756285629563056315632563356345635563656375638563956405641564256435644564556465647564856495650565156525653565456555656565756585659566056615662566356645665566656675668566956705671567256735674567556765677567856795680568156825683568456855686568756885689569056915692569356945695569656975698569957005701570257035704570557065707570857095710571157125713571457155716571757185719572057215722572357245725572657275728572957305731573257335734573557365737573857395740574157425743574457455746574757485749575057515752575357545755575657575758575957605761576257635764576557665767576857695770577157725773577457755776577757785779578057815782578357845785578657875788578957905791579257935794579557965797579857995800580158025803580458055806580758085809581058115812581358145815581658175818581958205821582258235824582558265827582858295830583158325833583458355836583758385839584058415842584358445845584658475848584958505851585258535854585558565857585858595860586158625863586458655866586758685869587058715872587358745875587658775878587958805881588258835884588558865887588858895890589158925893589458955896589758985899590059015902590359045905590659075908590959105911591259135914591559165917591859195920592159225923592459255926592759285929593059315932593359345935593659375938593959405941594259435944594559465947594859495950595159525953595459555956595759585959596059615962596359645965596659675968596959705971597259735974597559765977597859795980598159825983598459855986598759885989599059915992599359945995599659975998599960006001600260036004600560066007600860096010601160126013601460156016601760186019602060216022602360246025602660276028602960306031603260336034603560366037603860396040604160426043604460456046604760486049605060516052605360546055605660576058605960606061606260636064606560666067606860696070607160726073607460756076607760786079608060816082608360846085608660876088608960906091609260936094609560966097609860996100610161026103610461056106610761086109611061116112611361146115611661176118611961206121612261236124612561266127612861296130613161326133613461356136613761386139614061416142614361446145614661476148614961506151615261536154615561566157615861596160616161626163616461656166616761686169617061716172617361746175617661776178617961806181618261836184618561866187618861896190619161926193619461956196619761986199620062016202620362046205620662076208620962106211621262136214621562166217621862196220622162226223622462256226622762286229623062316232623362346235623662376238623962406241624262436244624562466247624862496250625162526253625462556256625762586259626062616262626362646265626662676268626962706271627262736274627562766277627862796280628162826283628462856286628762886289629062916292629362946295629662976298629963006301630263036304630563066307630863096310631163126313631463156316631763186319632063216322632363246325632663276328632963306331633263336334633563366337633863396340634163426343634463456346634763486349635063516352635363546355635663576358635963606361636263636364636563666367636863696370637163726373637463756376637763786379638063816382638363846385638663876388638963906391639263936394639563966397639863996400640164026403640464056406640764086409641064116412641364146415641664176418641964206421642264236424642564266427642864296430643164326433643464356436643764386439644064416442644364446445644664476448644964506451645264536454645564566457645864596460646164626463646464656466646764686469647064716472647364746475647664776478647964806481648264836484648564866487648864896490649164926493649464956496649764986499650065016502650365046505650665076508650965106511651265136514651565166517651865196520652165226523652465256526652765286529653065316532653365346535653665376538653965406541654265436544654565466547654865496550655165526553655465556556655765586559656065616562656365646565656665676568656965706571657265736574657565766577657865796580658165826583658465856586658765886589659065916592659365946595659665976598659966006601660266036604660566066607660866096610661166126613661466156616661766186619662066216622662366246625662666276628662966306631663266336634663566366637663866396640664166426643664466456646664766486649665066516652665366546655665666576658665966606661666266636664666566666667666866696670667166726673667466756676667766786679668066816682668366846685668666876688668966906691669266936694669566966697669866996700670167026703670467056706670767086709671067116712671367146715671667176718671967206721672267236724672567266727672867296730673167326733673467356736673767386739674067416742674367446745674667476748674967506751675267536754675567566757675867596760676167626763676467656766676767686769677067716772677367746775677667776778677967806781678267836784678567866787678867896790679167926793679467956796679767986799680068016802680368046805680668076808680968106811681268136814681568166817681868196820682168226823682468256826682768286829683068316832683368346835683668376838683968406841684268436844684568466847684868496850685168526853685468556856685768586859686068616862686368646865686668676868686968706871687268736874687568766877687868796880688168826883688468856886688768886889689068916892689368946895689668976898689969006901690269036904690569066907690869096910691169126913691469156916691769186919692069216922692369246925692669276928692969306931693269336934693569366937693869396940694169426943694469456946694769486949695069516952695369546955695669576958695969606961696269636964696569666967696869696970697169726973697469756976697769786979698069816982698369846985698669876988698969906991699269936994699569966997699869997000700170027003700470057006700770087009701070117012701370147015701670177018701970207021702270237024702570267027702870297030703170327033703470357036703770387039704070417042704370447045704670477048704970507051705270537054705570567057705870597060706170627063706470657066706770687069707070717072707370747075707670777078707970807081708270837084708570867087708870897090709170927093709470957096709770987099710071017102710371047105710671077108710971107111711271137114711571167117711871197120712171227123712471257126712771287129713071317132713371347135713671377138713971407141714271437144714571467147714871497150715171527153715471557156715771587159716071617162716371647165716671677168716971707171717271737174717571767177717871797180718171827183718471857186718771887189719071917192719371947195719671977198719972007201720272037204720572067207720872097210721172127213721472157216721772187219722072217222722372247225722672277228722972307231723272337234723572367237723872397240724172427243724472457246724772487249725072517252725372547255725672577258725972607261726272637264726572667267726872697270727172727273727472757276727772787279728072817282728372847285728672877288728972907291729272937294729572967297729872997300730173027303730473057306730773087309731073117312731373147315731673177318731973207321732273237324732573267327732873297330733173327333733473357336733773387339734073417342734373447345734673477348734973507351735273537354735573567357735873597360736173627363736473657366736773687369737073717372737373747375737673777378737973807381738273837384738573867387738873897390739173927393739473957396739773987399740074017402740374047405740674077408740974107411741274137414741574167417741874197420742174227423742474257426742774287429743074317432743374347435743674377438743974407441744274437444744574467447744874497450745174527453745474557456745774587459746074617462746374647465746674677468746974707471747274737474747574767477747874797480748174827483748474857486748774887489749074917492749374947495749674977498749975007501750275037504750575067507750875097510751175127513751475157516751775187519752075217522752375247525752675277528752975307531753275337534753575367537753875397540754175427543754475457546754775487549755075517552755375547555755675577558755975607561756275637564756575667567756875697570757175727573757475757576757775787579758075817582758375847585758675877588758975907591759275937594759575967597759875997600760176027603760476057606760776087609761076117612761376147615761676177618761976207621762276237624762576267627762876297630763176327633763476357636763776387639764076417642764376447645764676477648764976507651765276537654765576567657765876597660766176627663766476657666766776687669767076717672767376747675767676777678767976807681768276837684768576867687768876897690769176927693769476957696769776987699770077017702770377047705770677077708770977107711771277137714771577167717771877197720772177227723772477257726772777287729773077317732773377347735773677377738773977407741774277437744774577467747774877497750775177527753775477557756775777587759776077617762776377647765776677677768776977707771777277737774777577767777777877797780778177827783778477857786778777887789779077917792779377947795779677977798779978007801780278037804780578067807780878097810781178127813781478157816781778187819782078217822782378247825782678277828782978307831783278337834783578367837783878397840784178427843784478457846784778487849785078517852785378547855785678577858785978607861786278637864786578667867786878697870787178727873787478757876787778787879788078817882788378847885788678877888788978907891789278937894789578967897789878997900790179027903790479057906790779087909791079117912791379147915791679177918791979207921792279237924792579267927792879297930793179327933793479357936793779387939794079417942794379447945794679477948794979507951795279537954795579567957795879597960796179627963796479657966796779687969797079717972797379747975797679777978797979807981798279837984798579867987798879897990799179927993799479957996799779987999800080018002800380048005800680078008800980108011801280138014801580168017801880198020802180228023802480258026802780288029803080318032803380348035803680378038803980408041804280438044804580468047804880498050805180528053805480558056805780588059806080618062806380648065806680678068806980708071807280738074807580768077807880798080808180828083808480858086808780888089809080918092809380948095809680978098809981008101810281038104810581068107810881098110811181128113811481158116811781188119812081218122812381248125812681278128812981308131813281338134813581368137813881398140814181428143814481458146814781488149815081518152815381548155815681578158815981608161816281638164816581668167816881698170817181728173817481758176817781788179818081818182818381848185818681878188818981908191819281938194819581968197819881998200820182028203820482058206820782088209821082118212821382148215821682178218821982208221822282238224822582268227822882298230823182328233823482358236823782388239824082418242824382448245824682478248824982508251825282538254825582568257825882598260826182628263826482658266826782688269827082718272827382748275827682778278827982808281828282838284828582868287828882898290829182928293829482958296829782988299830083018302830383048305830683078308830983108311831283138314831583168317831883198320832183228323832483258326832783288329833083318332833383348335833683378338833983408341834283438344834583468347834883498350835183528353835483558356835783588359836083618362836383648365836683678368836983708371837283738374837583768377837883798380838183828383838483858386838783888389839083918392839383948395839683978398839984008401840284038404840584068407840884098410841184128413841484158416841784188419842084218422842384248425842684278428842984308431843284338434843584368437843884398440844184428443844484458446844784488449845084518452845384548455845684578458845984608461846284638464846584668467846884698470847184728473847484758476847784788479848084818482848384848485848684878488848984908491849284938494849584968497849884998500850185028503850485058506850785088509851085118512851385148515851685178518851985208521852285238524852585268527852885298530853185328533853485358536853785388539854085418542854385448545854685478548854985508551855285538554855585568557855885598560856185628563856485658566856785688569857085718572857385748575857685778578857985808581858285838584858585868587858885898590859185928593859485958596859785988599860086018602860386048605860686078608860986108611861286138614861586168617861886198620862186228623862486258626862786288629863086318632863386348635863686378638863986408641864286438644864586468647864886498650865186528653865486558656865786588659866086618662866386648665866686678668866986708671867286738674867586768677867886798680868186828683868486858686868786888689869086918692869386948695869686978698869987008701870287038704870587068707870887098710871187128713871487158716871787188719872087218722872387248725872687278728872987308731873287338734873587368737873887398740874187428743874487458746874787488749875087518752875387548755875687578758875987608761876287638764876587668767876887698770877187728773877487758776877787788779878087818782878387848785878687878788878987908791879287938794879587968797879887998800880188028803880488058806880788088809881088118812881388148815881688178818881988208821882288238824882588268827882888298830883188328833883488358836883788388839884088418842884388448845884688478848884988508851885288538854885588568857885888598860886188628863886488658866886788688869887088718872887388748875887688778878887988808881888288838884888588868887888888898890889188928893889488958896889788988899890089018902890389048905890689078908890989108911891289138914891589168917891889198920892189228923892489258926892789288929893089318932893389348935893689378938893989408941894289438944894589468947894889498950895189528953895489558956895789588959896089618962896389648965896689678968896989708971897289738974897589768977897889798980898189828983898489858986898789888989899089918992899389948995899689978998899990009001900290039004900590069007900890099010901190129013901490159016901790189019902090219022902390249025902690279028902990309031903290339034903590369037903890399040904190429043904490459046904790489049905090519052905390549055905690579058905990609061906290639064906590669067906890699070907190729073907490759076907790789079908090819082908390849085908690879088908990909091909290939094909590969097909890999100910191029103910491059106910791089109911091119112911391149115911691179118911991209121912291239124912591269127912891299130913191329133913491359136913791389139914091419142914391449145914691479148914991509151915291539154915591569157915891599160916191629163916491659166916791689169917091719172917391749175917691779178917991809181918291839184918591869187918891899190919191929193919491959196919791989199920092019202920392049205920692079208920992109211921292139214921592169217921892199220922192229223922492259226922792289229923092319232923392349235923692379238923992409241924292439244924592469247924892499250925192529253925492559256925792589259926092619262926392649265926692679268926992709271927292739274927592769277927892799280928192829283928492859286928792889289929092919292929392949295929692979298929993009301930293039304930593069307930893099310931193129313931493159316931793189319932093219322932393249325932693279328932993309331933293339334933593369337933893399340934193429343934493459346934793489349935093519352935393549355935693579358935993609361936293639364936593669367936893699370937193729373937493759376937793789379938093819382938393849385938693879388938993909391939293939394939593969397939893999400940194029403940494059406940794089409941094119412941394149415941694179418941994209421942294239424942594269427942894299430943194329433943494359436943794389439944094419442944394449445944694479448944994509451945294539454945594569457945894599460946194629463946494659466946794689469947094719472947394749475947694779478947994809481948294839484948594869487948894899490949194929493949494959496949794989499950095019502950395049505950695079508950995109511951295139514951595169517951895199520952195229523952495259526952795289529953095319532953395349535953695379538953995409541954295439544954595469547954895499550955195529553955495559556955795589559956095619562956395649565956695679568956995709571957295739574957595769577957895799580958195829583958495859586958795889589959095919592959395949595959695979598959996009601960296039604960596069607960896099610961196129613961496159616961796189619962096219622962396249625962696279628962996309631963296339634963596369637963896399640964196429643964496459646964796489649965096519652965396549655965696579658965996609661966296639664966596669667966896699670967196729673967496759676967796789679968096819682968396849685968696879688968996909691969296939694969596969697969896999700970197029703970497059706970797089709971097119712971397149715971697179718971997209721972297239724972597269727972897299730973197329733973497359736973797389739974097419742974397449745974697479748974997509751975297539754975597569757975897599760976197629763976497659766976797689769977097719772977397749775977697779778977997809781978297839784978597869787978897899790979197929793979497959796979797989799980098019802980398049805980698079808980998109811981298139814981598169817981898199820982198229823982498259826982798289829983098319832983398349835983698379838983998409841984298439844984598469847984898499850985198529853985498559856985798589859986098619862986398649865986698679868986998709871987298739874987598769877987898799880988198829883988498859886988798889889989098919892989398949895989698979898989999009901990299039904990599069907990899099910991199129913991499159916991799189919992099219922992399249925992699279928992999309931993299339934993599369937993899399940994199429943994499459946994799489949995099519952995399549955995699579958995999609961996299639964996599669967996899699970997199729973997499759976997799789979998099819982998399849985998699879988998999909991999299939994999599969997999899991000010001100021000310004100051000610007100081000910010100111001210013100141001510016100171001810019100201002110022100231002410025100261002710028100291003010031100321003310034100351003610037100381003910040100411004210043100441004510046100471004810049100501005110052100531005410055100561005710058100591006010061100621006310064100651006610067100681006910070100711007210073100741007510076100771007810079100801008110082100831008410085100861008710088100891009010091100921009310094100951009610097100981009910100101011010210103101041010510106101071010810109101101011110112101131011410115101161011710118101191012010121101221012310124101251012610127101281012910130101311013210133101341013510136101371013810139101401014110142101431014410145101461014710148101491015010151101521015310154101551015610157101581015910160101611016210163101641016510166101671016810169101701017110172101731017410175101761017710178101791018010181101821018310184101851018610187101881018910190101911019210193101941019510196101971019810199102001020110202102031020410205102061020710208102091021010211102121021310214102151021610217102181021910220102211022210223102241022510226102271022810229102301023110232102331023410235102361023710238102391024010241102421024310244102451024610247102481024910250102511025210253102541025510256102571025810259102601026110262102631026410265102661026710268102691027010271102721027310274102751027610277102781027910280102811028210283102841028510286102871028810289102901029110292102931029410295102961029710298102991030010301103021030310304103051030610307103081030910310103111031210313103141031510316103171031810319103201032110322103231032410325103261032710328103291033010331103321033310334103351033610337103381033910340103411034210343103441034510346103471034810349103501035110352103531035410355103561035710358103591036010361103621036310364103651036610367103681036910370103711037210373103741037510376103771037810379103801038110382103831038410385103861038710388103891039010391103921039310394103951039610397103981039910400104011040210403104041040510406104071040810409104101041110412104131041410415104161041710418104191042010421104221042310424104251042610427104281042910430104311043210433104341043510436104371043810439104401044110442104431044410445104461044710448104491045010451104521045310454104551045610457104581045910460104611046210463104641046510466104671046810469104701047110472104731047410475104761047710478104791048010481104821048310484104851048610487104881048910490104911049210493104941049510496104971049810499105001050110502105031050410505105061050710508105091051010511105121051310514105151051610517105181051910520105211052210523105241052510526105271052810529105301053110532105331053410535105361053710538105391054010541105421054310544105451054610547105481054910550105511055210553105541055510556105571055810559105601056110562105631056410565105661056710568105691057010571105721057310574105751057610577105781057910580105811058210583105841058510586105871058810589105901059110592105931059410595105961059710598105991060010601106021060310604106051060610607106081060910610106111061210613106141061510616106171061810619106201062110622106231062410625106261062710628106291063010631106321063310634106351063610637106381063910640106411064210643106441064510646106471064810649106501065110652106531065410655106561065710658106591066010661106621066310664106651066610667106681066910670106711067210673106741067510676106771067810679106801068110682106831068410685106861068710688106891069010691106921069310694106951069610697106981069910700107011070210703107041070510706107071070810709107101071110712107131071410715107161071710718107191072010721107221072310724107251072610727107281072910730107311073210733107341073510736107371073810739107401074110742107431074410745107461074710748107491075010751107521075310754107551075610757107581075910760107611076210763107641076510766107671076810769107701077110772107731077410775107761077710778107791078010781107821078310784107851078610787107881078910790107911079210793107941079510796107971079810799108001080110802108031080410805108061080710808108091081010811108121081310814108151081610817108181081910820108211082210823108241082510826108271082810829108301083110832108331083410835108361083710838108391084010841108421084310844108451084610847108481084910850108511085210853108541085510856108571085810859108601086110862108631086410865108661086710868108691087010871108721087310874108751087610877108781087910880108811088210883108841088510886108871088810889108901089110892108931089410895108961089710898108991090010901109021090310904109051090610907109081090910910109111091210913109141091510916109171091810919109201092110922109231092410925109261092710928109291093010931109321093310934109351093610937109381093910940109411094210943109441094510946109471094810949109501095110952109531095410955109561095710958109591096010961109621096310964109651096610967109681096910970109711097210973109741097510976109771097810979109801098110982109831098410985109861098710988109891099010991109921099310994109951099610997109981099911000110011100211003110041100511006110071100811009110101101111012110131101411015110161101711018110191102011021110221102311024110251102611027110281102911030110311103211033110341103511036110371103811039110401104111042110431104411045110461104711048110491105011051110521105311054110551105611057110581105911060110611106211063110641106511066110671106811069110701107111072110731107411075110761107711078110791108011081110821108311084110851108611087110881108911090110911109211093110941109511096110971109811099111001110111102111031110411105111061110711108111091111011111111121111311114111151111611117111181111911120111211112211123111241112511126111271112811129111301113111132111331113411135111361113711138111391114011141111421114311144111451114611147111481114911150111511115211153111541115511156111571115811159111601116111162111631116411165111661116711168111691117011171111721117311174111751117611177111781117911180111811118211183111841118511186111871118811189111901119111192111931119411195111961119711198111991120011201112021120311204112051120611207112081120911210112111121211213112141121511216112171121811219112201122111222112231122411225112261122711228112291123011231112321123311234112351123611237112381123911240112411124211243112441124511246112471124811249112501125111252112531125411255112561125711258112591126011261112621126311264112651126611267112681126911270112711127211273112741127511276112771127811279112801128111282112831128411285112861128711288112891129011291112921129311294112951129611297112981129911300113011130211303113041130511306113071130811309113101131111312113131131411315113161131711318113191132011321113221132311324113251132611327113281132911330113311133211333113341133511336113371133811339113401134111342113431134411345113461134711348113491135011351113521135311354113551135611357113581135911360113611136211363113641136511366113671136811369113701137111372113731137411375113761137711378113791138011381113821138311384113851138611387113881138911390113911139211393113941139511396113971139811399114001140111402114031140411405114061140711408114091141011411114121141311414114151141611417114181141911420114211142211423114241142511426114271142811429114301143111432114331143411435114361143711438114391144011441114421144311444114451144611447114481144911450114511145211453114541145511456114571145811459114601146111462114631146411465114661146711468114691147011471114721147311474114751147611477114781147911480114811148211483114841148511486114871148811489114901149111492114931149411495114961149711498114991150011501115021150311504115051150611507115081150911510115111151211513115141151511516115171151811519115201152111522115231152411525115261152711528115291153011531115321153311534115351153611537115381153911540115411154211543115441154511546115471154811549115501155111552115531155411555115561155711558115591156011561115621156311564115651156611567115681156911570115711157211573115741157511576115771157811579115801158111582115831158411585115861158711588115891159011591115921159311594115951159611597115981159911600116011160211603116041160511606116071160811609116101161111612116131161411615116161161711618116191162011621116221162311624116251162611627116281162911630116311163211633116341163511636116371163811639116401164111642116431164411645116461164711648116491165011651116521165311654116551165611657116581165911660116611166211663116641166511666116671166811669116701167111672116731167411675116761167711678116791168011681116821168311684116851168611687116881168911690116911169211693116941169511696116971169811699117001170111702117031170411705117061170711708117091171011711117121171311714117151171611717117181171911720117211172211723117241172511726117271172811729117301173111732117331173411735117361173711738117391174011741117421174311744117451174611747117481174911750117511175211753117541175511756117571175811759117601176111762117631176411765117661176711768117691177011771117721177311774117751177611777117781177911780117811178211783117841178511786117871178811789117901179111792117931179411795117961179711798117991180011801118021180311804118051180611807118081180911810118111181211813118141181511816118171181811819118201182111822118231182411825118261182711828118291183011831118321183311834118351183611837118381183911840118411184211843118441184511846118471184811849118501185111852118531185411855118561185711858118591186011861118621186311864118651186611867118681186911870118711187211873118741187511876118771187811879118801188111882118831188411885118861188711888118891189011891118921189311894118951189611897118981189911900119011190211903119041190511906119071190811909119101191111912119131191411915119161191711918119191192011921119221192311924119251192611927119281192911930119311193211933119341193511936119371193811939119401194111942119431194411945119461194711948119491195011951119521195311954119551195611957119581195911960119611196211963119641196511966119671196811969119701197111972119731197411975119761197711978119791198011981119821198311984119851198611987119881198911990119911199211993119941199511996119971199811999120001200112002120031200412005120061200712008120091201012011120121201312014120151201612017120181201912020120211202212023120241202512026120271202812029120301203112032120331203412035120361203712038120391204012041120421204312044120451204612047120481204912050120511205212053120541205512056120571205812059120601206112062120631206412065120661206712068120691207012071120721207312074120751207612077120781207912080120811208212083120841208512086120871208812089120901209112092120931209412095120961209712098120991210012101121021210312104121051210612107121081210912110121111211212113121141211512116121171211812119121201212112122121231212412125121261212712128121291213012131121321213312134121351213612137121381213912140121411214212143121441214512146121471214812149121501215112152121531215412155121561215712158121591216012161121621216312164121651216612167121681216912170121711217212173121741217512176121771217812179121801218112182121831218412185121861218712188121891219012191121921219312194121951219612197121981219912200122011220212203122041220512206122071220812209122101221112212122131221412215122161221712218122191222012221122221222312224122251222612227122281222912230122311223212233122341223512236122371223812239122401224112242122431224412245122461224712248122491225012251122521225312254122551225612257122581225912260122611226212263122641226512266122671226812269122701227112272122731227412275122761227712278122791228012281122821228312284122851228612287122881228912290122911229212293122941229512296122971229812299123001230112302123031230412305123061230712308123091231012311123121231312314123151231612317123181231912320123211232212323123241232512326123271232812329123301233112332123331233412335123361233712338123391234012341123421234312344123451234612347123481234912350123511235212353123541235512356123571235812359123601236112362123631236412365123661236712368123691237012371123721237312374123751237612377123781237912380123811238212383123841238512386123871238812389123901239112392123931239412395123961239712398123991240012401124021240312404124051240612407124081240912410124111241212413124141241512416124171241812419124201242112422124231242412425124261242712428124291243012431124321243312434124351243612437124381243912440124411244212443124441244512446124471244812449124501245112452124531245412455124561245712458124591246012461124621246312464124651246612467124681246912470124711247212473124741247512476124771247812479124801248112482124831248412485124861248712488124891249012491124921249312494124951249612497124981249912500125011250212503125041250512506125071250812509125101251112512125131251412515125161251712518125191252012521125221252312524125251252612527125281252912530125311253212533125341253512536125371253812539125401254112542125431254412545125461254712548125491255012551125521255312554125551255612557125581255912560125611256212563125641256512566125671256812569125701257112572125731257412575125761257712578125791258012581125821258312584125851258612587125881258912590125911259212593125941259512596125971259812599126001260112602126031260412605126061260712608126091261012611126121261312614126151261612617126181261912620126211262212623126241262512626126271262812629126301263112632126331263412635126361263712638126391264012641126421264312644126451264612647126481264912650126511265212653126541265512656126571265812659126601266112662126631266412665126661266712668126691267012671126721267312674126751267612677126781267912680126811268212683126841268512686126871268812689126901269112692126931269412695126961269712698126991270012701127021270312704127051270612707127081270912710127111271212713127141271512716127171271812719127201272112722127231272412725127261272712728127291273012731127321273312734127351273612737127381273912740127411274212743127441274512746127471274812749127501275112752127531275412755127561275712758127591276012761127621276312764127651276612767127681276912770127711277212773127741277512776127771277812779127801278112782127831278412785127861278712788127891279012791127921279312794127951279612797127981279912800128011280212803128041280512806128071280812809128101281112812128131281412815128161281712818128191282012821128221282312824128251282612827128281282912830128311283212833128341283512836128371283812839128401284112842128431284412845128461284712848128491285012851128521285312854128551285612857128581285912860128611286212863128641286512866128671286812869128701287112872128731287412875128761287712878128791288012881128821288312884128851288612887128881288912890128911289212893128941289512896128971289812899129001290112902129031290412905129061290712908129091291012911129121291312914129151291612917129181291912920129211292212923129241292512926129271292812929129301293112932129331293412935129361293712938129391294012941129421294312944129451294612947129481294912950129511295212953129541295512956129571295812959129601296112962129631296412965129661296712968129691297012971129721297312974129751297612977129781297912980129811298212983129841298512986129871298812989129901299112992129931299412995129961299712998129991300013001130021300313004130051300613007130081300913010130111301213013130141301513016130171301813019130201302113022130231302413025130261302713028130291303013031130321303313034130351303613037130381303913040130411304213043130441304513046130471304813049130501305113052130531305413055130561305713058130591306013061130621306313064130651306613067130681306913070130711307213073130741307513076130771307813079130801308113082130831308413085130861308713088130891309013091130921309313094130951309613097130981309913100131011310213103131041310513106131071310813109131101311113112131131311413115131161311713118131191312013121131221312313124131251312613127131281312913130131311313213133131341313513136131371313813139131401314113142131431314413145131461314713148131491315013151131521315313154131551315613157131581315913160131611316213163131641316513166131671316813169131701317113172131731317413175131761317713178131791318013181131821318313184131851318613187131881318913190131911319213193131941319513196131971319813199132001320113202132031320413205132061320713208132091321013211132121321313214132151321613217132181321913220132211322213223132241322513226132271322813229132301323113232132331323413235132361323713238132391324013241132421324313244132451324613247132481324913250132511325213253132541325513256132571325813259132601326113262132631326413265132661326713268132691327013271132721327313274132751327613277132781327913280132811328213283132841328513286132871328813289132901329113292132931329413295132961329713298132991330013301133021330313304133051330613307133081330913310133111331213313133141331513316133171331813319133201332113322133231332413325133261332713328133291333013331133321333313334133351333613337133381333913340133411334213343133441334513346133471334813349133501335113352133531335413355133561335713358133591336013361133621336313364133651336613367133681336913370133711337213373133741337513376133771337813379133801338113382133831338413385133861338713388133891339013391133921339313394133951339613397133981339913400134011340213403134041340513406134071340813409134101341113412134131341413415134161341713418134191342013421134221342313424134251342613427134281342913430134311343213433134341343513436134371343813439134401344113442134431344413445134461344713448134491345013451134521345313454134551345613457134581345913460134611346213463134641346513466134671346813469134701347113472134731347413475134761347713478134791348013481134821348313484134851348613487134881348913490134911349213493134941349513496134971349813499135001350113502135031350413505135061350713508135091351013511135121351313514135151351613517135181351913520135211352213523135241352513526135271352813529135301353113532135331353413535135361353713538135391354013541135421354313544135451354613547135481354913550135511355213553135541355513556135571355813559135601356113562135631356413565135661356713568135691357013571135721357313574135751357613577135781357913580135811358213583135841358513586135871358813589135901359113592135931359413595135961359713598135991360013601136021360313604136051360613607136081360913610136111361213613136141361513616136171361813619136201362113622136231362413625136261362713628136291363013631136321363313634136351363613637136381363913640136411364213643136441364513646136471364813649136501365113652136531365413655136561365713658136591366013661136621366313664136651366613667136681366913670136711367213673136741367513676136771367813679136801368113682136831368413685136861368713688136891369013691136921369313694136951369613697136981369913700137011370213703137041370513706137071370813709137101371113712137131371413715137161371713718137191372013721137221372313724137251372613727137281372913730137311373213733137341373513736137371373813739137401374113742137431374413745137461374713748137491375013751137521375313754137551375613757137581375913760137611376213763137641376513766137671376813769137701377113772137731377413775137761377713778137791378013781137821378313784137851378613787137881378913790137911379213793137941379513796137971379813799138001380113802138031380413805138061380713808138091381013811138121381313814138151381613817138181381913820138211382213823138241382513826138271382813829138301383113832138331383413835138361383713838138391384013841138421384313844138451384613847138481384913850138511385213853138541385513856138571385813859138601386113862138631386413865138661386713868138691387013871138721387313874138751387613877138781387913880138811388213883138841388513886138871388813889138901389113892138931389413895138961389713898138991390013901139021390313904139051390613907139081390913910139111391213913139141391513916139171391813919139201392113922139231392413925139261392713928139291393013931139321393313934139351393613937139381393913940139411394213943139441394513946139471394813949139501395113952139531395413955139561395713958139591396013961139621396313964139651396613967139681396913970139711397213973139741397513976139771397813979139801398113982139831398413985139861398713988139891399013991139921399313994139951399613997139981399914000140011400214003140041400514006140071400814009140101401114012140131401414015140161401714018140191402014021140221402314024140251402614027140281402914030140311403214033140341403514036140371403814039140401404114042140431404414045140461404714048140491405014051140521405314054140551405614057140581405914060140611406214063140641406514066140671406814069140701407114072140731407414075140761407714078140791408014081140821408314084140851408614087140881408914090140911409214093140941409514096140971409814099141001410114102141031410414105141061410714108141091411014111141121411314114141151411614117141181411914120141211412214123141241412514126141271412814129141301413114132141331413414135141361413714138141391414014141141421414314144141451414614147141481414914150141511415214153141541415514156141571415814159141601416114162141631416414165141661416714168141691417014171141721417314174141751417614177141781417914180141811418214183141841418514186141871418814189141901419114192141931419414195141961419714198141991420014201142021420314204142051420614207142081420914210142111421214213142141421514216142171421814219142201422114222142231422414225142261422714228142291423014231142321423314234142351423614237142381423914240142411424214243142441424514246142471424814249142501425114252142531425414255142561425714258142591426014261142621426314264142651426614267142681426914270142711427214273142741427514276142771427814279142801428114282142831428414285142861428714288142891429014291142921429314294142951429614297142981429914300143011430214303143041430514306143071430814309143101431114312143131431414315143161431714318143191432014321143221432314324143251432614327143281432914330143311433214333143341433514336143371433814339143401434114342143431434414345143461434714348143491435014351143521435314354143551435614357143581435914360143611436214363143641436514366143671436814369143701437114372143731437414375143761437714378143791438014381143821438314384143851438614387143881438914390143911439214393143941439514396143971439814399144001440114402144031440414405144061440714408144091441014411144121441314414144151441614417144181441914420144211442214423144241442514426144271442814429144301443114432144331443414435144361443714438144391444014441144421444314444144451444614447144481444914450144511445214453144541445514456144571445814459144601446114462144631446414465144661446714468144691447014471144721447314474144751447614477144781447914480144811448214483144841448514486144871448814489144901449114492144931449414495144961449714498144991450014501145021450314504145051450614507145081450914510145111451214513145141451514516145171451814519145201452114522145231452414525145261452714528145291453014531145321453314534145351453614537145381453914540145411454214543145441454514546145471454814549145501455114552145531455414555145561455714558145591456014561145621456314564145651456614567145681456914570145711457214573145741457514576145771457814579145801458114582145831458414585145861458714588145891459014591145921459314594145951459614597145981459914600146011460214603146041460514606146071460814609146101461114612146131461414615146161461714618146191462014621146221462314624146251462614627146281462914630146311463214633146341463514636146371463814639146401464114642146431464414645146461464714648146491465014651146521465314654146551465614657146581465914660146611466214663146641466514666146671466814669146701467114672146731467414675146761467714678146791468014681146821468314684146851468614687146881468914690146911469214693146941469514696146971469814699147001470114702147031470414705147061470714708147091471014711147121471314714147151471614717147181471914720147211472214723147241472514726147271472814729147301473114732147331473414735147361473714738147391474014741147421474314744147451474614747147481474914750147511475214753147541475514756147571475814759147601476114762147631476414765147661476714768147691477014771147721477314774147751477614777147781477914780147811478214783147841478514786147871478814789147901479114792147931479414795147961479714798147991480014801148021480314804148051480614807148081480914810148111481214813148141481514816148171481814819148201482114822148231482414825148261482714828148291483014831148321483314834148351483614837148381483914840148411484214843148441484514846148471484814849148501485114852148531485414855148561485714858148591486014861148621486314864148651486614867148681486914870148711487214873148741487514876148771487814879148801488114882148831488414885148861488714888148891489014891148921489314894148951489614897148981489914900149011490214903149041490514906149071490814909149101491114912149131491414915149161491714918149191492014921149221492314924149251492614927149281492914930149311493214933149341493514936149371493814939149401494114942149431494414945149461494714948149491495014951149521495314954149551495614957149581495914960149611496214963149641496514966149671496814969149701497114972149731497414975149761497714978149791498014981149821498314984149851498614987149881498914990149911499214993149941499514996149971499814999150001500115002150031500415005150061500715008150091501015011150121501315014150151501615017150181501915020150211502215023150241502515026150271502815029150301503115032150331503415035150361503715038150391504015041150421504315044150451504615047150481504915050150511505215053150541505515056150571505815059150601506115062150631506415065150661506715068150691507015071150721507315074150751507615077150781507915080150811508215083150841508515086150871508815089150901509115092150931509415095150961509715098150991510015101151021510315104151051510615107151081510915110151111511215113151141511515116151171511815119151201512115122151231512415125151261512715128151291513015131151321513315134151351513615137151381513915140151411514215143151441514515146151471514815149151501515115152151531515415155151561515715158151591516015161151621516315164151651516615167151681516915170151711517215173151741517515176151771517815179151801518115182151831518415185151861518715188151891519015191151921519315194151951519615197151981519915200152011520215203152041520515206152071520815209152101521115212152131521415215152161521715218152191522015221152221522315224152251522615227152281522915230152311523215233152341523515236152371523815239152401524115242152431524415245152461524715248152491525015251152521525315254152551525615257152581525915260152611526215263152641526515266152671526815269152701527115272152731527415275152761527715278152791528015281152821528315284152851528615287152881528915290152911529215293152941529515296152971529815299153001530115302153031530415305153061530715308153091531015311153121531315314153151531615317153181531915320153211532215323153241532515326153271532815329153301533115332153331533415335153361533715338153391534015341153421534315344153451534615347153481534915350153511535215353153541535515356153571535815359153601536115362153631536415365153661536715368153691537015371153721537315374153751537615377153781537915380153811538215383153841538515386153871538815389153901539115392153931539415395153961539715398153991540015401154021540315404154051540615407154081540915410154111541215413154141541515416154171541815419154201542115422154231542415425154261542715428154291543015431154321543315434154351543615437154381543915440154411544215443154441544515446154471544815449154501545115452154531545415455154561545715458154591546015461154621546315464154651546615467154681546915470154711547215473154741547515476154771547815479154801548115482154831548415485154861548715488154891549015491154921549315494154951549615497154981549915500155011550215503155041550515506155071550815509155101551115512155131551415515155161551715518155191552015521155221552315524155251552615527155281552915530155311553215533155341553515536155371553815539155401554115542155431554415545155461554715548155491555015551155521555315554155551555615557155581555915560155611556215563155641556515566155671556815569155701557115572155731557415575155761557715578155791558015581155821558315584155851558615587155881558915590155911559215593155941559515596155971559815599156001560115602156031560415605156061560715608156091561015611156121561315614156151561615617156181561915620156211562215623156241562515626156271562815629156301563115632156331563415635156361563715638156391564015641156421564315644156451564615647156481564915650156511565215653156541565515656156571565815659156601566115662156631566415665156661566715668156691567015671156721567315674156751567615677156781567915680156811568215683156841568515686156871568815689156901569115692156931569415695156961569715698156991570015701157021570315704157051570615707157081570915710157111571215713157141571515716157171571815719157201572115722157231572415725157261572715728157291573015731157321573315734157351573615737157381573915740157411574215743157441574515746157471574815749157501575115752157531575415755157561575715758157591576015761157621576315764157651576615767157681576915770157711577215773157741577515776157771577815779157801578115782157831578415785157861578715788157891579015791157921579315794157951579615797157981579915800158011580215803158041580515806158071580815809158101581115812158131581415815158161581715818158191582015821158221582315824158251582615827158281582915830158311583215833158341583515836158371583815839158401584115842158431584415845158461584715848158491585015851158521585315854158551585615857158581585915860158611586215863158641586515866158671586815869158701587115872158731587415875158761587715878158791588015881158821588315884158851588615887158881588915890158911589215893158941589515896158971589815899159001590115902159031590415905159061590715908159091591015911159121591315914159151591615917159181591915920159211592215923159241592515926159271592815929159301593115932159331593415935159361593715938159391594015941159421594315944159451594615947159481594915950159511595215953159541595515956159571595815959159601596115962159631596415965159661596715968159691597015971159721597315974159751597615977159781597915980159811598215983159841598515986159871598815989159901599115992159931599415995159961599715998159991600016001160021600316004160051600616007160081600916010160111601216013160141601516016160171601816019160201602116022160231602416025160261602716028160291603016031160321603316034160351603616037160381603916040160411604216043160441604516046160471604816049160501605116052160531605416055160561605716058160591606016061160621606316064160651606616067160681606916070160711607216073160741607516076160771607816079160801608116082160831608416085160861608716088160891609016091160921609316094160951609616097160981609916100161011610216103161041610516106161071610816109161101611116112161131611416115161161611716118161191612016121161221612316124161251612616127161281612916130161311613216133161341613516136161371613816139161401614116142161431614416145161461614716148161491615016151161521615316154161551615616157161581615916160161611616216163161641616516166161671616816169161701617116172161731617416175161761617716178161791618016181161821618316184161851618616187161881618916190161911619216193161941619516196161971619816199162001620116202162031620416205162061620716208162091621016211162121621316214162151621616217162181621916220162211622216223162241622516226162271622816229162301623116232162331623416235162361623716238162391624016241162421624316244162451624616247162481624916250162511625216253162541625516256162571625816259162601626116262162631626416265162661626716268162691627016271162721627316274162751627616277162781627916280162811628216283162841628516286162871628816289162901629116292162931629416295162961629716298162991630016301163021630316304163051630616307163081630916310163111631216313163141631516316163171631816319163201632116322163231632416325163261632716328163291633016331163321633316334163351633616337163381633916340163411634216343163441634516346163471634816349163501635116352163531635416355163561635716358163591636016361163621636316364163651636616367163681636916370163711637216373163741637516376163771637816379163801638116382163831638416385163861638716388163891639016391163921639316394163951639616397163981639916400164011640216403164041640516406164071640816409164101641116412164131641416415164161641716418164191642016421164221642316424164251642616427164281642916430164311643216433164341643516436164371643816439164401644116442164431644416445164461644716448164491645016451164521645316454164551645616457164581645916460164611646216463164641646516466164671646816469164701647116472164731647416475164761647716478164791648016481164821648316484164851648616487164881648916490164911649216493164941649516496164971649816499165001650116502165031650416505165061650716508165091651016511165121651316514165151651616517165181651916520165211652216523165241652516526165271652816529165301653116532165331653416535165361653716538165391654016541165421654316544165451654616547165481654916550165511655216553165541655516556165571655816559165601656116562165631656416565165661656716568165691657016571165721657316574165751657616577165781657916580165811658216583165841658516586165871658816589165901659116592165931659416595165961659716598165991660016601166021660316604166051660616607166081660916610166111661216613166141661516616166171661816619166201662116622166231662416625166261662716628166291663016631166321663316634166351663616637166381663916640166411664216643166441664516646166471664816649166501665116652166531665416655166561665716658166591666016661166621666316664166651666616667166681666916670166711667216673166741667516676166771667816679166801668116682166831668416685166861668716688166891669016691166921669316694166951669616697166981669916700167011670216703167041670516706167071670816709167101671116712167131671416715167161671716718167191672016721167221672316724167251672616727167281672916730167311673216733167341673516736167371673816739167401674116742167431674416745167461674716748167491675016751167521675316754167551675616757167581675916760167611676216763167641676516766167671676816769167701677116772167731677416775167761677716778167791678016781167821678316784167851678616787167881678916790167911679216793167941679516796167971679816799168001680116802168031680416805168061680716808168091681016811168121681316814168151681616817168181681916820168211682216823168241682516826168271682816829168301683116832168331683416835168361683716838168391684016841168421684316844168451684616847168481684916850168511685216853168541685516856168571685816859168601686116862168631686416865168661686716868168691687016871168721687316874168751687616877168781687916880168811688216883168841688516886168871688816889168901689116892168931689416895168961689716898168991690016901169021690316904169051690616907169081690916910169111691216913169141691516916169171691816919169201692116922169231692416925169261692716928169291693016931169321693316934169351693616937169381693916940169411694216943169441694516946169471694816949169501695116952169531695416955169561695716958169591696016961169621696316964169651696616967169681696916970169711697216973169741697516976169771697816979169801698116982169831698416985169861698716988169891699016991169921699316994169951699616997169981699917000170011700217003170041700517006170071700817009170101701117012170131701417015170161701717018170191702017021170221702317024170251702617027170281702917030170311703217033170341703517036170371703817039170401704117042170431704417045170461704717048170491705017051170521705317054170551705617057170581705917060170611706217063170641706517066170671706817069170701707117072170731707417075170761707717078170791708017081170821708317084170851708617087170881708917090170911709217093170941709517096170971709817099171001710117102171031710417105171061710717108171091711017111171121711317114171151711617117171181711917120171211712217123171241712517126171271712817129171301713117132171331713417135171361713717138171391714017141171421714317144171451714617147171481714917150171511715217153171541715517156171571715817159171601716117162171631716417165171661716717168171691717017171171721717317174171751717617177171781717917180171811718217183171841718517186171871718817189171901719117192171931719417195171961719717198171991720017201172021720317204172051720617207172081720917210172111721217213172141721517216172171721817219172201722117222172231722417225172261722717228172291723017231172321723317234172351723617237172381723917240172411724217243172441724517246172471724817249172501725117252172531725417255172561725717258172591726017261172621726317264172651726617267172681726917270172711727217273172741727517276172771727817279172801728117282172831728417285172861728717288172891729017291172921729317294172951729617297172981729917300173011730217303173041730517306173071730817309173101731117312173131731417315173161731717318173191732017321173221732317324173251732617327173281732917330173311733217333173341733517336173371733817339173401734117342173431734417345173461734717348173491735017351173521735317354173551735617357173581735917360173611736217363173641736517366173671736817369173701737117372173731737417375173761737717378173791738017381173821738317384173851738617387173881738917390173911739217393173941739517396173971739817399174001740117402174031740417405174061740717408174091741017411174121741317414174151741617417174181741917420174211742217423174241742517426174271742817429174301743117432174331743417435174361743717438174391744017441174421744317444174451744617447174481744917450174511745217453174541745517456174571745817459174601746117462174631746417465174661746717468174691747017471174721747317474174751747617477174781747917480174811748217483174841748517486174871748817489174901749117492174931749417495174961749717498174991750017501175021750317504175051750617507175081750917510175111751217513175141751517516175171751817519175201752117522175231752417525175261752717528175291753017531175321753317534175351753617537175381753917540175411754217543175441754517546175471754817549175501755117552175531755417555175561755717558175591756017561175621756317564175651756617567175681756917570175711757217573175741757517576175771757817579175801758117582175831758417585175861758717588175891759017591175921759317594175951759617597175981759917600176011760217603176041760517606176071760817609176101761117612176131761417615176161761717618176191762017621176221762317624176251762617627176281762917630176311763217633176341763517636176371763817639176401764117642176431764417645176461764717648176491765017651176521765317654176551765617657176581765917660176611766217663176641766517666176671766817669176701767117672176731767417675176761767717678176791768017681176821768317684176851768617687176881768917690176911769217693176941769517696176971769817699177001770117702177031770417705177061770717708177091771017711177121771317714177151771617717177181771917720177211772217723177241772517726177271772817729177301773117732177331773417735177361773717738177391774017741177421774317744177451774617747177481774917750177511775217753177541775517756177571775817759177601776117762177631776417765177661776717768177691777017771177721777317774177751777617777177781777917780177811778217783177841778517786177871778817789177901779117792177931779417795177961779717798177991780017801178021780317804178051780617807178081780917810178111781217813178141781517816178171781817819178201782117822178231782417825178261782717828178291783017831178321783317834178351783617837178381783917840178411784217843178441784517846178471784817849178501785117852178531785417855178561785717858178591786017861178621786317864178651786617867178681786917870178711787217873178741787517876178771787817879178801788117882178831788417885178861788717888178891789017891178921789317894178951789617897178981789917900179011790217903179041790517906179071790817909179101791117912179131791417915179161791717918179191792017921179221792317924179251792617927179281792917930179311793217933179341793517936179371793817939179401794117942179431794417945179461794717948179491795017951179521795317954179551795617957179581795917960179611796217963179641796517966179671796817969179701797117972179731797417975179761797717978179791798017981179821798317984179851798617987179881798917990179911799217993179941799517996179971799817999180001800118002180031800418005180061800718008180091801018011180121801318014180151801618017180181801918020180211802218023180241802518026180271802818029180301803118032180331803418035180361803718038180391804018041180421804318044180451804618047180481804918050180511805218053180541805518056180571805818059180601806118062180631806418065180661806718068180691807018071180721807318074180751807618077180781807918080180811808218083180841808518086180871808818089180901809118092180931809418095180961809718098180991810018101181021810318104181051810618107181081810918110181111811218113181141811518116181171811818119181201812118122181231812418125181261812718128181291813018131181321813318134181351813618137181381813918140181411814218143181441814518146181471814818149181501815118152181531815418155181561815718158181591816018161181621816318164181651816618167181681816918170181711817218173181741817518176181771817818179181801818118182181831818418185181861818718188181891819018191181921819318194181951819618197181981819918200182011820218203182041820518206182071820818209182101821118212182131821418215182161821718218182191822018221182221822318224182251822618227182281822918230182311823218233182341823518236182371823818239182401824118242182431824418245182461824718248182491825018251182521825318254182551825618257182581825918260182611826218263182641826518266182671826818269182701827118272182731827418275182761827718278182791828018281182821828318284182851828618287182881828918290182911829218293182941829518296182971829818299183001830118302183031830418305183061830718308183091831018311183121831318314183151831618317183181831918320183211832218323183241832518326183271832818329183301833118332183331833418335183361833718338183391834018341183421834318344183451834618347183481834918350183511835218353183541835518356183571835818359183601836118362183631836418365183661836718368183691837018371183721837318374183751837618377183781837918380183811838218383183841838518386183871838818389183901839118392183931839418395183961839718398183991840018401184021840318404184051840618407184081840918410184111841218413184141841518416184171841818419184201842118422184231842418425184261842718428184291843018431184321843318434184351843618437184381843918440184411844218443184441844518446184471844818449184501845118452184531845418455184561845718458184591846018461184621846318464184651846618467184681846918470184711847218473184741847518476184771847818479184801848118482184831848418485184861848718488184891849018491184921849318494184951849618497184981849918500185011850218503185041850518506185071850818509185101851118512185131851418515185161851718518185191852018521185221852318524185251852618527185281852918530185311853218533185341853518536185371853818539185401854118542185431854418545185461854718548185491855018551185521855318554185551855618557185581855918560185611856218563185641856518566185671856818569185701857118572185731857418575185761857718578185791858018581185821858318584185851858618587185881858918590185911859218593185941859518596185971859818599186001860118602186031860418605186061860718608186091861018611186121861318614186151861618617186181861918620186211862218623186241862518626186271862818629186301863118632186331863418635186361863718638186391864018641186421864318644186451864618647186481864918650186511865218653186541865518656186571865818659186601866118662186631866418665186661866718668186691867018671186721867318674186751867618677186781867918680186811868218683186841868518686186871868818689186901869118692186931869418695186961869718698186991870018701187021870318704187051870618707187081870918710187111871218713187141871518716187171871818719187201872118722187231872418725187261872718728187291873018731187321873318734187351873618737187381873918740187411874218743187441874518746187471874818749187501875118752187531875418755187561875718758187591876018761187621876318764187651876618767187681876918770187711877218773187741877518776187771877818779187801878118782187831878418785187861878718788187891879018791187921879318794187951879618797187981879918800188011880218803188041880518806188071880818809188101881118812188131881418815188161881718818188191882018821188221882318824188251882618827188281882918830188311883218833188341883518836188371883818839188401884118842188431884418845188461884718848188491885018851188521885318854188551885618857188581885918860188611886218863188641886518866188671886818869188701887118872188731887418875188761887718878188791888018881188821888318884188851888618887188881888918890188911889218893188941889518896188971889818899189001890118902189031890418905189061890718908189091891018911189121891318914189151891618917189181891918920189211892218923189241892518926189271892818929189301893118932189331893418935189361893718938189391894018941189421894318944189451894618947189481894918950189511895218953189541895518956189571895818959189601896118962189631896418965189661896718968189691897018971189721897318974189751897618977189781897918980189811898218983189841898518986189871898818989189901899118992189931899418995189961899718998189991900019001190021900319004190051900619007190081900919010190111901219013190141901519016190171901819019190201902119022190231902419025190261902719028190291903019031190321903319034190351903619037190381903919040190411904219043190441904519046190471904819049190501905119052190531905419055190561905719058190591906019061190621906319064190651906619067190681906919070190711907219073190741907519076190771907819079190801908119082190831908419085190861908719088190891909019091190921909319094190951909619097190981909919100191011910219103191041910519106191071910819109191101911119112191131911419115191161911719118191191912019121191221912319124191251912619127191281912919130191311913219133191341913519136191371913819139191401914119142191431914419145191461914719148191491915019151191521915319154191551915619157191581915919160191611916219163191641916519166191671916819169191701917119172191731917419175191761917719178191791918019181191821918319184191851918619187191881918919190191911919219193191941919519196191971919819199192001920119202192031920419205192061920719208192091921019211192121921319214192151921619217192181921919220192211922219223192241922519226192271922819229192301923119232192331923419235192361923719238192391924019241192421924319244192451924619247192481924919250192511925219253192541925519256192571925819259192601926119262192631926419265192661926719268192691927019271192721927319274192751927619277192781927919280192811928219283192841928519286192871928819289192901929119292192931929419295192961929719298192991930019301193021930319304193051930619307193081930919310193111931219313193141931519316193171931819319193201932119322193231932419325193261932719328193291933019331193321933319334193351933619337193381933919340193411934219343193441934519346193471934819349193501935119352193531935419355193561935719358193591936019361193621936319364193651936619367193681936919370193711937219373193741937519376193771937819379193801938119382193831938419385193861938719388193891939019391193921939319394193951939619397193981939919400194011940219403194041940519406194071940819409194101941119412194131941419415194161941719418194191942019421194221942319424194251942619427194281942919430194311943219433194341943519436194371943819439194401944119442194431944419445194461944719448194491945019451194521945319454194551945619457194581945919460194611946219463194641946519466194671946819469194701947119472194731947419475194761947719478194791948019481194821948319484194851948619487194881948919490194911949219493194941949519496194971949819499195001950119502195031950419505195061950719508195091951019511195121951319514195151951619517195181951919520195211952219523195241952519526195271952819529195301953119532195331953419535195361953719538195391954019541195421954319544195451954619547195481954919550195511955219553195541955519556195571955819559195601956119562195631956419565195661956719568195691957019571195721957319574195751957619577195781957919580195811958219583195841958519586195871958819589195901959119592195931959419595195961959719598195991960019601196021960319604196051960619607196081960919610196111961219613196141961519616196171961819619196201962119622196231962419625196261962719628196291963019631196321963319634196351963619637196381963919640196411964219643196441964519646196471964819649196501965119652196531965419655196561965719658196591966019661196621966319664196651966619667196681966919670196711967219673196741967519676196771967819679196801968119682196831968419685196861968719688196891969019691196921969319694196951969619697196981969919700197011970219703197041970519706197071970819709197101971119712197131971419715197161971719718197191972019721197221972319724197251972619727197281972919730197311973219733197341973519736197371973819739197401974119742197431974419745197461974719748197491975019751197521975319754197551975619757197581975919760197611976219763197641976519766197671976819769197701977119772197731977419775197761977719778197791978019781197821978319784197851978619787197881978919790197911979219793197941979519796197971979819799198001980119802198031980419805198061980719808198091981019811198121981319814198151981619817198181981919820198211982219823198241982519826198271982819829198301983119832198331983419835198361983719838198391984019841198421984319844198451984619847198481984919850198511985219853198541985519856198571985819859198601986119862198631986419865198661986719868198691987019871198721987319874198751987619877198781987919880198811988219883198841988519886198871988819889198901989119892198931989419895198961989719898198991990019901199021990319904199051990619907199081990919910199111991219913199141991519916199171991819919199201992119922199231992419925199261992719928199291993019931199321993319934199351993619937199381993919940199411994219943199441994519946199471994819949199501995119952199531995419955199561995719958199591996019961199621996319964199651996619967199681996919970199711997219973199741997519976199771997819979199801998119982199831998419985199861998719988199891999019991199921999319994199951999619997199981999920000200012000220003200042000520006200072000820009200102001120012200132001420015200162001720018200192002020021200222002320024200252002620027200282002920030200312003220033200342003520036200372003820039200402004120042200432004420045200462004720048200492005020051200522005320054200552005620057200582005920060200612006220063200642006520066200672006820069200702007120072200732007420075200762007720078200792008020081200822008320084200852008620087200882008920090200912009220093200942009520096200972009820099201002010120102201032010420105201062010720108201092011020111201122011320114201152011620117201182011920120201212012220123201242012520126201272012820129201302013120132201332013420135201362013720138201392014020141201422014320144201452014620147201482014920150201512015220153201542015520156201572015820159201602016120162201632016420165201662016720168201692017020171201722017320174201752017620177201782017920180201812018220183201842018520186201872018820189201902019120192201932019420195201962019720198201992020020201202022020320204202052020620207202082020920210202112021220213202142021520216202172021820219202202022120222202232022420225202262022720228202292023020231202322023320234202352023620237202382023920240202412024220243202442024520246202472024820249202502025120252202532025420255202562025720258202592026020261202622026320264202652026620267202682026920270202712027220273202742027520276202772027820279202802028120282202832028420285202862028720288202892029020291202922029320294202952029620297202982029920300203012030220303203042030520306203072030820309203102031120312203132031420315203162031720318203192032020321203222032320324203252032620327203282032920330203312033220333203342033520336203372033820339203402034120342203432034420345203462034720348203492035020351203522035320354203552035620357203582035920360203612036220363203642036520366203672036820369203702037120372203732037420375203762037720378203792038020381203822038320384203852038620387203882038920390203912039220393203942039520396203972039820399204002040120402204032040420405204062040720408204092041020411204122041320414204152041620417204182041920420204212042220423204242042520426204272042820429204302043120432204332043420435204362043720438204392044020441204422044320444204452044620447204482044920450204512045220453204542045520456204572045820459204602046120462204632046420465204662046720468204692047020471204722047320474204752047620477204782047920480204812048220483204842048520486204872048820489204902049120492204932049420495204962049720498204992050020501205022050320504205052050620507205082050920510205112051220513205142051520516205172051820519205202052120522205232052420525205262052720528205292053020531205322053320534205352053620537205382053920540205412054220543205442054520546205472054820549205502055120552205532055420555205562055720558205592056020561205622056320564205652056620567205682056920570205712057220573205742057520576205772057820579205802058120582205832058420585205862058720588205892059020591205922059320594205952059620597205982059920600206012060220603206042060520606206072060820609206102061120612206132061420615206162061720618206192062020621206222062320624206252062620627206282062920630206312063220633206342063520636206372063820639206402064120642206432064420645206462064720648206492065020651206522065320654206552065620657206582065920660206612066220663206642066520666206672066820669206702067120672206732067420675206762067720678206792068020681206822068320684206852068620687206882068920690206912069220693206942069520696206972069820699207002070120702207032070420705207062070720708207092071020711207122071320714207152071620717207182071920720207212072220723207242072520726207272072820729207302073120732207332073420735207362073720738207392074020741207422074320744207452074620747207482074920750207512075220753207542075520756207572075820759207602076120762207632076420765207662076720768207692077020771207722077320774207752077620777207782077920780207812078220783207842078520786207872078820789207902079120792207932079420795207962079720798207992080020801208022080320804208052080620807208082080920810208112081220813208142081520816208172081820819208202082120822208232082420825208262082720828208292083020831208322083320834208352083620837208382083920840208412084220843208442084520846208472084820849208502085120852208532085420855208562085720858208592086020861208622086320864208652086620867208682086920870208712087220873208742087520876208772087820879208802088120882208832088420885208862088720888208892089020891208922089320894208952089620897208982089920900209012090220903209042090520906209072090820909209102091120912209132091420915209162091720918209192092020921209222092320924209252092620927209282092920930209312093220933209342093520936209372093820939209402094120942209432094420945209462094720948209492095020951209522095320954209552095620957209582095920960209612096220963209642096520966209672096820969209702097120972209732097420975209762097720978209792098020981209822098320984209852098620987209882098920990209912099220993209942099520996209972099820999210002100121002210032100421005210062100721008210092101021011210122101321014210152101621017210182101921020210212102221023210242102521026210272102821029210302103121032210332103421035210362103721038210392104021041210422104321044210452104621047210482104921050210512105221053210542105521056210572105821059210602106121062210632106421065210662106721068210692107021071210722107321074210752107621077210782107921080210812108221083210842108521086210872108821089210902109121092210932109421095210962109721098210992110021101211022110321104211052110621107211082110921110211112111221113211142111521116211172111821119211202112121122211232112421125211262112721128211292113021131211322113321134211352113621137211382113921140211412114221143211442114521146211472114821149211502115121152211532115421155211562115721158211592116021161211622116321164211652116621167211682116921170211712117221173211742117521176211772117821179211802118121182211832118421185211862118721188211892119021191211922119321194211952119621197211982119921200212012120221203212042120521206212072120821209212102121121212212132121421215212162121721218212192122021221212222122321224212252122621227212282122921230212312123221233212342123521236212372123821239212402124121242212432124421245212462124721248212492125021251212522125321254212552125621257212582125921260212612126221263212642126521266212672126821269212702127121272212732127421275212762127721278212792128021281212822128321284212852128621287212882128921290212912129221293212942129521296212972129821299213002130121302213032130421305213062130721308213092131021311213122131321314213152131621317213182131921320213212132221323213242132521326213272132821329213302133121332213332133421335213362133721338213392134021341213422134321344213452134621347213482134921350213512135221353213542135521356213572135821359213602136121362213632136421365213662136721368213692137021371213722137321374213752137621377213782137921380213812138221383213842138521386213872138821389213902139121392213932139421395213962139721398213992140021401214022140321404214052140621407214082140921410214112141221413214142141521416214172141821419214202142121422214232142421425214262142721428214292143021431214322143321434214352143621437214382143921440214412144221443214442144521446214472144821449214502145121452214532145421455214562145721458214592146021461214622146321464214652146621467214682146921470214712147221473214742147521476214772147821479214802148121482214832148421485214862148721488214892149021491214922149321494214952149621497214982149921500215012150221503215042150521506215072150821509215102151121512215132151421515215162151721518215192152021521215222152321524215252152621527215282152921530215312153221533215342153521536215372153821539215402154121542215432154421545215462154721548215492155021551215522155321554215552155621557215582155921560215612156221563215642156521566215672156821569215702157121572215732157421575215762157721578215792158021581215822158321584215852158621587215882158921590215912159221593215942159521596215972159821599216002160121602216032160421605216062160721608216092161021611216122161321614216152161621617216182161921620216212162221623216242162521626216272162821629216302163121632216332163421635216362163721638216392164021641216422164321644216452164621647216482164921650216512165221653216542165521656216572165821659216602166121662216632166421665216662166721668216692167021671216722167321674216752167621677216782167921680216812168221683216842168521686216872168821689216902169121692216932169421695216962169721698216992170021701217022170321704217052170621707217082170921710217112171221713217142171521716217172171821719217202172121722217232172421725217262172721728217292173021731217322173321734217352173621737217382173921740217412174221743217442174521746217472174821749217502175121752217532175421755217562175721758217592176021761217622176321764217652176621767217682176921770217712177221773217742177521776217772177821779217802178121782217832178421785217862178721788217892179021791217922179321794217952179621797217982179921800218012180221803218042180521806218072180821809218102181121812218132181421815218162181721818218192182021821218222182321824218252182621827218282182921830218312183221833218342183521836218372183821839218402184121842218432184421845218462184721848218492185021851218522185321854218552185621857218582185921860218612186221863218642186521866218672186821869218702187121872218732187421875218762187721878218792188021881218822188321884218852188621887218882188921890218912189221893218942189521896218972189821899219002190121902219032190421905219062190721908219092191021911219122191321914219152191621917219182191921920219212192221923219242192521926219272192821929219302193121932219332193421935219362193721938219392194021941219422194321944219452194621947219482194921950219512195221953219542195521956219572195821959219602196121962219632196421965219662196721968219692197021971219722197321974219752197621977219782197921980219812198221983219842198521986219872198821989219902199121992219932199421995219962199721998219992200022001220022200322004220052200622007220082200922010220112201222013220142201522016220172201822019220202202122022220232202422025220262202722028220292203022031220322203322034220352203622037220382203922040220412204222043220442204522046220472204822049220502205122052220532205422055220562205722058220592206022061220622206322064220652206622067220682206922070220712207222073220742207522076220772207822079220802208122082220832208422085220862208722088220892209022091220922209322094220952209622097220982209922100221012210222103221042210522106221072210822109221102211122112221132211422115221162211722118221192212022121221222212322124221252212622127221282212922130221312213222133221342213522136221372213822139221402214122142221432214422145221462214722148221492215022151221522215322154221552215622157221582215922160221612216222163221642216522166221672216822169221702217122172221732217422175221762217722178221792218022181221822218322184221852218622187221882218922190221912219222193221942219522196221972219822199222002220122202222032220422205222062220722208222092221022211222122221322214222152221622217222182221922220222212222222223222242222522226222272222822229222302223122232222332223422235222362223722238222392224022241222422224322244222452224622247222482224922250222512225222253222542225522256222572225822259222602226122262222632226422265222662226722268222692227022271222722227322274222752227622277222782227922280222812228222283222842228522286222872228822289222902229122292222932229422295222962229722298222992230022301223022230322304223052230622307223082230922310223112231222313223142231522316223172231822319223202232122322223232232422325223262232722328223292233022331223322233322334223352233622337223382233922340223412234222343223442234522346223472234822349223502235122352223532235422355223562235722358223592236022361223622236322364223652236622367223682236922370223712237222373223742237522376223772237822379223802238122382223832238422385223862238722388223892239022391223922239322394223952239622397223982239922400224012240222403224042240522406224072240822409224102241122412224132241422415224162241722418224192242022421224222242322424224252242622427224282242922430224312243222433224342243522436224372243822439224402244122442224432244422445224462244722448224492245022451224522245322454224552245622457224582245922460224612246222463224642246522466224672246822469224702247122472224732247422475224762247722478224792248022481224822248322484224852248622487224882248922490224912249222493224942249522496224972249822499225002250122502225032250422505225062250722508225092251022511225122251322514225152251622517225182251922520225212252222523225242252522526225272252822529225302253122532225332253422535225362253722538225392254022541225422254322544225452254622547225482254922550225512255222553225542255522556225572255822559225602256122562225632256422565225662256722568225692257022571225722257322574225752257622577225782257922580225812258222583225842258522586225872258822589225902259122592225932259422595225962259722598225992260022601226022260322604226052260622607226082260922610226112261222613226142261522616226172261822619226202262122622226232262422625226262262722628226292263022631226322263322634226352263622637226382263922640226412264222643226442264522646226472264822649226502265122652226532265422655226562265722658226592266022661226622266322664226652266622667226682266922670226712267222673226742267522676226772267822679226802268122682226832268422685226862268722688226892269022691226922269322694226952269622697226982269922700227012270222703227042270522706227072270822709227102271122712227132271422715227162271722718227192272022721227222272322724227252272622727227282272922730227312273222733227342273522736227372273822739227402274122742227432274422745227462274722748227492275022751227522275322754227552275622757227582275922760227612276222763227642276522766227672276822769227702277122772227732277422775227762277722778227792278022781227822278322784227852278622787227882278922790227912279222793227942279522796227972279822799228002280122802228032280422805228062280722808228092281022811228122281322814228152281622817228182281922820228212282222823228242282522826228272282822829228302283122832228332283422835228362283722838228392284022841228422284322844228452284622847228482284922850228512285222853228542285522856228572285822859228602286122862228632286422865228662286722868228692287022871228722287322874228752287622877228782287922880228812288222883228842288522886228872288822889228902289122892228932289422895228962289722898228992290022901229022290322904229052290622907229082290922910229112291222913229142291522916229172291822919229202292122922229232292422925229262292722928229292293022931229322293322934229352293622937229382293922940229412294222943229442294522946229472294822949229502295122952229532295422955229562295722958229592296022961229622296322964229652296622967229682296922970229712297222973229742297522976229772297822979229802298122982229832298422985229862298722988229892299022991229922299322994229952299622997229982299923000230012300223003230042300523006230072300823009230102301123012230132301423015230162301723018230192302023021230222302323024230252302623027230282302923030230312303223033230342303523036230372303823039230402304123042230432304423045230462304723048230492305023051230522305323054230552305623057230582305923060230612306223063230642306523066230672306823069230702307123072230732307423075230762307723078230792308023081230822308323084230852308623087230882308923090230912309223093230942309523096230972309823099231002310123102231032310423105231062310723108231092311023111231122311323114231152311623117231182311923120231212312223123231242312523126231272312823129231302313123132231332313423135231362313723138231392314023141231422314323144231452314623147231482314923150231512315223153231542315523156231572315823159231602316123162231632316423165231662316723168231692317023171231722317323174231752317623177231782317923180231812318223183231842318523186231872318823189231902319123192231932319423195231962319723198231992320023201232022320323204232052320623207232082320923210232112321223213232142321523216232172321823219232202322123222232232322423225232262322723228232292323023231232322323323234232352323623237232382323923240232412324223243232442324523246232472324823249232502325123252232532325423255232562325723258232592326023261232622326323264232652326623267232682326923270232712327223273232742327523276232772327823279232802328123282232832328423285232862328723288232892329023291232922329323294232952329623297232982329923300233012330223303233042330523306233072330823309233102331123312233132331423315233162331723318233192332023321233222332323324233252332623327233282332923330233312333223333233342333523336233372333823339233402334123342233432334423345233462334723348233492335023351233522335323354233552335623357233582335923360233612336223363233642336523366233672336823369233702337123372233732337423375233762337723378233792338023381233822338323384233852338623387233882338923390233912339223393233942339523396233972339823399234002340123402234032340423405234062340723408234092341023411234122341323414234152341623417234182341923420234212342223423234242342523426234272342823429234302343123432234332343423435234362343723438234392344023441234422344323444234452344623447234482344923450234512345223453234542345523456234572345823459234602346123462234632346423465234662346723468234692347023471234722347323474234752347623477234782347923480234812348223483234842348523486234872348823489234902349123492234932349423495234962349723498234992350023501235022350323504235052350623507235082350923510235112351223513235142351523516235172351823519235202352123522235232352423525235262352723528235292353023531235322353323534235352353623537235382353923540235412354223543235442354523546235472354823549235502355123552235532355423555235562355723558235592356023561235622356323564235652356623567235682356923570235712357223573235742357523576235772357823579235802358123582235832358423585235862358723588235892359023591235922359323594235952359623597235982359923600236012360223603236042360523606236072360823609236102361123612236132361423615236162361723618236192362023621236222362323624236252362623627236282362923630236312363223633236342363523636236372363823639236402364123642236432364423645236462364723648236492365023651236522365323654236552365623657236582365923660236612366223663236642366523666236672366823669236702367123672236732367423675236762367723678236792368023681236822368323684236852368623687236882368923690236912369223693236942369523696236972369823699237002370123702237032370423705237062370723708237092371023711237122371323714237152371623717237182371923720237212372223723237242372523726237272372823729237302373123732237332373423735237362373723738237392374023741237422374323744237452374623747237482374923750237512375223753237542375523756237572375823759237602376123762237632376423765237662376723768237692377023771237722377323774237752377623777237782377923780237812378223783237842378523786237872378823789237902379123792237932379423795237962379723798237992380023801238022380323804238052380623807238082380923810238112381223813238142381523816238172381823819238202382123822238232382423825238262382723828238292383023831238322383323834238352383623837238382383923840238412384223843238442384523846238472384823849238502385123852238532385423855238562385723858238592386023861238622386323864238652386623867238682386923870238712387223873238742387523876238772387823879238802388123882238832388423885238862388723888238892389023891238922389323894238952389623897238982389923900239012390223903239042390523906239072390823909239102391123912239132391423915239162391723918239192392023921239222392323924239252392623927239282392923930239312393223933239342393523936239372393823939239402394123942239432394423945239462394723948239492395023951239522395323954239552395623957239582395923960239612396223963239642396523966239672396823969239702397123972239732397423975239762397723978239792398023981239822398323984239852398623987239882398923990239912399223993239942399523996239972399823999240002400124002240032400424005240062400724008240092401024011240122401324014240152401624017240182401924020240212402224023240242402524026240272402824029240302403124032240332403424035240362403724038240392404024041240422404324044240452404624047240482404924050240512405224053240542405524056240572405824059240602406124062240632406424065240662406724068240692407024071240722407324074240752407624077240782407924080240812408224083240842408524086240872408824089240902409124092240932409424095240962409724098240992410024101241022410324104241052410624107241082410924110241112411224113241142411524116241172411824119241202412124122241232412424125241262412724128241292413024131241322413324134241352413624137241382413924140241412414224143241442414524146241472414824149241502415124152241532415424155241562415724158241592416024161241622416324164241652416624167241682416924170241712417224173241742417524176241772417824179241802418124182241832418424185241862418724188241892419024191241922419324194241952419624197241982419924200242012420224203242042420524206242072420824209242102421124212242132421424215242162421724218242192422024221242222422324224242252422624227242282422924230242312423224233242342423524236242372423824239242402424124242242432424424245242462424724248242492425024251242522425324254242552425624257242582425924260242612426224263242642426524266242672426824269242702427124272242732427424275242762427724278242792428024281242822428324284242852428624287242882428924290242912429224293242942429524296242972429824299243002430124302243032430424305243062430724308243092431024311243122431324314243152431624317243182431924320243212432224323243242432524326243272432824329243302433124332243332433424335243362433724338243392434024341243422434324344243452434624347243482434924350243512435224353243542435524356243572435824359243602436124362243632436424365243662436724368243692437024371243722437324374243752437624377243782437924380243812438224383243842438524386243872438824389243902439124392243932439424395243962439724398243992440024401244022440324404244052440624407244082440924410244112441224413244142441524416244172441824419244202442124422244232442424425244262442724428244292443024431244322443324434244352443624437244382443924440244412444224443244442444524446244472444824449244502445124452244532445424455244562445724458244592446024461244622446324464244652446624467244682446924470244712447224473244742447524476244772447824479244802448124482244832448424485244862448724488244892449024491244922449324494244952449624497244982449924500245012450224503245042450524506245072450824509245102451124512245132451424515245162451724518245192452024521245222452324524245252452624527245282452924530245312453224533245342453524536245372453824539245402454124542245432454424545245462454724548245492455024551245522455324554245552455624557245582455924560245612456224563245642456524566245672456824569245702457124572245732457424575245762457724578245792458024581245822458324584245852458624587245882458924590245912459224593245942459524596245972459824599246002460124602246032460424605246062460724608246092461024611246122461324614246152461624617246182461924620246212462224623246242462524626246272462824629246302463124632246332463424635246362463724638246392464024641246422464324644246452464624647246482464924650246512465224653246542465524656246572465824659246602466124662246632466424665246662466724668246692467024671246722467324674246752467624677246782467924680246812468224683246842468524686246872468824689246902469124692246932469424695246962469724698246992470024701247022470324704247052470624707247082470924710247112471224713247142471524716247172471824719247202472124722247232472424725247262472724728247292473024731247322473324734247352473624737247382473924740247412474224743247442474524746247472474824749247502475124752247532475424755247562475724758247592476024761247622476324764247652476624767247682476924770247712477224773247742477524776247772477824779247802478124782247832478424785247862478724788247892479024791247922479324794247952479624797247982479924800248012480224803248042480524806248072480824809248102481124812248132481424815248162481724818248192482024821248222482324824248252482624827248282482924830248312483224833248342483524836248372483824839248402484124842248432484424845248462484724848248492485024851248522485324854248552485624857248582485924860248612486224863248642486524866248672486824869248702487124872248732487424875248762487724878248792488024881248822488324884248852488624887248882488924890248912489224893248942489524896248972489824899249002490124902249032490424905249062490724908249092491024911249122491324914249152491624917249182491924920249212492224923249242492524926249272492824929249302493124932249332493424935249362493724938249392494024941249422494324944249452494624947249482494924950249512495224953249542495524956249572495824959249602496124962249632496424965249662496724968249692497024971249722497324974249752497624977249782497924980249812498224983249842498524986249872498824989249902499124992249932499424995249962499724998249992500025001250022500325004250052500625007250082500925010250112501225013250142501525016250172501825019250202502125022250232502425025250262502725028250292503025031250322503325034250352503625037250382503925040250412504225043250442504525046250472504825049250502505125052250532505425055250562505725058250592506025061250622506325064250652506625067250682506925070250712507225073250742507525076250772507825079250802508125082250832508425085250862508725088250892509025091250922509325094250952509625097250982509925100251012510225103251042510525106251072510825109251102511125112251132511425115251162511725118251192512025121251222512325124251252512625127251282512925130251312513225133251342513525136251372513825139251402514125142251432514425145251462514725148251492515025151251522515325154251552515625157251582515925160251612516225163251642516525166251672516825169251702517125172251732517425175251762517725178251792518025181251822518325184251852518625187251882518925190251912519225193251942519525196251972519825199252002520125202252032520425205252062520725208252092521025211252122521325214252152521625217252182521925220252212522225223252242522525226252272522825229252302523125232252332523425235252362523725238252392524025241252422524325244252452524625247252482524925250252512525225253252542525525256252572525825259252602526125262252632526425265252662526725268252692527025271252722527325274252752527625277252782527925280252812528225283252842528525286252872528825289252902529125292252932529425295252962529725298252992530025301253022530325304253052530625307253082530925310253112531225313253142531525316253172531825319253202532125322253232532425325253262532725328253292533025331253322533325334253352533625337253382533925340253412534225343253442534525346253472534825349253502535125352253532535425355253562535725358253592536025361253622536325364253652536625367253682536925370253712537225373253742537525376253772537825379253802538125382253832538425385253862538725388253892539025391253922539325394253952539625397253982539925400254012540225403254042540525406254072540825409254102541125412254132541425415254162541725418254192542025421254222542325424254252542625427254282542925430254312543225433254342543525436254372543825439254402544125442254432544425445254462544725448254492545025451254522545325454254552545625457254582545925460254612546225463254642546525466254672546825469254702547125472254732547425475254762547725478254792548025481254822548325484254852548625487254882548925490254912549225493254942549525496254972549825499255002550125502255032550425505255062550725508255092551025511255122551325514255152551625517255182551925520255212552225523255242552525526255272552825529255302553125532255332553425535255362553725538255392554025541255422554325544255452554625547255482554925550255512555225553255542555525556255572555825559255602556125562255632556425565255662556725568255692557025571255722557325574255752557625577255782557925580255812558225583255842558525586255872558825589255902559125592255932559425595255962559725598255992560025601256022560325604256052560625607256082560925610256112561225613256142561525616256172561825619256202562125622256232562425625256262562725628256292563025631256322563325634256352563625637256382563925640256412564225643256442564525646256472564825649256502565125652256532565425655256562565725658256592566025661256622566325664256652566625667256682566925670256712567225673256742567525676256772567825679256802568125682256832568425685256862568725688256892569025691256922569325694256952569625697256982569925700257012570225703257042570525706257072570825709257102571125712257132571425715257162571725718257192572025721257222572325724257252572625727257282572925730257312573225733257342573525736257372573825739257402574125742257432574425745257462574725748257492575025751257522575325754257552575625757257582575925760257612576225763257642576525766257672576825769257702577125772257732577425775257762577725778257792578025781257822578325784257852578625787257882578925790257912579225793257942579525796257972579825799258002580125802258032580425805258062580725808258092581025811258122581325814258152581625817258182581925820258212582225823258242582525826258272582825829258302583125832258332583425835258362583725838258392584025841258422584325844258452584625847258482584925850258512585225853258542585525856258572585825859258602586125862258632586425865258662586725868258692587025871258722587325874258752587625877258782587925880258812588225883258842588525886258872588825889258902589125892258932589425895258962589725898258992590025901259022590325904259052590625907259082590925910259112591225913259142591525916259172591825919259202592125922259232592425925259262592725928259292593025931259322593325934259352593625937259382593925940259412594225943259442594525946259472594825949259502595125952259532595425955259562595725958259592596025961259622596325964259652596625967259682596925970259712597225973259742597525976259772597825979259802598125982259832598425985259862598725988259892599025991259922599325994259952599625997259982599926000260012600226003260042600526006260072600826009260102601126012260132601426015260162601726018260192602026021260222602326024260252602626027260282602926030260312603226033260342603526036260372603826039260402604126042260432604426045260462604726048260492605026051260522605326054260552605626057260582605926060260612606226063260642606526066260672606826069260702607126072260732607426075260762607726078260792608026081260822608326084260852608626087260882608926090260912609226093260942609526096260972609826099261002610126102261032610426105261062610726108261092611026111261122611326114261152611626117261182611926120261212612226123261242612526126261272612826129261302613126132261332613426135261362613726138261392614026141261422614326144261452614626147261482614926150261512615226153261542615526156261572615826159261602616126162261632616426165261662616726168261692617026171261722617326174261752617626177261782617926180261812618226183261842618526186261872618826189261902619126192261932619426195261962619726198261992620026201262022620326204262052620626207262082620926210262112621226213262142621526216262172621826219262202622126222262232622426225262262622726228262292623026231262322623326234262352623626237262382623926240262412624226243262442624526246262472624826249262502625126252262532625426255262562625726258262592626026261262622626326264262652626626267262682626926270262712627226273262742627526276262772627826279262802628126282262832628426285262862628726288262892629026291262922629326294262952629626297262982629926300263012630226303263042630526306263072630826309263102631126312263132631426315263162631726318263192632026321263222632326324263252632626327263282632926330263312633226333263342633526336263372633826339263402634126342263432634426345263462634726348263492635026351263522635326354263552635626357263582635926360263612636226363263642636526366263672636826369263702637126372263732637426375263762637726378263792638026381263822638326384263852638626387263882638926390263912639226393263942639526396263972639826399264002640126402264032640426405264062640726408264092641026411264122641326414264152641626417264182641926420264212642226423264242642526426264272642826429264302643126432264332643426435264362643726438264392644026441264422644326444264452644626447264482644926450264512645226453264542645526456264572645826459264602646126462264632646426465264662646726468264692647026471264722647326474264752647626477264782647926480264812648226483264842648526486264872648826489264902649126492264932649426495264962649726498264992650026501265022650326504265052650626507265082650926510265112651226513265142651526516265172651826519265202652126522265232652426525265262652726528265292653026531265322653326534265352653626537265382653926540265412654226543265442654526546265472654826549265502655126552265532655426555265562655726558265592656026561265622656326564265652656626567265682656926570265712657226573265742657526576265772657826579265802658126582265832658426585265862658726588265892659026591265922659326594265952659626597265982659926600266012660226603266042660526606266072660826609266102661126612266132661426615266162661726618266192662026621266222662326624266252662626627266282662926630266312663226633266342663526636266372663826639266402664126642266432664426645266462664726648266492665026651266522665326654266552665626657266582665926660266612666226663266642666526666266672666826669266702667126672266732667426675266762667726678266792668026681266822668326684266852668626687266882668926690266912669226693266942669526696266972669826699267002670126702267032670426705267062670726708267092671026711267122671326714267152671626717267182671926720267212672226723267242672526726267272672826729267302673126732267332673426735267362673726738267392674026741267422674326744267452674626747267482674926750267512675226753267542675526756267572675826759267602676126762267632676426765267662676726768267692677026771267722677326774267752677626777267782677926780267812678226783267842678526786267872678826789267902679126792267932679426795267962679726798267992680026801268022680326804268052680626807268082680926810268112681226813268142681526816268172681826819268202682126822268232682426825268262682726828268292683026831268322683326834268352683626837268382683926840268412684226843268442684526846268472684826849268502685126852268532685426855268562685726858268592686026861268622686326864268652686626867268682686926870268712687226873268742687526876268772687826879268802688126882268832688426885268862688726888268892689026891268922689326894268952689626897268982689926900269012690226903269042690526906269072690826909269102691126912269132691426915269162691726918269192692026921269222692326924269252692626927269282692926930269312693226933269342693526936269372693826939269402694126942269432694426945269462694726948269492695026951269522695326954269552695626957269582695926960269612696226963269642696526966269672696826969269702697126972269732697426975269762697726978269792698026981269822698326984269852698626987269882698926990269912699226993269942699526996269972699826999270002700127002270032700427005270062700727008270092701027011270122701327014270152701627017270182701927020270212702227023270242702527026270272702827029270302703127032270332703427035270362703727038270392704027041270422704327044270452704627047270482704927050270512705227053270542705527056270572705827059270602706127062270632706427065270662706727068270692707027071270722707327074270752707627077270782707927080270812708227083270842708527086270872708827089270902709127092270932709427095270962709727098270992710027101271022710327104271052710627107271082710927110271112711227113271142711527116271172711827119271202712127122271232712427125271262712727128271292713027131271322713327134271352713627137271382713927140271412714227143271442714527146271472714827149271502715127152271532715427155271562715727158271592716027161271622716327164271652716627167271682716927170271712717227173271742717527176271772717827179271802718127182271832718427185271862718727188271892719027191271922719327194271952719627197271982719927200272012720227203272042720527206272072720827209272102721127212272132721427215272162721727218272192722027221272222722327224272252722627227272282722927230272312723227233272342723527236272372723827239272402724127242272432724427245272462724727248272492725027251272522725327254272552725627257272582725927260272612726227263272642726527266272672726827269272702727127272272732727427275272762727727278272792728027281272822728327284272852728627287272882728927290272912729227293272942729527296272972729827299273002730127302273032730427305273062730727308273092731027311273122731327314273152731627317273182731927320273212732227323273242732527326273272732827329273302733127332273332733427335273362733727338273392734027341273422734327344273452734627347273482734927350273512735227353273542735527356273572735827359273602736127362273632736427365273662736727368273692737027371273722737327374273752737627377273782737927380273812738227383273842738527386273872738827389273902739127392273932739427395273962739727398273992740027401274022740327404274052740627407274082740927410274112741227413274142741527416274172741827419274202742127422274232742427425274262742727428274292743027431274322743327434274352743627437274382743927440274412744227443274442744527446274472744827449274502745127452274532745427455274562745727458274592746027461274622746327464274652746627467274682746927470274712747227473274742747527476274772747827479274802748127482274832748427485274862748727488274892749027491274922749327494274952749627497274982749927500275012750227503275042750527506275072750827509275102751127512275132751427515275162751727518275192752027521275222752327524275252752627527275282752927530275312753227533275342753527536275372753827539275402754127542275432754427545275462754727548275492755027551275522755327554275552755627557275582755927560275612756227563275642756527566275672756827569275702757127572275732757427575275762757727578275792758027581275822758327584275852758627587275882758927590275912759227593275942759527596275972759827599276002760127602276032760427605276062760727608276092761027611276122761327614276152761627617276182761927620276212762227623276242762527626276272762827629276302763127632276332763427635276362763727638276392764027641276422764327644276452764627647276482764927650276512765227653276542765527656276572765827659276602766127662276632766427665276662766727668276692767027671276722767327674276752767627677276782767927680276812768227683276842768527686276872768827689276902769127692276932769427695276962769727698276992770027701277022770327704277052770627707277082770927710277112771227713277142771527716277172771827719277202772127722277232772427725277262772727728277292773027731277322773327734277352773627737277382773927740277412774227743277442774527746277472774827749277502775127752277532775427755277562775727758277592776027761277622776327764277652776627767277682776927770277712777227773277742777527776277772777827779277802778127782277832778427785277862778727788277892779027791277922779327794277952779627797277982779927800278012780227803278042780527806278072780827809278102781127812278132781427815278162781727818278192782027821278222782327824278252782627827278282782927830278312783227833278342783527836278372783827839278402784127842278432784427845278462784727848278492785027851278522785327854278552785627857278582785927860278612786227863278642786527866278672786827869278702787127872278732787427875278762787727878278792788027881278822788327884278852788627887278882788927890278912789227893278942789527896278972789827899279002790127902279032790427905279062790727908279092791027911279122791327914279152791627917279182791927920279212792227923279242792527926279272792827929279302793127932279332793427935279362793727938279392794027941279422794327944279452794627947279482794927950279512795227953279542795527956279572795827959279602796127962279632796427965279662796727968279692797027971279722797327974279752797627977279782797927980279812798227983279842798527986279872798827989279902799127992279932799427995279962799727998279992800028001280022800328004280052800628007280082800928010280112801228013280142801528016280172801828019280202802128022280232802428025280262802728028280292803028031280322803328034280352803628037280382803928040280412804228043280442804528046280472804828049280502805128052280532805428055280562805728058280592806028061280622806328064280652806628067280682806928070280712807228073280742807528076280772807828079280802808128082280832808428085280862808728088280892809028091280922809328094280952809628097280982809928100281012810228103281042810528106281072810828109281102811128112281132811428115281162811728118281192812028121281222812328124281252812628127281282812928130281312813228133281342813528136281372813828139281402814128142281432814428145281462814728148281492815028151281522815328154281552815628157281582815928160281612816228163281642816528166281672816828169281702817128172281732817428175281762817728178281792818028181281822818328184281852818628187281882818928190281912819228193281942819528196281972819828199282002820128202282032820428205282062820728208282092821028211282122821328214282152821628217282182821928220282212822228223282242822528226282272822828229282302823128232282332823428235282362823728238282392824028241282422824328244282452824628247282482824928250282512825228253282542825528256282572825828259282602826128262282632826428265282662826728268282692827028271282722827328274282752827628277282782827928280282812828228283282842828528286282872828828289282902829128292282932829428295282962829728298282992830028301283022830328304283052830628307283082830928310283112831228313283142831528316283172831828319283202832128322283232832428325283262832728328283292833028331283322833328334283352833628337283382833928340283412834228343283442834528346283472834828349283502835128352283532835428355283562835728358283592836028361283622836328364283652836628367283682836928370283712837228373283742837528376283772837828379283802838128382283832838428385283862838728388283892839028391283922839328394283952839628397283982839928400284012840228403284042840528406284072840828409284102841128412284132841428415284162841728418284192842028421284222842328424284252842628427284282842928430284312843228433284342843528436284372843828439284402844128442284432844428445284462844728448284492845028451284522845328454284552845628457284582845928460284612846228463284642846528466284672846828469284702847128472284732847428475284762847728478284792848028481284822848328484284852848628487284882848928490284912849228493284942849528496284972849828499285002850128502285032850428505285062850728508285092851028511285122851328514285152851628517285182851928520285212852228523285242852528526285272852828529285302853128532285332853428535285362853728538285392854028541285422854328544285452854628547285482854928550285512855228553285542855528556285572855828559285602856128562285632856428565285662856728568285692857028571285722857328574285752857628577285782857928580285812858228583285842858528586285872858828589285902859128592285932859428595285962859728598285992860028601286022860328604286052860628607286082860928610286112861228613286142861528616286172861828619286202862128622286232862428625286262862728628286292863028631286322863328634286352863628637286382863928640286412864228643286442864528646286472864828649286502865128652286532865428655286562865728658286592866028661286622866328664286652866628667286682866928670286712867228673286742867528676286772867828679286802868128682286832868428685286862868728688286892869028691286922869328694286952869628697286982869928700287012870228703287042870528706287072870828709287102871128712287132871428715287162871728718287192872028721287222872328724287252872628727287282872928730287312873228733287342873528736287372873828739287402874128742287432874428745287462874728748287492875028751287522875328754287552875628757287582875928760287612876228763287642876528766287672876828769287702877128772287732877428775287762877728778287792878028781287822878328784287852878628787287882878928790287912879228793287942879528796287972879828799288002880128802288032880428805288062880728808288092881028811288122881328814288152881628817288182881928820288212882228823288242882528826288272882828829288302883128832288332883428835288362883728838288392884028841288422884328844288452884628847288482884928850288512885228853288542885528856288572885828859288602886128862288632886428865288662886728868288692887028871288722887328874288752887628877288782887928880288812888228883288842888528886288872888828889288902889128892288932889428895288962889728898288992890028901289022890328904289052890628907289082890928910289112891228913289142891528916289172891828919289202892128922289232892428925289262892728928289292893028931289322893328934289352893628937289382893928940289412894228943289442894528946289472894828949289502895128952289532895428955289562895728958289592896028961289622896328964289652896628967289682896928970289712897228973289742897528976289772897828979289802898128982289832898428985289862898728988289892899028991289922899328994289952899628997289982899929000290012900229003290042900529006290072900829009290102901129012290132901429015290162901729018290192902029021290222902329024290252902629027290282902929030290312903229033290342903529036290372903829039290402904129042290432904429045290462904729048290492905029051290522905329054290552905629057290582905929060290612906229063290642906529066290672906829069290702907129072290732907429075290762907729078290792908029081290822908329084290852908629087290882908929090290912909229093290942909529096290972909829099291002910129102291032910429105291062910729108291092911029111291122911329114291152911629117291182911929120291212912229123291242912529126291272912829129291302913129132291332913429135291362913729138291392914029141291422914329144291452914629147291482914929150291512915229153291542915529156291572915829159291602916129162291632916429165291662916729168291692917029171291722917329174291752917629177291782917929180291812918229183291842918529186291872918829189291902919129192291932919429195291962919729198291992920029201292022920329204292052920629207292082920929210292112921229213292142921529216292172921829219292202922129222292232922429225292262922729228292292923029231292322923329234292352923629237292382923929240292412924229243292442924529246292472924829249292502925129252292532925429255292562925729258292592926029261292622926329264292652926629267292682926929270292712927229273292742927529276292772927829279292802928129282292832928429285292862928729288292892929029291292922929329294292952929629297292982929929300293012930229303293042930529306293072930829309293102931129312293132931429315293162931729318293192932029321293222932329324293252932629327293282932929330293312933229333293342933529336293372933829339293402934129342293432934429345293462934729348293492935029351293522935329354293552935629357293582935929360293612936229363293642936529366293672936829369293702937129372293732937429375293762937729378293792938029381293822938329384293852938629387293882938929390293912939229393293942939529396293972939829399294002940129402294032940429405294062940729408294092941029411294122941329414294152941629417294182941929420294212942229423294242942529426294272942829429294302943129432294332943429435294362943729438294392944029441294422944329444294452944629447294482944929450294512945229453294542945529456294572945829459294602946129462294632946429465294662946729468294692947029471294722947329474294752947629477294782947929480294812948229483294842948529486294872948829489294902949129492294932949429495294962949729498294992950029501295022950329504295052950629507295082950929510295112951229513295142951529516295172951829519295202952129522295232952429525295262952729528295292953029531295322953329534295352953629537295382953929540295412954229543295442954529546295472954829549295502955129552295532955429555295562955729558295592956029561295622956329564295652956629567295682956929570295712957229573295742957529576295772957829579295802958129582295832958429585295862958729588295892959029591295922959329594295952959629597295982959929600296012960229603296042960529606296072960829609296102961129612296132961429615296162961729618296192962029621296222962329624296252962629627296282962929630296312963229633296342963529636296372963829639296402964129642296432964429645296462964729648296492965029651296522965329654296552965629657296582965929660296612966229663296642966529666296672966829669296702967129672296732967429675296762967729678296792968029681296822968329684296852968629687296882968929690296912969229693296942969529696296972969829699297002970129702297032970429705297062970729708297092971029711297122971329714297152971629717297182971929720297212972229723297242972529726297272972829729297302973129732297332973429735297362973729738297392974029741297422974329744297452974629747297482974929750297512975229753297542975529756297572975829759297602976129762297632976429765297662976729768297692977029771297722977329774297752977629777297782977929780297812978229783297842978529786297872978829789297902979129792297932979429795297962979729798297992980029801298022980329804298052980629807298082980929810298112981229813298142981529816298172981829819298202982129822298232982429825298262982729828298292983029831298322983329834298352983629837298382983929840298412984229843298442984529846298472984829849298502985129852298532985429855298562985729858298592986029861298622986329864298652986629867298682986929870298712987229873298742987529876298772987829879298802988129882298832988429885298862988729888298892989029891298922989329894298952989629897298982989929900299012990229903299042990529906299072990829909299102991129912299132991429915299162991729918299192992029921299222992329924299252992629927299282992929930299312993229933299342993529936299372993829939299402994129942299432994429945299462994729948299492995029951299522995329954299552995629957299582995929960299612996229963299642996529966299672996829969299702997129972299732997429975299762997729978299792998029981299822998329984299852998629987299882998929990299912999229993299942999529996299972999829999300003000130002300033000430005300063000730008300093001030011300123001330014300153001630017300183001930020300213002230023300243002530026300273002830029300303003130032300333003430035300363003730038300393004030041300423004330044300453004630047300483004930050300513005230053300543005530056300573005830059300603006130062300633006430065300663006730068300693007030071300723007330074300753007630077300783007930080300813008230083300843008530086300873008830089300903009130092300933009430095300963009730098300993010030101301023010330104301053010630107301083010930110301113011230113301143011530116301173011830119301203012130122301233012430125301263012730128301293013030131301323013330134301353013630137301383013930140301413014230143301443014530146301473014830149301503015130152301533015430155301563015730158301593016030161301623016330164301653016630167301683016930170301713017230173301743017530176301773017830179301803018130182301833018430185301863018730188301893019030191301923019330194301953019630197301983019930200302013020230203302043020530206302073020830209302103021130212302133021430215302163021730218302193022030221302223022330224302253022630227302283022930230302313023230233302343023530236302373023830239302403024130242302433024430245302463024730248302493025030251302523025330254302553025630257302583025930260302613026230263302643026530266302673026830269302703027130272302733027430275302763027730278302793028030281302823028330284302853028630287302883028930290302913029230293302943029530296302973029830299303003030130302303033030430305303063030730308303093031030311303123031330314303153031630317303183031930320303213032230323303243032530326303273032830329303303033130332303333033430335303363033730338303393034030341303423034330344303453034630347303483034930350303513035230353303543035530356303573035830359303603036130362303633036430365303663036730368303693037030371303723037330374303753037630377303783037930380303813038230383303843038530386303873038830389303903039130392303933039430395303963039730398303993040030401304023040330404304053040630407304083040930410304113041230413304143041530416304173041830419304203042130422304233042430425304263042730428304293043030431304323043330434304353043630437304383043930440304413044230443304443044530446304473044830449304503045130452304533045430455304563045730458304593046030461304623046330464304653046630467304683046930470304713047230473304743047530476304773047830479304803048130482304833048430485304863048730488304893049030491304923049330494304953049630497304983049930500305013050230503305043050530506305073050830509305103051130512305133051430515305163051730518305193052030521305223052330524305253052630527305283052930530305313053230533305343053530536305373053830539305403054130542305433054430545305463054730548305493055030551305523055330554305553055630557305583055930560305613056230563305643056530566305673056830569305703057130572305733057430575305763057730578305793058030581305823058330584305853058630587305883058930590305913059230593305943059530596305973059830599306003060130602306033060430605306063060730608306093061030611306123061330614306153061630617306183061930620306213062230623306243062530626306273062830629306303063130632306333063430635306363063730638306393064030641306423064330644306453064630647306483064930650306513065230653306543065530656306573065830659306603066130662306633066430665306663066730668306693067030671306723067330674306753067630677306783067930680306813068230683306843068530686306873068830689306903069130692306933069430695306963069730698306993070030701307023070330704307053070630707307083070930710307113071230713307143071530716307173071830719307203072130722307233072430725307263072730728307293073030731307323073330734307353073630737307383073930740307413074230743307443074530746307473074830749307503075130752307533075430755307563075730758307593076030761307623076330764307653076630767307683076930770307713077230773307743077530776307773077830779307803078130782307833078430785307863078730788307893079030791307923079330794307953079630797307983079930800308013080230803308043080530806308073080830809308103081130812308133081430815308163081730818308193082030821308223082330824308253082630827308283082930830308313083230833308343083530836308373083830839308403084130842308433084430845308463084730848308493085030851308523085330854308553085630857308583085930860308613086230863308643086530866308673086830869308703087130872308733087430875308763087730878308793088030881308823088330884308853088630887308883088930890308913089230893308943089530896308973089830899309003090130902309033090430905309063090730908309093091030911309123091330914309153091630917309183091930920309213092230923309243092530926309273092830929309303093130932309333093430935309363093730938309393094030941309423094330944309453094630947309483094930950309513095230953309543095530956309573095830959309603096130962309633096430965309663096730968309693097030971309723097330974309753097630977309783097930980309813098230983309843098530986309873098830989309903099130992309933099430995309963099730998309993100031001310023100331004310053100631007310083100931010310113101231013310143101531016310173101831019310203102131022310233102431025310263102731028310293103031031310323103331034310353103631037310383103931040310413104231043310443104531046310473104831049310503105131052310533105431055310563105731058310593106031061310623106331064310653106631067310683106931070310713107231073310743107531076310773107831079310803108131082310833108431085310863108731088310893109031091310923109331094310953109631097310983109931100311013110231103311043110531106311073110831109311103111131112311133111431115311163111731118311193112031121311223112331124311253112631127311283112931130311313113231133311343113531136311373113831139311403114131142311433114431145311463114731148311493115031151311523115331154311553115631157311583115931160311613116231163311643116531166311673116831169311703117131172311733117431175311763117731178311793118031181311823118331184311853118631187311883118931190311913119231193311943119531196311973119831199312003120131202312033120431205312063120731208312093121031211312123121331214312153121631217312183121931220312213122231223312243122531226312273122831229312303123131232312333123431235312363123731238312393124031241312423124331244312453124631247312483124931250312513125231253312543125531256312573125831259312603126131262312633126431265312663126731268312693127031271312723127331274312753127631277312783127931280312813128231283312843128531286312873128831289312903129131292312933129431295312963129731298312993130031301313023130331304313053130631307313083130931310313113131231313313143131531316313173131831319313203132131322313233132431325313263132731328313293133031331313323133331334313353133631337313383133931340313413134231343313443134531346313473134831349313503135131352313533135431355313563135731358313593136031361313623136331364313653136631367313683136931370313713137231373313743137531376313773137831379313803138131382313833138431385313863138731388313893139031391313923139331394313953139631397313983139931400314013140231403314043140531406314073140831409314103141131412314133141431415314163141731418314193142031421314223142331424314253142631427314283142931430314313143231433314343143531436314373143831439314403144131442314433144431445314463144731448314493145031451314523145331454314553145631457314583145931460314613146231463314643146531466314673146831469314703147131472314733147431475314763147731478314793148031481314823148331484314853148631487314883148931490314913149231493314943149531496314973149831499315003150131502315033150431505315063150731508315093151031511315123151331514315153151631517315183151931520315213152231523315243152531526315273152831529315303153131532315333153431535315363153731538315393154031541315423154331544315453154631547315483154931550315513155231553315543155531556315573155831559315603156131562315633156431565315663156731568315693157031571315723157331574315753157631577315783157931580315813158231583315843158531586315873158831589315903159131592315933159431595315963159731598315993160031601316023160331604316053160631607316083160931610316113161231613316143161531616316173161831619316203162131622316233162431625316263162731628316293163031631316323163331634316353163631637316383163931640316413164231643316443164531646316473164831649316503165131652316533165431655316563165731658316593166031661316623166331664316653166631667316683166931670316713167231673316743167531676316773167831679316803168131682316833168431685316863168731688316893169031691316923169331694316953169631697316983169931700317013170231703317043170531706317073170831709317103171131712317133171431715317163171731718317193172031721317223172331724317253172631727317283172931730317313173231733317343173531736317373173831739317403174131742317433174431745317463174731748317493175031751317523175331754317553175631757317583175931760317613176231763317643176531766317673176831769317703177131772317733177431775317763177731778317793178031781317823178331784317853178631787317883178931790317913179231793317943179531796317973179831799318003180131802318033180431805318063180731808318093181031811318123181331814318153181631817318183181931820318213182231823318243182531826318273182831829318303183131832318333183431835318363183731838318393184031841318423184331844318453184631847318483184931850318513185231853318543185531856318573185831859318603186131862318633186431865318663186731868318693187031871318723187331874318753187631877318783187931880318813188231883318843188531886318873188831889318903189131892318933189431895318963189731898318993190031901319023190331904319053190631907319083190931910319113191231913319143191531916319173191831919319203192131922319233192431925319263192731928319293193031931319323193331934319353193631937319383193931940319413194231943319443194531946319473194831949319503195131952319533195431955319563195731958319593196031961319623196331964319653196631967319683196931970319713197231973319743197531976319773197831979319803198131982319833198431985319863198731988319893199031991319923199331994319953199631997319983199932000320013200232003320043200532006320073200832009320103201132012320133201432015320163201732018320193202032021320223202332024320253202632027320283202932030320313203232033320343203532036320373203832039320403204132042320433204432045320463204732048320493205032051320523205332054320553205632057320583205932060320613206232063320643206532066320673206832069320703207132072320733207432075320763207732078320793208032081320823208332084320853208632087320883208932090320913209232093320943209532096320973209832099321003210132102321033210432105321063210732108321093211032111321123211332114321153211632117321183211932120321213212232123321243212532126321273212832129321303213132132321333213432135321363213732138321393214032141321423214332144321453214632147321483214932150321513215232153321543215532156321573215832159321603216132162321633216432165321663216732168321693217032171321723217332174321753217632177321783217932180321813218232183321843218532186321873218832189321903219132192321933219432195321963219732198321993220032201322023220332204322053220632207322083220932210322113221232213322143221532216322173221832219322203222132222322233222432225322263222732228322293223032231322323223332234322353223632237322383223932240322413224232243322443224532246322473224832249322503225132252322533225432255322563225732258322593226032261322623226332264322653226632267322683226932270322713227232273322743227532276322773227832279322803228132282322833228432285322863228732288322893229032291322923229332294322953229632297322983229932300323013230232303323043230532306323073230832309323103231132312323133231432315323163231732318323193232032321323223232332324323253232632327323283232932330323313233232333323343233532336323373233832339323403234132342323433234432345323463234732348323493235032351323523235332354323553235632357323583235932360323613236232363323643236532366323673236832369323703237132372323733237432375323763237732378323793238032381323823238332384323853238632387323883238932390323913239232393323943239532396323973239832399324003240132402324033240432405324063240732408324093241032411324123241332414324153241632417324183241932420324213242232423324243242532426324273242832429324303243132432324333243432435324363243732438324393244032441324423244332444324453244632447324483244932450324513245232453324543245532456324573245832459324603246132462324633246432465324663246732468324693247032471324723247332474324753247632477324783247932480324813248232483324843248532486324873248832489324903249132492324933249432495324963249732498324993250032501325023250332504325053250632507325083250932510325113251232513325143251532516325173251832519325203252132522325233252432525325263252732528325293253032531325323253332534325353253632537325383253932540325413254232543325443254532546325473254832549325503255132552325533255432555325563255732558325593256032561325623256332564325653256632567325683256932570325713257232573325743257532576325773257832579325803258132582325833258432585325863258732588325893259032591325923259332594325953259632597325983259932600326013260232603326043260532606326073260832609326103261132612326133261432615326163261732618326193262032621326223262332624326253262632627326283262932630326313263232633326343263532636326373263832639326403264132642326433264432645326463264732648326493265032651326523265332654326553265632657326583265932660326613266232663326643266532666326673266832669326703267132672326733267432675326763267732678326793268032681326823268332684326853268632687326883268932690326913269232693326943269532696326973269832699327003270132702327033270432705327063270732708327093271032711327123271332714327153271632717327183271932720327213272232723327243272532726327273272832729327303273132732327333273432735327363273732738327393274032741327423274332744327453274632747327483274932750327513275232753327543275532756327573275832759327603276132762327633276432765327663276732768327693277032771327723277332774327753277632777327783277932780327813278232783327843278532786327873278832789327903279132792327933279432795327963279732798327993280032801328023280332804328053280632807328083280932810328113281232813328143281532816328173281832819328203282132822328233282432825328263282732828328293283032831328323283332834328353283632837328383283932840328413284232843328443284532846328473284832849328503285132852328533285432855328563285732858328593286032861328623286332864328653286632867328683286932870328713287232873328743287532876328773287832879328803288132882328833288432885328863288732888328893289032891328923289332894328953289632897328983289932900329013290232903329043290532906329073290832909329103291132912329133291432915329163291732918329193292032921329223292332924329253292632927329283292932930329313293232933329343293532936329373293832939329403294132942329433294432945329463294732948329493295032951329523295332954329553295632957329583295932960329613296232963329643296532966329673296832969329703297132972329733297432975329763297732978329793298032981329823298332984329853298632987329883298932990329913299232993329943299532996329973299832999330003300133002330033300433005330063300733008330093301033011330123301333014330153301633017330183301933020330213302233023330243302533026330273302833029330303303133032330333303433035330363303733038330393304033041330423304333044330453304633047330483304933050330513305233053330543305533056330573305833059330603306133062330633306433065330663306733068330693307033071330723307333074330753307633077330783307933080330813308233083330843308533086330873308833089330903309133092330933309433095330963309733098330993310033101331023310333104331053310633107331083310933110331113311233113331143311533116331173311833119331203312133122331233312433125331263312733128331293313033131331323313333134331353313633137331383313933140331413314233143331443314533146331473314833149331503315133152331533315433155331563315733158331593316033161331623316333164331653316633167331683316933170331713317233173331743317533176331773317833179331803318133182331833318433185331863318733188331893319033191331923319333194331953319633197331983319933200332013320233203332043320533206332073320833209332103321133212332133321433215332163321733218332193322033221332223322333224332253322633227332283322933230332313323233233332343323533236332373323833239332403324133242332433324433245332463324733248332493325033251332523325333254332553325633257332583325933260332613326233263332643326533266332673326833269332703327133272332733327433275332763327733278332793328033281332823328333284332853328633287332883328933290332913329233293332943329533296332973329833299333003330133302333033330433305333063330733308333093331033311333123331333314333153331633317333183331933320333213332233323333243332533326333273332833329333303333133332333333333433335333363333733338333393334033341333423334333344333453334633347333483334933350333513335233353333543335533356333573335833359333603336133362333633336433365333663336733368333693337033371333723337333374333753337633377333783337933380333813338233383333843338533386333873338833389333903339133392333933339433395333963339733398333993340033401334023340333404334053340633407334083340933410334113341233413334143341533416334173341833419334203342133422334233342433425334263342733428334293343033431334323343333434334353343633437334383343933440334413344233443334443344533446334473344833449334503345133452334533345433455334563345733458334593346033461334623346333464334653346633467334683346933470334713347233473334743347533476334773347833479334803348133482334833348433485334863348733488334893349033491334923349333494334953349633497334983349933500335013350233503335043350533506335073350833509335103351133512335133351433515335163351733518335193352033521335223352333524335253352633527335283352933530335313353233533
  1. #! /bin/sh
  2. # From configure.ac Revision: 421229 .
  3. # Guess values for system-dependent variables and create Makefiles.
  4. # Generated by GNU Autoconf 2.69 for asterisk trunk.
  5. #
  6. # Report bugs to <https://issues.asterisk.org>.
  7. #
  8. #
  9. # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
  10. #
  11. #
  12. # This configure script is free software; the Free Software Foundation
  13. # gives unlimited permission to copy, distribute and modify it.
  14. #
  15. # "Asterisk"
  16. ## -------------------- ##
  17. ## M4sh Initialization. ##
  18. ## -------------------- ##
  19. # Be more Bourne compatible
  20. DUALCASE=1; export DUALCASE # for MKS sh
  21. if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
  22. emulate sh
  23. NULLCMD=:
  24. # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
  25. # is contrary to our usage. Disable this feature.
  26. alias -g '${1+"$@"}'='"$@"'
  27. setopt NO_GLOB_SUBST
  28. else
  29. case `(set -o) 2>/dev/null` in #(
  30. *posix*) :
  31. set -o posix ;; #(
  32. *) :
  33. ;;
  34. esac
  35. fi
  36. as_nl='
  37. '
  38. export as_nl
  39. # Printing a long string crashes Solaris 7 /usr/bin/printf.
  40. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
  41. as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
  42. as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
  43. # Prefer a ksh shell builtin over an external printf program on Solaris,
  44. # but without wasting forks for bash or zsh.
  45. if test -z "$BASH_VERSION$ZSH_VERSION" \
  46. && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
  47. as_echo='print -r --'
  48. as_echo_n='print -rn --'
  49. elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
  50. as_echo='printf %s\n'
  51. as_echo_n='printf %s'
  52. else
  53. if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
  54. as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
  55. as_echo_n='/usr/ucb/echo -n'
  56. else
  57. as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
  58. as_echo_n_body='eval
  59. arg=$1;
  60. case $arg in #(
  61. *"$as_nl"*)
  62. expr "X$arg" : "X\\(.*\\)$as_nl";
  63. arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
  64. esac;
  65. expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
  66. '
  67. export as_echo_n_body
  68. as_echo_n='sh -c $as_echo_n_body as_echo'
  69. fi
  70. export as_echo_body
  71. as_echo='sh -c $as_echo_body as_echo'
  72. fi
  73. # The user is always right.
  74. if test "${PATH_SEPARATOR+set}" != set; then
  75. PATH_SEPARATOR=:
  76. (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
  77. (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
  78. PATH_SEPARATOR=';'
  79. }
  80. fi
  81. # IFS
  82. # We need space, tab and new line, in precisely that order. Quoting is
  83. # there to prevent editors from complaining about space-tab.
  84. # (If _AS_PATH_WALK were called with IFS unset, it would disable word
  85. # splitting by setting IFS to empty value.)
  86. IFS=" "" $as_nl"
  87. # Find who we are. Look in the path if we contain no directory separator.
  88. as_myself=
  89. case $0 in #((
  90. *[\\/]* ) as_myself=$0 ;;
  91. *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  92. for as_dir in $PATH
  93. do
  94. IFS=$as_save_IFS
  95. test -z "$as_dir" && as_dir=.
  96. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
  97. done
  98. IFS=$as_save_IFS
  99. ;;
  100. esac
  101. # We did not find ourselves, most probably we were run as `sh COMMAND'
  102. # in which case we are not to be found in the path.
  103. if test "x$as_myself" = x; then
  104. as_myself=$0
  105. fi
  106. if test ! -f "$as_myself"; then
  107. $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
  108. exit 1
  109. fi
  110. # Unset variables that we do not need and which cause bugs (e.g. in
  111. # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
  112. # suppresses any "Segmentation fault" message there. '((' could
  113. # trigger a bug in pdksh 5.2.14.
  114. for as_var in BASH_ENV ENV MAIL MAILPATH
  115. do eval test x\${$as_var+set} = xset \
  116. && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
  117. done
  118. PS1='$ '
  119. PS2='> '
  120. PS4='+ '
  121. # NLS nuisances.
  122. LC_ALL=C
  123. export LC_ALL
  124. LANGUAGE=C
  125. export LANGUAGE
  126. # CDPATH.
  127. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
  128. # Use a proper internal environment variable to ensure we don't fall
  129. # into an infinite loop, continuously re-executing ourselves.
  130. if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
  131. _as_can_reexec=no; export _as_can_reexec;
  132. # We cannot yet assume a decent shell, so we have to provide a
  133. # neutralization value for shells without unset; and this also
  134. # works around shells that cannot unset nonexistent variables.
  135. # Preserve -v and -x to the replacement shell.
  136. BASH_ENV=/dev/null
  137. ENV=/dev/null
  138. (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
  139. case $- in # ((((
  140. *v*x* | *x*v* ) as_opts=-vx ;;
  141. *v* ) as_opts=-v ;;
  142. *x* ) as_opts=-x ;;
  143. * ) as_opts= ;;
  144. esac
  145. exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
  146. # Admittedly, this is quite paranoid, since all the known shells bail
  147. # out after a failed `exec'.
  148. $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
  149. as_fn_exit 255
  150. fi
  151. # We don't want this to propagate to other subprocesses.
  152. { _as_can_reexec=; unset _as_can_reexec;}
  153. if test "x$CONFIG_SHELL" = x; then
  154. as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
  155. emulate sh
  156. NULLCMD=:
  157. # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
  158. # is contrary to our usage. Disable this feature.
  159. alias -g '\${1+\"\$@\"}'='\"\$@\"'
  160. setopt NO_GLOB_SUBST
  161. else
  162. case \`(set -o) 2>/dev/null\` in #(
  163. *posix*) :
  164. set -o posix ;; #(
  165. *) :
  166. ;;
  167. esac
  168. fi
  169. "
  170. as_required="as_fn_return () { (exit \$1); }
  171. as_fn_success () { as_fn_return 0; }
  172. as_fn_failure () { as_fn_return 1; }
  173. as_fn_ret_success () { return 0; }
  174. as_fn_ret_failure () { return 1; }
  175. exitcode=0
  176. as_fn_success || { exitcode=1; echo as_fn_success failed.; }
  177. as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
  178. as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
  179. as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
  180. if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
  181. else
  182. exitcode=1; echo positional parameters were not saved.
  183. fi
  184. test x\$exitcode = x0 || exit 1
  185. test -x / || exit 1"
  186. as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
  187. as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
  188. eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
  189. test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
  190. test \$(( 1 + 1 )) = 2 || exit 1"
  191. if (eval "$as_required") 2>/dev/null; then :
  192. as_have_required=yes
  193. else
  194. as_have_required=no
  195. fi
  196. if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
  197. else
  198. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  199. as_found=false
  200. for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
  201. do
  202. IFS=$as_save_IFS
  203. test -z "$as_dir" && as_dir=.
  204. as_found=:
  205. case $as_dir in #(
  206. /*)
  207. for as_base in sh bash ksh sh5; do
  208. # Try only shells that exist, to save several forks.
  209. as_shell=$as_dir/$as_base
  210. if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
  211. { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
  212. CONFIG_SHELL=$as_shell as_have_required=yes
  213. if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
  214. break 2
  215. fi
  216. fi
  217. done;;
  218. esac
  219. as_found=false
  220. done
  221. $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
  222. { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
  223. CONFIG_SHELL=$SHELL as_have_required=yes
  224. fi; }
  225. IFS=$as_save_IFS
  226. if test "x$CONFIG_SHELL" != x; then :
  227. export CONFIG_SHELL
  228. # We cannot yet assume a decent shell, so we have to provide a
  229. # neutralization value for shells without unset; and this also
  230. # works around shells that cannot unset nonexistent variables.
  231. # Preserve -v and -x to the replacement shell.
  232. BASH_ENV=/dev/null
  233. ENV=/dev/null
  234. (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
  235. case $- in # ((((
  236. *v*x* | *x*v* ) as_opts=-vx ;;
  237. *v* ) as_opts=-v ;;
  238. *x* ) as_opts=-x ;;
  239. * ) as_opts= ;;
  240. esac
  241. exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
  242. # Admittedly, this is quite paranoid, since all the known shells bail
  243. # out after a failed `exec'.
  244. $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
  245. exit 255
  246. fi
  247. if test x$as_have_required = xno; then :
  248. $as_echo "$0: This script requires a shell more modern than all"
  249. $as_echo "$0: the shells that I found on your system."
  250. if test x${ZSH_VERSION+set} = xset ; then
  251. $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
  252. $as_echo "$0: be upgraded to zsh 4.3.4 or later."
  253. else
  254. $as_echo "$0: Please tell bug-autoconf@gnu.org and
  255. $0: https://issues.asterisk.org about your system,
  256. $0: including any error possibly output before this
  257. $0: message. Then install a modern shell, or manually run
  258. $0: the script under such a shell if you do have one."
  259. fi
  260. exit 1
  261. fi
  262. fi
  263. fi
  264. SHELL=${CONFIG_SHELL-/bin/sh}
  265. export SHELL
  266. # Unset more variables known to interfere with behavior of common tools.
  267. CLICOLOR_FORCE= GREP_OPTIONS=
  268. unset CLICOLOR_FORCE GREP_OPTIONS
  269. ## --------------------- ##
  270. ## M4sh Shell Functions. ##
  271. ## --------------------- ##
  272. # as_fn_unset VAR
  273. # ---------------
  274. # Portably unset VAR.
  275. as_fn_unset ()
  276. {
  277. { eval $1=; unset $1;}
  278. }
  279. as_unset=as_fn_unset
  280. # as_fn_set_status STATUS
  281. # -----------------------
  282. # Set $? to STATUS, without forking.
  283. as_fn_set_status ()
  284. {
  285. return $1
  286. } # as_fn_set_status
  287. # as_fn_exit STATUS
  288. # -----------------
  289. # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
  290. as_fn_exit ()
  291. {
  292. set +e
  293. as_fn_set_status $1
  294. exit $1
  295. } # as_fn_exit
  296. # as_fn_mkdir_p
  297. # -------------
  298. # Create "$as_dir" as a directory, including parents if necessary.
  299. as_fn_mkdir_p ()
  300. {
  301. case $as_dir in #(
  302. -*) as_dir=./$as_dir;;
  303. esac
  304. test -d "$as_dir" || eval $as_mkdir_p || {
  305. as_dirs=
  306. while :; do
  307. case $as_dir in #(
  308. *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
  309. *) as_qdir=$as_dir;;
  310. esac
  311. as_dirs="'$as_qdir' $as_dirs"
  312. as_dir=`$as_dirname -- "$as_dir" ||
  313. $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
  314. X"$as_dir" : 'X\(//\)[^/]' \| \
  315. X"$as_dir" : 'X\(//\)$' \| \
  316. X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
  317. $as_echo X"$as_dir" |
  318. sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
  319. s//\1/
  320. q
  321. }
  322. /^X\(\/\/\)[^/].*/{
  323. s//\1/
  324. q
  325. }
  326. /^X\(\/\/\)$/{
  327. s//\1/
  328. q
  329. }
  330. /^X\(\/\).*/{
  331. s//\1/
  332. q
  333. }
  334. s/.*/./; q'`
  335. test -d "$as_dir" && break
  336. done
  337. test -z "$as_dirs" || eval "mkdir $as_dirs"
  338. } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
  339. } # as_fn_mkdir_p
  340. # as_fn_executable_p FILE
  341. # -----------------------
  342. # Test if FILE is an executable regular file.
  343. as_fn_executable_p ()
  344. {
  345. test -f "$1" && test -x "$1"
  346. } # as_fn_executable_p
  347. # as_fn_append VAR VALUE
  348. # ----------------------
  349. # Append the text in VALUE to the end of the definition contained in VAR. Take
  350. # advantage of any shell optimizations that allow amortized linear growth over
  351. # repeated appends, instead of the typical quadratic growth present in naive
  352. # implementations.
  353. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
  354. eval 'as_fn_append ()
  355. {
  356. eval $1+=\$2
  357. }'
  358. else
  359. as_fn_append ()
  360. {
  361. eval $1=\$$1\$2
  362. }
  363. fi # as_fn_append
  364. # as_fn_arith ARG...
  365. # ------------------
  366. # Perform arithmetic evaluation on the ARGs, and store the result in the
  367. # global $as_val. Take advantage of shells that can avoid forks. The arguments
  368. # must be portable across $(()) and expr.
  369. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
  370. eval 'as_fn_arith ()
  371. {
  372. as_val=$(( $* ))
  373. }'
  374. else
  375. as_fn_arith ()
  376. {
  377. as_val=`expr "$@" || test $? -eq 1`
  378. }
  379. fi # as_fn_arith
  380. # as_fn_error STATUS ERROR [LINENO LOG_FD]
  381. # ----------------------------------------
  382. # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
  383. # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
  384. # script with STATUS, using 1 if that was 0.
  385. as_fn_error ()
  386. {
  387. as_status=$1; test $as_status -eq 0 && as_status=1
  388. if test "$4"; then
  389. as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  390. $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
  391. fi
  392. $as_echo "$as_me: error: $2" >&2
  393. as_fn_exit $as_status
  394. } # as_fn_error
  395. if expr a : '\(a\)' >/dev/null 2>&1 &&
  396. test "X`expr 00001 : '.*\(...\)'`" = X001; then
  397. as_expr=expr
  398. else
  399. as_expr=false
  400. fi
  401. if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
  402. as_basename=basename
  403. else
  404. as_basename=false
  405. fi
  406. if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
  407. as_dirname=dirname
  408. else
  409. as_dirname=false
  410. fi
  411. as_me=`$as_basename -- "$0" ||
  412. $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
  413. X"$0" : 'X\(//\)$' \| \
  414. X"$0" : 'X\(/\)' \| . 2>/dev/null ||
  415. $as_echo X/"$0" |
  416. sed '/^.*\/\([^/][^/]*\)\/*$/{
  417. s//\1/
  418. q
  419. }
  420. /^X\/\(\/\/\)$/{
  421. s//\1/
  422. q
  423. }
  424. /^X\/\(\/\).*/{
  425. s//\1/
  426. q
  427. }
  428. s/.*/./; q'`
  429. # Avoid depending upon Character Ranges.
  430. as_cr_letters='abcdefghijklmnopqrstuvwxyz'
  431. as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
  432. as_cr_Letters=$as_cr_letters$as_cr_LETTERS
  433. as_cr_digits='0123456789'
  434. as_cr_alnum=$as_cr_Letters$as_cr_digits
  435. as_lineno_1=$LINENO as_lineno_1a=$LINENO
  436. as_lineno_2=$LINENO as_lineno_2a=$LINENO
  437. eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
  438. test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
  439. # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
  440. sed -n '
  441. p
  442. /[$]LINENO/=
  443. ' <$as_myself |
  444. sed '
  445. s/[$]LINENO.*/&-/
  446. t lineno
  447. b
  448. :lineno
  449. N
  450. :loop
  451. s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
  452. t loop
  453. s/-\n.*//
  454. ' >$as_me.lineno &&
  455. chmod +x "$as_me.lineno" ||
  456. { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
  457. # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
  458. # already done that, so ensure we don't try to do so again and fall
  459. # in an infinite loop. This has already happened in practice.
  460. _as_can_reexec=no; export _as_can_reexec
  461. # Don't try to exec as it changes $[0], causing all sort of problems
  462. # (the dirname of $[0] is not the place where we might find the
  463. # original and so on. Autoconf is especially sensitive to this).
  464. . "./$as_me.lineno"
  465. # Exit status is that of the last command.
  466. exit
  467. }
  468. ECHO_C= ECHO_N= ECHO_T=
  469. case `echo -n x` in #(((((
  470. -n*)
  471. case `echo 'xy\c'` in
  472. *c*) ECHO_T=' ';; # ECHO_T is single tab character.
  473. xy) ECHO_C='\c';;
  474. *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
  475. ECHO_T=' ';;
  476. esac;;
  477. *)
  478. ECHO_N='-n';;
  479. esac
  480. rm -f conf$$ conf$$.exe conf$$.file
  481. if test -d conf$$.dir; then
  482. rm -f conf$$.dir/conf$$.file
  483. else
  484. rm -f conf$$.dir
  485. mkdir conf$$.dir 2>/dev/null
  486. fi
  487. if (echo >conf$$.file) 2>/dev/null; then
  488. if ln -s conf$$.file conf$$ 2>/dev/null; then
  489. as_ln_s='ln -s'
  490. # ... but there are two gotchas:
  491. # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
  492. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
  493. # In both cases, we have to default to `cp -pR'.
  494. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
  495. as_ln_s='cp -pR'
  496. elif ln conf$$.file conf$$ 2>/dev/null; then
  497. as_ln_s=ln
  498. else
  499. as_ln_s='cp -pR'
  500. fi
  501. else
  502. as_ln_s='cp -pR'
  503. fi
  504. rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
  505. rmdir conf$$.dir 2>/dev/null
  506. if mkdir -p . 2>/dev/null; then
  507. as_mkdir_p='mkdir -p "$as_dir"'
  508. else
  509. test -d ./-p && rmdir ./-p
  510. as_mkdir_p=false
  511. fi
  512. as_test_x='test -x'
  513. as_executable_p=as_fn_executable_p
  514. # Sed expression to map a string onto a valid CPP name.
  515. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
  516. # Sed expression to map a string onto a valid variable name.
  517. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
  518. test -n "$DJDIR" || exec 7<&0 </dev/null
  519. exec 6>&1
  520. # Name of the host.
  521. # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
  522. # so uname gets run too.
  523. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
  524. #
  525. # Initializations.
  526. #
  527. ac_default_prefix=/usr/local
  528. ac_clean_files=
  529. ac_config_libobj_dir=.
  530. LIBOBJS=
  531. cross_compiling=no
  532. subdirs=
  533. MFLAGS=
  534. MAKEFLAGS=
  535. # Identity of this package.
  536. PACKAGE_NAME='asterisk'
  537. PACKAGE_TARNAME='asterisk'
  538. PACKAGE_VERSION='trunk'
  539. PACKAGE_STRING='asterisk trunk'
  540. PACKAGE_BUGREPORT='https://issues.asterisk.org'
  541. PACKAGE_URL=''
  542. ac_unique_file="main/asterisk.c"
  543. # Factoring default headers for most tests.
  544. ac_includes_default="\
  545. #include <stdio.h>
  546. #ifdef HAVE_SYS_TYPES_H
  547. # include <sys/types.h>
  548. #endif
  549. #ifdef HAVE_SYS_STAT_H
  550. # include <sys/stat.h>
  551. #endif
  552. #ifdef STDC_HEADERS
  553. # include <stdlib.h>
  554. # include <stddef.h>
  555. #else
  556. # ifdef HAVE_STDLIB_H
  557. # include <stdlib.h>
  558. # endif
  559. #endif
  560. #ifdef HAVE_STRING_H
  561. # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
  562. # include <memory.h>
  563. # endif
  564. # include <string.h>
  565. #endif
  566. #ifdef HAVE_STRINGS_H
  567. # include <strings.h>
  568. #endif
  569. #ifdef HAVE_INTTYPES_H
  570. # include <inttypes.h>
  571. #endif
  572. #ifdef HAVE_STDINT_H
  573. # include <stdint.h>
  574. #endif
  575. #ifdef HAVE_UNISTD_H
  576. # include <unistd.h>
  577. #endif"
  578. ac_header_list=
  579. ac_subst_vars='LTLIBOBJS
  580. PBX_SYSLOG
  581. PBX_SYSLOG_FACILITY_LOG_UUCP
  582. PBX_SYSLOG_FACILITY_LOG_SYSLOG
  583. PBX_SYSLOG_FACILITY_LOG_NEWS
  584. PBX_SYSLOG_FACILITY_LOG_MAIL
  585. PBX_SYSLOG_FACILITY_LOG_LPR
  586. PBX_SYSLOG_FACILITY_LOG_KERN
  587. PBX_SYSLOG_FACILITY_LOG_FTP
  588. PBX_SYSLOG_FACILITY_LOG_DAEMON
  589. PBX_SYSLOG_FACILITY_LOG_CRON
  590. PBX_SYSLOG_FACILITY_LOG_AUTHPRIV
  591. PBX_SYSLOG_FACILITY_LOG_AUTH
  592. PBX_GENERIC_ODBC
  593. GENERIC_ODBC_INCLUDE
  594. GENERIC_ODBC_LIB
  595. GTK2_LIBS
  596. GTK2_CFLAGS
  597. PBX_LAUNCHD
  598. CONFIG_SDL
  599. PBX_SO_NOSIGPIPE
  600. PBX_MSG_NOSIGNAL
  601. PBX_IXJUSER
  602. PBX_H323
  603. GMIME_LIBS
  604. GMIME_CFLAGS
  605. OPENH323_BUILD
  606. OPENH323_SUFFIX
  607. OPENH323_LIBDIR
  608. OPENH323_INCDIR
  609. OPENH323DIR
  610. PWLIB_PLATFORM
  611. PWLIB_LIBDIR
  612. PWLIB_INCDIR
  613. PWLIBDIR
  614. PTLIB_CONFIG
  615. PJPROJECT_LIBS
  616. PJPROJECT_CFLAGS
  617. PG_CONFIG
  618. CONFIG_NETSNMP
  619. CONFIG_NEON29
  620. CONFIG_NEON
  621. CONFIG_MYSQLCLIENT
  622. PBX_MISDN_FAC_ERROR
  623. PBX_MISDN_FAC_RESULT
  624. LIBEDIT_LIBS
  625. LIBEDIT_CFLAGS
  626. LIBEDIT_INTERNAL
  627. ILBC_LIBS
  628. ILBC_CFLAGS
  629. ILBC_INTERNAL
  630. GSM_INTERNAL
  631. PBX_DAHDI_HALF_FULL
  632. PKG_CONFIG_LIBDIR
  633. PKG_CONFIG_PATH
  634. PKG_CONFIG
  635. PBX_DLADDR
  636. PBX_IP_MTU_DISCOVER
  637. PBX_RTLD_NOLOAD
  638. PBX_GLOB_BRACE
  639. PBX_GLOB_NOMAGIC
  640. AST_RPATH
  641. AST_NESTED_FUNCTIONS
  642. AST_NATIVE_ARCH
  643. AST_SHADOW_WARNINGS
  644. AST_NO_STRICT_OVERFLOW
  645. AST_FORTIFY_SOURCE
  646. AST_TRAMPOLINES
  647. AST_DECLARATION_AFTER_STATEMENT
  648. GC_LDFLAGS
  649. GC_CFLAGS
  650. PBX_PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP
  651. PBX_PTHREAD_RWLOCK_INITIALIZER
  652. AST_ASTERISKSSL
  653. HAS_POLL
  654. PBX_DYNAMIC_LIST
  655. POW_LIB
  656. PBX_WORKING_FORK
  657. LIBOBJS
  658. CONFIG_LIBXML2
  659. UUID_LIB
  660. UUID_INCLUDE
  661. EDITLINE_LIB
  662. ALLOCA
  663. PBX_ZLIB
  664. ZLIB_DIR
  665. ZLIB_INCLUDE
  666. ZLIB_LIB
  667. PBX_X11
  668. X11_DIR
  669. X11_INCLUDE
  670. X11_LIB
  671. PBX_VPB
  672. VPB_DIR
  673. VPB_INCLUDE
  674. VPB_LIB
  675. PBX_VORBIS
  676. VORBIS_DIR
  677. VORBIS_INCLUDE
  678. VORBIS_LIB
  679. PBX_UNIXODBC
  680. UNIXODBC_DIR
  681. UNIXODBC_INCLUDE
  682. UNIXODBC_LIB
  683. PBX_TONEZONE
  684. TONEZONE_DIR
  685. TONEZONE_INCLUDE
  686. TONEZONE_LIB
  687. PBX_TINFO
  688. TINFO_DIR
  689. TINFO_INCLUDE
  690. TINFO_LIB
  691. PBX_TIMERFD
  692. TIMERFD_DIR
  693. TIMERFD_INCLUDE
  694. TIMERFD_LIB
  695. PBX_TERMCAP
  696. TERMCAP_DIR
  697. TERMCAP_INCLUDE
  698. TERMCAP_LIB
  699. PBX_FREETDS
  700. FREETDS_DIR
  701. FREETDS_INCLUDE
  702. FREETDS_LIB
  703. PBX_SUPPSERV
  704. SUPPSERV_DIR
  705. SUPPSERV_INCLUDE
  706. SUPPSERV_LIB
  707. PBX_OPENSSL
  708. OPENSSL_DIR
  709. OPENSSL_INCLUDE
  710. OPENSSL_LIB
  711. PBX_SRTP_SHUTDOWN
  712. SRTP_SHUTDOWN_DIR
  713. SRTP_SHUTDOWN_INCLUDE
  714. SRTP_SHUTDOWN_LIB
  715. PBX_SRTP
  716. SRTP_DIR
  717. SRTP_INCLUDE
  718. SRTP_LIB
  719. PBX_SQLITE3
  720. SQLITE3_DIR
  721. SQLITE3_INCLUDE
  722. SQLITE3_LIB
  723. PBX_SQLITE
  724. SQLITE_DIR
  725. SQLITE_INCLUDE
  726. SQLITE_LIB
  727. PBX_SPEEXDSP
  728. SPEEXDSP_DIR
  729. SPEEXDSP_INCLUDE
  730. SPEEXDSP_LIB
  731. PBX_SPEEX_PREPROCESS
  732. SPEEX_PREPROCESS_DIR
  733. SPEEX_PREPROCESS_INCLUDE
  734. SPEEX_PREPROCESS_LIB
  735. PBX_SPEEX
  736. SPEEX_DIR
  737. SPEEX_INCLUDE
  738. SPEEX_LIB
  739. PBX_SS7
  740. SS7_DIR
  741. SS7_INCLUDE
  742. SS7_LIB
  743. PBX_SPANDSP
  744. SPANDSP_DIR
  745. SPANDSP_INCLUDE
  746. SPANDSP_LIB
  747. SOUNDS_CACHE_DIR
  748. PBX_SDL_IMAGE
  749. SDL_IMAGE_DIR
  750. SDL_IMAGE_INCLUDE
  751. SDL_IMAGE_LIB
  752. PBX_SDL
  753. SDL_DIR
  754. SDL_INCLUDE
  755. SDL_LIB
  756. PBX_RESAMPLE
  757. RESAMPLE_DIR
  758. RESAMPLE_INCLUDE
  759. RESAMPLE_LIB
  760. PBX_RADIUS
  761. RADIUS_DIR
  762. RADIUS_INCLUDE
  763. RADIUS_LIB
  764. PBX_PWLIB
  765. PWLIB_DIR
  766. PWLIB_INCLUDE
  767. PWLIB_LIB
  768. PBX_PRI_REVERSE_CHARGE
  769. PRI_REVERSE_CHARGE_DIR
  770. PRI_REVERSE_CHARGE_INCLUDE
  771. PRI_REVERSE_CHARGE_LIB
  772. PBX_PRI_SERVICE_MESSAGES
  773. PRI_SERVICE_MESSAGES_DIR
  774. PRI_SERVICE_MESSAGES_INCLUDE
  775. PRI_SERVICE_MESSAGES_LIB
  776. PBX_PRI_PROG_W_CAUSE
  777. PRI_PROG_W_CAUSE_DIR
  778. PRI_PROG_W_CAUSE_INCLUDE
  779. PRI_PROG_W_CAUSE_LIB
  780. PBX_PRI_INBANDDISCONNECT
  781. PRI_INBANDDISCONNECT_DIR
  782. PRI_INBANDDISCONNECT_INCLUDE
  783. PRI_INBANDDISCONNECT_LIB
  784. PBX_PRI_SETUP_KEYPAD
  785. PRI_SETUP_KEYPAD_DIR
  786. PRI_SETUP_KEYPAD_INCLUDE
  787. PRI_SETUP_KEYPAD_LIB
  788. PBX_PRI_CALL_REROUTING
  789. PRI_CALL_REROUTING_DIR
  790. PRI_CALL_REROUTING_INCLUDE
  791. PRI_CALL_REROUTING_LIB
  792. PBX_PRI_CALL_HOLD
  793. PRI_CALL_HOLD_DIR
  794. PRI_CALL_HOLD_INCLUDE
  795. PRI_CALL_HOLD_LIB
  796. PBX_PRI_SUBADDR
  797. PRI_SUBADDR_DIR
  798. PRI_SUBADDR_INCLUDE
  799. PRI_SUBADDR_LIB
  800. PBX_PRI_HANGUP_FIX
  801. PRI_HANGUP_FIX_DIR
  802. PRI_HANGUP_FIX_INCLUDE
  803. PRI_HANGUP_FIX_LIB
  804. PBX_PRI_CCSS
  805. PRI_CCSS_DIR
  806. PRI_CCSS_INCLUDE
  807. PRI_CCSS_LIB
  808. PBX_PRI_TRANSFER
  809. PRI_TRANSFER_DIR
  810. PRI_TRANSFER_INCLUDE
  811. PRI_TRANSFER_LIB
  812. PBX_PRI_AOC_EVENTS
  813. PRI_AOC_EVENTS_DIR
  814. PRI_AOC_EVENTS_INCLUDE
  815. PRI_AOC_EVENTS_LIB
  816. PBX_PRI_CALL_WAITING
  817. PRI_CALL_WAITING_DIR
  818. PRI_CALL_WAITING_INCLUDE
  819. PRI_CALL_WAITING_LIB
  820. PBX_PRI_MCID
  821. PRI_MCID_DIR
  822. PRI_MCID_INCLUDE
  823. PRI_MCID_LIB
  824. PBX_PRI_MWI
  825. PRI_MWI_DIR
  826. PRI_MWI_INCLUDE
  827. PRI_MWI_LIB
  828. PBX_PRI_DISPLAY_TEXT
  829. PRI_DISPLAY_TEXT_DIR
  830. PRI_DISPLAY_TEXT_INCLUDE
  831. PRI_DISPLAY_TEXT_LIB
  832. PBX_PRI_MWI_V2
  833. PRI_MWI_V2_DIR
  834. PRI_MWI_V2_INCLUDE
  835. PRI_MWI_V2_LIB
  836. PBX_PRI_DATETIME_SEND
  837. PRI_DATETIME_SEND_DIR
  838. PRI_DATETIME_SEND_INCLUDE
  839. PRI_DATETIME_SEND_LIB
  840. PBX_PRI_L2_PERSISTENCE
  841. PRI_L2_PERSISTENCE_DIR
  842. PRI_L2_PERSISTENCE_INCLUDE
  843. PRI_L2_PERSISTENCE_LIB
  844. PBX_PRI_SETUP_ACK_INBAND
  845. PRI_SETUP_ACK_INBAND_DIR
  846. PRI_SETUP_ACK_INBAND_INCLUDE
  847. PRI_SETUP_ACK_INBAND_LIB
  848. PBX_PRI
  849. PRI_DIR
  850. PRI_INCLUDE
  851. PRI_LIB
  852. PBX_PORTAUDIO
  853. PORTAUDIO_DIR
  854. PORTAUDIO_INCLUDE
  855. PORTAUDIO_LIB
  856. PBX_PJSIP_REPLACE_MEDIA_STREAM
  857. PJSIP_REPLACE_MEDIA_STREAM_DIR
  858. PJSIP_REPLACE_MEDIA_STREAM_INCLUDE
  859. PJSIP_REPLACE_MEDIA_STREAM_LIB
  860. PBX_PJ_TRANSACTION_GRP_LOCK
  861. PJ_TRANSACTION_GRP_LOCK_DIR
  862. PJ_TRANSACTION_GRP_LOCK_INCLUDE
  863. PJ_TRANSACTION_GRP_LOCK_LIB
  864. PBX_POPT
  865. POPT_DIR
  866. POPT_INCLUDE
  867. POPT_LIB
  868. PBX_PJPROJECT
  869. PJPROJECT_DIR
  870. PJPROJECT_INCLUDE
  871. PJPROJECT_LIB
  872. PBX_PGSQL
  873. PGSQL_DIR
  874. PGSQL_INCLUDE
  875. PGSQL_LIB
  876. PBX_OSS
  877. OSS_DIR
  878. OSS_INCLUDE
  879. OSS_LIB
  880. PBX_OSPTK
  881. OSPTK_DIR
  882. OSPTK_INCLUDE
  883. OSPTK_LIB
  884. PBX_OPENR2
  885. OPENR2_DIR
  886. OPENR2_INCLUDE
  887. OPENR2_LIB
  888. PBX_OGG
  889. OGG_DIR
  890. OGG_INCLUDE
  891. OGG_LIB
  892. PBX_NEWT
  893. NEWT_DIR
  894. NEWT_INCLUDE
  895. NEWT_LIB
  896. PBX_NETSNMP
  897. NETSNMP_DIR
  898. NETSNMP_INCLUDE
  899. NETSNMP_LIB
  900. PBX_NEON29
  901. NEON29_DIR
  902. NEON29_INCLUDE
  903. NEON29_LIB
  904. PBX_NEON
  905. NEON_DIR
  906. NEON_INCLUDE
  907. NEON_LIB
  908. PBX_NCURSES
  909. NCURSES_DIR
  910. NCURSES_INCLUDE
  911. NCURSES_LIB
  912. PBX_NBS
  913. NBS_DIR
  914. NBS_INCLUDE
  915. NBS_LIB
  916. PBX_MYSQLCLIENT
  917. MYSQLCLIENT_DIR
  918. MYSQLCLIENT_INCLUDE
  919. MYSQLCLIENT_LIB
  920. PBX_MISDN
  921. MISDN_DIR
  922. MISDN_INCLUDE
  923. MISDN_LIB
  924. PBX_LUA
  925. LUA_DIR
  926. LUA_INCLUDE
  927. LUA_LIB
  928. PBX_LTDL
  929. LTDL_DIR
  930. LTDL_INCLUDE
  931. LTDL_LIB
  932. PBX_LIBXSLT_CLEANUP
  933. LIBXSLT_CLEANUP_DIR
  934. LIBXSLT_CLEANUP_INCLUDE
  935. LIBXSLT_CLEANUP_LIB
  936. PBX_LIBXSLT
  937. LIBXSLT_DIR
  938. LIBXSLT_INCLUDE
  939. LIBXSLT_LIB
  940. PBX_LIBXML2
  941. LIBXML2_DIR
  942. LIBXML2_INCLUDE
  943. LIBXML2_LIB
  944. PBX_LIBEDIT
  945. LIBEDIT_DIR
  946. LIBEDIT_INCLUDE
  947. LIBEDIT_LIB
  948. CURL_LIB
  949. CURL_INCLUDE
  950. _libcurl_config
  951. PBX_CURL
  952. PBX_LDAP
  953. LDAP_DIR
  954. LDAP_INCLUDE
  955. LDAP_LIB
  956. PBX_KQUEUE
  957. KQUEUE_DIR
  958. KQUEUE_INCLUDE
  959. KQUEUE_LIB
  960. PBX_URIPARSER
  961. URIPARSER_DIR
  962. URIPARSER_INCLUDE
  963. URIPARSER_LIB
  964. PBX_JANSSON
  965. JANSSON_DIR
  966. JANSSON_INCLUDE
  967. JANSSON_LIB
  968. PBX_JACK
  969. JACK_DIR
  970. JACK_INCLUDE
  971. JACK_LIB
  972. PBX_ISDNNET
  973. ISDNNET_DIR
  974. ISDNNET_INCLUDE
  975. ISDNNET_LIB
  976. PBX_IODBC
  977. IODBC_DIR
  978. IODBC_INCLUDE
  979. IODBC_LIB
  980. PBX_INOTIFY
  981. INOTIFY_DIR
  982. INOTIFY_INCLUDE
  983. INOTIFY_LIB
  984. PBX_IMAP_TK
  985. IMAP_TK_DIR
  986. IMAP_TK_INCLUDE
  987. IMAP_TK_LIB
  988. PBX_IKSEMEL
  989. IKSEMEL_DIR
  990. IKSEMEL_INCLUDE
  991. IKSEMEL_LIB
  992. PBX_ICONV
  993. ICONV_DIR
  994. ICONV_INCLUDE
  995. ICONV_LIB
  996. PBX_ICAL
  997. ICAL_DIR
  998. ICAL_INCLUDE
  999. ICAL_LIB
  1000. PBX_HOARD
  1001. HOARD_DIR
  1002. HOARD_INCLUDE
  1003. HOARD_LIB
  1004. PBX_OPENH323
  1005. OPENH323_DIR
  1006. OPENH323_INCLUDE
  1007. OPENH323_LIB
  1008. PBX_GMIME
  1009. GMIME_DIR
  1010. GMIME_INCLUDE
  1011. GMIME_LIB
  1012. PBX_GTK2
  1013. GTK2_DIR
  1014. GTK2_INCLUDE
  1015. GTK2_LIB
  1016. PBX_ILBC
  1017. ILBC_DIR
  1018. ILBC_INCLUDE
  1019. ILBC_LIB
  1020. PBX_GSM
  1021. GSM_DIR
  1022. GSM_INCLUDE
  1023. GSM_LIB
  1024. PBX_FFMPEG
  1025. FFMPEG_DIR
  1026. FFMPEG_INCLUDE
  1027. FFMPEG_LIB
  1028. PBX_DAHDI
  1029. DAHDI_DIR
  1030. DAHDI_INCLUDE
  1031. DAHDI_LIB
  1032. PBX_OPENSSL_SRTP
  1033. OPENSSL_SRTP_DIR
  1034. OPENSSL_SRTP_INCLUDE
  1035. OPENSSL_SRTP_LIB
  1036. PBX_CRYPTO
  1037. CRYPTO_DIR
  1038. CRYPTO_INCLUDE
  1039. CRYPTO_LIB
  1040. PBX_CRYPT
  1041. CRYPT_DIR
  1042. CRYPT_INCLUDE
  1043. CRYPT_LIB
  1044. PBX_CURSES
  1045. CURSES_DIR
  1046. CURSES_INCLUDE
  1047. CURSES_LIB
  1048. PBX_COROSYNC_CFG_STATE_TRACK
  1049. COROSYNC_CFG_STATE_TRACK_DIR
  1050. COROSYNC_CFG_STATE_TRACK_INCLUDE
  1051. COROSYNC_CFG_STATE_TRACK_LIB
  1052. PBX_COROSYNC
  1053. COROSYNC_DIR
  1054. COROSYNC_INCLUDE
  1055. COROSYNC_LIB
  1056. PBX_CAP
  1057. CAP_DIR
  1058. CAP_INCLUDE
  1059. CAP_LIB
  1060. PBX_BLUETOOTH
  1061. BLUETOOTH_DIR
  1062. BLUETOOTH_INCLUDE
  1063. BLUETOOTH_LIB
  1064. PBX_BKTR
  1065. BKTR_DIR
  1066. BKTR_INCLUDE
  1067. BKTR_LIB
  1068. PBX_BFD
  1069. BFD_DIR
  1070. BFD_INCLUDE
  1071. BFD_LIB
  1072. PBX_ALSA
  1073. ALSA_DIR
  1074. ALSA_INCLUDE
  1075. ALSA_LIB
  1076. AST_CODE_COVERAGE
  1077. AST_DEVMODE_STRICT
  1078. AST_DEVMODE
  1079. NOISY_BUILD
  1080. PTHREAD_CFLAGS
  1081. PTHREAD_LIBS
  1082. PTHREAD_CC
  1083. acx_pthread_config
  1084. MD5
  1085. SOXMIX
  1086. PBX_FLEX
  1087. PBX_BISON
  1088. OPENSSL
  1089. SHA1SUM
  1090. LDCONFIG
  1091. DOWNLOAD
  1092. FETCH
  1093. GIT
  1094. XMLSTARLET
  1095. XMLLINT
  1096. KPATHSEA
  1097. CATDVI
  1098. RUBBER
  1099. CURL
  1100. WGET
  1101. DOT
  1102. DOXYGEN
  1103. LN
  1104. DIRNAME
  1105. BASENAME
  1106. COMPRESS
  1107. FIND
  1108. PYTHON
  1109. FLEX
  1110. CMP
  1111. BISON
  1112. GNU_LD
  1113. ac_ct_AR
  1114. AR
  1115. ac_ct_STRIP
  1116. STRIP
  1117. GNU_MAKE
  1118. LN_S
  1119. INSTALL_DATA
  1120. INSTALL_SCRIPT
  1121. INSTALL_PROGRAM
  1122. AWK
  1123. SED
  1124. CXXCPP
  1125. ac_ct_CXX
  1126. CXXFLAGS
  1127. RANLIB
  1128. LD
  1129. CXX
  1130. PBX_OSREV
  1131. UNAME
  1132. CONFIG_SIGNED_CHAR
  1133. PBX_WINARCH
  1134. OSARCH
  1135. HOST_OS
  1136. HOST_VENDOR
  1137. HOST_CPU
  1138. HOST_PLATFORM
  1139. BUILD_OS
  1140. BUILD_VENDOR
  1141. BUILD_CPU
  1142. BUILD_PLATFORM
  1143. astvarrundir
  1144. astlogdir
  1145. astspooldir
  1146. astkeydir
  1147. astdbdir
  1148. astdatadir
  1149. astvarlibdir
  1150. astmandir
  1151. astmoddir
  1152. astlibdir
  1153. astheaderdir
  1154. astetcdir
  1155. astsbindir
  1156. EGREP
  1157. GREP
  1158. CPP
  1159. OBJEXT
  1160. EXEEXT
  1161. ac_ct_CC
  1162. CPPFLAGS
  1163. LDFLAGS
  1164. CFLAGS
  1165. CC
  1166. CONFIG_LDFLAGS
  1167. CONFIG_CFLAGS
  1168. host_os
  1169. host_vendor
  1170. host_cpu
  1171. host
  1172. build_os
  1173. build_vendor
  1174. build_cpu
  1175. build
  1176. target_alias
  1177. host_alias
  1178. build_alias
  1179. LIBS
  1180. ECHO_T
  1181. ECHO_N
  1182. ECHO_C
  1183. DEFS
  1184. mandir
  1185. localedir
  1186. libdir
  1187. psdir
  1188. pdfdir
  1189. dvidir
  1190. htmldir
  1191. infodir
  1192. docdir
  1193. oldincludedir
  1194. includedir
  1195. localstatedir
  1196. sharedstatedir
  1197. sysconfdir
  1198. datadir
  1199. datarootdir
  1200. libexecdir
  1201. sbindir
  1202. bindir
  1203. program_transform_name
  1204. prefix
  1205. exec_prefix
  1206. PACKAGE_URL
  1207. PACKAGE_BUGREPORT
  1208. PACKAGE_STRING
  1209. PACKAGE_VERSION
  1210. PACKAGE_TARNAME
  1211. PACKAGE_NAME
  1212. PATH_SEPARATOR
  1213. SHELL'
  1214. ac_subst_files=''
  1215. ac_user_opts='
  1216. enable_option_checking
  1217. with_gnu_ld
  1218. enable_dev_mode
  1219. enable_coverage
  1220. with_asound
  1221. with_bfd
  1222. with_execinfo
  1223. with_bluetooth
  1224. with_cap
  1225. with_cpg
  1226. with_curses
  1227. with_crypt
  1228. with_crypto
  1229. with_dahdi
  1230. with_avcodec
  1231. with_gsm
  1232. with_ilbc
  1233. with_gtk2
  1234. with_gmime
  1235. with_h323
  1236. with_hoard
  1237. with_ical
  1238. with_iconv
  1239. with_iksemel
  1240. with_imap
  1241. with_inotify
  1242. with_iodbc
  1243. with_isdnnet
  1244. with_jack
  1245. with_jansson
  1246. with_uriparser
  1247. with_kqueue
  1248. with_ldap
  1249. with_libcurl
  1250. with_libedit
  1251. with_libxml2
  1252. with_libxslt
  1253. with_ltdl
  1254. with_lua
  1255. with_misdn
  1256. with_mysqlclient
  1257. with_nbs
  1258. with_ncurses
  1259. with_neon
  1260. with_neon29
  1261. with_netsnmp
  1262. with_newt
  1263. with_ogg
  1264. with_openr2
  1265. with_osptk
  1266. with_oss
  1267. with_postgres
  1268. with_pjproject
  1269. with_popt
  1270. with_portaudio
  1271. with_pri
  1272. with_pwlib
  1273. with_radius
  1274. with_resample
  1275. with_sdl
  1276. with_SDL_image
  1277. with_sounds_cache
  1278. with_spandsp
  1279. with_ss7
  1280. with_speex
  1281. with_speexdsp
  1282. with_sqlite
  1283. with_sqlite3
  1284. with_srtp
  1285. with_ssl
  1286. with_suppserv
  1287. with_tds
  1288. with_termcap
  1289. with_timerfd
  1290. with_tinfo
  1291. with_tonezone
  1292. with_unixodbc
  1293. with_vorbis
  1294. with_vpb
  1295. with_x11
  1296. with_z
  1297. enable_xmldoc
  1298. enable_largefile
  1299. enable_internal_poll
  1300. enable_asteriskssl
  1301. enable_rpath
  1302. '
  1303. ac_precious_vars='build_alias
  1304. host_alias
  1305. target_alias
  1306. CC
  1307. CFLAGS
  1308. LDFLAGS
  1309. LIBS
  1310. CPPFLAGS
  1311. CPP
  1312. CXX
  1313. CXXFLAGS
  1314. CCC
  1315. CXXCPP
  1316. PKG_CONFIG
  1317. PKG_CONFIG_PATH
  1318. PKG_CONFIG_LIBDIR
  1319. ILBC_CFLAGS
  1320. ILBC_LIBS
  1321. LIBEDIT_CFLAGS
  1322. LIBEDIT_LIBS
  1323. PJPROJECT_CFLAGS
  1324. PJPROJECT_LIBS
  1325. GMIME_CFLAGS
  1326. GMIME_LIBS
  1327. GTK2_CFLAGS
  1328. GTK2_LIBS'
  1329. # Initialize some variables set by options.
  1330. ac_init_help=
  1331. ac_init_version=false
  1332. ac_unrecognized_opts=
  1333. ac_unrecognized_sep=
  1334. # The variables have the same names as the options, with
  1335. # dashes changed to underlines.
  1336. cache_file=/dev/null
  1337. exec_prefix=NONE
  1338. no_create=
  1339. no_recursion=
  1340. prefix=NONE
  1341. program_prefix=NONE
  1342. program_suffix=NONE
  1343. program_transform_name=s,x,x,
  1344. silent=
  1345. site=
  1346. srcdir=
  1347. verbose=
  1348. x_includes=NONE
  1349. x_libraries=NONE
  1350. # Installation directory options.
  1351. # These are left unexpanded so users can "make install exec_prefix=/foo"
  1352. # and all the variables that are supposed to be based on exec_prefix
  1353. # by default will actually change.
  1354. # Use braces instead of parens because sh, perl, etc. also accept them.
  1355. # (The list follows the same order as the GNU Coding Standards.)
  1356. bindir='${exec_prefix}/bin'
  1357. sbindir='${exec_prefix}/sbin'
  1358. libexecdir='${exec_prefix}/libexec'
  1359. datarootdir='${prefix}/share'
  1360. datadir='${datarootdir}'
  1361. sysconfdir='${prefix}/etc'
  1362. sharedstatedir='${prefix}/com'
  1363. localstatedir='${prefix}/var'
  1364. includedir='${prefix}/include'
  1365. oldincludedir='/usr/include'
  1366. docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
  1367. infodir='${datarootdir}/info'
  1368. htmldir='${docdir}'
  1369. dvidir='${docdir}'
  1370. pdfdir='${docdir}'
  1371. psdir='${docdir}'
  1372. libdir='${exec_prefix}/lib'
  1373. localedir='${datarootdir}/locale'
  1374. mandir='${datarootdir}/man'
  1375. ac_prev=
  1376. ac_dashdash=
  1377. for ac_option
  1378. do
  1379. # If the previous option needs an argument, assign it.
  1380. if test -n "$ac_prev"; then
  1381. eval $ac_prev=\$ac_option
  1382. ac_prev=
  1383. continue
  1384. fi
  1385. case $ac_option in
  1386. *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
  1387. *=) ac_optarg= ;;
  1388. *) ac_optarg=yes ;;
  1389. esac
  1390. # Accept the important Cygnus configure options, so we can diagnose typos.
  1391. case $ac_dashdash$ac_option in
  1392. --)
  1393. ac_dashdash=yes ;;
  1394. -bindir | --bindir | --bindi | --bind | --bin | --bi)
  1395. ac_prev=bindir ;;
  1396. -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
  1397. bindir=$ac_optarg ;;
  1398. -build | --build | --buil | --bui | --bu)
  1399. ac_prev=build_alias ;;
  1400. -build=* | --build=* | --buil=* | --bui=* | --bu=*)
  1401. build_alias=$ac_optarg ;;
  1402. -cache-file | --cache-file | --cache-fil | --cache-fi \
  1403. | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
  1404. ac_prev=cache_file ;;
  1405. -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
  1406. | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
  1407. cache_file=$ac_optarg ;;
  1408. --config-cache | -C)
  1409. cache_file=config.cache ;;
  1410. -datadir | --datadir | --datadi | --datad)
  1411. ac_prev=datadir ;;
  1412. -datadir=* | --datadir=* | --datadi=* | --datad=*)
  1413. datadir=$ac_optarg ;;
  1414. -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
  1415. | --dataroo | --dataro | --datar)
  1416. ac_prev=datarootdir ;;
  1417. -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
  1418. | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
  1419. datarootdir=$ac_optarg ;;
  1420. -disable-* | --disable-*)
  1421. ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
  1422. # Reject names that are not valid shell variable names.
  1423. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
  1424. as_fn_error $? "invalid feature name: $ac_useropt"
  1425. ac_useropt_orig=$ac_useropt
  1426. ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
  1427. case $ac_user_opts in
  1428. *"
  1429. "enable_$ac_useropt"
  1430. "*) ;;
  1431. *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
  1432. ac_unrecognized_sep=', ';;
  1433. esac
  1434. eval enable_$ac_useropt=no ;;
  1435. -docdir | --docdir | --docdi | --doc | --do)
  1436. ac_prev=docdir ;;
  1437. -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
  1438. docdir=$ac_optarg ;;
  1439. -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
  1440. ac_prev=dvidir ;;
  1441. -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
  1442. dvidir=$ac_optarg ;;
  1443. -enable-* | --enable-*)
  1444. ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
  1445. # Reject names that are not valid shell variable names.
  1446. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
  1447. as_fn_error $? "invalid feature name: $ac_useropt"
  1448. ac_useropt_orig=$ac_useropt
  1449. ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
  1450. case $ac_user_opts in
  1451. *"
  1452. "enable_$ac_useropt"
  1453. "*) ;;
  1454. *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
  1455. ac_unrecognized_sep=', ';;
  1456. esac
  1457. eval enable_$ac_useropt=\$ac_optarg ;;
  1458. -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
  1459. | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
  1460. | --exec | --exe | --ex)
  1461. ac_prev=exec_prefix ;;
  1462. -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
  1463. | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
  1464. | --exec=* | --exe=* | --ex=*)
  1465. exec_prefix=$ac_optarg ;;
  1466. -gas | --gas | --ga | --g)
  1467. # Obsolete; use --with-gas.
  1468. with_gas=yes ;;
  1469. -help | --help | --hel | --he | -h)
  1470. ac_init_help=long ;;
  1471. -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
  1472. ac_init_help=recursive ;;
  1473. -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
  1474. ac_init_help=short ;;
  1475. -host | --host | --hos | --ho)
  1476. ac_prev=host_alias ;;
  1477. -host=* | --host=* | --hos=* | --ho=*)
  1478. host_alias=$ac_optarg ;;
  1479. -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
  1480. ac_prev=htmldir ;;
  1481. -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
  1482. | --ht=*)
  1483. htmldir=$ac_optarg ;;
  1484. -includedir | --includedir | --includedi | --included | --include \
  1485. | --includ | --inclu | --incl | --inc)
  1486. ac_prev=includedir ;;
  1487. -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
  1488. | --includ=* | --inclu=* | --incl=* | --inc=*)
  1489. includedir=$ac_optarg ;;
  1490. -infodir | --infodir | --infodi | --infod | --info | --inf)
  1491. ac_prev=infodir ;;
  1492. -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
  1493. infodir=$ac_optarg ;;
  1494. -libdir | --libdir | --libdi | --libd)
  1495. ac_prev=libdir ;;
  1496. -libdir=* | --libdir=* | --libdi=* | --libd=*)
  1497. libdir=$ac_optarg ;;
  1498. -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
  1499. | --libexe | --libex | --libe)
  1500. ac_prev=libexecdir ;;
  1501. -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
  1502. | --libexe=* | --libex=* | --libe=*)
  1503. libexecdir=$ac_optarg ;;
  1504. -localedir | --localedir | --localedi | --localed | --locale)
  1505. ac_prev=localedir ;;
  1506. -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
  1507. localedir=$ac_optarg ;;
  1508. -localstatedir | --localstatedir | --localstatedi | --localstated \
  1509. | --localstate | --localstat | --localsta | --localst | --locals)
  1510. ac_prev=localstatedir ;;
  1511. -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
  1512. | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
  1513. localstatedir=$ac_optarg ;;
  1514. -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
  1515. ac_prev=mandir ;;
  1516. -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
  1517. mandir=$ac_optarg ;;
  1518. -nfp | --nfp | --nf)
  1519. # Obsolete; use --without-fp.
  1520. with_fp=no ;;
  1521. -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  1522. | --no-cr | --no-c | -n)
  1523. no_create=yes ;;
  1524. -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  1525. | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
  1526. no_recursion=yes ;;
  1527. -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
  1528. | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
  1529. | --oldin | --oldi | --old | --ol | --o)
  1530. ac_prev=oldincludedir ;;
  1531. -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
  1532. | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
  1533. | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
  1534. oldincludedir=$ac_optarg ;;
  1535. -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
  1536. ac_prev=prefix ;;
  1537. -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
  1538. prefix=$ac_optarg ;;
  1539. -program-prefix | --program-prefix | --program-prefi | --program-pref \
  1540. | --program-pre | --program-pr | --program-p)
  1541. ac_prev=program_prefix ;;
  1542. -program-prefix=* | --program-prefix=* | --program-prefi=* \
  1543. | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
  1544. program_prefix=$ac_optarg ;;
  1545. -program-suffix | --program-suffix | --program-suffi | --program-suff \
  1546. | --program-suf | --program-su | --program-s)
  1547. ac_prev=program_suffix ;;
  1548. -program-suffix=* | --program-suffix=* | --program-suffi=* \
  1549. | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
  1550. program_suffix=$ac_optarg ;;
  1551. -program-transform-name | --program-transform-name \
  1552. | --program-transform-nam | --program-transform-na \
  1553. | --program-transform-n | --program-transform- \
  1554. | --program-transform | --program-transfor \
  1555. | --program-transfo | --program-transf \
  1556. | --program-trans | --program-tran \
  1557. | --progr-tra | --program-tr | --program-t)
  1558. ac_prev=program_transform_name ;;
  1559. -program-transform-name=* | --program-transform-name=* \
  1560. | --program-transform-nam=* | --program-transform-na=* \
  1561. | --program-transform-n=* | --program-transform-=* \
  1562. | --program-transform=* | --program-transfor=* \
  1563. | --program-transfo=* | --program-transf=* \
  1564. | --program-trans=* | --program-tran=* \
  1565. | --progr-tra=* | --program-tr=* | --program-t=*)
  1566. program_transform_name=$ac_optarg ;;
  1567. -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
  1568. ac_prev=pdfdir ;;
  1569. -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
  1570. pdfdir=$ac_optarg ;;
  1571. -psdir | --psdir | --psdi | --psd | --ps)
  1572. ac_prev=psdir ;;
  1573. -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
  1574. psdir=$ac_optarg ;;
  1575. -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  1576. | -silent | --silent | --silen | --sile | --sil)
  1577. silent=yes ;;
  1578. -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
  1579. ac_prev=sbindir ;;
  1580. -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
  1581. | --sbi=* | --sb=*)
  1582. sbindir=$ac_optarg ;;
  1583. -sharedstatedir | --sharedstatedir | --sharedstatedi \
  1584. | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
  1585. | --sharedst | --shareds | --shared | --share | --shar \
  1586. | --sha | --sh)
  1587. ac_prev=sharedstatedir ;;
  1588. -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
  1589. | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
  1590. | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
  1591. | --sha=* | --sh=*)
  1592. sharedstatedir=$ac_optarg ;;
  1593. -site | --site | --sit)
  1594. ac_prev=site ;;
  1595. -site=* | --site=* | --sit=*)
  1596. site=$ac_optarg ;;
  1597. -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
  1598. ac_prev=srcdir ;;
  1599. -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
  1600. srcdir=$ac_optarg ;;
  1601. -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
  1602. | --syscon | --sysco | --sysc | --sys | --sy)
  1603. ac_prev=sysconfdir ;;
  1604. -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
  1605. | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
  1606. sysconfdir=$ac_optarg ;;
  1607. -target | --target | --targe | --targ | --tar | --ta | --t)
  1608. ac_prev=target_alias ;;
  1609. -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
  1610. target_alias=$ac_optarg ;;
  1611. -v | -verbose | --verbose | --verbos | --verbo | --verb)
  1612. verbose=yes ;;
  1613. -version | --version | --versio | --versi | --vers | -V)
  1614. ac_init_version=: ;;
  1615. -with-* | --with-*)
  1616. ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
  1617. # Reject names that are not valid shell variable names.
  1618. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
  1619. as_fn_error $? "invalid package name: $ac_useropt"
  1620. ac_useropt_orig=$ac_useropt
  1621. ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
  1622. case $ac_user_opts in
  1623. *"
  1624. "with_$ac_useropt"
  1625. "*) ;;
  1626. *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
  1627. ac_unrecognized_sep=', ';;
  1628. esac
  1629. eval with_$ac_useropt=\$ac_optarg ;;
  1630. -without-* | --without-*)
  1631. ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
  1632. # Reject names that are not valid shell variable names.
  1633. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
  1634. as_fn_error $? "invalid package name: $ac_useropt"
  1635. ac_useropt_orig=$ac_useropt
  1636. ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
  1637. case $ac_user_opts in
  1638. *"
  1639. "with_$ac_useropt"
  1640. "*) ;;
  1641. *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
  1642. ac_unrecognized_sep=', ';;
  1643. esac
  1644. eval with_$ac_useropt=no ;;
  1645. --x)
  1646. # Obsolete; use --with-x.
  1647. with_x=yes ;;
  1648. -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
  1649. | --x-incl | --x-inc | --x-in | --x-i)
  1650. ac_prev=x_includes ;;
  1651. -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
  1652. | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
  1653. x_includes=$ac_optarg ;;
  1654. -x-libraries | --x-libraries | --x-librarie | --x-librari \
  1655. | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
  1656. ac_prev=x_libraries ;;
  1657. -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
  1658. | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
  1659. x_libraries=$ac_optarg ;;
  1660. -*) as_fn_error $? "unrecognized option: \`$ac_option'
  1661. Try \`$0 --help' for more information"
  1662. ;;
  1663. *=*)
  1664. ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
  1665. # Reject names that are not valid shell variable names.
  1666. case $ac_envvar in #(
  1667. '' | [0-9]* | *[!_$as_cr_alnum]* )
  1668. as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
  1669. esac
  1670. eval $ac_envvar=\$ac_optarg
  1671. export $ac_envvar ;;
  1672. *)
  1673. # FIXME: should be removed in autoconf 3.0.
  1674. $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
  1675. expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
  1676. $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
  1677. : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
  1678. ;;
  1679. esac
  1680. done
  1681. if test -n "$ac_prev"; then
  1682. ac_option=--`echo $ac_prev | sed 's/_/-/g'`
  1683. as_fn_error $? "missing argument to $ac_option"
  1684. fi
  1685. if test -n "$ac_unrecognized_opts"; then
  1686. case $enable_option_checking in
  1687. no) ;;
  1688. fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
  1689. *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
  1690. esac
  1691. fi
  1692. # Check all directory arguments for consistency.
  1693. for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
  1694. datadir sysconfdir sharedstatedir localstatedir includedir \
  1695. oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
  1696. libdir localedir mandir
  1697. do
  1698. eval ac_val=\$$ac_var
  1699. # Remove trailing slashes.
  1700. case $ac_val in
  1701. */ )
  1702. ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
  1703. eval $ac_var=\$ac_val;;
  1704. esac
  1705. # Be sure to have absolute directory names.
  1706. case $ac_val in
  1707. [\\/$]* | ?:[\\/]* ) continue;;
  1708. NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
  1709. esac
  1710. as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
  1711. done
  1712. # There might be people who depend on the old broken behavior: `$host'
  1713. # used to hold the argument of --host etc.
  1714. # FIXME: To remove some day.
  1715. build=$build_alias
  1716. host=$host_alias
  1717. target=$target_alias
  1718. # FIXME: To remove some day.
  1719. if test "x$host_alias" != x; then
  1720. if test "x$build_alias" = x; then
  1721. cross_compiling=maybe
  1722. elif test "x$build_alias" != "x$host_alias"; then
  1723. cross_compiling=yes
  1724. fi
  1725. fi
  1726. ac_tool_prefix=
  1727. test -n "$host_alias" && ac_tool_prefix=$host_alias-
  1728. test "$silent" = yes && exec 6>/dev/null
  1729. ac_pwd=`pwd` && test -n "$ac_pwd" &&
  1730. ac_ls_di=`ls -di .` &&
  1731. ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
  1732. as_fn_error $? "working directory cannot be determined"
  1733. test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
  1734. as_fn_error $? "pwd does not report name of working directory"
  1735. # Find the source files, if location was not specified.
  1736. if test -z "$srcdir"; then
  1737. ac_srcdir_defaulted=yes
  1738. # Try the directory containing this script, then the parent directory.
  1739. ac_confdir=`$as_dirname -- "$as_myself" ||
  1740. $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
  1741. X"$as_myself" : 'X\(//\)[^/]' \| \
  1742. X"$as_myself" : 'X\(//\)$' \| \
  1743. X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
  1744. $as_echo X"$as_myself" |
  1745. sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
  1746. s//\1/
  1747. q
  1748. }
  1749. /^X\(\/\/\)[^/].*/{
  1750. s//\1/
  1751. q
  1752. }
  1753. /^X\(\/\/\)$/{
  1754. s//\1/
  1755. q
  1756. }
  1757. /^X\(\/\).*/{
  1758. s//\1/
  1759. q
  1760. }
  1761. s/.*/./; q'`
  1762. srcdir=$ac_confdir
  1763. if test ! -r "$srcdir/$ac_unique_file"; then
  1764. srcdir=..
  1765. fi
  1766. else
  1767. ac_srcdir_defaulted=no
  1768. fi
  1769. if test ! -r "$srcdir/$ac_unique_file"; then
  1770. test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
  1771. as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
  1772. fi
  1773. ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
  1774. ac_abs_confdir=`(
  1775. cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
  1776. pwd)`
  1777. # When building in place, set srcdir=.
  1778. if test "$ac_abs_confdir" = "$ac_pwd"; then
  1779. srcdir=.
  1780. fi
  1781. # Remove unnecessary trailing slashes from srcdir.
  1782. # Double slashes in file names in object file debugging info
  1783. # mess up M-x gdb in Emacs.
  1784. case $srcdir in
  1785. */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
  1786. esac
  1787. for ac_var in $ac_precious_vars; do
  1788. eval ac_env_${ac_var}_set=\${${ac_var}+set}
  1789. eval ac_env_${ac_var}_value=\$${ac_var}
  1790. eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
  1791. eval ac_cv_env_${ac_var}_value=\$${ac_var}
  1792. done
  1793. #
  1794. # Report the --help message.
  1795. #
  1796. if test "$ac_init_help" = "long"; then
  1797. # Omit some internal or obsolete options to make the list less imposing.
  1798. # This message is too long to be a string in the A/UX 3.1 sh.
  1799. cat <<_ACEOF
  1800. \`configure' configures asterisk trunk to adapt to many kinds of systems.
  1801. Usage: $0 [OPTION]... [VAR=VALUE]...
  1802. To assign environment variables (e.g., CC, CFLAGS...), specify them as
  1803. VAR=VALUE. See below for descriptions of some of the useful variables.
  1804. Defaults for the options are specified in brackets.
  1805. Configuration:
  1806. -h, --help display this help and exit
  1807. --help=short display options specific to this package
  1808. --help=recursive display the short help of all the included packages
  1809. -V, --version display version information and exit
  1810. -q, --quiet, --silent do not print \`checking ...' messages
  1811. --cache-file=FILE cache test results in FILE [disabled]
  1812. -C, --config-cache alias for \`--cache-file=config.cache'
  1813. -n, --no-create do not create output files
  1814. --srcdir=DIR find the sources in DIR [configure dir or \`..']
  1815. Installation directories:
  1816. --prefix=PREFIX install architecture-independent files in PREFIX
  1817. [$ac_default_prefix]
  1818. --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
  1819. [PREFIX]
  1820. By default, \`make install' will install all the files in
  1821. \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
  1822. an installation prefix other than \`$ac_default_prefix' using \`--prefix',
  1823. for instance \`--prefix=\$HOME'.
  1824. For better control, use the options below.
  1825. Fine tuning of the installation directories:
  1826. --bindir=DIR user executables [EPREFIX/bin]
  1827. --sbindir=DIR system admin executables [EPREFIX/sbin]
  1828. --libexecdir=DIR program executables [EPREFIX/libexec]
  1829. --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
  1830. --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
  1831. --localstatedir=DIR modifiable single-machine data [PREFIX/var]
  1832. --libdir=DIR object code libraries [EPREFIX/lib]
  1833. --includedir=DIR C header files [PREFIX/include]
  1834. --oldincludedir=DIR C header files for non-gcc [/usr/include]
  1835. --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
  1836. --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
  1837. --infodir=DIR info documentation [DATAROOTDIR/info]
  1838. --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
  1839. --mandir=DIR man documentation [DATAROOTDIR/man]
  1840. --docdir=DIR documentation root [DATAROOTDIR/doc/asterisk]
  1841. --htmldir=DIR html documentation [DOCDIR]
  1842. --dvidir=DIR dvi documentation [DOCDIR]
  1843. --pdfdir=DIR pdf documentation [DOCDIR]
  1844. --psdir=DIR ps documentation [DOCDIR]
  1845. _ACEOF
  1846. cat <<\_ACEOF
  1847. System types:
  1848. --build=BUILD configure for building on BUILD [guessed]
  1849. --host=HOST cross-compile to build programs to run on HOST [BUILD]
  1850. _ACEOF
  1851. fi
  1852. if test -n "$ac_init_help"; then
  1853. case $ac_init_help in
  1854. short | recursive ) echo "Configuration of asterisk trunk:";;
  1855. esac
  1856. cat <<\_ACEOF
  1857. Optional Features:
  1858. --disable-option-checking ignore unrecognized --enable/--with options
  1859. --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
  1860. --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
  1861. --enable-dev-mode Turn on developer mode
  1862. --enable-coverage Turn on code coverage tracking (for gcov)
  1863. --disable-xmldoc Explicitly disable XML documentation
  1864. --disable-largefile omit support for large files
  1865. --enable-internal-poll Use Asterisk's poll implementation
  1866. --disable-asteriskssl Disable Asterisk's SSL wrapper library
  1867. --disable-rpath Disables rpath linker option checking
  1868. Optional Packages:
  1869. --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
  1870. --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
  1871. --with-gnu-ld assume the C compiler uses GNU ld [default=no]
  1872. --with-asound=PATH use Advanced Linux Sound Architecture files in PATH
  1873. --with-bfd=PATH use Debug symbol decoding files in PATH
  1874. --with-execinfo=PATH use Stack Backtrace files in PATH
  1875. --with-bluetooth=PATH use Bluetooth files in PATH
  1876. --with-cap=PATH use POSIX 1.e capabilities files in PATH
  1877. --with-cpg=PATH use Corosync files in PATH
  1878. --with-curses=PATH use curses files in PATH
  1879. --with-crypt=PATH use password and data encryption files in PATH
  1880. --with-crypto=PATH use OpenSSL Cryptography files in PATH
  1881. --with-dahdi=PATH use DAHDI files in PATH
  1882. --with-avcodec=PATH use Ffmpeg and avcodec files in PATH
  1883. --with-gsm=PATH use External GSM files in PATH, use 'internal' GSM
  1884. otherwise
  1885. --with-ilbc=PATH use System iLBC files in PATH, use 'internal' iLBC
  1886. otherwise
  1887. --with-gtk2=PATH use gtk2 files in PATH
  1888. --with-gmime=PATH use GMime files in PATH
  1889. --with-h323=PATH use OpenH323 files in PATH
  1890. --with-hoard=PATH use Hoard Memory Allocator files in PATH
  1891. --with-ical=PATH use iCal files in PATH
  1892. --with-iconv=PATH use Iconv files in PATH
  1893. --with-iksemel=PATH use Iksemel Jabber files in PATH
  1894. --with-imap=PATH use UW IMAP Toolkit files in PATH
  1895. --with-inotify=PATH use inotify support files in PATH
  1896. --with-iodbc=PATH use iODBC files in PATH
  1897. --with-isdnnet=PATH use ISDN4Linux files in PATH
  1898. --with-jack=PATH use Jack Audio Connection Kit files in PATH
  1899. --with-jansson=PATH use Jansson JSON library files in PATH
  1900. --with-uriparser=PATH use uriparser library files in PATH
  1901. --with-kqueue=PATH use kqueue support files in PATH
  1902. --with-ldap=PATH use OpenLDAP files in PATH
  1903. --with-libcurl=DIR look for the curl library in DIR
  1904. --with-libedit=PATH use NetBSD Editline library files in PATH, use
  1905. 'internal' Editline otherwise
  1906. --with-libxml2=PATH use LibXML2 files in PATH
  1907. --with-libxslt=PATH use LibXSLT files in PATH
  1908. --with-ltdl=PATH use libtool files in PATH
  1909. --with-lua=PATH use Lua files in PATH
  1910. --with-misdn=PATH use mISDN user files in PATH
  1911. --with-mysqlclient=PATH use MySQL client files in PATH
  1912. --with-nbs=PATH use Network Broadcast Sound files in PATH
  1913. --with-ncurses=PATH use ncurses files in PATH
  1914. --with-neon=PATH use neon files in PATH
  1915. --with-neon29=PATH use neon29 files in PATH
  1916. --with-netsnmp=PATH use Net-SNMP files in PATH
  1917. --with-newt=PATH use newt files in PATH
  1918. --with-ogg=PATH use OGG files in PATH
  1919. --with-openr2=PATH use MFR2 files in PATH
  1920. --with-osptk=PATH use OSP Toolkit files in PATH
  1921. --with-oss=PATH use Open Sound System files in PATH
  1922. --with-postgres=PATH use PostgreSQL files in PATH
  1923. --with-pjproject=PATH use PJPROJECT files in PATH
  1924. --with-popt=PATH use popt files in PATH
  1925. --with-portaudio=PATH use PortAudio files in PATH
  1926. --with-pri=PATH use ISDN PRI files in PATH
  1927. --with-pwlib=PATH use PWlib files in PATH
  1928. --with-radius=PATH use Radius Client files in PATH
  1929. --with-resample=PATH use LIBRESAMPLE files in PATH
  1930. --with-sdl=PATH use Sdl files in PATH
  1931. --with-SDL_image=PATH use Sdl Image files in PATH
  1932. --with-sounds-cache=PATH
  1933. use cached sound tarfiles in PATH
  1934. --with-spandsp=PATH use SPANDSP files in PATH
  1935. --with-ss7=PATH use ISDN SS7 files in PATH
  1936. --with-speex=PATH use Speex files in PATH
  1937. --with-speex=PATH use Speex preprocess routines files in PATH
  1938. --with-speexdsp=PATH use SpeexDSP files in PATH
  1939. --with-sqlite=PATH use SQLite files in PATH
  1940. --with-sqlite3=PATH use SQLite files in PATH
  1941. --with-srtp=PATH use Secure RTP files in PATH
  1942. --with-ssl=PATH use OpenSSL Secure Sockets Layer files in PATH
  1943. --with-suppserv=PATH use mISDN Supplemental Services files in PATH
  1944. --with-tds=PATH use FreeTDS files in PATH
  1945. --with-termcap=PATH use Termcap files in PATH
  1946. --with-timerfd=PATH use timerfd files in PATH
  1947. --with-tinfo=PATH use Term Info files in PATH
  1948. --with-tonezone=PATH use tonezone files in PATH
  1949. --with-unixodbc=PATH use unixODBC files in PATH
  1950. --with-vorbis=PATH use Vorbis files in PATH
  1951. --with-vpb=PATH use Voicetronix API files in PATH
  1952. --with-x11=PATH use X11 files in PATH
  1953. --with-z=PATH use zlib compression files in PATH
  1954. Some influential environment variables:
  1955. CC C compiler command
  1956. CFLAGS C compiler flags
  1957. LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
  1958. nonstandard directory <lib dir>
  1959. LIBS libraries to pass to the linker, e.g. -l<library>
  1960. CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
  1961. you have headers in a nonstandard directory <include dir>
  1962. CPP C preprocessor
  1963. CXX C++ compiler command
  1964. CXXFLAGS C++ compiler flags
  1965. CXXCPP C++ preprocessor
  1966. PKG_CONFIG path to pkg-config utility
  1967. PKG_CONFIG_PATH
  1968. directories to add to pkg-config's search path
  1969. PKG_CONFIG_LIBDIR
  1970. path overriding pkg-config's built-in search path
  1971. ILBC_CFLAGS C compiler flags for ILBC, overriding pkg-config
  1972. ILBC_LIBS linker flags for ILBC, overriding pkg-config
  1973. LIBEDIT_CFLAGS
  1974. C compiler flags for LIBEDIT, overriding pkg-config
  1975. LIBEDIT_LIBS
  1976. linker flags for LIBEDIT, overriding pkg-config
  1977. PJPROJECT_CFLAGS
  1978. C compiler flags for PJPROJECT, overriding pkg-config
  1979. PJPROJECT_LIBS
  1980. linker flags for PJPROJECT, overriding pkg-config
  1981. GMIME_CFLAGS
  1982. C compiler flags for GMIME, overriding pkg-config
  1983. GMIME_LIBS linker flags for GMIME, overriding pkg-config
  1984. GTK2_CFLAGS C compiler flags for GTK2, overriding pkg-config
  1985. GTK2_LIBS linker flags for GTK2, overriding pkg-config
  1986. Use these variables to override the choices made by `configure' or to help
  1987. it to find libraries and programs with nonstandard names/locations.
  1988. Report bugs to <https://issues.asterisk.org>.
  1989. _ACEOF
  1990. ac_status=$?
  1991. fi
  1992. if test "$ac_init_help" = "recursive"; then
  1993. # If there are subdirs, report their specific --help.
  1994. for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
  1995. test -d "$ac_dir" ||
  1996. { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
  1997. continue
  1998. ac_builddir=.
  1999. case "$ac_dir" in
  2000. .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
  2001. *)
  2002. ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
  2003. # A ".." for each directory in $ac_dir_suffix.
  2004. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
  2005. case $ac_top_builddir_sub in
  2006. "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
  2007. *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
  2008. esac ;;
  2009. esac
  2010. ac_abs_top_builddir=$ac_pwd
  2011. ac_abs_builddir=$ac_pwd$ac_dir_suffix
  2012. # for backward compatibility:
  2013. ac_top_builddir=$ac_top_build_prefix
  2014. case $srcdir in
  2015. .) # We are building in place.
  2016. ac_srcdir=.
  2017. ac_top_srcdir=$ac_top_builddir_sub
  2018. ac_abs_top_srcdir=$ac_pwd ;;
  2019. [\\/]* | ?:[\\/]* ) # Absolute name.
  2020. ac_srcdir=$srcdir$ac_dir_suffix;
  2021. ac_top_srcdir=$srcdir
  2022. ac_abs_top_srcdir=$srcdir ;;
  2023. *) # Relative name.
  2024. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
  2025. ac_top_srcdir=$ac_top_build_prefix$srcdir
  2026. ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
  2027. esac
  2028. ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
  2029. cd "$ac_dir" || { ac_status=$?; continue; }
  2030. # Check for guested configure.
  2031. if test -f "$ac_srcdir/configure.gnu"; then
  2032. echo &&
  2033. $SHELL "$ac_srcdir/configure.gnu" --help=recursive
  2034. elif test -f "$ac_srcdir/configure"; then
  2035. echo &&
  2036. $SHELL "$ac_srcdir/configure" --help=recursive
  2037. else
  2038. $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
  2039. fi || ac_status=$?
  2040. cd "$ac_pwd" || { ac_status=$?; break; }
  2041. done
  2042. fi
  2043. test -n "$ac_init_help" && exit $ac_status
  2044. if $ac_init_version; then
  2045. cat <<\_ACEOF
  2046. asterisk configure trunk
  2047. generated by GNU Autoconf 2.69
  2048. Copyright (C) 2012 Free Software Foundation, Inc.
  2049. This configure script is free software; the Free Software Foundation
  2050. gives unlimited permission to copy, distribute and modify it.
  2051. "Asterisk"
  2052. _ACEOF
  2053. exit
  2054. fi
  2055. ## ------------------------ ##
  2056. ## Autoconf initialization. ##
  2057. ## ------------------------ ##
  2058. # ac_fn_c_try_compile LINENO
  2059. # --------------------------
  2060. # Try to compile conftest.$ac_ext, and return whether this succeeded.
  2061. ac_fn_c_try_compile ()
  2062. {
  2063. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2064. rm -f conftest.$ac_objext
  2065. if { { ac_try="$ac_compile"
  2066. case "(($ac_try" in
  2067. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2068. *) ac_try_echo=$ac_try;;
  2069. esac
  2070. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2071. $as_echo "$ac_try_echo"; } >&5
  2072. (eval "$ac_compile") 2>conftest.err
  2073. ac_status=$?
  2074. if test -s conftest.err; then
  2075. grep -v '^ *+' conftest.err >conftest.er1
  2076. cat conftest.er1 >&5
  2077. mv -f conftest.er1 conftest.err
  2078. fi
  2079. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2080. test $ac_status = 0; } && {
  2081. test -z "$ac_c_werror_flag" ||
  2082. test ! -s conftest.err
  2083. } && test -s conftest.$ac_objext; then :
  2084. ac_retval=0
  2085. else
  2086. $as_echo "$as_me: failed program was:" >&5
  2087. sed 's/^/| /' conftest.$ac_ext >&5
  2088. ac_retval=1
  2089. fi
  2090. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2091. as_fn_set_status $ac_retval
  2092. } # ac_fn_c_try_compile
  2093. # ac_fn_c_try_cpp LINENO
  2094. # ----------------------
  2095. # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
  2096. ac_fn_c_try_cpp ()
  2097. {
  2098. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2099. if { { ac_try="$ac_cpp conftest.$ac_ext"
  2100. case "(($ac_try" in
  2101. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2102. *) ac_try_echo=$ac_try;;
  2103. esac
  2104. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2105. $as_echo "$ac_try_echo"; } >&5
  2106. (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
  2107. ac_status=$?
  2108. if test -s conftest.err; then
  2109. grep -v '^ *+' conftest.err >conftest.er1
  2110. cat conftest.er1 >&5
  2111. mv -f conftest.er1 conftest.err
  2112. fi
  2113. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2114. test $ac_status = 0; } > conftest.i && {
  2115. test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
  2116. test ! -s conftest.err
  2117. }; then :
  2118. ac_retval=0
  2119. else
  2120. $as_echo "$as_me: failed program was:" >&5
  2121. sed 's/^/| /' conftest.$ac_ext >&5
  2122. ac_retval=1
  2123. fi
  2124. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2125. as_fn_set_status $ac_retval
  2126. } # ac_fn_c_try_cpp
  2127. # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
  2128. # -------------------------------------------------------
  2129. # Tests whether HEADER exists, giving a warning if it cannot be compiled using
  2130. # the include files in INCLUDES and setting the cache variable VAR
  2131. # accordingly.
  2132. ac_fn_c_check_header_mongrel ()
  2133. {
  2134. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2135. if eval \${$3+:} false; then :
  2136. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  2137. $as_echo_n "checking for $2... " >&6; }
  2138. if eval \${$3+:} false; then :
  2139. $as_echo_n "(cached) " >&6
  2140. fi
  2141. eval ac_res=\$$3
  2142. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2143. $as_echo "$ac_res" >&6; }
  2144. else
  2145. # Is the header compilable?
  2146. { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
  2147. $as_echo_n "checking $2 usability... " >&6; }
  2148. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2149. /* end confdefs.h. */
  2150. $4
  2151. #include <$2>
  2152. _ACEOF
  2153. if ac_fn_c_try_compile "$LINENO"; then :
  2154. ac_header_compiler=yes
  2155. else
  2156. ac_header_compiler=no
  2157. fi
  2158. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2159. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
  2160. $as_echo "$ac_header_compiler" >&6; }
  2161. # Is the header present?
  2162. { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
  2163. $as_echo_n "checking $2 presence... " >&6; }
  2164. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2165. /* end confdefs.h. */
  2166. #include <$2>
  2167. _ACEOF
  2168. if ac_fn_c_try_cpp "$LINENO"; then :
  2169. ac_header_preproc=yes
  2170. else
  2171. ac_header_preproc=no
  2172. fi
  2173. rm -f conftest.err conftest.i conftest.$ac_ext
  2174. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
  2175. $as_echo "$ac_header_preproc" >&6; }
  2176. # So? What about this header?
  2177. case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
  2178. yes:no: )
  2179. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
  2180. $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
  2181. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
  2182. $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
  2183. ;;
  2184. no:yes:* )
  2185. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
  2186. $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
  2187. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
  2188. $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
  2189. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
  2190. $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
  2191. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
  2192. $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
  2193. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
  2194. $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
  2195. ( $as_echo "## ------------------------------------------ ##
  2196. ## Report this to https://issues.asterisk.org ##
  2197. ## ------------------------------------------ ##"
  2198. ) | sed "s/^/$as_me: WARNING: /" >&2
  2199. ;;
  2200. esac
  2201. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  2202. $as_echo_n "checking for $2... " >&6; }
  2203. if eval \${$3+:} false; then :
  2204. $as_echo_n "(cached) " >&6
  2205. else
  2206. eval "$3=\$ac_header_compiler"
  2207. fi
  2208. eval ac_res=\$$3
  2209. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2210. $as_echo "$ac_res" >&6; }
  2211. fi
  2212. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2213. } # ac_fn_c_check_header_mongrel
  2214. # ac_fn_c_try_run LINENO
  2215. # ----------------------
  2216. # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
  2217. # that executables *can* be run.
  2218. ac_fn_c_try_run ()
  2219. {
  2220. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2221. if { { ac_try="$ac_link"
  2222. case "(($ac_try" in
  2223. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2224. *) ac_try_echo=$ac_try;;
  2225. esac
  2226. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2227. $as_echo "$ac_try_echo"; } >&5
  2228. (eval "$ac_link") 2>&5
  2229. ac_status=$?
  2230. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2231. test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
  2232. { { case "(($ac_try" in
  2233. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2234. *) ac_try_echo=$ac_try;;
  2235. esac
  2236. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2237. $as_echo "$ac_try_echo"; } >&5
  2238. (eval "$ac_try") 2>&5
  2239. ac_status=$?
  2240. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2241. test $ac_status = 0; }; }; then :
  2242. ac_retval=0
  2243. else
  2244. $as_echo "$as_me: program exited with status $ac_status" >&5
  2245. $as_echo "$as_me: failed program was:" >&5
  2246. sed 's/^/| /' conftest.$ac_ext >&5
  2247. ac_retval=$ac_status
  2248. fi
  2249. rm -rf conftest.dSYM conftest_ipa8_conftest.oo
  2250. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2251. as_fn_set_status $ac_retval
  2252. } # ac_fn_c_try_run
  2253. # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
  2254. # -------------------------------------------------------
  2255. # Tests whether HEADER exists and can be compiled using the include files in
  2256. # INCLUDES, setting the cache variable VAR accordingly.
  2257. ac_fn_c_check_header_compile ()
  2258. {
  2259. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2260. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  2261. $as_echo_n "checking for $2... " >&6; }
  2262. if eval \${$3+:} false; then :
  2263. $as_echo_n "(cached) " >&6
  2264. else
  2265. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2266. /* end confdefs.h. */
  2267. $4
  2268. #include <$2>
  2269. _ACEOF
  2270. if ac_fn_c_try_compile "$LINENO"; then :
  2271. eval "$3=yes"
  2272. else
  2273. eval "$3=no"
  2274. fi
  2275. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2276. fi
  2277. eval ac_res=\$$3
  2278. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2279. $as_echo "$ac_res" >&6; }
  2280. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2281. } # ac_fn_c_check_header_compile
  2282. # ac_fn_cxx_try_compile LINENO
  2283. # ----------------------------
  2284. # Try to compile conftest.$ac_ext, and return whether this succeeded.
  2285. ac_fn_cxx_try_compile ()
  2286. {
  2287. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2288. rm -f conftest.$ac_objext
  2289. if { { ac_try="$ac_compile"
  2290. case "(($ac_try" in
  2291. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2292. *) ac_try_echo=$ac_try;;
  2293. esac
  2294. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2295. $as_echo "$ac_try_echo"; } >&5
  2296. (eval "$ac_compile") 2>conftest.err
  2297. ac_status=$?
  2298. if test -s conftest.err; then
  2299. grep -v '^ *+' conftest.err >conftest.er1
  2300. cat conftest.er1 >&5
  2301. mv -f conftest.er1 conftest.err
  2302. fi
  2303. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2304. test $ac_status = 0; } && {
  2305. test -z "$ac_cxx_werror_flag" ||
  2306. test ! -s conftest.err
  2307. } && test -s conftest.$ac_objext; then :
  2308. ac_retval=0
  2309. else
  2310. $as_echo "$as_me: failed program was:" >&5
  2311. sed 's/^/| /' conftest.$ac_ext >&5
  2312. ac_retval=1
  2313. fi
  2314. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2315. as_fn_set_status $ac_retval
  2316. } # ac_fn_cxx_try_compile
  2317. # ac_fn_cxx_try_cpp LINENO
  2318. # ------------------------
  2319. # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
  2320. ac_fn_cxx_try_cpp ()
  2321. {
  2322. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2323. if { { ac_try="$ac_cpp conftest.$ac_ext"
  2324. case "(($ac_try" in
  2325. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2326. *) ac_try_echo=$ac_try;;
  2327. esac
  2328. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2329. $as_echo "$ac_try_echo"; } >&5
  2330. (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
  2331. ac_status=$?
  2332. if test -s conftest.err; then
  2333. grep -v '^ *+' conftest.err >conftest.er1
  2334. cat conftest.er1 >&5
  2335. mv -f conftest.er1 conftest.err
  2336. fi
  2337. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2338. test $ac_status = 0; } > conftest.i && {
  2339. test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
  2340. test ! -s conftest.err
  2341. }; then :
  2342. ac_retval=0
  2343. else
  2344. $as_echo "$as_me: failed program was:" >&5
  2345. sed 's/^/| /' conftest.$ac_ext >&5
  2346. ac_retval=1
  2347. fi
  2348. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2349. as_fn_set_status $ac_retval
  2350. } # ac_fn_cxx_try_cpp
  2351. # ac_fn_c_try_link LINENO
  2352. # -----------------------
  2353. # Try to link conftest.$ac_ext, and return whether this succeeded.
  2354. ac_fn_c_try_link ()
  2355. {
  2356. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2357. rm -f conftest.$ac_objext conftest$ac_exeext
  2358. if { { ac_try="$ac_link"
  2359. case "(($ac_try" in
  2360. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2361. *) ac_try_echo=$ac_try;;
  2362. esac
  2363. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2364. $as_echo "$ac_try_echo"; } >&5
  2365. (eval "$ac_link") 2>conftest.err
  2366. ac_status=$?
  2367. if test -s conftest.err; then
  2368. grep -v '^ *+' conftest.err >conftest.er1
  2369. cat conftest.er1 >&5
  2370. mv -f conftest.er1 conftest.err
  2371. fi
  2372. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2373. test $ac_status = 0; } && {
  2374. test -z "$ac_c_werror_flag" ||
  2375. test ! -s conftest.err
  2376. } && test -s conftest$ac_exeext && {
  2377. test "$cross_compiling" = yes ||
  2378. test -x conftest$ac_exeext
  2379. }; then :
  2380. ac_retval=0
  2381. else
  2382. $as_echo "$as_me: failed program was:" >&5
  2383. sed 's/^/| /' conftest.$ac_ext >&5
  2384. ac_retval=1
  2385. fi
  2386. # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
  2387. # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
  2388. # interfere with the next link command; also delete a directory that is
  2389. # left behind by Apple's compiler. We do this before executing the actions.
  2390. rm -rf conftest.dSYM conftest_ipa8_conftest.oo
  2391. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2392. as_fn_set_status $ac_retval
  2393. } # ac_fn_c_try_link
  2394. # ac_fn_c_check_func LINENO FUNC VAR
  2395. # ----------------------------------
  2396. # Tests whether FUNC exists, setting the cache variable VAR accordingly
  2397. ac_fn_c_check_func ()
  2398. {
  2399. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2400. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  2401. $as_echo_n "checking for $2... " >&6; }
  2402. if eval \${$3+:} false; then :
  2403. $as_echo_n "(cached) " >&6
  2404. else
  2405. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2406. /* end confdefs.h. */
  2407. /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
  2408. For example, HP-UX 11i <limits.h> declares gettimeofday. */
  2409. #define $2 innocuous_$2
  2410. /* System header to define __stub macros and hopefully few prototypes,
  2411. which can conflict with char $2 (); below.
  2412. Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  2413. <limits.h> exists even on freestanding compilers. */
  2414. #ifdef __STDC__
  2415. # include <limits.h>
  2416. #else
  2417. # include <assert.h>
  2418. #endif
  2419. #undef $2
  2420. /* Override any GCC internal prototype to avoid an error.
  2421. Use char because int might match the return type of a GCC
  2422. builtin and then its argument prototype would still apply. */
  2423. #ifdef __cplusplus
  2424. extern "C"
  2425. #endif
  2426. char $2 ();
  2427. /* The GNU C library defines this for functions which it implements
  2428. to always fail with ENOSYS. Some functions are actually named
  2429. something starting with __ and the normal name is an alias. */
  2430. #if defined __stub_$2 || defined __stub___$2
  2431. choke me
  2432. #endif
  2433. int
  2434. main ()
  2435. {
  2436. return $2 ();
  2437. ;
  2438. return 0;
  2439. }
  2440. _ACEOF
  2441. if ac_fn_c_try_link "$LINENO"; then :
  2442. eval "$3=yes"
  2443. else
  2444. eval "$3=no"
  2445. fi
  2446. rm -f core conftest.err conftest.$ac_objext \
  2447. conftest$ac_exeext conftest.$ac_ext
  2448. fi
  2449. eval ac_res=\$$3
  2450. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2451. $as_echo "$ac_res" >&6; }
  2452. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2453. } # ac_fn_c_check_func
  2454. # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
  2455. # -------------------------------------------
  2456. # Tests whether TYPE exists after having included INCLUDES, setting cache
  2457. # variable VAR accordingly.
  2458. ac_fn_c_check_type ()
  2459. {
  2460. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2461. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  2462. $as_echo_n "checking for $2... " >&6; }
  2463. if eval \${$3+:} false; then :
  2464. $as_echo_n "(cached) " >&6
  2465. else
  2466. eval "$3=no"
  2467. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2468. /* end confdefs.h. */
  2469. $4
  2470. int
  2471. main ()
  2472. {
  2473. if (sizeof ($2))
  2474. return 0;
  2475. ;
  2476. return 0;
  2477. }
  2478. _ACEOF
  2479. if ac_fn_c_try_compile "$LINENO"; then :
  2480. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2481. /* end confdefs.h. */
  2482. $4
  2483. int
  2484. main ()
  2485. {
  2486. if (sizeof (($2)))
  2487. return 0;
  2488. ;
  2489. return 0;
  2490. }
  2491. _ACEOF
  2492. if ac_fn_c_try_compile "$LINENO"; then :
  2493. else
  2494. eval "$3=yes"
  2495. fi
  2496. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2497. fi
  2498. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2499. fi
  2500. eval ac_res=\$$3
  2501. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2502. $as_echo "$ac_res" >&6; }
  2503. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2504. } # ac_fn_c_check_type
  2505. # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
  2506. # ----------------------------------------------------
  2507. # Tries to find if the field MEMBER exists in type AGGR, after including
  2508. # INCLUDES, setting cache variable VAR accordingly.
  2509. ac_fn_c_check_member ()
  2510. {
  2511. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2512. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
  2513. $as_echo_n "checking for $2.$3... " >&6; }
  2514. if eval \${$4+:} false; then :
  2515. $as_echo_n "(cached) " >&6
  2516. else
  2517. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2518. /* end confdefs.h. */
  2519. $5
  2520. int
  2521. main ()
  2522. {
  2523. static $2 ac_aggr;
  2524. if (ac_aggr.$3)
  2525. return 0;
  2526. ;
  2527. return 0;
  2528. }
  2529. _ACEOF
  2530. if ac_fn_c_try_compile "$LINENO"; then :
  2531. eval "$4=yes"
  2532. else
  2533. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2534. /* end confdefs.h. */
  2535. $5
  2536. int
  2537. main ()
  2538. {
  2539. static $2 ac_aggr;
  2540. if (sizeof ac_aggr.$3)
  2541. return 0;
  2542. ;
  2543. return 0;
  2544. }
  2545. _ACEOF
  2546. if ac_fn_c_try_compile "$LINENO"; then :
  2547. eval "$4=yes"
  2548. else
  2549. eval "$4=no"
  2550. fi
  2551. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2552. fi
  2553. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2554. fi
  2555. eval ac_res=\$$4
  2556. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2557. $as_echo "$ac_res" >&6; }
  2558. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2559. } # ac_fn_c_check_member
  2560. # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
  2561. # --------------------------------------------
  2562. # Tries to find the compile-time value of EXPR in a program that includes
  2563. # INCLUDES, setting VAR accordingly. Returns whether the value could be
  2564. # computed
  2565. ac_fn_c_compute_int ()
  2566. {
  2567. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2568. if test "$cross_compiling" = yes; then
  2569. # Depending upon the size, compute the lo and hi bounds.
  2570. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2571. /* end confdefs.h. */
  2572. $4
  2573. int
  2574. main ()
  2575. {
  2576. static int test_array [1 - 2 * !(($2) >= 0)];
  2577. test_array [0] = 0;
  2578. return test_array [0];
  2579. ;
  2580. return 0;
  2581. }
  2582. _ACEOF
  2583. if ac_fn_c_try_compile "$LINENO"; then :
  2584. ac_lo=0 ac_mid=0
  2585. while :; do
  2586. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2587. /* end confdefs.h. */
  2588. $4
  2589. int
  2590. main ()
  2591. {
  2592. static int test_array [1 - 2 * !(($2) <= $ac_mid)];
  2593. test_array [0] = 0;
  2594. return test_array [0];
  2595. ;
  2596. return 0;
  2597. }
  2598. _ACEOF
  2599. if ac_fn_c_try_compile "$LINENO"; then :
  2600. ac_hi=$ac_mid; break
  2601. else
  2602. as_fn_arith $ac_mid + 1 && ac_lo=$as_val
  2603. if test $ac_lo -le $ac_mid; then
  2604. ac_lo= ac_hi=
  2605. break
  2606. fi
  2607. as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
  2608. fi
  2609. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2610. done
  2611. else
  2612. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2613. /* end confdefs.h. */
  2614. $4
  2615. int
  2616. main ()
  2617. {
  2618. static int test_array [1 - 2 * !(($2) < 0)];
  2619. test_array [0] = 0;
  2620. return test_array [0];
  2621. ;
  2622. return 0;
  2623. }
  2624. _ACEOF
  2625. if ac_fn_c_try_compile "$LINENO"; then :
  2626. ac_hi=-1 ac_mid=-1
  2627. while :; do
  2628. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2629. /* end confdefs.h. */
  2630. $4
  2631. int
  2632. main ()
  2633. {
  2634. static int test_array [1 - 2 * !(($2) >= $ac_mid)];
  2635. test_array [0] = 0;
  2636. return test_array [0];
  2637. ;
  2638. return 0;
  2639. }
  2640. _ACEOF
  2641. if ac_fn_c_try_compile "$LINENO"; then :
  2642. ac_lo=$ac_mid; break
  2643. else
  2644. as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
  2645. if test $ac_mid -le $ac_hi; then
  2646. ac_lo= ac_hi=
  2647. break
  2648. fi
  2649. as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
  2650. fi
  2651. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2652. done
  2653. else
  2654. ac_lo= ac_hi=
  2655. fi
  2656. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2657. fi
  2658. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2659. # Binary search between lo and hi bounds.
  2660. while test "x$ac_lo" != "x$ac_hi"; do
  2661. as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
  2662. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2663. /* end confdefs.h. */
  2664. $4
  2665. int
  2666. main ()
  2667. {
  2668. static int test_array [1 - 2 * !(($2) <= $ac_mid)];
  2669. test_array [0] = 0;
  2670. return test_array [0];
  2671. ;
  2672. return 0;
  2673. }
  2674. _ACEOF
  2675. if ac_fn_c_try_compile "$LINENO"; then :
  2676. ac_hi=$ac_mid
  2677. else
  2678. as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
  2679. fi
  2680. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2681. done
  2682. case $ac_lo in #((
  2683. ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
  2684. '') ac_retval=1 ;;
  2685. esac
  2686. else
  2687. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2688. /* end confdefs.h. */
  2689. $4
  2690. static long int longval () { return $2; }
  2691. static unsigned long int ulongval () { return $2; }
  2692. #include <stdio.h>
  2693. #include <stdlib.h>
  2694. int
  2695. main ()
  2696. {
  2697. FILE *f = fopen ("conftest.val", "w");
  2698. if (! f)
  2699. return 1;
  2700. if (($2) < 0)
  2701. {
  2702. long int i = longval ();
  2703. if (i != ($2))
  2704. return 1;
  2705. fprintf (f, "%ld", i);
  2706. }
  2707. else
  2708. {
  2709. unsigned long int i = ulongval ();
  2710. if (i != ($2))
  2711. return 1;
  2712. fprintf (f, "%lu", i);
  2713. }
  2714. /* Do not output a trailing newline, as this causes \r\n confusion
  2715. on some platforms. */
  2716. return ferror (f) || fclose (f) != 0;
  2717. ;
  2718. return 0;
  2719. }
  2720. _ACEOF
  2721. if ac_fn_c_try_run "$LINENO"; then :
  2722. echo >>conftest.val; read $3 <conftest.val; ac_retval=0
  2723. else
  2724. ac_retval=1
  2725. fi
  2726. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  2727. conftest.$ac_objext conftest.beam conftest.$ac_ext
  2728. rm -f conftest.val
  2729. fi
  2730. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2731. as_fn_set_status $ac_retval
  2732. } # ac_fn_c_compute_int
  2733. # ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES
  2734. # ---------------------------------------------------------
  2735. # Tests whether HEADER exists, giving a warning if it cannot be compiled using
  2736. # the include files in INCLUDES and setting the cache variable VAR
  2737. # accordingly.
  2738. ac_fn_cxx_check_header_mongrel ()
  2739. {
  2740. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2741. if eval \${$3+:} false; then :
  2742. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  2743. $as_echo_n "checking for $2... " >&6; }
  2744. if eval \${$3+:} false; then :
  2745. $as_echo_n "(cached) " >&6
  2746. fi
  2747. eval ac_res=\$$3
  2748. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2749. $as_echo "$ac_res" >&6; }
  2750. else
  2751. # Is the header compilable?
  2752. { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
  2753. $as_echo_n "checking $2 usability... " >&6; }
  2754. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2755. /* end confdefs.h. */
  2756. $4
  2757. #include <$2>
  2758. _ACEOF
  2759. if ac_fn_cxx_try_compile "$LINENO"; then :
  2760. ac_header_compiler=yes
  2761. else
  2762. ac_header_compiler=no
  2763. fi
  2764. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2765. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
  2766. $as_echo "$ac_header_compiler" >&6; }
  2767. # Is the header present?
  2768. { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
  2769. $as_echo_n "checking $2 presence... " >&6; }
  2770. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2771. /* end confdefs.h. */
  2772. #include <$2>
  2773. _ACEOF
  2774. if ac_fn_cxx_try_cpp "$LINENO"; then :
  2775. ac_header_preproc=yes
  2776. else
  2777. ac_header_preproc=no
  2778. fi
  2779. rm -f conftest.err conftest.i conftest.$ac_ext
  2780. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
  2781. $as_echo "$ac_header_preproc" >&6; }
  2782. # So? What about this header?
  2783. case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #((
  2784. yes:no: )
  2785. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
  2786. $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
  2787. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
  2788. $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
  2789. ;;
  2790. no:yes:* )
  2791. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
  2792. $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
  2793. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
  2794. $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
  2795. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
  2796. $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
  2797. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
  2798. $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
  2799. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
  2800. $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
  2801. ( $as_echo "## ------------------------------------------ ##
  2802. ## Report this to https://issues.asterisk.org ##
  2803. ## ------------------------------------------ ##"
  2804. ) | sed "s/^/$as_me: WARNING: /" >&2
  2805. ;;
  2806. esac
  2807. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  2808. $as_echo_n "checking for $2... " >&6; }
  2809. if eval \${$3+:} false; then :
  2810. $as_echo_n "(cached) " >&6
  2811. else
  2812. eval "$3=\$ac_header_compiler"
  2813. fi
  2814. eval ac_res=\$$3
  2815. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2816. $as_echo "$ac_res" >&6; }
  2817. fi
  2818. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2819. } # ac_fn_cxx_check_header_mongrel
  2820. # ac_fn_cxx_try_link LINENO
  2821. # -------------------------
  2822. # Try to link conftest.$ac_ext, and return whether this succeeded.
  2823. ac_fn_cxx_try_link ()
  2824. {
  2825. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2826. rm -f conftest.$ac_objext conftest$ac_exeext
  2827. if { { ac_try="$ac_link"
  2828. case "(($ac_try" in
  2829. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2830. *) ac_try_echo=$ac_try;;
  2831. esac
  2832. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2833. $as_echo "$ac_try_echo"; } >&5
  2834. (eval "$ac_link") 2>conftest.err
  2835. ac_status=$?
  2836. if test -s conftest.err; then
  2837. grep -v '^ *+' conftest.err >conftest.er1
  2838. cat conftest.er1 >&5
  2839. mv -f conftest.er1 conftest.err
  2840. fi
  2841. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2842. test $ac_status = 0; } && {
  2843. test -z "$ac_cxx_werror_flag" ||
  2844. test ! -s conftest.err
  2845. } && test -s conftest$ac_exeext && {
  2846. test "$cross_compiling" = yes ||
  2847. test -x conftest$ac_exeext
  2848. }; then :
  2849. ac_retval=0
  2850. else
  2851. $as_echo "$as_me: failed program was:" >&5
  2852. sed 's/^/| /' conftest.$ac_ext >&5
  2853. ac_retval=1
  2854. fi
  2855. # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
  2856. # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
  2857. # interfere with the next link command; also delete a directory that is
  2858. # left behind by Apple's compiler. We do this before executing the actions.
  2859. rm -rf conftest.dSYM conftest_ipa8_conftest.oo
  2860. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2861. as_fn_set_status $ac_retval
  2862. } # ac_fn_cxx_try_link
  2863. # ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES
  2864. # ---------------------------------------------------------
  2865. # Tests whether HEADER exists and can be compiled using the include files in
  2866. # INCLUDES, setting the cache variable VAR accordingly.
  2867. ac_fn_cxx_check_header_compile ()
  2868. {
  2869. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2870. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  2871. $as_echo_n "checking for $2... " >&6; }
  2872. if eval \${$3+:} false; then :
  2873. $as_echo_n "(cached) " >&6
  2874. else
  2875. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2876. /* end confdefs.h. */
  2877. $4
  2878. #include <$2>
  2879. _ACEOF
  2880. if ac_fn_cxx_try_compile "$LINENO"; then :
  2881. eval "$3=yes"
  2882. else
  2883. eval "$3=no"
  2884. fi
  2885. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2886. fi
  2887. eval ac_res=\$$3
  2888. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2889. $as_echo "$ac_res" >&6; }
  2890. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2891. } # ac_fn_cxx_check_header_compile
  2892. cat >config.log <<_ACEOF
  2893. This file contains any messages produced by compilers while
  2894. running configure, to aid debugging if configure makes a mistake.
  2895. It was created by asterisk $as_me trunk, which was
  2896. generated by GNU Autoconf 2.69. Invocation command line was
  2897. $ $0 $@
  2898. _ACEOF
  2899. exec 5>>config.log
  2900. {
  2901. cat <<_ASUNAME
  2902. ## --------- ##
  2903. ## Platform. ##
  2904. ## --------- ##
  2905. hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
  2906. uname -m = `(uname -m) 2>/dev/null || echo unknown`
  2907. uname -r = `(uname -r) 2>/dev/null || echo unknown`
  2908. uname -s = `(uname -s) 2>/dev/null || echo unknown`
  2909. uname -v = `(uname -v) 2>/dev/null || echo unknown`
  2910. /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
  2911. /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
  2912. /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
  2913. /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
  2914. /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
  2915. /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
  2916. /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
  2917. /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
  2918. /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
  2919. _ASUNAME
  2920. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  2921. for as_dir in $PATH
  2922. do
  2923. IFS=$as_save_IFS
  2924. test -z "$as_dir" && as_dir=.
  2925. $as_echo "PATH: $as_dir"
  2926. done
  2927. IFS=$as_save_IFS
  2928. } >&5
  2929. cat >&5 <<_ACEOF
  2930. ## ----------- ##
  2931. ## Core tests. ##
  2932. ## ----------- ##
  2933. _ACEOF
  2934. # Keep a trace of the command line.
  2935. # Strip out --no-create and --no-recursion so they do not pile up.
  2936. # Strip out --silent because we don't want to record it for future runs.
  2937. # Also quote any args containing shell meta-characters.
  2938. # Make two passes to allow for proper duplicate-argument suppression.
  2939. ac_configure_args=
  2940. ac_configure_args0=
  2941. ac_configure_args1=
  2942. ac_must_keep_next=false
  2943. for ac_pass in 1 2
  2944. do
  2945. for ac_arg
  2946. do
  2947. case $ac_arg in
  2948. -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
  2949. -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  2950. | -silent | --silent | --silen | --sile | --sil)
  2951. continue ;;
  2952. *\'*)
  2953. ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
  2954. esac
  2955. case $ac_pass in
  2956. 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
  2957. 2)
  2958. as_fn_append ac_configure_args1 " '$ac_arg'"
  2959. if test $ac_must_keep_next = true; then
  2960. ac_must_keep_next=false # Got value, back to normal.
  2961. else
  2962. case $ac_arg in
  2963. *=* | --config-cache | -C | -disable-* | --disable-* \
  2964. | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
  2965. | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
  2966. | -with-* | --with-* | -without-* | --without-* | --x)
  2967. case "$ac_configure_args0 " in
  2968. "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
  2969. esac
  2970. ;;
  2971. -* ) ac_must_keep_next=true ;;
  2972. esac
  2973. fi
  2974. as_fn_append ac_configure_args " '$ac_arg'"
  2975. ;;
  2976. esac
  2977. done
  2978. done
  2979. { ac_configure_args0=; unset ac_configure_args0;}
  2980. { ac_configure_args1=; unset ac_configure_args1;}
  2981. # When interrupted or exit'd, cleanup temporary files, and complete
  2982. # config.log. We remove comments because anyway the quotes in there
  2983. # would cause problems or look ugly.
  2984. # WARNING: Use '\'' to represent an apostrophe within the trap.
  2985. # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
  2986. trap 'exit_status=$?
  2987. # Save into config.log some information that might help in debugging.
  2988. {
  2989. echo
  2990. $as_echo "## ---------------- ##
  2991. ## Cache variables. ##
  2992. ## ---------------- ##"
  2993. echo
  2994. # The following way of writing the cache mishandles newlines in values,
  2995. (
  2996. for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
  2997. eval ac_val=\$$ac_var
  2998. case $ac_val in #(
  2999. *${as_nl}*)
  3000. case $ac_var in #(
  3001. *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
  3002. $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
  3003. esac
  3004. case $ac_var in #(
  3005. _ | IFS | as_nl) ;; #(
  3006. BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
  3007. *) { eval $ac_var=; unset $ac_var;} ;;
  3008. esac ;;
  3009. esac
  3010. done
  3011. (set) 2>&1 |
  3012. case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
  3013. *${as_nl}ac_space=\ *)
  3014. sed -n \
  3015. "s/'\''/'\''\\\\'\'''\''/g;
  3016. s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
  3017. ;; #(
  3018. *)
  3019. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
  3020. ;;
  3021. esac |
  3022. sort
  3023. )
  3024. echo
  3025. $as_echo "## ----------------- ##
  3026. ## Output variables. ##
  3027. ## ----------------- ##"
  3028. echo
  3029. for ac_var in $ac_subst_vars
  3030. do
  3031. eval ac_val=\$$ac_var
  3032. case $ac_val in
  3033. *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
  3034. esac
  3035. $as_echo "$ac_var='\''$ac_val'\''"
  3036. done | sort
  3037. echo
  3038. if test -n "$ac_subst_files"; then
  3039. $as_echo "## ------------------- ##
  3040. ## File substitutions. ##
  3041. ## ------------------- ##"
  3042. echo
  3043. for ac_var in $ac_subst_files
  3044. do
  3045. eval ac_val=\$$ac_var
  3046. case $ac_val in
  3047. *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
  3048. esac
  3049. $as_echo "$ac_var='\''$ac_val'\''"
  3050. done | sort
  3051. echo
  3052. fi
  3053. if test -s confdefs.h; then
  3054. $as_echo "## ----------- ##
  3055. ## confdefs.h. ##
  3056. ## ----------- ##"
  3057. echo
  3058. cat confdefs.h
  3059. echo
  3060. fi
  3061. test "$ac_signal" != 0 &&
  3062. $as_echo "$as_me: caught signal $ac_signal"
  3063. $as_echo "$as_me: exit $exit_status"
  3064. } >&5
  3065. rm -f core *.core core.conftest.* &&
  3066. rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
  3067. exit $exit_status
  3068. ' 0
  3069. for ac_signal in 1 2 13 15; do
  3070. trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
  3071. done
  3072. ac_signal=0
  3073. # confdefs.h avoids OS command line length limits that DEFS can exceed.
  3074. rm -f -r conftest* confdefs.h
  3075. $as_echo "/* confdefs.h */" > confdefs.h
  3076. # Predefined preprocessor variables.
  3077. cat >>confdefs.h <<_ACEOF
  3078. #define PACKAGE_NAME "$PACKAGE_NAME"
  3079. _ACEOF
  3080. cat >>confdefs.h <<_ACEOF
  3081. #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
  3082. _ACEOF
  3083. cat >>confdefs.h <<_ACEOF
  3084. #define PACKAGE_VERSION "$PACKAGE_VERSION"
  3085. _ACEOF
  3086. cat >>confdefs.h <<_ACEOF
  3087. #define PACKAGE_STRING "$PACKAGE_STRING"
  3088. _ACEOF
  3089. cat >>confdefs.h <<_ACEOF
  3090. #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
  3091. _ACEOF
  3092. cat >>confdefs.h <<_ACEOF
  3093. #define PACKAGE_URL "$PACKAGE_URL"
  3094. _ACEOF
  3095. # Let the site file select an alternate cache file if it wants to.
  3096. # Prefer an explicitly selected file to automatically selected ones.
  3097. ac_site_file1=NONE
  3098. ac_site_file2=NONE
  3099. if test -n "$CONFIG_SITE"; then
  3100. # We do not want a PATH search for config.site.
  3101. case $CONFIG_SITE in #((
  3102. -*) ac_site_file1=./$CONFIG_SITE;;
  3103. */*) ac_site_file1=$CONFIG_SITE;;
  3104. *) ac_site_file1=./$CONFIG_SITE;;
  3105. esac
  3106. elif test "x$prefix" != xNONE; then
  3107. ac_site_file1=$prefix/share/config.site
  3108. ac_site_file2=$prefix/etc/config.site
  3109. else
  3110. ac_site_file1=$ac_default_prefix/share/config.site
  3111. ac_site_file2=$ac_default_prefix/etc/config.site
  3112. fi
  3113. for ac_site_file in "$ac_site_file1" "$ac_site_file2"
  3114. do
  3115. test "x$ac_site_file" = xNONE && continue
  3116. if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
  3117. { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
  3118. $as_echo "$as_me: loading site script $ac_site_file" >&6;}
  3119. sed 's/^/| /' "$ac_site_file" >&5
  3120. . "$ac_site_file" \
  3121. || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  3122. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  3123. as_fn_error $? "failed to load site script $ac_site_file
  3124. See \`config.log' for more details" "$LINENO" 5; }
  3125. fi
  3126. done
  3127. if test -r "$cache_file"; then
  3128. # Some versions of bash will fail to source /dev/null (special files
  3129. # actually), so we avoid doing that. DJGPP emulates it as a regular file.
  3130. if test /dev/null != "$cache_file" && test -f "$cache_file"; then
  3131. { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
  3132. $as_echo "$as_me: loading cache $cache_file" >&6;}
  3133. case $cache_file in
  3134. [\\/]* | ?:[\\/]* ) . "$cache_file";;
  3135. *) . "./$cache_file";;
  3136. esac
  3137. fi
  3138. else
  3139. { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
  3140. $as_echo "$as_me: creating cache $cache_file" >&6;}
  3141. >$cache_file
  3142. fi
  3143. as_fn_append ac_header_list " stdlib.h"
  3144. as_fn_append ac_header_list " unistd.h"
  3145. as_fn_append ac_header_list " sys/param.h"
  3146. as_fn_append ac_header_list " utime.h"
  3147. # Check that the precious variables saved in the cache have kept the same
  3148. # value.
  3149. ac_cache_corrupted=false
  3150. for ac_var in $ac_precious_vars; do
  3151. eval ac_old_set=\$ac_cv_env_${ac_var}_set
  3152. eval ac_new_set=\$ac_env_${ac_var}_set
  3153. eval ac_old_val=\$ac_cv_env_${ac_var}_value
  3154. eval ac_new_val=\$ac_env_${ac_var}_value
  3155. case $ac_old_set,$ac_new_set in
  3156. set,)
  3157. { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
  3158. $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
  3159. ac_cache_corrupted=: ;;
  3160. ,set)
  3161. { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
  3162. $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
  3163. ac_cache_corrupted=: ;;
  3164. ,);;
  3165. *)
  3166. if test "x$ac_old_val" != "x$ac_new_val"; then
  3167. # differences in whitespace do not lead to failure.
  3168. ac_old_val_w=`echo x $ac_old_val`
  3169. ac_new_val_w=`echo x $ac_new_val`
  3170. if test "$ac_old_val_w" != "$ac_new_val_w"; then
  3171. { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
  3172. $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
  3173. ac_cache_corrupted=:
  3174. else
  3175. { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
  3176. $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
  3177. eval $ac_var=\$ac_old_val
  3178. fi
  3179. { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
  3180. $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
  3181. { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
  3182. $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
  3183. fi;;
  3184. esac
  3185. # Pass precious variables to config.status.
  3186. if test "$ac_new_set" = set; then
  3187. case $ac_new_val in
  3188. *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
  3189. *) ac_arg=$ac_var=$ac_new_val ;;
  3190. esac
  3191. case " $ac_configure_args " in
  3192. *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
  3193. *) as_fn_append ac_configure_args " '$ac_arg'" ;;
  3194. esac
  3195. fi
  3196. done
  3197. if $ac_cache_corrupted; then
  3198. { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  3199. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  3200. { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
  3201. $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
  3202. as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
  3203. fi
  3204. ## -------------------- ##
  3205. ## Main body of script. ##
  3206. ## -------------------- ##
  3207. ac_ext=c
  3208. ac_cpp='$CPP $CPPFLAGS'
  3209. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  3210. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  3211. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  3212. # cross-compile macros
  3213. ac_aux_dir=
  3214. for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
  3215. if test -f "$ac_dir/install-sh"; then
  3216. ac_aux_dir=$ac_dir
  3217. ac_install_sh="$ac_aux_dir/install-sh -c"
  3218. break
  3219. elif test -f "$ac_dir/install.sh"; then
  3220. ac_aux_dir=$ac_dir
  3221. ac_install_sh="$ac_aux_dir/install.sh -c"
  3222. break
  3223. elif test -f "$ac_dir/shtool"; then
  3224. ac_aux_dir=$ac_dir
  3225. ac_install_sh="$ac_aux_dir/shtool install -c"
  3226. break
  3227. fi
  3228. done
  3229. if test -z "$ac_aux_dir"; then
  3230. as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
  3231. fi
  3232. # These three variables are undocumented and unsupported,
  3233. # and are intended to be withdrawn in a future Autoconf release.
  3234. # They can cause serious problems if a builder's source tree is in a directory
  3235. # whose full name contains unusual characters.
  3236. ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
  3237. ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
  3238. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
  3239. # Make sure we can run config.sub.
  3240. $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
  3241. as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
  3242. { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
  3243. $as_echo_n "checking build system type... " >&6; }
  3244. if ${ac_cv_build+:} false; then :
  3245. $as_echo_n "(cached) " >&6
  3246. else
  3247. ac_build_alias=$build_alias
  3248. test "x$ac_build_alias" = x &&
  3249. ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
  3250. test "x$ac_build_alias" = x &&
  3251. as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
  3252. ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
  3253. as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
  3254. fi
  3255. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
  3256. $as_echo "$ac_cv_build" >&6; }
  3257. case $ac_cv_build in
  3258. *-*-*) ;;
  3259. *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
  3260. esac
  3261. build=$ac_cv_build
  3262. ac_save_IFS=$IFS; IFS='-'
  3263. set x $ac_cv_build
  3264. shift
  3265. build_cpu=$1
  3266. build_vendor=$2
  3267. shift; shift
  3268. # Remember, the first character of IFS is used to create $*,
  3269. # except with old shells:
  3270. build_os=$*
  3271. IFS=$ac_save_IFS
  3272. case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
  3273. { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
  3274. $as_echo_n "checking host system type... " >&6; }
  3275. if ${ac_cv_host+:} false; then :
  3276. $as_echo_n "(cached) " >&6
  3277. else
  3278. if test "x$host_alias" = x; then
  3279. ac_cv_host=$ac_cv_build
  3280. else
  3281. ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
  3282. as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
  3283. fi
  3284. fi
  3285. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
  3286. $as_echo "$ac_cv_host" >&6; }
  3287. case $ac_cv_host in
  3288. *-*-*) ;;
  3289. *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
  3290. esac
  3291. host=$ac_cv_host
  3292. ac_save_IFS=$IFS; IFS='-'
  3293. set x $ac_cv_host
  3294. shift
  3295. host_cpu=$1
  3296. host_vendor=$2
  3297. shift; shift
  3298. # Remember, the first character of IFS is used to create $*,
  3299. # except with old shells:
  3300. host_os=$*
  3301. IFS=$ac_save_IFS
  3302. case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
  3303. # check existence of the package
  3304. ac_aux_dir=
  3305. for ac_dir in `pwd` "$srcdir"/`pwd`; do
  3306. if test -f "$ac_dir/install-sh"; then
  3307. ac_aux_dir=$ac_dir
  3308. ac_install_sh="$ac_aux_dir/install-sh -c"
  3309. break
  3310. elif test -f "$ac_dir/install.sh"; then
  3311. ac_aux_dir=$ac_dir
  3312. ac_install_sh="$ac_aux_dir/install.sh -c"
  3313. break
  3314. elif test -f "$ac_dir/shtool"; then
  3315. ac_aux_dir=$ac_dir
  3316. ac_install_sh="$ac_aux_dir/shtool install -c"
  3317. break
  3318. fi
  3319. done
  3320. if test -z "$ac_aux_dir"; then
  3321. as_fn_error $? "cannot find install-sh, install.sh, or shtool in \`pwd\` \"$srcdir\"/\`pwd\`" "$LINENO" 5
  3322. fi
  3323. # These three variables are undocumented and unsupported,
  3324. # and are intended to be withdrawn in a future Autoconf release.
  3325. # They can cause serious problems if a builder's source tree is in a directory
  3326. # whose full name contains unusual characters.
  3327. ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
  3328. ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
  3329. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
  3330. # preserve any CFLAGS or LDFLAGS that may be set
  3331. # NOTE: This must be done before calling any macros that end up
  3332. # calling AC_PROG_CC or the like, since they will set a default
  3333. # set of CFLAGS ("-g -O2") if the user did not supply any, and
  3334. # we don't want those default flags to be carried over into the
  3335. # rest of the build system since we have other means of controlling
  3336. # debugging symbol generation and optimization.
  3337. CONFIG_CFLAGS="${CFLAGS}"
  3338. CONFIG_LDFLAGS="${LDFLAGS}"
  3339. # specify output header file
  3340. ac_config_headers="$ac_config_headers include/asterisk/autoconfig.h"
  3341. # Note: AC_PROG_CC *must* be specified before AC_USE_SYSTEM_EXTENSIONS or any
  3342. # other macro that uses the C compiler, or the default order will be used.
  3343. ac_ext=c
  3344. ac_cpp='$CPP $CPPFLAGS'
  3345. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  3346. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  3347. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  3348. if test -n "$ac_tool_prefix"; then
  3349. for ac_prog in gcc cc
  3350. do
  3351. # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
  3352. set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  3353. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  3354. $as_echo_n "checking for $ac_word... " >&6; }
  3355. if ${ac_cv_prog_CC+:} false; then :
  3356. $as_echo_n "(cached) " >&6
  3357. else
  3358. if test -n "$CC"; then
  3359. ac_cv_prog_CC="$CC" # Let the user override the test.
  3360. else
  3361. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  3362. for as_dir in $PATH
  3363. do
  3364. IFS=$as_save_IFS
  3365. test -z "$as_dir" && as_dir=.
  3366. for ac_exec_ext in '' $ac_executable_extensions; do
  3367. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  3368. ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
  3369. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  3370. break 2
  3371. fi
  3372. done
  3373. done
  3374. IFS=$as_save_IFS
  3375. fi
  3376. fi
  3377. CC=$ac_cv_prog_CC
  3378. if test -n "$CC"; then
  3379. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
  3380. $as_echo "$CC" >&6; }
  3381. else
  3382. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  3383. $as_echo "no" >&6; }
  3384. fi
  3385. test -n "$CC" && break
  3386. done
  3387. fi
  3388. if test -z "$CC"; then
  3389. ac_ct_CC=$CC
  3390. for ac_prog in gcc cc
  3391. do
  3392. # Extract the first word of "$ac_prog", so it can be a program name with args.
  3393. set dummy $ac_prog; ac_word=$2
  3394. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  3395. $as_echo_n "checking for $ac_word... " >&6; }
  3396. if ${ac_cv_prog_ac_ct_CC+:} false; then :
  3397. $as_echo_n "(cached) " >&6
  3398. else
  3399. if test -n "$ac_ct_CC"; then
  3400. ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
  3401. else
  3402. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  3403. for as_dir in $PATH
  3404. do
  3405. IFS=$as_save_IFS
  3406. test -z "$as_dir" && as_dir=.
  3407. for ac_exec_ext in '' $ac_executable_extensions; do
  3408. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  3409. ac_cv_prog_ac_ct_CC="$ac_prog"
  3410. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  3411. break 2
  3412. fi
  3413. done
  3414. done
  3415. IFS=$as_save_IFS
  3416. fi
  3417. fi
  3418. ac_ct_CC=$ac_cv_prog_ac_ct_CC
  3419. if test -n "$ac_ct_CC"; then
  3420. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
  3421. $as_echo "$ac_ct_CC" >&6; }
  3422. else
  3423. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  3424. $as_echo "no" >&6; }
  3425. fi
  3426. test -n "$ac_ct_CC" && break
  3427. done
  3428. if test "x$ac_ct_CC" = x; then
  3429. CC=""
  3430. else
  3431. case $cross_compiling:$ac_tool_warned in
  3432. yes:)
  3433. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  3434. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  3435. ac_tool_warned=yes ;;
  3436. esac
  3437. CC=$ac_ct_CC
  3438. fi
  3439. fi
  3440. test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  3441. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  3442. as_fn_error $? "no acceptable C compiler found in \$PATH
  3443. See \`config.log' for more details" "$LINENO" 5; }
  3444. # Provide some information about the compiler.
  3445. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
  3446. set X $ac_compile
  3447. ac_compiler=$2
  3448. for ac_option in --version -v -V -qversion; do
  3449. { { ac_try="$ac_compiler $ac_option >&5"
  3450. case "(($ac_try" in
  3451. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  3452. *) ac_try_echo=$ac_try;;
  3453. esac
  3454. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  3455. $as_echo "$ac_try_echo"; } >&5
  3456. (eval "$ac_compiler $ac_option >&5") 2>conftest.err
  3457. ac_status=$?
  3458. if test -s conftest.err; then
  3459. sed '10a\
  3460. ... rest of stderr output deleted ...
  3461. 10q' conftest.err >conftest.er1
  3462. cat conftest.er1 >&5
  3463. fi
  3464. rm -f conftest.er1 conftest.err
  3465. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  3466. test $ac_status = 0; }
  3467. done
  3468. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3469. /* end confdefs.h. */
  3470. int
  3471. main ()
  3472. {
  3473. ;
  3474. return 0;
  3475. }
  3476. _ACEOF
  3477. ac_clean_files_save=$ac_clean_files
  3478. ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
  3479. # Try to create an executable without -o first, disregard a.out.
  3480. # It will help us diagnose broken compilers, and finding out an intuition
  3481. # of exeext.
  3482. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
  3483. $as_echo_n "checking whether the C compiler works... " >&6; }
  3484. ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
  3485. # The possible output files:
  3486. ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
  3487. ac_rmfiles=
  3488. for ac_file in $ac_files
  3489. do
  3490. case $ac_file in
  3491. *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
  3492. * ) ac_rmfiles="$ac_rmfiles $ac_file";;
  3493. esac
  3494. done
  3495. rm -f $ac_rmfiles
  3496. if { { ac_try="$ac_link_default"
  3497. case "(($ac_try" in
  3498. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  3499. *) ac_try_echo=$ac_try;;
  3500. esac
  3501. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  3502. $as_echo "$ac_try_echo"; } >&5
  3503. (eval "$ac_link_default") 2>&5
  3504. ac_status=$?
  3505. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  3506. test $ac_status = 0; }; then :
  3507. # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
  3508. # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
  3509. # in a Makefile. We should not override ac_cv_exeext if it was cached,
  3510. # so that the user can short-circuit this test for compilers unknown to
  3511. # Autoconf.
  3512. for ac_file in $ac_files ''
  3513. do
  3514. test -f "$ac_file" || continue
  3515. case $ac_file in
  3516. *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
  3517. ;;
  3518. [ab].out )
  3519. # We found the default executable, but exeext='' is most
  3520. # certainly right.
  3521. break;;
  3522. *.* )
  3523. if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
  3524. then :; else
  3525. ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
  3526. fi
  3527. # We set ac_cv_exeext here because the later test for it is not
  3528. # safe: cross compilers may not add the suffix if given an `-o'
  3529. # argument, so we may need to know it at that point already.
  3530. # Even if this section looks crufty: it has the advantage of
  3531. # actually working.
  3532. break;;
  3533. * )
  3534. break;;
  3535. esac
  3536. done
  3537. test "$ac_cv_exeext" = no && ac_cv_exeext=
  3538. else
  3539. ac_file=''
  3540. fi
  3541. if test -z "$ac_file"; then :
  3542. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  3543. $as_echo "no" >&6; }
  3544. $as_echo "$as_me: failed program was:" >&5
  3545. sed 's/^/| /' conftest.$ac_ext >&5
  3546. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  3547. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  3548. as_fn_error 77 "C compiler cannot create executables
  3549. See \`config.log' for more details" "$LINENO" 5; }
  3550. else
  3551. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  3552. $as_echo "yes" >&6; }
  3553. fi
  3554. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
  3555. $as_echo_n "checking for C compiler default output file name... " >&6; }
  3556. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
  3557. $as_echo "$ac_file" >&6; }
  3558. ac_exeext=$ac_cv_exeext
  3559. rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
  3560. ac_clean_files=$ac_clean_files_save
  3561. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
  3562. $as_echo_n "checking for suffix of executables... " >&6; }
  3563. if { { ac_try="$ac_link"
  3564. case "(($ac_try" in
  3565. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  3566. *) ac_try_echo=$ac_try;;
  3567. esac
  3568. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  3569. $as_echo "$ac_try_echo"; } >&5
  3570. (eval "$ac_link") 2>&5
  3571. ac_status=$?
  3572. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  3573. test $ac_status = 0; }; then :
  3574. # If both `conftest.exe' and `conftest' are `present' (well, observable)
  3575. # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
  3576. # work properly (i.e., refer to `conftest.exe'), while it won't with
  3577. # `rm'.
  3578. for ac_file in conftest.exe conftest conftest.*; do
  3579. test -f "$ac_file" || continue
  3580. case $ac_file in
  3581. *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
  3582. *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
  3583. break;;
  3584. * ) break;;
  3585. esac
  3586. done
  3587. else
  3588. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  3589. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  3590. as_fn_error $? "cannot compute suffix of executables: cannot compile and link
  3591. See \`config.log' for more details" "$LINENO" 5; }
  3592. fi
  3593. rm -f conftest conftest$ac_cv_exeext
  3594. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
  3595. $as_echo "$ac_cv_exeext" >&6; }
  3596. rm -f conftest.$ac_ext
  3597. EXEEXT=$ac_cv_exeext
  3598. ac_exeext=$EXEEXT
  3599. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3600. /* end confdefs.h. */
  3601. #include <stdio.h>
  3602. int
  3603. main ()
  3604. {
  3605. FILE *f = fopen ("conftest.out", "w");
  3606. return ferror (f) || fclose (f) != 0;
  3607. ;
  3608. return 0;
  3609. }
  3610. _ACEOF
  3611. ac_clean_files="$ac_clean_files conftest.out"
  3612. # Check that the compiler produces executables we can run. If not, either
  3613. # the compiler is broken, or we cross compile.
  3614. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
  3615. $as_echo_n "checking whether we are cross compiling... " >&6; }
  3616. if test "$cross_compiling" != yes; then
  3617. { { ac_try="$ac_link"
  3618. case "(($ac_try" in
  3619. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  3620. *) ac_try_echo=$ac_try;;
  3621. esac
  3622. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  3623. $as_echo "$ac_try_echo"; } >&5
  3624. (eval "$ac_link") 2>&5
  3625. ac_status=$?
  3626. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  3627. test $ac_status = 0; }
  3628. if { ac_try='./conftest$ac_cv_exeext'
  3629. { { case "(($ac_try" in
  3630. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  3631. *) ac_try_echo=$ac_try;;
  3632. esac
  3633. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  3634. $as_echo "$ac_try_echo"; } >&5
  3635. (eval "$ac_try") 2>&5
  3636. ac_status=$?
  3637. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  3638. test $ac_status = 0; }; }; then
  3639. cross_compiling=no
  3640. else
  3641. if test "$cross_compiling" = maybe; then
  3642. cross_compiling=yes
  3643. else
  3644. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  3645. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  3646. as_fn_error $? "cannot run C compiled programs.
  3647. If you meant to cross compile, use \`--host'.
  3648. See \`config.log' for more details" "$LINENO" 5; }
  3649. fi
  3650. fi
  3651. fi
  3652. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
  3653. $as_echo "$cross_compiling" >&6; }
  3654. rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
  3655. ac_clean_files=$ac_clean_files_save
  3656. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
  3657. $as_echo_n "checking for suffix of object files... " >&6; }
  3658. if ${ac_cv_objext+:} false; then :
  3659. $as_echo_n "(cached) " >&6
  3660. else
  3661. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3662. /* end confdefs.h. */
  3663. int
  3664. main ()
  3665. {
  3666. ;
  3667. return 0;
  3668. }
  3669. _ACEOF
  3670. rm -f conftest.o conftest.obj
  3671. if { { ac_try="$ac_compile"
  3672. case "(($ac_try" in
  3673. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  3674. *) ac_try_echo=$ac_try;;
  3675. esac
  3676. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  3677. $as_echo "$ac_try_echo"; } >&5
  3678. (eval "$ac_compile") 2>&5
  3679. ac_status=$?
  3680. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  3681. test $ac_status = 0; }; then :
  3682. for ac_file in conftest.o conftest.obj conftest.*; do
  3683. test -f "$ac_file" || continue;
  3684. case $ac_file in
  3685. *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
  3686. *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
  3687. break;;
  3688. esac
  3689. done
  3690. else
  3691. $as_echo "$as_me: failed program was:" >&5
  3692. sed 's/^/| /' conftest.$ac_ext >&5
  3693. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  3694. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  3695. as_fn_error $? "cannot compute suffix of object files: cannot compile
  3696. See \`config.log' for more details" "$LINENO" 5; }
  3697. fi
  3698. rm -f conftest.$ac_cv_objext conftest.$ac_ext
  3699. fi
  3700. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
  3701. $as_echo "$ac_cv_objext" >&6; }
  3702. OBJEXT=$ac_cv_objext
  3703. ac_objext=$OBJEXT
  3704. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
  3705. $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
  3706. if ${ac_cv_c_compiler_gnu+:} false; then :
  3707. $as_echo_n "(cached) " >&6
  3708. else
  3709. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3710. /* end confdefs.h. */
  3711. int
  3712. main ()
  3713. {
  3714. #ifndef __GNUC__
  3715. choke me
  3716. #endif
  3717. ;
  3718. return 0;
  3719. }
  3720. _ACEOF
  3721. if ac_fn_c_try_compile "$LINENO"; then :
  3722. ac_compiler_gnu=yes
  3723. else
  3724. ac_compiler_gnu=no
  3725. fi
  3726. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  3727. ac_cv_c_compiler_gnu=$ac_compiler_gnu
  3728. fi
  3729. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
  3730. $as_echo "$ac_cv_c_compiler_gnu" >&6; }
  3731. if test $ac_compiler_gnu = yes; then
  3732. GCC=yes
  3733. else
  3734. GCC=
  3735. fi
  3736. ac_test_CFLAGS=${CFLAGS+set}
  3737. ac_save_CFLAGS=$CFLAGS
  3738. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
  3739. $as_echo_n "checking whether $CC accepts -g... " >&6; }
  3740. if ${ac_cv_prog_cc_g+:} false; then :
  3741. $as_echo_n "(cached) " >&6
  3742. else
  3743. ac_save_c_werror_flag=$ac_c_werror_flag
  3744. ac_c_werror_flag=yes
  3745. ac_cv_prog_cc_g=no
  3746. CFLAGS="-g"
  3747. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3748. /* end confdefs.h. */
  3749. int
  3750. main ()
  3751. {
  3752. ;
  3753. return 0;
  3754. }
  3755. _ACEOF
  3756. if ac_fn_c_try_compile "$LINENO"; then :
  3757. ac_cv_prog_cc_g=yes
  3758. else
  3759. CFLAGS=""
  3760. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3761. /* end confdefs.h. */
  3762. int
  3763. main ()
  3764. {
  3765. ;
  3766. return 0;
  3767. }
  3768. _ACEOF
  3769. if ac_fn_c_try_compile "$LINENO"; then :
  3770. else
  3771. ac_c_werror_flag=$ac_save_c_werror_flag
  3772. CFLAGS="-g"
  3773. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3774. /* end confdefs.h. */
  3775. int
  3776. main ()
  3777. {
  3778. ;
  3779. return 0;
  3780. }
  3781. _ACEOF
  3782. if ac_fn_c_try_compile "$LINENO"; then :
  3783. ac_cv_prog_cc_g=yes
  3784. fi
  3785. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  3786. fi
  3787. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  3788. fi
  3789. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  3790. ac_c_werror_flag=$ac_save_c_werror_flag
  3791. fi
  3792. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
  3793. $as_echo "$ac_cv_prog_cc_g" >&6; }
  3794. if test "$ac_test_CFLAGS" = set; then
  3795. CFLAGS=$ac_save_CFLAGS
  3796. elif test $ac_cv_prog_cc_g = yes; then
  3797. if test "$GCC" = yes; then
  3798. CFLAGS="-g -O2"
  3799. else
  3800. CFLAGS="-g"
  3801. fi
  3802. else
  3803. if test "$GCC" = yes; then
  3804. CFLAGS="-O2"
  3805. else
  3806. CFLAGS=
  3807. fi
  3808. fi
  3809. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
  3810. $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
  3811. if ${ac_cv_prog_cc_c89+:} false; then :
  3812. $as_echo_n "(cached) " >&6
  3813. else
  3814. ac_cv_prog_cc_c89=no
  3815. ac_save_CC=$CC
  3816. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3817. /* end confdefs.h. */
  3818. #include <stdarg.h>
  3819. #include <stdio.h>
  3820. struct stat;
  3821. /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
  3822. struct buf { int x; };
  3823. FILE * (*rcsopen) (struct buf *, struct stat *, int);
  3824. static char *e (p, i)
  3825. char **p;
  3826. int i;
  3827. {
  3828. return p[i];
  3829. }
  3830. static char *f (char * (*g) (char **, int), char **p, ...)
  3831. {
  3832. char *s;
  3833. va_list v;
  3834. va_start (v,p);
  3835. s = g (p, va_arg (v,int));
  3836. va_end (v);
  3837. return s;
  3838. }
  3839. /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
  3840. function prototypes and stuff, but not '\xHH' hex character constants.
  3841. These don't provoke an error unfortunately, instead are silently treated
  3842. as 'x'. The following induces an error, until -std is added to get
  3843. proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
  3844. array size at least. It's necessary to write '\x00'==0 to get something
  3845. that's true only with -std. */
  3846. int osf4_cc_array ['\x00' == 0 ? 1 : -1];
  3847. /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
  3848. inside strings and character constants. */
  3849. #define FOO(x) 'x'
  3850. int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
  3851. int test (int i, double x);
  3852. struct s1 {int (*f) (int a);};
  3853. struct s2 {int (*f) (double a);};
  3854. int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
  3855. int argc;
  3856. char **argv;
  3857. int
  3858. main ()
  3859. {
  3860. return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
  3861. ;
  3862. return 0;
  3863. }
  3864. _ACEOF
  3865. for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
  3866. -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
  3867. do
  3868. CC="$ac_save_CC $ac_arg"
  3869. if ac_fn_c_try_compile "$LINENO"; then :
  3870. ac_cv_prog_cc_c89=$ac_arg
  3871. fi
  3872. rm -f core conftest.err conftest.$ac_objext
  3873. test "x$ac_cv_prog_cc_c89" != "xno" && break
  3874. done
  3875. rm -f conftest.$ac_ext
  3876. CC=$ac_save_CC
  3877. fi
  3878. # AC_CACHE_VAL
  3879. case "x$ac_cv_prog_cc_c89" in
  3880. x)
  3881. { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
  3882. $as_echo "none needed" >&6; } ;;
  3883. xno)
  3884. { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
  3885. $as_echo "unsupported" >&6; } ;;
  3886. *)
  3887. CC="$CC $ac_cv_prog_cc_c89"
  3888. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
  3889. $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
  3890. esac
  3891. if test "x$ac_cv_prog_cc_c89" != xno; then :
  3892. fi
  3893. ac_ext=c
  3894. ac_cpp='$CPP $CPPFLAGS'
  3895. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  3896. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  3897. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  3898. ac_ext=c
  3899. ac_cpp='$CPP $CPPFLAGS'
  3900. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  3901. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  3902. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  3903. { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
  3904. $as_echo_n "checking how to run the C preprocessor... " >&6; }
  3905. # On Suns, sometimes $CPP names a directory.
  3906. if test -n "$CPP" && test -d "$CPP"; then
  3907. CPP=
  3908. fi
  3909. if test -z "$CPP"; then
  3910. if ${ac_cv_prog_CPP+:} false; then :
  3911. $as_echo_n "(cached) " >&6
  3912. else
  3913. # Double quotes because CPP needs to be expanded
  3914. for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
  3915. do
  3916. ac_preproc_ok=false
  3917. for ac_c_preproc_warn_flag in '' yes
  3918. do
  3919. # Use a header file that comes with gcc, so configuring glibc
  3920. # with a fresh cross-compiler works.
  3921. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  3922. # <limits.h> exists even on freestanding compilers.
  3923. # On the NeXT, cc -E runs the code through the compiler's parser,
  3924. # not just through cpp. "Syntax error" is here to catch this case.
  3925. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3926. /* end confdefs.h. */
  3927. #ifdef __STDC__
  3928. # include <limits.h>
  3929. #else
  3930. # include <assert.h>
  3931. #endif
  3932. Syntax error
  3933. _ACEOF
  3934. if ac_fn_c_try_cpp "$LINENO"; then :
  3935. else
  3936. # Broken: fails on valid input.
  3937. continue
  3938. fi
  3939. rm -f conftest.err conftest.i conftest.$ac_ext
  3940. # OK, works on sane cases. Now check whether nonexistent headers
  3941. # can be detected and how.
  3942. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3943. /* end confdefs.h. */
  3944. #include <ac_nonexistent.h>
  3945. _ACEOF
  3946. if ac_fn_c_try_cpp "$LINENO"; then :
  3947. # Broken: success on invalid input.
  3948. continue
  3949. else
  3950. # Passes both tests.
  3951. ac_preproc_ok=:
  3952. break
  3953. fi
  3954. rm -f conftest.err conftest.i conftest.$ac_ext
  3955. done
  3956. # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
  3957. rm -f conftest.i conftest.err conftest.$ac_ext
  3958. if $ac_preproc_ok; then :
  3959. break
  3960. fi
  3961. done
  3962. ac_cv_prog_CPP=$CPP
  3963. fi
  3964. CPP=$ac_cv_prog_CPP
  3965. else
  3966. ac_cv_prog_CPP=$CPP
  3967. fi
  3968. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
  3969. $as_echo "$CPP" >&6; }
  3970. ac_preproc_ok=false
  3971. for ac_c_preproc_warn_flag in '' yes
  3972. do
  3973. # Use a header file that comes with gcc, so configuring glibc
  3974. # with a fresh cross-compiler works.
  3975. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  3976. # <limits.h> exists even on freestanding compilers.
  3977. # On the NeXT, cc -E runs the code through the compiler's parser,
  3978. # not just through cpp. "Syntax error" is here to catch this case.
  3979. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3980. /* end confdefs.h. */
  3981. #ifdef __STDC__
  3982. # include <limits.h>
  3983. #else
  3984. # include <assert.h>
  3985. #endif
  3986. Syntax error
  3987. _ACEOF
  3988. if ac_fn_c_try_cpp "$LINENO"; then :
  3989. else
  3990. # Broken: fails on valid input.
  3991. continue
  3992. fi
  3993. rm -f conftest.err conftest.i conftest.$ac_ext
  3994. # OK, works on sane cases. Now check whether nonexistent headers
  3995. # can be detected and how.
  3996. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3997. /* end confdefs.h. */
  3998. #include <ac_nonexistent.h>
  3999. _ACEOF
  4000. if ac_fn_c_try_cpp "$LINENO"; then :
  4001. # Broken: success on invalid input.
  4002. continue
  4003. else
  4004. # Passes both tests.
  4005. ac_preproc_ok=:
  4006. break
  4007. fi
  4008. rm -f conftest.err conftest.i conftest.$ac_ext
  4009. done
  4010. # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
  4011. rm -f conftest.i conftest.err conftest.$ac_ext
  4012. if $ac_preproc_ok; then :
  4013. else
  4014. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  4015. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  4016. as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
  4017. See \`config.log' for more details" "$LINENO" 5; }
  4018. fi
  4019. ac_ext=c
  4020. ac_cpp='$CPP $CPPFLAGS'
  4021. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  4022. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  4023. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  4024. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
  4025. $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
  4026. if ${ac_cv_path_GREP+:} false; then :
  4027. $as_echo_n "(cached) " >&6
  4028. else
  4029. if test -z "$GREP"; then
  4030. ac_path_GREP_found=false
  4031. # Loop through the user's path and test for each of PROGNAME-LIST
  4032. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4033. for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
  4034. do
  4035. IFS=$as_save_IFS
  4036. test -z "$as_dir" && as_dir=.
  4037. for ac_prog in grep ggrep; do
  4038. for ac_exec_ext in '' $ac_executable_extensions; do
  4039. ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
  4040. as_fn_executable_p "$ac_path_GREP" || continue
  4041. # Check for GNU ac_path_GREP and select it if it is found.
  4042. # Check for GNU $ac_path_GREP
  4043. case `"$ac_path_GREP" --version 2>&1` in
  4044. *GNU*)
  4045. ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
  4046. *)
  4047. ac_count=0
  4048. $as_echo_n 0123456789 >"conftest.in"
  4049. while :
  4050. do
  4051. cat "conftest.in" "conftest.in" >"conftest.tmp"
  4052. mv "conftest.tmp" "conftest.in"
  4053. cp "conftest.in" "conftest.nl"
  4054. $as_echo 'GREP' >> "conftest.nl"
  4055. "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
  4056. diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
  4057. as_fn_arith $ac_count + 1 && ac_count=$as_val
  4058. if test $ac_count -gt ${ac_path_GREP_max-0}; then
  4059. # Best one so far, save it but keep looking for a better one
  4060. ac_cv_path_GREP="$ac_path_GREP"
  4061. ac_path_GREP_max=$ac_count
  4062. fi
  4063. # 10*(2^10) chars as input seems more than enough
  4064. test $ac_count -gt 10 && break
  4065. done
  4066. rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
  4067. esac
  4068. $ac_path_GREP_found && break 3
  4069. done
  4070. done
  4071. done
  4072. IFS=$as_save_IFS
  4073. if test -z "$ac_cv_path_GREP"; then
  4074. as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
  4075. fi
  4076. else
  4077. ac_cv_path_GREP=$GREP
  4078. fi
  4079. fi
  4080. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
  4081. $as_echo "$ac_cv_path_GREP" >&6; }
  4082. GREP="$ac_cv_path_GREP"
  4083. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
  4084. $as_echo_n "checking for egrep... " >&6; }
  4085. if ${ac_cv_path_EGREP+:} false; then :
  4086. $as_echo_n "(cached) " >&6
  4087. else
  4088. if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
  4089. then ac_cv_path_EGREP="$GREP -E"
  4090. else
  4091. if test -z "$EGREP"; then
  4092. ac_path_EGREP_found=false
  4093. # Loop through the user's path and test for each of PROGNAME-LIST
  4094. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4095. for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
  4096. do
  4097. IFS=$as_save_IFS
  4098. test -z "$as_dir" && as_dir=.
  4099. for ac_prog in egrep; do
  4100. for ac_exec_ext in '' $ac_executable_extensions; do
  4101. ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
  4102. as_fn_executable_p "$ac_path_EGREP" || continue
  4103. # Check for GNU ac_path_EGREP and select it if it is found.
  4104. # Check for GNU $ac_path_EGREP
  4105. case `"$ac_path_EGREP" --version 2>&1` in
  4106. *GNU*)
  4107. ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
  4108. *)
  4109. ac_count=0
  4110. $as_echo_n 0123456789 >"conftest.in"
  4111. while :
  4112. do
  4113. cat "conftest.in" "conftest.in" >"conftest.tmp"
  4114. mv "conftest.tmp" "conftest.in"
  4115. cp "conftest.in" "conftest.nl"
  4116. $as_echo 'EGREP' >> "conftest.nl"
  4117. "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
  4118. diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
  4119. as_fn_arith $ac_count + 1 && ac_count=$as_val
  4120. if test $ac_count -gt ${ac_path_EGREP_max-0}; then
  4121. # Best one so far, save it but keep looking for a better one
  4122. ac_cv_path_EGREP="$ac_path_EGREP"
  4123. ac_path_EGREP_max=$ac_count
  4124. fi
  4125. # 10*(2^10) chars as input seems more than enough
  4126. test $ac_count -gt 10 && break
  4127. done
  4128. rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
  4129. esac
  4130. $ac_path_EGREP_found && break 3
  4131. done
  4132. done
  4133. done
  4134. IFS=$as_save_IFS
  4135. if test -z "$ac_cv_path_EGREP"; then
  4136. as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
  4137. fi
  4138. else
  4139. ac_cv_path_EGREP=$EGREP
  4140. fi
  4141. fi
  4142. fi
  4143. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
  4144. $as_echo "$ac_cv_path_EGREP" >&6; }
  4145. EGREP="$ac_cv_path_EGREP"
  4146. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
  4147. $as_echo_n "checking for ANSI C header files... " >&6; }
  4148. if ${ac_cv_header_stdc+:} false; then :
  4149. $as_echo_n "(cached) " >&6
  4150. else
  4151. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  4152. /* end confdefs.h. */
  4153. #include <stdlib.h>
  4154. #include <stdarg.h>
  4155. #include <string.h>
  4156. #include <float.h>
  4157. int
  4158. main ()
  4159. {
  4160. ;
  4161. return 0;
  4162. }
  4163. _ACEOF
  4164. if ac_fn_c_try_compile "$LINENO"; then :
  4165. ac_cv_header_stdc=yes
  4166. else
  4167. ac_cv_header_stdc=no
  4168. fi
  4169. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  4170. if test $ac_cv_header_stdc = yes; then
  4171. # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
  4172. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  4173. /* end confdefs.h. */
  4174. #include <string.h>
  4175. _ACEOF
  4176. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  4177. $EGREP "memchr" >/dev/null 2>&1; then :
  4178. else
  4179. ac_cv_header_stdc=no
  4180. fi
  4181. rm -f conftest*
  4182. fi
  4183. if test $ac_cv_header_stdc = yes; then
  4184. # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
  4185. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  4186. /* end confdefs.h. */
  4187. #include <stdlib.h>
  4188. _ACEOF
  4189. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  4190. $EGREP "free" >/dev/null 2>&1; then :
  4191. else
  4192. ac_cv_header_stdc=no
  4193. fi
  4194. rm -f conftest*
  4195. fi
  4196. if test $ac_cv_header_stdc = yes; then
  4197. # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
  4198. if test "$cross_compiling" = yes; then :
  4199. :
  4200. else
  4201. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  4202. /* end confdefs.h. */
  4203. #include <ctype.h>
  4204. #include <stdlib.h>
  4205. #if ((' ' & 0x0FF) == 0x020)
  4206. # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
  4207. # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
  4208. #else
  4209. # define ISLOWER(c) \
  4210. (('a' <= (c) && (c) <= 'i') \
  4211. || ('j' <= (c) && (c) <= 'r') \
  4212. || ('s' <= (c) && (c) <= 'z'))
  4213. # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
  4214. #endif
  4215. #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
  4216. int
  4217. main ()
  4218. {
  4219. int i;
  4220. for (i = 0; i < 256; i++)
  4221. if (XOR (islower (i), ISLOWER (i))
  4222. || toupper (i) != TOUPPER (i))
  4223. return 2;
  4224. return 0;
  4225. }
  4226. _ACEOF
  4227. if ac_fn_c_try_run "$LINENO"; then :
  4228. else
  4229. ac_cv_header_stdc=no
  4230. fi
  4231. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  4232. conftest.$ac_objext conftest.beam conftest.$ac_ext
  4233. fi
  4234. fi
  4235. fi
  4236. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
  4237. $as_echo "$ac_cv_header_stdc" >&6; }
  4238. if test $ac_cv_header_stdc = yes; then
  4239. $as_echo "#define STDC_HEADERS 1" >>confdefs.h
  4240. fi
  4241. # On IRIX 5.3, sys/types and inttypes.h are conflicting.
  4242. for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
  4243. inttypes.h stdint.h unistd.h
  4244. do :
  4245. as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
  4246. ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
  4247. "
  4248. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  4249. cat >>confdefs.h <<_ACEOF
  4250. #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
  4251. _ACEOF
  4252. fi
  4253. done
  4254. ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
  4255. if test "x$ac_cv_header_minix_config_h" = xyes; then :
  4256. MINIX=yes
  4257. else
  4258. MINIX=
  4259. fi
  4260. if test "$MINIX" = yes; then
  4261. $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
  4262. $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
  4263. $as_echo "#define _MINIX 1" >>confdefs.h
  4264. fi
  4265. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
  4266. $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
  4267. if ${ac_cv_safe_to_define___extensions__+:} false; then :
  4268. $as_echo_n "(cached) " >&6
  4269. else
  4270. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  4271. /* end confdefs.h. */
  4272. # define __EXTENSIONS__ 1
  4273. $ac_includes_default
  4274. int
  4275. main ()
  4276. {
  4277. ;
  4278. return 0;
  4279. }
  4280. _ACEOF
  4281. if ac_fn_c_try_compile "$LINENO"; then :
  4282. ac_cv_safe_to_define___extensions__=yes
  4283. else
  4284. ac_cv_safe_to_define___extensions__=no
  4285. fi
  4286. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  4287. fi
  4288. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
  4289. $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
  4290. test $ac_cv_safe_to_define___extensions__ = yes &&
  4291. $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
  4292. $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
  4293. $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
  4294. $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
  4295. $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
  4296. # System default paths
  4297. astsbindir='${sbindir}'
  4298. astetcdir='${sysconfdir}/asterisk'
  4299. astheaderdir='${includedir}/asterisk'
  4300. astlibdir='${libdir}'
  4301. astmoddir='${libdir}/asterisk/modules'
  4302. astmandir='${mandir}'
  4303. astvarlibdir='${localstatedir}/lib/asterisk'
  4304. astdatadir='${astvarlibdir}'
  4305. astdbdir='${astvarlibdir}'
  4306. astkeydir='${astvarlibdir}'
  4307. astspooldir='${localstatedir}/spool/asterisk'
  4308. astlogdir='${localstatedir}/log/asterisk'
  4309. astvarrundir='${localstatedir}/run/asterisk'
  4310. case "${host_os}" in
  4311. *bsd*)
  4312. if test ${prefix} = 'NONE'; then
  4313. astvarlibdir='${prefix}/share/asterisk'
  4314. astdbdir='${localstatedir}/db/asterisk'
  4315. fi
  4316. ;;
  4317. darwin*)
  4318. if test ${prefix} = 'NONE'; then
  4319. astvarrundir='/Library/Application Support/Asterisk/Run'
  4320. fi
  4321. ;;
  4322. esac
  4323. case "${host_os}" in
  4324. freebsd*)
  4325. ac_default_prefix=/usr/local
  4326. CPPFLAGS=-I/usr/local/include
  4327. LDFLAGS=-L/usr/local/lib
  4328. ;;
  4329. openbsd*)
  4330. ac_default_prefix=/usr/local
  4331. if test ${prefix} = '/usr/local' || test ${prefix} = 'NONE'; then
  4332. if test ${sysconfdir} = '${prefix}/etc'; then
  4333. astetcdir=/etc/asterisk
  4334. fi
  4335. if test ${mandir} = '${prefix}/man'; then
  4336. astmandir=/usr/share/man
  4337. fi
  4338. fi
  4339. CPPFLAGS=-I/usr/local/include
  4340. LDFLAGS=-L/usr/local/lib
  4341. ;;
  4342. darwin*)
  4343. ac_default_prefix=/usr/local
  4344. if test ${prefix} = 'NONE'; then
  4345. astmoddir='/Library/Application Support/Asterisk/Modules'
  4346. astvarlibdir='/Library/Application Support/Asterisk'
  4347. astlogdir=/Library/Logs/Asterisk
  4348. astvarrundir='/Library/Application Support/Asterisk/Run'
  4349. fi
  4350. $as_echo "#define AST_POLL_COMPAT 1" >>confdefs.h
  4351. $as_echo "#define _DARWIN_UNLIMITED_SELECT 1" >>confdefs.h
  4352. ;;
  4353. solaris*)
  4354. if test ${prefix} = 'NONE'; then
  4355. astetcdir=/var/etc/asterisk
  4356. astsbindir=/opt/asterisk/sbin
  4357. astlibdir=/opt/asterisk/lib
  4358. astmoddir=/opt/asterisk/lib/modules
  4359. astheaderdir=/opt/asterisk/include
  4360. astmandir=/opt/asterisk/man
  4361. astvarlibdir=/var/opt/asterisk
  4362. astspooldir=/var/spool/asterisk
  4363. astlogdir=/var/log/asterisk
  4364. astvarrundir=/var/run/asterisk
  4365. fi
  4366. ;;
  4367. *)
  4368. ac_default_prefix=/usr
  4369. if test ${prefix} = '/usr' || test ${prefix} = 'NONE'; then
  4370. if test ${sysconfdir} = '${prefix}/etc'; then
  4371. sysconfdir=/etc
  4372. fi
  4373. if test ${mandir} = '${prefix}/man'; then
  4374. mandir=/usr/share/man
  4375. fi
  4376. fi
  4377. ;;
  4378. esac
  4379. if test ${prefix} = ${ac_default_prefix} || test ${prefix} = 'NONE'; then
  4380. if test ${localstatedir} = '${prefix}/var'; then
  4381. localstatedir=/var
  4382. fi
  4383. fi
  4384. BUILD_PLATFORM=${build}
  4385. BUILD_CPU=${build_cpu}
  4386. BUILD_VENDOR=${build_vendor}
  4387. BUILD_OS=${build_os}
  4388. HOST_PLATFORM=${host}
  4389. HOST_CPU=${host_cpu}
  4390. HOST_VENDOR=${host_vendor}
  4391. HOST_OS=${host_os}
  4392. PBX_WINARCH=0
  4393. case "${host_os}" in
  4394. freebsd*)
  4395. OSARCH=FreeBSD
  4396. ;;
  4397. netbsd*)
  4398. OSARCH=NetBSD
  4399. ;;
  4400. openbsd*)
  4401. OSARCH=OpenBSD
  4402. ;;
  4403. solaris*)
  4404. OSARCH=SunOS
  4405. ;;
  4406. mingw32)
  4407. OSARCH=mingw32
  4408. PBX_WINARCH=1
  4409. ;;
  4410. cygwin)
  4411. OSARCH=cygwin
  4412. PBX_WINARCH=1
  4413. ;;
  4414. linux-gnueabi* | linux-gnuspe)
  4415. OSARCH=linux-gnu
  4416. ;;
  4417. kfreebsd*-gnu)
  4418. OSARCH=kfreebsd-gnu
  4419. ;;
  4420. *)
  4421. OSARCH=${host_os}
  4422. ;;
  4423. esac
  4424. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5
  4425. $as_echo_n "checking whether char is unsigned... " >&6; }
  4426. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  4427. /* end confdefs.h. */
  4428. #include <limits.h>
  4429. #if CHAR_MIN == 0
  4430. #error
  4431. #endif
  4432. _ACEOF
  4433. if ac_fn_c_try_compile "$LINENO"; then :
  4434. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4435. $as_echo "no" >&6; }
  4436. CONFIG_SIGNED_CHAR=""
  4437. else
  4438. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  4439. $as_echo "yes" >&6; }
  4440. CONFIG_SIGNED_CHAR="-fsigned-char"
  4441. fi
  4442. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  4443. # check for uname
  4444. if test -n "$ac_tool_prefix"; then
  4445. # Extract the first word of "${ac_tool_prefix}uname", so it can be a program name with args.
  4446. set dummy ${ac_tool_prefix}uname; ac_word=$2
  4447. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4448. $as_echo_n "checking for $ac_word... " >&6; }
  4449. if ${ac_cv_path_UNAME+:} false; then :
  4450. $as_echo_n "(cached) " >&6
  4451. else
  4452. case $UNAME in
  4453. [\\/]* | ?:[\\/]*)
  4454. ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
  4455. ;;
  4456. *)
  4457. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4458. for as_dir in $PATH
  4459. do
  4460. IFS=$as_save_IFS
  4461. test -z "$as_dir" && as_dir=.
  4462. for ac_exec_ext in '' $ac_executable_extensions; do
  4463. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4464. ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
  4465. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4466. break 2
  4467. fi
  4468. done
  4469. done
  4470. IFS=$as_save_IFS
  4471. ;;
  4472. esac
  4473. fi
  4474. UNAME=$ac_cv_path_UNAME
  4475. if test -n "$UNAME"; then
  4476. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
  4477. $as_echo "$UNAME" >&6; }
  4478. else
  4479. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4480. $as_echo "no" >&6; }
  4481. fi
  4482. fi
  4483. if test -z "$ac_cv_path_UNAME"; then
  4484. ac_pt_UNAME=$UNAME
  4485. # Extract the first word of "uname", so it can be a program name with args.
  4486. set dummy uname; ac_word=$2
  4487. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4488. $as_echo_n "checking for $ac_word... " >&6; }
  4489. if ${ac_cv_path_ac_pt_UNAME+:} false; then :
  4490. $as_echo_n "(cached) " >&6
  4491. else
  4492. case $ac_pt_UNAME in
  4493. [\\/]* | ?:[\\/]*)
  4494. ac_cv_path_ac_pt_UNAME="$ac_pt_UNAME" # Let the user override the test with a path.
  4495. ;;
  4496. *)
  4497. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4498. for as_dir in $PATH
  4499. do
  4500. IFS=$as_save_IFS
  4501. test -z "$as_dir" && as_dir=.
  4502. for ac_exec_ext in '' $ac_executable_extensions; do
  4503. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4504. ac_cv_path_ac_pt_UNAME="$as_dir/$ac_word$ac_exec_ext"
  4505. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4506. break 2
  4507. fi
  4508. done
  4509. done
  4510. IFS=$as_save_IFS
  4511. ;;
  4512. esac
  4513. fi
  4514. ac_pt_UNAME=$ac_cv_path_ac_pt_UNAME
  4515. if test -n "$ac_pt_UNAME"; then
  4516. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_UNAME" >&5
  4517. $as_echo "$ac_pt_UNAME" >&6; }
  4518. else
  4519. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4520. $as_echo "no" >&6; }
  4521. fi
  4522. if test "x$ac_pt_UNAME" = x; then
  4523. UNAME="No"
  4524. else
  4525. case $cross_compiling:$ac_tool_warned in
  4526. yes:)
  4527. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  4528. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  4529. ac_tool_warned=yes ;;
  4530. esac
  4531. UNAME=$ac_pt_UNAME
  4532. fi
  4533. else
  4534. UNAME="$ac_cv_path_UNAME"
  4535. fi
  4536. if test ! x"${UNAME}" = xNo; then
  4537. PBX_OSREV=$(${UNAME} -r)
  4538. fi
  4539. # cross-compile checks
  4540. if test "${cross_compiling}" = "yes";
  4541. then
  4542. if test -n "$ac_tool_prefix"; then
  4543. # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
  4544. set dummy ${ac_tool_prefix}gcc; ac_word=$2
  4545. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4546. $as_echo_n "checking for $ac_word... " >&6; }
  4547. if ${ac_cv_prog_CC+:} false; then :
  4548. $as_echo_n "(cached) " >&6
  4549. else
  4550. if test -n "$CC"; then
  4551. ac_cv_prog_CC="$CC" # Let the user override the test.
  4552. else
  4553. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4554. for as_dir in $PATH
  4555. do
  4556. IFS=$as_save_IFS
  4557. test -z "$as_dir" && as_dir=.
  4558. for ac_exec_ext in '' $ac_executable_extensions; do
  4559. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4560. ac_cv_prog_CC="${ac_tool_prefix}gcc"
  4561. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4562. break 2
  4563. fi
  4564. done
  4565. done
  4566. IFS=$as_save_IFS
  4567. fi
  4568. fi
  4569. CC=$ac_cv_prog_CC
  4570. if test -n "$CC"; then
  4571. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
  4572. $as_echo "$CC" >&6; }
  4573. else
  4574. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4575. $as_echo "no" >&6; }
  4576. fi
  4577. fi
  4578. if test -z "$ac_cv_prog_CC"; then
  4579. ac_ct_CC=$CC
  4580. # Extract the first word of "gcc", so it can be a program name with args.
  4581. set dummy gcc; ac_word=$2
  4582. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4583. $as_echo_n "checking for $ac_word... " >&6; }
  4584. if ${ac_cv_prog_ac_ct_CC+:} false; then :
  4585. $as_echo_n "(cached) " >&6
  4586. else
  4587. if test -n "$ac_ct_CC"; then
  4588. ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
  4589. else
  4590. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4591. for as_dir in $PATH
  4592. do
  4593. IFS=$as_save_IFS
  4594. test -z "$as_dir" && as_dir=.
  4595. for ac_exec_ext in '' $ac_executable_extensions; do
  4596. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4597. ac_cv_prog_ac_ct_CC="gcc"
  4598. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4599. break 2
  4600. fi
  4601. done
  4602. done
  4603. IFS=$as_save_IFS
  4604. fi
  4605. fi
  4606. ac_ct_CC=$ac_cv_prog_ac_ct_CC
  4607. if test -n "$ac_ct_CC"; then
  4608. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
  4609. $as_echo "$ac_ct_CC" >&6; }
  4610. else
  4611. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4612. $as_echo "no" >&6; }
  4613. fi
  4614. if test "x$ac_ct_CC" = x; then
  4615. CC=":"
  4616. else
  4617. case $cross_compiling:$ac_tool_warned in
  4618. yes:)
  4619. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  4620. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  4621. ac_tool_warned=yes ;;
  4622. esac
  4623. CC=$ac_ct_CC
  4624. fi
  4625. else
  4626. CC="$ac_cv_prog_CC"
  4627. fi
  4628. if test -n "$ac_tool_prefix"; then
  4629. # Extract the first word of "${ac_tool_prefix}g++", so it can be a program name with args.
  4630. set dummy ${ac_tool_prefix}g++; ac_word=$2
  4631. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4632. $as_echo_n "checking for $ac_word... " >&6; }
  4633. if ${ac_cv_prog_CXX+:} false; then :
  4634. $as_echo_n "(cached) " >&6
  4635. else
  4636. if test -n "$CXX"; then
  4637. ac_cv_prog_CXX="$CXX" # Let the user override the test.
  4638. else
  4639. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4640. for as_dir in $PATH
  4641. do
  4642. IFS=$as_save_IFS
  4643. test -z "$as_dir" && as_dir=.
  4644. for ac_exec_ext in '' $ac_executable_extensions; do
  4645. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4646. ac_cv_prog_CXX="${ac_tool_prefix}g++"
  4647. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4648. break 2
  4649. fi
  4650. done
  4651. done
  4652. IFS=$as_save_IFS
  4653. fi
  4654. fi
  4655. CXX=$ac_cv_prog_CXX
  4656. if test -n "$CXX"; then
  4657. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
  4658. $as_echo "$CXX" >&6; }
  4659. else
  4660. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4661. $as_echo "no" >&6; }
  4662. fi
  4663. fi
  4664. if test -z "$ac_cv_prog_CXX"; then
  4665. ac_ct_CXX=$CXX
  4666. # Extract the first word of "g++", so it can be a program name with args.
  4667. set dummy g++; ac_word=$2
  4668. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4669. $as_echo_n "checking for $ac_word... " >&6; }
  4670. if ${ac_cv_prog_ac_ct_CXX+:} false; then :
  4671. $as_echo_n "(cached) " >&6
  4672. else
  4673. if test -n "$ac_ct_CXX"; then
  4674. ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
  4675. else
  4676. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4677. for as_dir in $PATH
  4678. do
  4679. IFS=$as_save_IFS
  4680. test -z "$as_dir" && as_dir=.
  4681. for ac_exec_ext in '' $ac_executable_extensions; do
  4682. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4683. ac_cv_prog_ac_ct_CXX="g++"
  4684. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4685. break 2
  4686. fi
  4687. done
  4688. done
  4689. IFS=$as_save_IFS
  4690. fi
  4691. fi
  4692. ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
  4693. if test -n "$ac_ct_CXX"; then
  4694. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
  4695. $as_echo "$ac_ct_CXX" >&6; }
  4696. else
  4697. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4698. $as_echo "no" >&6; }
  4699. fi
  4700. if test "x$ac_ct_CXX" = x; then
  4701. CXX=":"
  4702. else
  4703. case $cross_compiling:$ac_tool_warned in
  4704. yes:)
  4705. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  4706. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  4707. ac_tool_warned=yes ;;
  4708. esac
  4709. CXX=$ac_ct_CXX
  4710. fi
  4711. else
  4712. CXX="$ac_cv_prog_CXX"
  4713. fi
  4714. if test -n "$ac_tool_prefix"; then
  4715. # Extract the first word of "${ac_tool_prefix}ld", so it can be a program name with args.
  4716. set dummy ${ac_tool_prefix}ld; ac_word=$2
  4717. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4718. $as_echo_n "checking for $ac_word... " >&6; }
  4719. if ${ac_cv_prog_LD+:} false; then :
  4720. $as_echo_n "(cached) " >&6
  4721. else
  4722. if test -n "$LD"; then
  4723. ac_cv_prog_LD="$LD" # Let the user override the test.
  4724. else
  4725. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4726. for as_dir in $PATH
  4727. do
  4728. IFS=$as_save_IFS
  4729. test -z "$as_dir" && as_dir=.
  4730. for ac_exec_ext in '' $ac_executable_extensions; do
  4731. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4732. ac_cv_prog_LD="${ac_tool_prefix}ld"
  4733. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4734. break 2
  4735. fi
  4736. done
  4737. done
  4738. IFS=$as_save_IFS
  4739. fi
  4740. fi
  4741. LD=$ac_cv_prog_LD
  4742. if test -n "$LD"; then
  4743. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
  4744. $as_echo "$LD" >&6; }
  4745. else
  4746. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4747. $as_echo "no" >&6; }
  4748. fi
  4749. fi
  4750. if test -z "$ac_cv_prog_LD"; then
  4751. ac_ct_LD=$LD
  4752. # Extract the first word of "ld", so it can be a program name with args.
  4753. set dummy ld; ac_word=$2
  4754. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4755. $as_echo_n "checking for $ac_word... " >&6; }
  4756. if ${ac_cv_prog_ac_ct_LD+:} false; then :
  4757. $as_echo_n "(cached) " >&6
  4758. else
  4759. if test -n "$ac_ct_LD"; then
  4760. ac_cv_prog_ac_ct_LD="$ac_ct_LD" # Let the user override the test.
  4761. else
  4762. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4763. for as_dir in $PATH
  4764. do
  4765. IFS=$as_save_IFS
  4766. test -z "$as_dir" && as_dir=.
  4767. for ac_exec_ext in '' $ac_executable_extensions; do
  4768. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4769. ac_cv_prog_ac_ct_LD="ld"
  4770. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4771. break 2
  4772. fi
  4773. done
  4774. done
  4775. IFS=$as_save_IFS
  4776. fi
  4777. fi
  4778. ac_ct_LD=$ac_cv_prog_ac_ct_LD
  4779. if test -n "$ac_ct_LD"; then
  4780. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LD" >&5
  4781. $as_echo "$ac_ct_LD" >&6; }
  4782. else
  4783. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4784. $as_echo "no" >&6; }
  4785. fi
  4786. if test "x$ac_ct_LD" = x; then
  4787. LD=":"
  4788. else
  4789. case $cross_compiling:$ac_tool_warned in
  4790. yes:)
  4791. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  4792. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  4793. ac_tool_warned=yes ;;
  4794. esac
  4795. LD=$ac_ct_LD
  4796. fi
  4797. else
  4798. LD="$ac_cv_prog_LD"
  4799. fi
  4800. if test -n "$ac_tool_prefix"; then
  4801. # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
  4802. set dummy ${ac_tool_prefix}ranlib; ac_word=$2
  4803. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4804. $as_echo_n "checking for $ac_word... " >&6; }
  4805. if ${ac_cv_prog_RANLIB+:} false; then :
  4806. $as_echo_n "(cached) " >&6
  4807. else
  4808. if test -n "$RANLIB"; then
  4809. ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
  4810. else
  4811. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4812. for as_dir in $PATH
  4813. do
  4814. IFS=$as_save_IFS
  4815. test -z "$as_dir" && as_dir=.
  4816. for ac_exec_ext in '' $ac_executable_extensions; do
  4817. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4818. ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
  4819. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4820. break 2
  4821. fi
  4822. done
  4823. done
  4824. IFS=$as_save_IFS
  4825. fi
  4826. fi
  4827. RANLIB=$ac_cv_prog_RANLIB
  4828. if test -n "$RANLIB"; then
  4829. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
  4830. $as_echo "$RANLIB" >&6; }
  4831. else
  4832. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4833. $as_echo "no" >&6; }
  4834. fi
  4835. fi
  4836. if test -z "$ac_cv_prog_RANLIB"; then
  4837. ac_ct_RANLIB=$RANLIB
  4838. # Extract the first word of "ranlib", so it can be a program name with args.
  4839. set dummy ranlib; ac_word=$2
  4840. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4841. $as_echo_n "checking for $ac_word... " >&6; }
  4842. if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
  4843. $as_echo_n "(cached) " >&6
  4844. else
  4845. if test -n "$ac_ct_RANLIB"; then
  4846. ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
  4847. else
  4848. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4849. for as_dir in $PATH
  4850. do
  4851. IFS=$as_save_IFS
  4852. test -z "$as_dir" && as_dir=.
  4853. for ac_exec_ext in '' $ac_executable_extensions; do
  4854. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4855. ac_cv_prog_ac_ct_RANLIB="ranlib"
  4856. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4857. break 2
  4858. fi
  4859. done
  4860. done
  4861. IFS=$as_save_IFS
  4862. fi
  4863. fi
  4864. ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
  4865. if test -n "$ac_ct_RANLIB"; then
  4866. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
  4867. $as_echo "$ac_ct_RANLIB" >&6; }
  4868. else
  4869. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4870. $as_echo "no" >&6; }
  4871. fi
  4872. if test "x$ac_ct_RANLIB" = x; then
  4873. RANLIB=":"
  4874. else
  4875. case $cross_compiling:$ac_tool_warned in
  4876. yes:)
  4877. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  4878. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  4879. ac_tool_warned=yes ;;
  4880. esac
  4881. RANLIB=$ac_ct_RANLIB
  4882. fi
  4883. else
  4884. RANLIB="$ac_cv_prog_RANLIB"
  4885. fi
  4886. fi
  4887. # Checks for programs.
  4888. ac_ext=cpp
  4889. ac_cpp='$CXXCPP $CPPFLAGS'
  4890. ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  4891. ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  4892. ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
  4893. if test -z "$CXX"; then
  4894. if test -n "$CCC"; then
  4895. CXX=$CCC
  4896. else
  4897. if test -n "$ac_tool_prefix"; then
  4898. for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
  4899. do
  4900. # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
  4901. set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  4902. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4903. $as_echo_n "checking for $ac_word... " >&6; }
  4904. if ${ac_cv_prog_CXX+:} false; then :
  4905. $as_echo_n "(cached) " >&6
  4906. else
  4907. if test -n "$CXX"; then
  4908. ac_cv_prog_CXX="$CXX" # Let the user override the test.
  4909. else
  4910. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4911. for as_dir in $PATH
  4912. do
  4913. IFS=$as_save_IFS
  4914. test -z "$as_dir" && as_dir=.
  4915. for ac_exec_ext in '' $ac_executable_extensions; do
  4916. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4917. ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
  4918. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4919. break 2
  4920. fi
  4921. done
  4922. done
  4923. IFS=$as_save_IFS
  4924. fi
  4925. fi
  4926. CXX=$ac_cv_prog_CXX
  4927. if test -n "$CXX"; then
  4928. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
  4929. $as_echo "$CXX" >&6; }
  4930. else
  4931. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4932. $as_echo "no" >&6; }
  4933. fi
  4934. test -n "$CXX" && break
  4935. done
  4936. fi
  4937. if test -z "$CXX"; then
  4938. ac_ct_CXX=$CXX
  4939. for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
  4940. do
  4941. # Extract the first word of "$ac_prog", so it can be a program name with args.
  4942. set dummy $ac_prog; ac_word=$2
  4943. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4944. $as_echo_n "checking for $ac_word... " >&6; }
  4945. if ${ac_cv_prog_ac_ct_CXX+:} false; then :
  4946. $as_echo_n "(cached) " >&6
  4947. else
  4948. if test -n "$ac_ct_CXX"; then
  4949. ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
  4950. else
  4951. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4952. for as_dir in $PATH
  4953. do
  4954. IFS=$as_save_IFS
  4955. test -z "$as_dir" && as_dir=.
  4956. for ac_exec_ext in '' $ac_executable_extensions; do
  4957. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4958. ac_cv_prog_ac_ct_CXX="$ac_prog"
  4959. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4960. break 2
  4961. fi
  4962. done
  4963. done
  4964. IFS=$as_save_IFS
  4965. fi
  4966. fi
  4967. ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
  4968. if test -n "$ac_ct_CXX"; then
  4969. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
  4970. $as_echo "$ac_ct_CXX" >&6; }
  4971. else
  4972. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4973. $as_echo "no" >&6; }
  4974. fi
  4975. test -n "$ac_ct_CXX" && break
  4976. done
  4977. if test "x$ac_ct_CXX" = x; then
  4978. CXX="g++"
  4979. else
  4980. case $cross_compiling:$ac_tool_warned in
  4981. yes:)
  4982. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  4983. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  4984. ac_tool_warned=yes ;;
  4985. esac
  4986. CXX=$ac_ct_CXX
  4987. fi
  4988. fi
  4989. fi
  4990. fi
  4991. # Provide some information about the compiler.
  4992. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
  4993. set X $ac_compile
  4994. ac_compiler=$2
  4995. for ac_option in --version -v -V -qversion; do
  4996. { { ac_try="$ac_compiler $ac_option >&5"
  4997. case "(($ac_try" in
  4998. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  4999. *) ac_try_echo=$ac_try;;
  5000. esac
  5001. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  5002. $as_echo "$ac_try_echo"; } >&5
  5003. (eval "$ac_compiler $ac_option >&5") 2>conftest.err
  5004. ac_status=$?
  5005. if test -s conftest.err; then
  5006. sed '10a\
  5007. ... rest of stderr output deleted ...
  5008. 10q' conftest.err >conftest.er1
  5009. cat conftest.er1 >&5
  5010. fi
  5011. rm -f conftest.er1 conftest.err
  5012. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  5013. test $ac_status = 0; }
  5014. done
  5015. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
  5016. $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
  5017. if ${ac_cv_cxx_compiler_gnu+:} false; then :
  5018. $as_echo_n "(cached) " >&6
  5019. else
  5020. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5021. /* end confdefs.h. */
  5022. int
  5023. main ()
  5024. {
  5025. #ifndef __GNUC__
  5026. choke me
  5027. #endif
  5028. ;
  5029. return 0;
  5030. }
  5031. _ACEOF
  5032. if ac_fn_cxx_try_compile "$LINENO"; then :
  5033. ac_compiler_gnu=yes
  5034. else
  5035. ac_compiler_gnu=no
  5036. fi
  5037. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  5038. ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
  5039. fi
  5040. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
  5041. $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
  5042. if test $ac_compiler_gnu = yes; then
  5043. GXX=yes
  5044. else
  5045. GXX=
  5046. fi
  5047. ac_test_CXXFLAGS=${CXXFLAGS+set}
  5048. ac_save_CXXFLAGS=$CXXFLAGS
  5049. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
  5050. $as_echo_n "checking whether $CXX accepts -g... " >&6; }
  5051. if ${ac_cv_prog_cxx_g+:} false; then :
  5052. $as_echo_n "(cached) " >&6
  5053. else
  5054. ac_save_cxx_werror_flag=$ac_cxx_werror_flag
  5055. ac_cxx_werror_flag=yes
  5056. ac_cv_prog_cxx_g=no
  5057. CXXFLAGS="-g"
  5058. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5059. /* end confdefs.h. */
  5060. int
  5061. main ()
  5062. {
  5063. ;
  5064. return 0;
  5065. }
  5066. _ACEOF
  5067. if ac_fn_cxx_try_compile "$LINENO"; then :
  5068. ac_cv_prog_cxx_g=yes
  5069. else
  5070. CXXFLAGS=""
  5071. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5072. /* end confdefs.h. */
  5073. int
  5074. main ()
  5075. {
  5076. ;
  5077. return 0;
  5078. }
  5079. _ACEOF
  5080. if ac_fn_cxx_try_compile "$LINENO"; then :
  5081. else
  5082. ac_cxx_werror_flag=$ac_save_cxx_werror_flag
  5083. CXXFLAGS="-g"
  5084. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5085. /* end confdefs.h. */
  5086. int
  5087. main ()
  5088. {
  5089. ;
  5090. return 0;
  5091. }
  5092. _ACEOF
  5093. if ac_fn_cxx_try_compile "$LINENO"; then :
  5094. ac_cv_prog_cxx_g=yes
  5095. fi
  5096. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  5097. fi
  5098. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  5099. fi
  5100. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  5101. ac_cxx_werror_flag=$ac_save_cxx_werror_flag
  5102. fi
  5103. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
  5104. $as_echo "$ac_cv_prog_cxx_g" >&6; }
  5105. if test "$ac_test_CXXFLAGS" = set; then
  5106. CXXFLAGS=$ac_save_CXXFLAGS
  5107. elif test $ac_cv_prog_cxx_g = yes; then
  5108. if test "$GXX" = yes; then
  5109. CXXFLAGS="-g -O2"
  5110. else
  5111. CXXFLAGS="-g"
  5112. fi
  5113. else
  5114. if test "$GXX" = yes; then
  5115. CXXFLAGS="-O2"
  5116. else
  5117. CXXFLAGS=
  5118. fi
  5119. fi
  5120. ac_ext=c
  5121. ac_cpp='$CPP $CPPFLAGS'
  5122. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  5123. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  5124. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  5125. ac_ext=c
  5126. ac_cpp='$CPP $CPPFLAGS'
  5127. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  5128. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  5129. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  5130. { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
  5131. $as_echo_n "checking how to run the C preprocessor... " >&6; }
  5132. # On Suns, sometimes $CPP names a directory.
  5133. if test -n "$CPP" && test -d "$CPP"; then
  5134. CPP=
  5135. fi
  5136. if test -z "$CPP"; then
  5137. if ${ac_cv_prog_CPP+:} false; then :
  5138. $as_echo_n "(cached) " >&6
  5139. else
  5140. # Double quotes because CPP needs to be expanded
  5141. for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
  5142. do
  5143. ac_preproc_ok=false
  5144. for ac_c_preproc_warn_flag in '' yes
  5145. do
  5146. # Use a header file that comes with gcc, so configuring glibc
  5147. # with a fresh cross-compiler works.
  5148. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  5149. # <limits.h> exists even on freestanding compilers.
  5150. # On the NeXT, cc -E runs the code through the compiler's parser,
  5151. # not just through cpp. "Syntax error" is here to catch this case.
  5152. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5153. /* end confdefs.h. */
  5154. #ifdef __STDC__
  5155. # include <limits.h>
  5156. #else
  5157. # include <assert.h>
  5158. #endif
  5159. Syntax error
  5160. _ACEOF
  5161. if ac_fn_c_try_cpp "$LINENO"; then :
  5162. else
  5163. # Broken: fails on valid input.
  5164. continue
  5165. fi
  5166. rm -f conftest.err conftest.i conftest.$ac_ext
  5167. # OK, works on sane cases. Now check whether nonexistent headers
  5168. # can be detected and how.
  5169. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5170. /* end confdefs.h. */
  5171. #include <ac_nonexistent.h>
  5172. _ACEOF
  5173. if ac_fn_c_try_cpp "$LINENO"; then :
  5174. # Broken: success on invalid input.
  5175. continue
  5176. else
  5177. # Passes both tests.
  5178. ac_preproc_ok=:
  5179. break
  5180. fi
  5181. rm -f conftest.err conftest.i conftest.$ac_ext
  5182. done
  5183. # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
  5184. rm -f conftest.i conftest.err conftest.$ac_ext
  5185. if $ac_preproc_ok; then :
  5186. break
  5187. fi
  5188. done
  5189. ac_cv_prog_CPP=$CPP
  5190. fi
  5191. CPP=$ac_cv_prog_CPP
  5192. else
  5193. ac_cv_prog_CPP=$CPP
  5194. fi
  5195. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
  5196. $as_echo "$CPP" >&6; }
  5197. ac_preproc_ok=false
  5198. for ac_c_preproc_warn_flag in '' yes
  5199. do
  5200. # Use a header file that comes with gcc, so configuring glibc
  5201. # with a fresh cross-compiler works.
  5202. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  5203. # <limits.h> exists even on freestanding compilers.
  5204. # On the NeXT, cc -E runs the code through the compiler's parser,
  5205. # not just through cpp. "Syntax error" is here to catch this case.
  5206. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5207. /* end confdefs.h. */
  5208. #ifdef __STDC__
  5209. # include <limits.h>
  5210. #else
  5211. # include <assert.h>
  5212. #endif
  5213. Syntax error
  5214. _ACEOF
  5215. if ac_fn_c_try_cpp "$LINENO"; then :
  5216. else
  5217. # Broken: fails on valid input.
  5218. continue
  5219. fi
  5220. rm -f conftest.err conftest.i conftest.$ac_ext
  5221. # OK, works on sane cases. Now check whether nonexistent headers
  5222. # can be detected and how.
  5223. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5224. /* end confdefs.h. */
  5225. #include <ac_nonexistent.h>
  5226. _ACEOF
  5227. if ac_fn_c_try_cpp "$LINENO"; then :
  5228. # Broken: success on invalid input.
  5229. continue
  5230. else
  5231. # Passes both tests.
  5232. ac_preproc_ok=:
  5233. break
  5234. fi
  5235. rm -f conftest.err conftest.i conftest.$ac_ext
  5236. done
  5237. # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
  5238. rm -f conftest.i conftest.err conftest.$ac_ext
  5239. if $ac_preproc_ok; then :
  5240. else
  5241. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  5242. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  5243. as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
  5244. See \`config.log' for more details" "$LINENO" 5; }
  5245. fi
  5246. ac_ext=c
  5247. ac_cpp='$CPP $CPPFLAGS'
  5248. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  5249. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  5250. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  5251. ac_ext=cpp
  5252. ac_cpp='$CXXCPP $CPPFLAGS'
  5253. ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  5254. ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  5255. ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
  5256. { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
  5257. $as_echo_n "checking how to run the C++ preprocessor... " >&6; }
  5258. if test -z "$CXXCPP"; then
  5259. if ${ac_cv_prog_CXXCPP+:} false; then :
  5260. $as_echo_n "(cached) " >&6
  5261. else
  5262. # Double quotes because CXXCPP needs to be expanded
  5263. for CXXCPP in "$CXX -E" "/lib/cpp"
  5264. do
  5265. ac_preproc_ok=false
  5266. for ac_cxx_preproc_warn_flag in '' yes
  5267. do
  5268. # Use a header file that comes with gcc, so configuring glibc
  5269. # with a fresh cross-compiler works.
  5270. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  5271. # <limits.h> exists even on freestanding compilers.
  5272. # On the NeXT, cc -E runs the code through the compiler's parser,
  5273. # not just through cpp. "Syntax error" is here to catch this case.
  5274. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5275. /* end confdefs.h. */
  5276. #ifdef __STDC__
  5277. # include <limits.h>
  5278. #else
  5279. # include <assert.h>
  5280. #endif
  5281. Syntax error
  5282. _ACEOF
  5283. if ac_fn_cxx_try_cpp "$LINENO"; then :
  5284. else
  5285. # Broken: fails on valid input.
  5286. continue
  5287. fi
  5288. rm -f conftest.err conftest.i conftest.$ac_ext
  5289. # OK, works on sane cases. Now check whether nonexistent headers
  5290. # can be detected and how.
  5291. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5292. /* end confdefs.h. */
  5293. #include <ac_nonexistent.h>
  5294. _ACEOF
  5295. if ac_fn_cxx_try_cpp "$LINENO"; then :
  5296. # Broken: success on invalid input.
  5297. continue
  5298. else
  5299. # Passes both tests.
  5300. ac_preproc_ok=:
  5301. break
  5302. fi
  5303. rm -f conftest.err conftest.i conftest.$ac_ext
  5304. done
  5305. # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
  5306. rm -f conftest.i conftest.err conftest.$ac_ext
  5307. if $ac_preproc_ok; then :
  5308. break
  5309. fi
  5310. done
  5311. ac_cv_prog_CXXCPP=$CXXCPP
  5312. fi
  5313. CXXCPP=$ac_cv_prog_CXXCPP
  5314. else
  5315. ac_cv_prog_CXXCPP=$CXXCPP
  5316. fi
  5317. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
  5318. $as_echo "$CXXCPP" >&6; }
  5319. ac_preproc_ok=false
  5320. for ac_cxx_preproc_warn_flag in '' yes
  5321. do
  5322. # Use a header file that comes with gcc, so configuring glibc
  5323. # with a fresh cross-compiler works.
  5324. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  5325. # <limits.h> exists even on freestanding compilers.
  5326. # On the NeXT, cc -E runs the code through the compiler's parser,
  5327. # not just through cpp. "Syntax error" is here to catch this case.
  5328. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5329. /* end confdefs.h. */
  5330. #ifdef __STDC__
  5331. # include <limits.h>
  5332. #else
  5333. # include <assert.h>
  5334. #endif
  5335. Syntax error
  5336. _ACEOF
  5337. if ac_fn_cxx_try_cpp "$LINENO"; then :
  5338. else
  5339. # Broken: fails on valid input.
  5340. continue
  5341. fi
  5342. rm -f conftest.err conftest.i conftest.$ac_ext
  5343. # OK, works on sane cases. Now check whether nonexistent headers
  5344. # can be detected and how.
  5345. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5346. /* end confdefs.h. */
  5347. #include <ac_nonexistent.h>
  5348. _ACEOF
  5349. if ac_fn_cxx_try_cpp "$LINENO"; then :
  5350. # Broken: success on invalid input.
  5351. continue
  5352. else
  5353. # Passes both tests.
  5354. ac_preproc_ok=:
  5355. break
  5356. fi
  5357. rm -f conftest.err conftest.i conftest.$ac_ext
  5358. done
  5359. # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
  5360. rm -f conftest.i conftest.err conftest.$ac_ext
  5361. if $ac_preproc_ok; then :
  5362. else
  5363. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  5364. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  5365. as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
  5366. See \`config.log' for more details" "$LINENO" 5; }
  5367. fi
  5368. ac_ext=c
  5369. ac_cpp='$CPP $CPPFLAGS'
  5370. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  5371. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  5372. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  5373. # This macro is just copied into our local acinclude.m4 from libtool.m4 so that
  5374. # the developers regenerating the configure script don't have to install libtool.
  5375. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
  5376. $as_echo_n "checking for a sed that does not truncate output... " >&6; }
  5377. if ${ac_cv_path_SED+:} false; then :
  5378. $as_echo_n "(cached) " >&6
  5379. else
  5380. ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
  5381. for ac_i in 1 2 3 4 5 6 7; do
  5382. ac_script="$ac_script$as_nl$ac_script"
  5383. done
  5384. echo "$ac_script" | sed 99q >conftest.sed
  5385. $as_unset ac_script || ac_script=
  5386. if test -z "$SED"; then
  5387. ac_path_SED_found=false
  5388. # Loop through the user's path and test for each of PROGNAME-LIST
  5389. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5390. for as_dir in $PATH
  5391. do
  5392. IFS=$as_save_IFS
  5393. test -z "$as_dir" && as_dir=.
  5394. for ac_prog in sed gsed; do
  5395. for ac_exec_ext in '' $ac_executable_extensions; do
  5396. ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
  5397. as_fn_executable_p "$ac_path_SED" || continue
  5398. # Check for GNU ac_path_SED and select it if it is found.
  5399. # Check for GNU $ac_path_SED
  5400. case `"$ac_path_SED" --version 2>&1` in
  5401. *GNU*)
  5402. ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
  5403. *)
  5404. ac_count=0
  5405. $as_echo_n 0123456789 >"conftest.in"
  5406. while :
  5407. do
  5408. cat "conftest.in" "conftest.in" >"conftest.tmp"
  5409. mv "conftest.tmp" "conftest.in"
  5410. cp "conftest.in" "conftest.nl"
  5411. $as_echo '' >> "conftest.nl"
  5412. "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
  5413. diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
  5414. as_fn_arith $ac_count + 1 && ac_count=$as_val
  5415. if test $ac_count -gt ${ac_path_SED_max-0}; then
  5416. # Best one so far, save it but keep looking for a better one
  5417. ac_cv_path_SED="$ac_path_SED"
  5418. ac_path_SED_max=$ac_count
  5419. fi
  5420. # 10*(2^10) chars as input seems more than enough
  5421. test $ac_count -gt 10 && break
  5422. done
  5423. rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
  5424. esac
  5425. $ac_path_SED_found && break 3
  5426. done
  5427. done
  5428. done
  5429. IFS=$as_save_IFS
  5430. if test -z "$ac_cv_path_SED"; then
  5431. as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
  5432. fi
  5433. else
  5434. ac_cv_path_SED=$SED
  5435. fi
  5436. fi
  5437. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
  5438. $as_echo "$ac_cv_path_SED" >&6; }
  5439. SED="$ac_cv_path_SED"
  5440. rm -f conftest.sed
  5441. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
  5442. $as_echo_n "checking for egrep... " >&6; }
  5443. if ${ac_cv_prog_egrep+:} false; then :
  5444. $as_echo_n "(cached) " >&6
  5445. else
  5446. if echo a | (grep -E '(a|b)') >/dev/null 2>&1
  5447. then ac_cv_prog_egrep='grep -E'
  5448. else ac_cv_prog_egrep='egrep'
  5449. fi
  5450. fi
  5451. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_egrep" >&5
  5452. $as_echo "$ac_cv_prog_egrep" >&6; }
  5453. EGREP=$ac_cv_prog_egrep
  5454. # Check whether --with-gnu-ld was given.
  5455. if test "${with_gnu_ld+set}" = set; then :
  5456. withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
  5457. else
  5458. with_gnu_ld=no
  5459. fi
  5460. ac_prog=ld
  5461. if test "$GCC" = yes; then
  5462. # Check if gcc -print-prog-name=ld gives a path.
  5463. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
  5464. $as_echo_n "checking for ld used by $CC... " >&6; }
  5465. case $host in
  5466. *-*-mingw*)
  5467. # gcc leaves a trailing carriage return which upsets mingw
  5468. ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
  5469. *)
  5470. ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
  5471. esac
  5472. case $ac_prog in
  5473. # Accept absolute paths.
  5474. [\\/]* | ?:[\\/]*)
  5475. re_direlt='/[^/][^/]*/\.\./'
  5476. # Canonicalize the pathname of ld
  5477. ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
  5478. while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
  5479. ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
  5480. done
  5481. test -z "$LD" && LD="$ac_prog"
  5482. ;;
  5483. "")
  5484. # If it fails, then pretend we aren't using GCC.
  5485. ac_prog=ld
  5486. ;;
  5487. *)
  5488. # If it is relative, then search for the first ld in PATH.
  5489. with_gnu_ld=unknown
  5490. ;;
  5491. esac
  5492. elif test "$with_gnu_ld" = yes; then
  5493. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
  5494. $as_echo_n "checking for GNU ld... " >&6; }
  5495. else
  5496. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
  5497. $as_echo_n "checking for non-GNU ld... " >&6; }
  5498. fi
  5499. if ${lt_cv_path_LD+:} false; then :
  5500. $as_echo_n "(cached) " >&6
  5501. else
  5502. if test -z "$LD"; then
  5503. lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
  5504. for ac_dir in $PATH; do
  5505. IFS="$lt_save_ifs"
  5506. test -z "$ac_dir" && ac_dir=.
  5507. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
  5508. lt_cv_path_LD="$ac_dir/$ac_prog"
  5509. # Check to see if the program is GNU ld. I'd rather use --version,
  5510. # but apparently some variants of GNU ld only accept -v.
  5511. # Break only if it was the GNU/non-GNU ld that we prefer.
  5512. case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
  5513. *GNU* | *'with BFD'*)
  5514. test "$with_gnu_ld" != no && break
  5515. ;;
  5516. *)
  5517. test "$with_gnu_ld" != yes && break
  5518. ;;
  5519. esac
  5520. fi
  5521. done
  5522. IFS="$lt_save_ifs"
  5523. else
  5524. lt_cv_path_LD="$LD" # Let the user override the test with a path.
  5525. fi
  5526. fi
  5527. LD="$lt_cv_path_LD"
  5528. if test -n "$LD"; then
  5529. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
  5530. $as_echo "$LD" >&6; }
  5531. else
  5532. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5533. $as_echo "no" >&6; }
  5534. fi
  5535. test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
  5536. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
  5537. $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
  5538. if ${lt_cv_prog_gnu_ld+:} false; then :
  5539. $as_echo_n "(cached) " >&6
  5540. else
  5541. # I'd rather use --version here, but apparently some GNU lds only accept -v.
  5542. case `$LD -v 2>&1 </dev/null` in
  5543. *GNU* | *'with BFD'*)
  5544. lt_cv_prog_gnu_ld=yes
  5545. ;;
  5546. *)
  5547. lt_cv_prog_gnu_ld=no
  5548. ;;
  5549. esac
  5550. fi
  5551. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
  5552. $as_echo "$lt_cv_prog_gnu_ld" >&6; }
  5553. with_gnu_ld=$lt_cv_prog_gnu_ld
  5554. # note, does not work on FreeBSD
  5555. for ac_prog in gawk mawk nawk awk
  5556. do
  5557. # Extract the first word of "$ac_prog", so it can be a program name with args.
  5558. set dummy $ac_prog; ac_word=$2
  5559. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5560. $as_echo_n "checking for $ac_word... " >&6; }
  5561. if ${ac_cv_prog_AWK+:} false; then :
  5562. $as_echo_n "(cached) " >&6
  5563. else
  5564. if test -n "$AWK"; then
  5565. ac_cv_prog_AWK="$AWK" # Let the user override the test.
  5566. else
  5567. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5568. for as_dir in $PATH
  5569. do
  5570. IFS=$as_save_IFS
  5571. test -z "$as_dir" && as_dir=.
  5572. for ac_exec_ext in '' $ac_executable_extensions; do
  5573. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5574. ac_cv_prog_AWK="$ac_prog"
  5575. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5576. break 2
  5577. fi
  5578. done
  5579. done
  5580. IFS=$as_save_IFS
  5581. fi
  5582. fi
  5583. AWK=$ac_cv_prog_AWK
  5584. if test -n "$AWK"; then
  5585. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
  5586. $as_echo "$AWK" >&6; }
  5587. else
  5588. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5589. $as_echo "no" >&6; }
  5590. fi
  5591. test -n "$AWK" && break
  5592. done
  5593. # Find a good install program. We prefer a C program (faster),
  5594. # so one script is as good as another. But avoid the broken or
  5595. # incompatible versions:
  5596. # SysV /etc/install, /usr/sbin/install
  5597. # SunOS /usr/etc/install
  5598. # IRIX /sbin/install
  5599. # AIX /bin/install
  5600. # AmigaOS /C/install, which installs bootblocks on floppy discs
  5601. # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
  5602. # AFS /usr/afsws/bin/install, which mishandles nonexistent args
  5603. # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
  5604. # OS/2's system install, which has a completely different semantic
  5605. # ./install, which can be erroneously created by make from ./install.sh.
  5606. # Reject install programs that cannot install multiple files.
  5607. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
  5608. $as_echo_n "checking for a BSD-compatible install... " >&6; }
  5609. if test -z "$INSTALL"; then
  5610. if ${ac_cv_path_install+:} false; then :
  5611. $as_echo_n "(cached) " >&6
  5612. else
  5613. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5614. for as_dir in $PATH
  5615. do
  5616. IFS=$as_save_IFS
  5617. test -z "$as_dir" && as_dir=.
  5618. # Account for people who put trailing slashes in PATH elements.
  5619. case $as_dir/ in #((
  5620. ./ | .// | /[cC]/* | \
  5621. /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
  5622. ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
  5623. /usr/ucb/* ) ;;
  5624. *)
  5625. # OSF1 and SCO ODT 3.0 have their own names for install.
  5626. # Don't use installbsd from OSF since it installs stuff as root
  5627. # by default.
  5628. for ac_prog in ginstall scoinst install; do
  5629. for ac_exec_ext in '' $ac_executable_extensions; do
  5630. if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
  5631. if test $ac_prog = install &&
  5632. grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
  5633. # AIX install. It has an incompatible calling convention.
  5634. :
  5635. elif test $ac_prog = install &&
  5636. grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
  5637. # program-specific install script used by HP pwplus--don't use.
  5638. :
  5639. else
  5640. rm -rf conftest.one conftest.two conftest.dir
  5641. echo one > conftest.one
  5642. echo two > conftest.two
  5643. mkdir conftest.dir
  5644. if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
  5645. test -s conftest.one && test -s conftest.two &&
  5646. test -s conftest.dir/conftest.one &&
  5647. test -s conftest.dir/conftest.two
  5648. then
  5649. ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
  5650. break 3
  5651. fi
  5652. fi
  5653. fi
  5654. done
  5655. done
  5656. ;;
  5657. esac
  5658. done
  5659. IFS=$as_save_IFS
  5660. rm -rf conftest.one conftest.two conftest.dir
  5661. fi
  5662. if test "${ac_cv_path_install+set}" = set; then
  5663. INSTALL=$ac_cv_path_install
  5664. else
  5665. # As a last resort, use the slow shell script. Don't cache a
  5666. # value for INSTALL within a source directory, because that will
  5667. # break other packages using the cache if that directory is
  5668. # removed, or if the value is a relative name.
  5669. INSTALL=$ac_install_sh
  5670. fi
  5671. fi
  5672. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
  5673. $as_echo "$INSTALL" >&6; }
  5674. # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
  5675. # It thinks the first close brace ends the variable substitution.
  5676. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
  5677. test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
  5678. test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
  5679. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
  5680. $as_echo_n "checking whether ln -s works... " >&6; }
  5681. LN_S=$as_ln_s
  5682. if test "$LN_S" = "ln -s"; then
  5683. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  5684. $as_echo "yes" >&6; }
  5685. else
  5686. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
  5687. $as_echo "no, using $LN_S" >&6; }
  5688. fi
  5689. if test -n "$ac_tool_prefix"; then
  5690. # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
  5691. set dummy ${ac_tool_prefix}ranlib; ac_word=$2
  5692. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5693. $as_echo_n "checking for $ac_word... " >&6; }
  5694. if ${ac_cv_prog_RANLIB+:} false; then :
  5695. $as_echo_n "(cached) " >&6
  5696. else
  5697. if test -n "$RANLIB"; then
  5698. ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
  5699. else
  5700. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5701. for as_dir in $PATH
  5702. do
  5703. IFS=$as_save_IFS
  5704. test -z "$as_dir" && as_dir=.
  5705. for ac_exec_ext in '' $ac_executable_extensions; do
  5706. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5707. ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
  5708. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5709. break 2
  5710. fi
  5711. done
  5712. done
  5713. IFS=$as_save_IFS
  5714. fi
  5715. fi
  5716. RANLIB=$ac_cv_prog_RANLIB
  5717. if test -n "$RANLIB"; then
  5718. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
  5719. $as_echo "$RANLIB" >&6; }
  5720. else
  5721. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5722. $as_echo "no" >&6; }
  5723. fi
  5724. fi
  5725. if test -z "$ac_cv_prog_RANLIB"; then
  5726. ac_ct_RANLIB=$RANLIB
  5727. # Extract the first word of "ranlib", so it can be a program name with args.
  5728. set dummy ranlib; ac_word=$2
  5729. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5730. $as_echo_n "checking for $ac_word... " >&6; }
  5731. if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
  5732. $as_echo_n "(cached) " >&6
  5733. else
  5734. if test -n "$ac_ct_RANLIB"; then
  5735. ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
  5736. else
  5737. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5738. for as_dir in $PATH
  5739. do
  5740. IFS=$as_save_IFS
  5741. test -z "$as_dir" && as_dir=.
  5742. for ac_exec_ext in '' $ac_executable_extensions; do
  5743. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5744. ac_cv_prog_ac_ct_RANLIB="ranlib"
  5745. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5746. break 2
  5747. fi
  5748. done
  5749. done
  5750. IFS=$as_save_IFS
  5751. fi
  5752. fi
  5753. ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
  5754. if test -n "$ac_ct_RANLIB"; then
  5755. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
  5756. $as_echo "$ac_ct_RANLIB" >&6; }
  5757. else
  5758. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5759. $as_echo "no" >&6; }
  5760. fi
  5761. if test "x$ac_ct_RANLIB" = x; then
  5762. RANLIB=":"
  5763. else
  5764. case $cross_compiling:$ac_tool_warned in
  5765. yes:)
  5766. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  5767. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  5768. ac_tool_warned=yes ;;
  5769. esac
  5770. RANLIB=$ac_ct_RANLIB
  5771. fi
  5772. else
  5773. RANLIB="$ac_cv_prog_RANLIB"
  5774. fi
  5775. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU make" >&5
  5776. $as_echo_n "checking for GNU make... " >&6; }
  5777. if ${ac_cv_GNU_MAKE+:} false; then :
  5778. $as_echo_n "(cached) " >&6
  5779. else
  5780. ac_cv_GNU_MAKE='Not Found' ;
  5781. ac_cv_GNU_MAKE_VERSION_MAJOR=0 ;
  5782. ac_cv_GNU_MAKE_VERSION_MINOR=0 ;
  5783. for a in make gmake gnumake ; do
  5784. if test -z "$a" ; then continue ; fi ;
  5785. if ( sh -c "$a --version" 2> /dev/null | grep GNU 2>&1 > /dev/null ) ; then
  5786. ac_cv_GNU_MAKE=$a ;
  5787. ac_cv_GNU_MAKE_VERSION_MAJOR=`$ac_cv_GNU_MAKE --version | grep "GNU Make" | cut -f3 -d' ' | cut -f1 -d'.'`
  5788. ac_cv_GNU_MAKE_VERSION_MINOR=`$ac_cv_GNU_MAKE --version | grep "GNU Make" | cut -f2 -d'.' | cut -c1-2`
  5789. break;
  5790. fi
  5791. done ;
  5792. fi
  5793. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_GNU_MAKE" >&5
  5794. $as_echo "$ac_cv_GNU_MAKE" >&6; } ;
  5795. if test "x$ac_cv_GNU_MAKE" = "xNot Found" ; then
  5796. as_fn_error $? "*** Please install GNU make. It is required to build Asterisk!" "$LINENO" 5
  5797. exit 1
  5798. fi
  5799. GNU_MAKE=$ac_cv_GNU_MAKE
  5800. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
  5801. $as_echo_n "checking for egrep... " >&6; }
  5802. if ${ac_cv_path_EGREP+:} false; then :
  5803. $as_echo_n "(cached) " >&6
  5804. else
  5805. if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
  5806. then ac_cv_path_EGREP="$GREP -E"
  5807. else
  5808. if test -z "$EGREP"; then
  5809. ac_path_EGREP_found=false
  5810. # Loop through the user's path and test for each of PROGNAME-LIST
  5811. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5812. for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
  5813. do
  5814. IFS=$as_save_IFS
  5815. test -z "$as_dir" && as_dir=.
  5816. for ac_prog in egrep; do
  5817. for ac_exec_ext in '' $ac_executable_extensions; do
  5818. ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
  5819. as_fn_executable_p "$ac_path_EGREP" || continue
  5820. # Check for GNU ac_path_EGREP and select it if it is found.
  5821. # Check for GNU $ac_path_EGREP
  5822. case `"$ac_path_EGREP" --version 2>&1` in
  5823. *GNU*)
  5824. ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
  5825. *)
  5826. ac_count=0
  5827. $as_echo_n 0123456789 >"conftest.in"
  5828. while :
  5829. do
  5830. cat "conftest.in" "conftest.in" >"conftest.tmp"
  5831. mv "conftest.tmp" "conftest.in"
  5832. cp "conftest.in" "conftest.nl"
  5833. $as_echo 'EGREP' >> "conftest.nl"
  5834. "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
  5835. diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
  5836. as_fn_arith $ac_count + 1 && ac_count=$as_val
  5837. if test $ac_count -gt ${ac_path_EGREP_max-0}; then
  5838. # Best one so far, save it but keep looking for a better one
  5839. ac_cv_path_EGREP="$ac_path_EGREP"
  5840. ac_path_EGREP_max=$ac_count
  5841. fi
  5842. # 10*(2^10) chars as input seems more than enough
  5843. test $ac_count -gt 10 && break
  5844. done
  5845. rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
  5846. esac
  5847. $ac_path_EGREP_found && break 3
  5848. done
  5849. done
  5850. done
  5851. IFS=$as_save_IFS
  5852. if test -z "$ac_cv_path_EGREP"; then
  5853. as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
  5854. fi
  5855. else
  5856. ac_cv_path_EGREP=$EGREP
  5857. fi
  5858. fi
  5859. fi
  5860. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
  5861. $as_echo "$ac_cv_path_EGREP" >&6; }
  5862. EGREP="$ac_cv_path_EGREP"
  5863. if test -n "$ac_tool_prefix"; then
  5864. for ac_prog in strip gstrip
  5865. do
  5866. # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
  5867. set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  5868. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5869. $as_echo_n "checking for $ac_word... " >&6; }
  5870. if ${ac_cv_prog_STRIP+:} false; then :
  5871. $as_echo_n "(cached) " >&6
  5872. else
  5873. if test -n "$STRIP"; then
  5874. ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
  5875. else
  5876. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5877. for as_dir in $PATH
  5878. do
  5879. IFS=$as_save_IFS
  5880. test -z "$as_dir" && as_dir=.
  5881. for ac_exec_ext in '' $ac_executable_extensions; do
  5882. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5883. ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog"
  5884. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5885. break 2
  5886. fi
  5887. done
  5888. done
  5889. IFS=$as_save_IFS
  5890. fi
  5891. fi
  5892. STRIP=$ac_cv_prog_STRIP
  5893. if test -n "$STRIP"; then
  5894. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
  5895. $as_echo "$STRIP" >&6; }
  5896. else
  5897. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5898. $as_echo "no" >&6; }
  5899. fi
  5900. test -n "$STRIP" && break
  5901. done
  5902. fi
  5903. if test -z "$STRIP"; then
  5904. ac_ct_STRIP=$STRIP
  5905. for ac_prog in strip gstrip
  5906. do
  5907. # Extract the first word of "$ac_prog", so it can be a program name with args.
  5908. set dummy $ac_prog; ac_word=$2
  5909. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5910. $as_echo_n "checking for $ac_word... " >&6; }
  5911. if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
  5912. $as_echo_n "(cached) " >&6
  5913. else
  5914. if test -n "$ac_ct_STRIP"; then
  5915. ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
  5916. else
  5917. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5918. for as_dir in $PATH
  5919. do
  5920. IFS=$as_save_IFS
  5921. test -z "$as_dir" && as_dir=.
  5922. for ac_exec_ext in '' $ac_executable_extensions; do
  5923. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5924. ac_cv_prog_ac_ct_STRIP="$ac_prog"
  5925. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5926. break 2
  5927. fi
  5928. done
  5929. done
  5930. IFS=$as_save_IFS
  5931. fi
  5932. fi
  5933. ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
  5934. if test -n "$ac_ct_STRIP"; then
  5935. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
  5936. $as_echo "$ac_ct_STRIP" >&6; }
  5937. else
  5938. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5939. $as_echo "no" >&6; }
  5940. fi
  5941. test -n "$ac_ct_STRIP" && break
  5942. done
  5943. if test "x$ac_ct_STRIP" = x; then
  5944. STRIP=":"
  5945. else
  5946. case $cross_compiling:$ac_tool_warned in
  5947. yes:)
  5948. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  5949. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  5950. ac_tool_warned=yes ;;
  5951. esac
  5952. STRIP=$ac_ct_STRIP
  5953. fi
  5954. fi
  5955. if test -n "$ac_tool_prefix"; then
  5956. for ac_prog in ar gar
  5957. do
  5958. # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
  5959. set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  5960. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5961. $as_echo_n "checking for $ac_word... " >&6; }
  5962. if ${ac_cv_prog_AR+:} false; then :
  5963. $as_echo_n "(cached) " >&6
  5964. else
  5965. if test -n "$AR"; then
  5966. ac_cv_prog_AR="$AR" # Let the user override the test.
  5967. else
  5968. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5969. for as_dir in $PATH
  5970. do
  5971. IFS=$as_save_IFS
  5972. test -z "$as_dir" && as_dir=.
  5973. for ac_exec_ext in '' $ac_executable_extensions; do
  5974. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5975. ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
  5976. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5977. break 2
  5978. fi
  5979. done
  5980. done
  5981. IFS=$as_save_IFS
  5982. fi
  5983. fi
  5984. AR=$ac_cv_prog_AR
  5985. if test -n "$AR"; then
  5986. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
  5987. $as_echo "$AR" >&6; }
  5988. else
  5989. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5990. $as_echo "no" >&6; }
  5991. fi
  5992. test -n "$AR" && break
  5993. done
  5994. fi
  5995. if test -z "$AR"; then
  5996. ac_ct_AR=$AR
  5997. for ac_prog in ar gar
  5998. do
  5999. # Extract the first word of "$ac_prog", so it can be a program name with args.
  6000. set dummy $ac_prog; ac_word=$2
  6001. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6002. $as_echo_n "checking for $ac_word... " >&6; }
  6003. if ${ac_cv_prog_ac_ct_AR+:} false; then :
  6004. $as_echo_n "(cached) " >&6
  6005. else
  6006. if test -n "$ac_ct_AR"; then
  6007. ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
  6008. else
  6009. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6010. for as_dir in $PATH
  6011. do
  6012. IFS=$as_save_IFS
  6013. test -z "$as_dir" && as_dir=.
  6014. for ac_exec_ext in '' $ac_executable_extensions; do
  6015. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6016. ac_cv_prog_ac_ct_AR="$ac_prog"
  6017. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6018. break 2
  6019. fi
  6020. done
  6021. done
  6022. IFS=$as_save_IFS
  6023. fi
  6024. fi
  6025. ac_ct_AR=$ac_cv_prog_ac_ct_AR
  6026. if test -n "$ac_ct_AR"; then
  6027. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
  6028. $as_echo "$ac_ct_AR" >&6; }
  6029. else
  6030. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6031. $as_echo "no" >&6; }
  6032. fi
  6033. test -n "$ac_ct_AR" && break
  6034. done
  6035. if test "x$ac_ct_AR" = x; then
  6036. AR=":"
  6037. else
  6038. case $cross_compiling:$ac_tool_warned in
  6039. yes:)
  6040. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  6041. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  6042. ac_tool_warned=yes ;;
  6043. esac
  6044. AR=$ac_ct_AR
  6045. fi
  6046. fi
  6047. GNU_LD=0
  6048. if test "x$with_gnu_ld" = "xyes" ; then
  6049. GNU_LD=1
  6050. fi
  6051. # Extract the first word of "bison", so it can be a program name with args.
  6052. set dummy bison; ac_word=$2
  6053. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6054. $as_echo_n "checking for $ac_word... " >&6; }
  6055. if ${ac_cv_path_BISON+:} false; then :
  6056. $as_echo_n "(cached) " >&6
  6057. else
  6058. case $BISON in
  6059. [\\/]* | ?:[\\/]*)
  6060. ac_cv_path_BISON="$BISON" # Let the user override the test with a path.
  6061. ;;
  6062. *)
  6063. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6064. for as_dir in $PATH
  6065. do
  6066. IFS=$as_save_IFS
  6067. test -z "$as_dir" && as_dir=.
  6068. for ac_exec_ext in '' $ac_executable_extensions; do
  6069. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6070. ac_cv_path_BISON="$as_dir/$ac_word$ac_exec_ext"
  6071. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6072. break 2
  6073. fi
  6074. done
  6075. done
  6076. IFS=$as_save_IFS
  6077. test -z "$ac_cv_path_BISON" && ac_cv_path_BISON=":"
  6078. ;;
  6079. esac
  6080. fi
  6081. BISON=$ac_cv_path_BISON
  6082. if test -n "$BISON"; then
  6083. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BISON" >&5
  6084. $as_echo "$BISON" >&6; }
  6085. else
  6086. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6087. $as_echo "no" >&6; }
  6088. fi
  6089. # Extract the first word of "cmp", so it can be a program name with args.
  6090. set dummy cmp; ac_word=$2
  6091. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6092. $as_echo_n "checking for $ac_word... " >&6; }
  6093. if ${ac_cv_path_CMP+:} false; then :
  6094. $as_echo_n "(cached) " >&6
  6095. else
  6096. case $CMP in
  6097. [\\/]* | ?:[\\/]*)
  6098. ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
  6099. ;;
  6100. *)
  6101. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6102. for as_dir in $PATH
  6103. do
  6104. IFS=$as_save_IFS
  6105. test -z "$as_dir" && as_dir=.
  6106. for ac_exec_ext in '' $ac_executable_extensions; do
  6107. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6108. ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
  6109. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6110. break 2
  6111. fi
  6112. done
  6113. done
  6114. IFS=$as_save_IFS
  6115. test -z "$ac_cv_path_CMP" && ac_cv_path_CMP=":"
  6116. ;;
  6117. esac
  6118. fi
  6119. CMP=$ac_cv_path_CMP
  6120. if test -n "$CMP"; then
  6121. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
  6122. $as_echo "$CMP" >&6; }
  6123. else
  6124. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6125. $as_echo "no" >&6; }
  6126. fi
  6127. # Extract the first word of "flex", so it can be a program name with args.
  6128. set dummy flex; ac_word=$2
  6129. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6130. $as_echo_n "checking for $ac_word... " >&6; }
  6131. if ${ac_cv_path_FLEX+:} false; then :
  6132. $as_echo_n "(cached) " >&6
  6133. else
  6134. case $FLEX in
  6135. [\\/]* | ?:[\\/]*)
  6136. ac_cv_path_FLEX="$FLEX" # Let the user override the test with a path.
  6137. ;;
  6138. *)
  6139. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6140. for as_dir in $PATH
  6141. do
  6142. IFS=$as_save_IFS
  6143. test -z "$as_dir" && as_dir=.
  6144. for ac_exec_ext in '' $ac_executable_extensions; do
  6145. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6146. ac_cv_path_FLEX="$as_dir/$ac_word$ac_exec_ext"
  6147. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6148. break 2
  6149. fi
  6150. done
  6151. done
  6152. IFS=$as_save_IFS
  6153. test -z "$ac_cv_path_FLEX" && ac_cv_path_FLEX=":"
  6154. ;;
  6155. esac
  6156. fi
  6157. FLEX=$ac_cv_path_FLEX
  6158. if test -n "$FLEX"; then
  6159. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLEX" >&5
  6160. $as_echo "$FLEX" >&6; }
  6161. else
  6162. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6163. $as_echo "no" >&6; }
  6164. fi
  6165. # Extract the first word of "grep", so it can be a program name with args.
  6166. set dummy grep; ac_word=$2
  6167. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6168. $as_echo_n "checking for $ac_word... " >&6; }
  6169. if ${ac_cv_path_GREP+:} false; then :
  6170. $as_echo_n "(cached) " >&6
  6171. else
  6172. case $GREP in
  6173. [\\/]* | ?:[\\/]*)
  6174. ac_cv_path_GREP="$GREP" # Let the user override the test with a path.
  6175. ;;
  6176. *)
  6177. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6178. for as_dir in $PATH
  6179. do
  6180. IFS=$as_save_IFS
  6181. test -z "$as_dir" && as_dir=.
  6182. for ac_exec_ext in '' $ac_executable_extensions; do
  6183. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6184. ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext"
  6185. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6186. break 2
  6187. fi
  6188. done
  6189. done
  6190. IFS=$as_save_IFS
  6191. test -z "$ac_cv_path_GREP" && ac_cv_path_GREP=":"
  6192. ;;
  6193. esac
  6194. fi
  6195. GREP=$ac_cv_path_GREP
  6196. if test -n "$GREP"; then
  6197. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5
  6198. $as_echo "$GREP" >&6; }
  6199. else
  6200. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6201. $as_echo "no" >&6; }
  6202. fi
  6203. # Extract the first word of "python", so it can be a program name with args.
  6204. set dummy python; ac_word=$2
  6205. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6206. $as_echo_n "checking for $ac_word... " >&6; }
  6207. if ${ac_cv_path_PYTHON+:} false; then :
  6208. $as_echo_n "(cached) " >&6
  6209. else
  6210. case $PYTHON in
  6211. [\\/]* | ?:[\\/]*)
  6212. ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
  6213. ;;
  6214. *)
  6215. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6216. for as_dir in $PATH
  6217. do
  6218. IFS=$as_save_IFS
  6219. test -z "$as_dir" && as_dir=.
  6220. for ac_exec_ext in '' $ac_executable_extensions; do
  6221. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6222. ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
  6223. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6224. break 2
  6225. fi
  6226. done
  6227. done
  6228. IFS=$as_save_IFS
  6229. test -z "$ac_cv_path_PYTHON" && ac_cv_path_PYTHON=":"
  6230. ;;
  6231. esac
  6232. fi
  6233. PYTHON=$ac_cv_path_PYTHON
  6234. if test -n "$PYTHON"; then
  6235. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
  6236. $as_echo "$PYTHON" >&6; }
  6237. else
  6238. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6239. $as_echo "no" >&6; }
  6240. fi
  6241. # Extract the first word of "find", so it can be a program name with args.
  6242. set dummy find; ac_word=$2
  6243. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6244. $as_echo_n "checking for $ac_word... " >&6; }
  6245. if ${ac_cv_path_FIND+:} false; then :
  6246. $as_echo_n "(cached) " >&6
  6247. else
  6248. case $FIND in
  6249. [\\/]* | ?:[\\/]*)
  6250. ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
  6251. ;;
  6252. *)
  6253. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6254. for as_dir in $PATH
  6255. do
  6256. IFS=$as_save_IFS
  6257. test -z "$as_dir" && as_dir=.
  6258. for ac_exec_ext in '' $ac_executable_extensions; do
  6259. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6260. ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
  6261. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6262. break 2
  6263. fi
  6264. done
  6265. done
  6266. IFS=$as_save_IFS
  6267. test -z "$ac_cv_path_FIND" && ac_cv_path_FIND=":"
  6268. ;;
  6269. esac
  6270. fi
  6271. FIND=$ac_cv_path_FIND
  6272. if test -n "$FIND"; then
  6273. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
  6274. $as_echo "$FIND" >&6; }
  6275. else
  6276. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6277. $as_echo "no" >&6; }
  6278. fi
  6279. # Extract the first word of "compress", so it can be a program name with args.
  6280. set dummy compress; ac_word=$2
  6281. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6282. $as_echo_n "checking for $ac_word... " >&6; }
  6283. if ${ac_cv_path_COMPRESS+:} false; then :
  6284. $as_echo_n "(cached) " >&6
  6285. else
  6286. case $COMPRESS in
  6287. [\\/]* | ?:[\\/]*)
  6288. ac_cv_path_COMPRESS="$COMPRESS" # Let the user override the test with a path.
  6289. ;;
  6290. *)
  6291. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6292. for as_dir in $PATH
  6293. do
  6294. IFS=$as_save_IFS
  6295. test -z "$as_dir" && as_dir=.
  6296. for ac_exec_ext in '' $ac_executable_extensions; do
  6297. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6298. ac_cv_path_COMPRESS="$as_dir/$ac_word$ac_exec_ext"
  6299. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6300. break 2
  6301. fi
  6302. done
  6303. done
  6304. IFS=$as_save_IFS
  6305. test -z "$ac_cv_path_COMPRESS" && ac_cv_path_COMPRESS=":"
  6306. ;;
  6307. esac
  6308. fi
  6309. COMPRESS=$ac_cv_path_COMPRESS
  6310. if test -n "$COMPRESS"; then
  6311. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPRESS" >&5
  6312. $as_echo "$COMPRESS" >&6; }
  6313. else
  6314. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6315. $as_echo "no" >&6; }
  6316. fi
  6317. # Extract the first word of "basename", so it can be a program name with args.
  6318. set dummy basename; ac_word=$2
  6319. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6320. $as_echo_n "checking for $ac_word... " >&6; }
  6321. if ${ac_cv_path_BASENAME+:} false; then :
  6322. $as_echo_n "(cached) " >&6
  6323. else
  6324. case $BASENAME in
  6325. [\\/]* | ?:[\\/]*)
  6326. ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
  6327. ;;
  6328. *)
  6329. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6330. for as_dir in $PATH
  6331. do
  6332. IFS=$as_save_IFS
  6333. test -z "$as_dir" && as_dir=.
  6334. for ac_exec_ext in '' $ac_executable_extensions; do
  6335. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6336. ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
  6337. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6338. break 2
  6339. fi
  6340. done
  6341. done
  6342. IFS=$as_save_IFS
  6343. test -z "$ac_cv_path_BASENAME" && ac_cv_path_BASENAME=":"
  6344. ;;
  6345. esac
  6346. fi
  6347. BASENAME=$ac_cv_path_BASENAME
  6348. if test -n "$BASENAME"; then
  6349. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
  6350. $as_echo "$BASENAME" >&6; }
  6351. else
  6352. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6353. $as_echo "no" >&6; }
  6354. fi
  6355. # Extract the first word of "dirname", so it can be a program name with args.
  6356. set dummy dirname; ac_word=$2
  6357. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6358. $as_echo_n "checking for $ac_word... " >&6; }
  6359. if ${ac_cv_path_DIRNAME+:} false; then :
  6360. $as_echo_n "(cached) " >&6
  6361. else
  6362. case $DIRNAME in
  6363. [\\/]* | ?:[\\/]*)
  6364. ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
  6365. ;;
  6366. *)
  6367. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6368. for as_dir in $PATH
  6369. do
  6370. IFS=$as_save_IFS
  6371. test -z "$as_dir" && as_dir=.
  6372. for ac_exec_ext in '' $ac_executable_extensions; do
  6373. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6374. ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
  6375. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6376. break 2
  6377. fi
  6378. done
  6379. done
  6380. IFS=$as_save_IFS
  6381. test -z "$ac_cv_path_DIRNAME" && ac_cv_path_DIRNAME=":"
  6382. ;;
  6383. esac
  6384. fi
  6385. DIRNAME=$ac_cv_path_DIRNAME
  6386. if test -n "$DIRNAME"; then
  6387. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
  6388. $as_echo "$DIRNAME" >&6; }
  6389. else
  6390. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6391. $as_echo "no" >&6; }
  6392. fi
  6393. # Extract the first word of "sh", so it can be a program name with args.
  6394. set dummy sh; ac_word=$2
  6395. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6396. $as_echo_n "checking for $ac_word... " >&6; }
  6397. if ${ac_cv_path_SHELL+:} false; then :
  6398. $as_echo_n "(cached) " >&6
  6399. else
  6400. case $SHELL in
  6401. [\\/]* | ?:[\\/]*)
  6402. ac_cv_path_SHELL="$SHELL" # Let the user override the test with a path.
  6403. ;;
  6404. *)
  6405. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6406. for as_dir in $PATH
  6407. do
  6408. IFS=$as_save_IFS
  6409. test -z "$as_dir" && as_dir=.
  6410. for ac_exec_ext in '' $ac_executable_extensions; do
  6411. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6412. ac_cv_path_SHELL="$as_dir/$ac_word$ac_exec_ext"
  6413. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6414. break 2
  6415. fi
  6416. done
  6417. done
  6418. IFS=$as_save_IFS
  6419. test -z "$ac_cv_path_SHELL" && ac_cv_path_SHELL=":"
  6420. ;;
  6421. esac
  6422. fi
  6423. SHELL=$ac_cv_path_SHELL
  6424. if test -n "$SHELL"; then
  6425. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHELL" >&5
  6426. $as_echo "$SHELL" >&6; }
  6427. else
  6428. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6429. $as_echo "no" >&6; }
  6430. fi
  6431. # Extract the first word of "ln", so it can be a program name with args.
  6432. set dummy ln; ac_word=$2
  6433. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6434. $as_echo_n "checking for $ac_word... " >&6; }
  6435. if ${ac_cv_path_LN+:} false; then :
  6436. $as_echo_n "(cached) " >&6
  6437. else
  6438. case $LN in
  6439. [\\/]* | ?:[\\/]*)
  6440. ac_cv_path_LN="$LN" # Let the user override the test with a path.
  6441. ;;
  6442. *)
  6443. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6444. for as_dir in $PATH
  6445. do
  6446. IFS=$as_save_IFS
  6447. test -z "$as_dir" && as_dir=.
  6448. for ac_exec_ext in '' $ac_executable_extensions; do
  6449. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6450. ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
  6451. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6452. break 2
  6453. fi
  6454. done
  6455. done
  6456. IFS=$as_save_IFS
  6457. test -z "$ac_cv_path_LN" && ac_cv_path_LN=":"
  6458. ;;
  6459. esac
  6460. fi
  6461. LN=$ac_cv_path_LN
  6462. if test -n "$LN"; then
  6463. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
  6464. $as_echo "$LN" >&6; }
  6465. else
  6466. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6467. $as_echo "no" >&6; }
  6468. fi
  6469. # Extract the first word of "doxygen", so it can be a program name with args.
  6470. set dummy doxygen; ac_word=$2
  6471. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6472. $as_echo_n "checking for $ac_word... " >&6; }
  6473. if ${ac_cv_path_DOXYGEN+:} false; then :
  6474. $as_echo_n "(cached) " >&6
  6475. else
  6476. case $DOXYGEN in
  6477. [\\/]* | ?:[\\/]*)
  6478. ac_cv_path_DOXYGEN="$DOXYGEN" # Let the user override the test with a path.
  6479. ;;
  6480. *)
  6481. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6482. for as_dir in $PATH
  6483. do
  6484. IFS=$as_save_IFS
  6485. test -z "$as_dir" && as_dir=.
  6486. for ac_exec_ext in '' $ac_executable_extensions; do
  6487. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6488. ac_cv_path_DOXYGEN="$as_dir/$ac_word$ac_exec_ext"
  6489. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6490. break 2
  6491. fi
  6492. done
  6493. done
  6494. IFS=$as_save_IFS
  6495. test -z "$ac_cv_path_DOXYGEN" && ac_cv_path_DOXYGEN=":"
  6496. ;;
  6497. esac
  6498. fi
  6499. DOXYGEN=$ac_cv_path_DOXYGEN
  6500. if test -n "$DOXYGEN"; then
  6501. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOXYGEN" >&5
  6502. $as_echo "$DOXYGEN" >&6; }
  6503. else
  6504. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6505. $as_echo "no" >&6; }
  6506. fi
  6507. # Extract the first word of "dot", so it can be a program name with args.
  6508. set dummy dot; ac_word=$2
  6509. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6510. $as_echo_n "checking for $ac_word... " >&6; }
  6511. if ${ac_cv_path_DOT+:} false; then :
  6512. $as_echo_n "(cached) " >&6
  6513. else
  6514. case $DOT in
  6515. [\\/]* | ?:[\\/]*)
  6516. ac_cv_path_DOT="$DOT" # Let the user override the test with a path.
  6517. ;;
  6518. *)
  6519. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6520. for as_dir in $PATH
  6521. do
  6522. IFS=$as_save_IFS
  6523. test -z "$as_dir" && as_dir=.
  6524. for ac_exec_ext in '' $ac_executable_extensions; do
  6525. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6526. ac_cv_path_DOT="$as_dir/$ac_word$ac_exec_ext"
  6527. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6528. break 2
  6529. fi
  6530. done
  6531. done
  6532. IFS=$as_save_IFS
  6533. test -z "$ac_cv_path_DOT" && ac_cv_path_DOT=":"
  6534. ;;
  6535. esac
  6536. fi
  6537. DOT=$ac_cv_path_DOT
  6538. if test -n "$DOT"; then
  6539. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOT" >&5
  6540. $as_echo "$DOT" >&6; }
  6541. else
  6542. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6543. $as_echo "no" >&6; }
  6544. fi
  6545. # Extract the first word of "wget", so it can be a program name with args.
  6546. set dummy wget; ac_word=$2
  6547. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6548. $as_echo_n "checking for $ac_word... " >&6; }
  6549. if ${ac_cv_path_WGET+:} false; then :
  6550. $as_echo_n "(cached) " >&6
  6551. else
  6552. case $WGET in
  6553. [\\/]* | ?:[\\/]*)
  6554. ac_cv_path_WGET="$WGET" # Let the user override the test with a path.
  6555. ;;
  6556. *)
  6557. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6558. for as_dir in $PATH
  6559. do
  6560. IFS=$as_save_IFS
  6561. test -z "$as_dir" && as_dir=.
  6562. for ac_exec_ext in '' $ac_executable_extensions; do
  6563. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6564. ac_cv_path_WGET="$as_dir/$ac_word$ac_exec_ext"
  6565. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6566. break 2
  6567. fi
  6568. done
  6569. done
  6570. IFS=$as_save_IFS
  6571. test -z "$ac_cv_path_WGET" && ac_cv_path_WGET=":"
  6572. ;;
  6573. esac
  6574. fi
  6575. WGET=$ac_cv_path_WGET
  6576. if test -n "$WGET"; then
  6577. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WGET" >&5
  6578. $as_echo "$WGET" >&6; }
  6579. else
  6580. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6581. $as_echo "no" >&6; }
  6582. fi
  6583. # Extract the first word of "curl", so it can be a program name with args.
  6584. set dummy curl; ac_word=$2
  6585. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6586. $as_echo_n "checking for $ac_word... " >&6; }
  6587. if ${ac_cv_path_CURL+:} false; then :
  6588. $as_echo_n "(cached) " >&6
  6589. else
  6590. case $CURL in
  6591. [\\/]* | ?:[\\/]*)
  6592. ac_cv_path_CURL="$CURL" # Let the user override the test with a path.
  6593. ;;
  6594. *)
  6595. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6596. for as_dir in $PATH
  6597. do
  6598. IFS=$as_save_IFS
  6599. test -z "$as_dir" && as_dir=.
  6600. for ac_exec_ext in '' $ac_executable_extensions; do
  6601. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6602. ac_cv_path_CURL="$as_dir/$ac_word$ac_exec_ext"
  6603. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6604. break 2
  6605. fi
  6606. done
  6607. done
  6608. IFS=$as_save_IFS
  6609. test -z "$ac_cv_path_CURL" && ac_cv_path_CURL=":"
  6610. ;;
  6611. esac
  6612. fi
  6613. CURL=$ac_cv_path_CURL
  6614. if test -n "$CURL"; then
  6615. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CURL" >&5
  6616. $as_echo "$CURL" >&6; }
  6617. else
  6618. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6619. $as_echo "no" >&6; }
  6620. fi
  6621. # Extract the first word of "rubber", so it can be a program name with args.
  6622. set dummy rubber; ac_word=$2
  6623. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6624. $as_echo_n "checking for $ac_word... " >&6; }
  6625. if ${ac_cv_path_RUBBER+:} false; then :
  6626. $as_echo_n "(cached) " >&6
  6627. else
  6628. case $RUBBER in
  6629. [\\/]* | ?:[\\/]*)
  6630. ac_cv_path_RUBBER="$RUBBER" # Let the user override the test with a path.
  6631. ;;
  6632. *)
  6633. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6634. for as_dir in $PATH
  6635. do
  6636. IFS=$as_save_IFS
  6637. test -z "$as_dir" && as_dir=.
  6638. for ac_exec_ext in '' $ac_executable_extensions; do
  6639. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6640. ac_cv_path_RUBBER="$as_dir/$ac_word$ac_exec_ext"
  6641. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6642. break 2
  6643. fi
  6644. done
  6645. done
  6646. IFS=$as_save_IFS
  6647. test -z "$ac_cv_path_RUBBER" && ac_cv_path_RUBBER=":"
  6648. ;;
  6649. esac
  6650. fi
  6651. RUBBER=$ac_cv_path_RUBBER
  6652. if test -n "$RUBBER"; then
  6653. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RUBBER" >&5
  6654. $as_echo "$RUBBER" >&6; }
  6655. else
  6656. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6657. $as_echo "no" >&6; }
  6658. fi
  6659. # Extract the first word of "catdvi", so it can be a program name with args.
  6660. set dummy catdvi; ac_word=$2
  6661. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6662. $as_echo_n "checking for $ac_word... " >&6; }
  6663. if ${ac_cv_path_CATDVI+:} false; then :
  6664. $as_echo_n "(cached) " >&6
  6665. else
  6666. case $CATDVI in
  6667. [\\/]* | ?:[\\/]*)
  6668. ac_cv_path_CATDVI="$CATDVI" # Let the user override the test with a path.
  6669. ;;
  6670. *)
  6671. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6672. for as_dir in $PATH
  6673. do
  6674. IFS=$as_save_IFS
  6675. test -z "$as_dir" && as_dir=.
  6676. for ac_exec_ext in '' $ac_executable_extensions; do
  6677. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6678. ac_cv_path_CATDVI="$as_dir/$ac_word$ac_exec_ext"
  6679. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6680. break 2
  6681. fi
  6682. done
  6683. done
  6684. IFS=$as_save_IFS
  6685. test -z "$ac_cv_path_CATDVI" && ac_cv_path_CATDVI=":"
  6686. ;;
  6687. esac
  6688. fi
  6689. CATDVI=$ac_cv_path_CATDVI
  6690. if test -n "$CATDVI"; then
  6691. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CATDVI" >&5
  6692. $as_echo "$CATDVI" >&6; }
  6693. else
  6694. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6695. $as_echo "no" >&6; }
  6696. fi
  6697. # Extract the first word of "kpsewhich", so it can be a program name with args.
  6698. set dummy kpsewhich; ac_word=$2
  6699. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6700. $as_echo_n "checking for $ac_word... " >&6; }
  6701. if ${ac_cv_path_KPATHSEA+:} false; then :
  6702. $as_echo_n "(cached) " >&6
  6703. else
  6704. case $KPATHSEA in
  6705. [\\/]* | ?:[\\/]*)
  6706. ac_cv_path_KPATHSEA="$KPATHSEA" # Let the user override the test with a path.
  6707. ;;
  6708. *)
  6709. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6710. for as_dir in $PATH
  6711. do
  6712. IFS=$as_save_IFS
  6713. test -z "$as_dir" && as_dir=.
  6714. for ac_exec_ext in '' $ac_executable_extensions; do
  6715. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6716. ac_cv_path_KPATHSEA="$as_dir/$ac_word$ac_exec_ext"
  6717. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6718. break 2
  6719. fi
  6720. done
  6721. done
  6722. IFS=$as_save_IFS
  6723. test -z "$ac_cv_path_KPATHSEA" && ac_cv_path_KPATHSEA=":"
  6724. ;;
  6725. esac
  6726. fi
  6727. KPATHSEA=$ac_cv_path_KPATHSEA
  6728. if test -n "$KPATHSEA"; then
  6729. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $KPATHSEA" >&5
  6730. $as_echo "$KPATHSEA" >&6; }
  6731. else
  6732. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6733. $as_echo "no" >&6; }
  6734. fi
  6735. # Extract the first word of "xmllint", so it can be a program name with args.
  6736. set dummy xmllint; ac_word=$2
  6737. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6738. $as_echo_n "checking for $ac_word... " >&6; }
  6739. if ${ac_cv_path_XMLLINT+:} false; then :
  6740. $as_echo_n "(cached) " >&6
  6741. else
  6742. case $XMLLINT in
  6743. [\\/]* | ?:[\\/]*)
  6744. ac_cv_path_XMLLINT="$XMLLINT" # Let the user override the test with a path.
  6745. ;;
  6746. *)
  6747. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6748. for as_dir in $PATH
  6749. do
  6750. IFS=$as_save_IFS
  6751. test -z "$as_dir" && as_dir=.
  6752. for ac_exec_ext in '' $ac_executable_extensions; do
  6753. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6754. ac_cv_path_XMLLINT="$as_dir/$ac_word$ac_exec_ext"
  6755. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6756. break 2
  6757. fi
  6758. done
  6759. done
  6760. IFS=$as_save_IFS
  6761. test -z "$ac_cv_path_XMLLINT" && ac_cv_path_XMLLINT=":"
  6762. ;;
  6763. esac
  6764. fi
  6765. XMLLINT=$ac_cv_path_XMLLINT
  6766. if test -n "$XMLLINT"; then
  6767. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XMLLINT" >&5
  6768. $as_echo "$XMLLINT" >&6; }
  6769. else
  6770. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6771. $as_echo "no" >&6; }
  6772. fi
  6773. # Extract the first word of "xmlstarlet", so it can be a program name with args.
  6774. set dummy xmlstarlet; ac_word=$2
  6775. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6776. $as_echo_n "checking for $ac_word... " >&6; }
  6777. if ${ac_cv_path_XMLSTARLET+:} false; then :
  6778. $as_echo_n "(cached) " >&6
  6779. else
  6780. case $XMLSTARLET in
  6781. [\\/]* | ?:[\\/]*)
  6782. ac_cv_path_XMLSTARLET="$XMLSTARLET" # Let the user override the test with a path.
  6783. ;;
  6784. *)
  6785. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6786. for as_dir in $PATH
  6787. do
  6788. IFS=$as_save_IFS
  6789. test -z "$as_dir" && as_dir=.
  6790. for ac_exec_ext in '' $ac_executable_extensions; do
  6791. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6792. ac_cv_path_XMLSTARLET="$as_dir/$ac_word$ac_exec_ext"
  6793. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6794. break 2
  6795. fi
  6796. done
  6797. done
  6798. IFS=$as_save_IFS
  6799. test -z "$ac_cv_path_XMLSTARLET" && ac_cv_path_XMLSTARLET=":"
  6800. ;;
  6801. esac
  6802. fi
  6803. XMLSTARLET=$ac_cv_path_XMLSTARLET
  6804. if test -n "$XMLSTARLET"; then
  6805. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XMLSTARLET" >&5
  6806. $as_echo "$XMLSTARLET" >&6; }
  6807. else
  6808. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6809. $as_echo "no" >&6; }
  6810. fi
  6811. # Extract the first word of "git", so it can be a program name with args.
  6812. set dummy git; ac_word=$2
  6813. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6814. $as_echo_n "checking for $ac_word... " >&6; }
  6815. if ${ac_cv_path_GIT+:} false; then :
  6816. $as_echo_n "(cached) " >&6
  6817. else
  6818. case $GIT in
  6819. [\\/]* | ?:[\\/]*)
  6820. ac_cv_path_GIT="$GIT" # Let the user override the test with a path.
  6821. ;;
  6822. *)
  6823. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6824. for as_dir in $PATH
  6825. do
  6826. IFS=$as_save_IFS
  6827. test -z "$as_dir" && as_dir=.
  6828. for ac_exec_ext in '' $ac_executable_extensions; do
  6829. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6830. ac_cv_path_GIT="$as_dir/$ac_word$ac_exec_ext"
  6831. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6832. break 2
  6833. fi
  6834. done
  6835. done
  6836. IFS=$as_save_IFS
  6837. test -z "$ac_cv_path_GIT" && ac_cv_path_GIT=":"
  6838. ;;
  6839. esac
  6840. fi
  6841. GIT=$ac_cv_path_GIT
  6842. if test -n "$GIT"; then
  6843. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GIT" >&5
  6844. $as_echo "$GIT" >&6; }
  6845. else
  6846. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6847. $as_echo "no" >&6; }
  6848. fi
  6849. if test "${WGET}" != ":" ; then
  6850. DOWNLOAD=${WGET}
  6851. else if test "${CURL}" != ":" ; then
  6852. DOWNLOAD="${CURL} -O --progress-bar -w \"%{url_effective}\n\""
  6853. else
  6854. # Extract the first word of "fetch", so it can be a program name with args.
  6855. set dummy fetch; ac_word=$2
  6856. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6857. $as_echo_n "checking for $ac_word... " >&6; }
  6858. if ${ac_cv_path_FETCH+:} false; then :
  6859. $as_echo_n "(cached) " >&6
  6860. else
  6861. case $FETCH in
  6862. [\\/]* | ?:[\\/]*)
  6863. ac_cv_path_FETCH="$FETCH" # Let the user override the test with a path.
  6864. ;;
  6865. *)
  6866. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6867. for as_dir in $PATH
  6868. do
  6869. IFS=$as_save_IFS
  6870. test -z "$as_dir" && as_dir=.
  6871. for ac_exec_ext in '' $ac_executable_extensions; do
  6872. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6873. ac_cv_path_FETCH="$as_dir/$ac_word$ac_exec_ext"
  6874. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6875. break 2
  6876. fi
  6877. done
  6878. done
  6879. IFS=$as_save_IFS
  6880. test -z "$ac_cv_path_FETCH" && ac_cv_path_FETCH=":"
  6881. ;;
  6882. esac
  6883. fi
  6884. FETCH=$ac_cv_path_FETCH
  6885. if test -n "$FETCH"; then
  6886. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FETCH" >&5
  6887. $as_echo "$FETCH" >&6; }
  6888. else
  6889. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6890. $as_echo "no" >&6; }
  6891. fi
  6892. DOWNLOAD=${FETCH}
  6893. fi
  6894. fi
  6895. # Extract the first word of "ldconfig", so it can be a program name with args.
  6896. set dummy ldconfig; ac_word=$2
  6897. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6898. $as_echo_n "checking for $ac_word... " >&6; }
  6899. if ${ac_cv_path_LDCONFIG+:} false; then :
  6900. $as_echo_n "(cached) " >&6
  6901. else
  6902. case $LDCONFIG in
  6903. [\\/]* | ?:[\\/]*)
  6904. ac_cv_path_LDCONFIG="$LDCONFIG" # Let the user override the test with a path.
  6905. ;;
  6906. *)
  6907. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6908. for as_dir in $PATH
  6909. do
  6910. IFS=$as_save_IFS
  6911. test -z "$as_dir" && as_dir=.
  6912. for ac_exec_ext in '' $ac_executable_extensions; do
  6913. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6914. ac_cv_path_LDCONFIG="$as_dir/$ac_word$ac_exec_ext"
  6915. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6916. break 2
  6917. fi
  6918. done
  6919. done
  6920. IFS=$as_save_IFS
  6921. test -z "$ac_cv_path_LDCONFIG" && ac_cv_path_LDCONFIG=":"
  6922. ;;
  6923. esac
  6924. fi
  6925. LDCONFIG=$ac_cv_path_LDCONFIG
  6926. if test -n "$LDCONFIG"; then
  6927. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDCONFIG" >&5
  6928. $as_echo "$LDCONFIG" >&6; }
  6929. else
  6930. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6931. $as_echo "no" >&6; }
  6932. fi
  6933. # Extract the first word of "sha1sum", so it can be a program name with args.
  6934. set dummy sha1sum; ac_word=$2
  6935. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6936. $as_echo_n "checking for $ac_word... " >&6; }
  6937. if ${ac_cv_path_SHA1SUM+:} false; then :
  6938. $as_echo_n "(cached) " >&6
  6939. else
  6940. case $SHA1SUM in
  6941. [\\/]* | ?:[\\/]*)
  6942. ac_cv_path_SHA1SUM="$SHA1SUM" # Let the user override the test with a path.
  6943. ;;
  6944. *)
  6945. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6946. for as_dir in $PATH
  6947. do
  6948. IFS=$as_save_IFS
  6949. test -z "$as_dir" && as_dir=.
  6950. for ac_exec_ext in '' $ac_executable_extensions; do
  6951. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6952. ac_cv_path_SHA1SUM="$as_dir/$ac_word$ac_exec_ext"
  6953. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6954. break 2
  6955. fi
  6956. done
  6957. done
  6958. IFS=$as_save_IFS
  6959. test -z "$ac_cv_path_SHA1SUM" && ac_cv_path_SHA1SUM="$ac_aux_dir/build_tools/sha1sum-sh"
  6960. ;;
  6961. esac
  6962. fi
  6963. SHA1SUM=$ac_cv_path_SHA1SUM
  6964. if test -n "$SHA1SUM"; then
  6965. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHA1SUM" >&5
  6966. $as_echo "$SHA1SUM" >&6; }
  6967. else
  6968. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6969. $as_echo "no" >&6; }
  6970. fi
  6971. # Extract the first word of "openssl", so it can be a program name with args.
  6972. set dummy openssl; ac_word=$2
  6973. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6974. $as_echo_n "checking for $ac_word... " >&6; }
  6975. if ${ac_cv_path_OPENSSL+:} false; then :
  6976. $as_echo_n "(cached) " >&6
  6977. else
  6978. case $OPENSSL in
  6979. [\\/]* | ?:[\\/]*)
  6980. ac_cv_path_OPENSSL="$OPENSSL" # Let the user override the test with a path.
  6981. ;;
  6982. *)
  6983. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6984. for as_dir in $PATH
  6985. do
  6986. IFS=$as_save_IFS
  6987. test -z "$as_dir" && as_dir=.
  6988. for ac_exec_ext in '' $ac_executable_extensions; do
  6989. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6990. ac_cv_path_OPENSSL="$as_dir/$ac_word$ac_exec_ext"
  6991. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6992. break 2
  6993. fi
  6994. done
  6995. done
  6996. IFS=$as_save_IFS
  6997. test -z "$ac_cv_path_OPENSSL" && ac_cv_path_OPENSSL=":"
  6998. ;;
  6999. esac
  7000. fi
  7001. OPENSSL=$ac_cv_path_OPENSSL
  7002. if test -n "$OPENSSL"; then
  7003. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENSSL" >&5
  7004. $as_echo "$OPENSSL" >&6; }
  7005. else
  7006. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  7007. $as_echo "no" >&6; }
  7008. fi
  7009. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bison that supports parse-param" >&5
  7010. $as_echo_n "checking for bison that supports parse-param... " >&6; }
  7011. if ${ac_cv_path_BISON2+:} false; then :
  7012. $as_echo_n "(cached) " >&6
  7013. else
  7014. if test "x$BISON" != "x:" ; then
  7015. # Create a temporary directory $tmp in $TMPDIR (default /tmp).
  7016. # Use mktemp if possible; otherwise fall back on mkdir,
  7017. # with $RANDOM to make collisions less likely.
  7018. : ${TMPDIR=/tmp}
  7019. {
  7020. tmp=`
  7021. (umask 077 && mktemp -d "$TMPDIR/fooXXXXXX") 2>/dev/null
  7022. ` &&
  7023. test -n "$tmp" && test -d "$tmp"
  7024. } || {
  7025. tmp=$TMPDIR/foo$$-$RANDOM
  7026. (umask 077 && mkdir "$tmp")
  7027. } || exit $?
  7028. cat >$tmp/test.y <<__EOL__
  7029. %parse-param {struct parse_io *parseio}
  7030. %%
  7031. file : { \$\$ = parseio->pval = 1; }
  7032. ;
  7033. %%
  7034. __EOL__
  7035. ${BISON} -o ${tmp}/test.tab.c ${tmp}/test.y >/dev/null 2>&1
  7036. if test -e "${tmp}/test.tab.c"; then
  7037. ac_cv_path_BISON2=${BISON}
  7038. fi
  7039. rm -rf ${tmp}
  7040. fi
  7041. fi
  7042. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_BISON2" >&5
  7043. $as_echo "$ac_cv_path_BISON2" >&6; }
  7044. if test "x${ac_cv_path_BISON2}" = "x" ; then
  7045. BISON=:
  7046. PBX_BISON=0
  7047. else
  7048. PBX_BISON=1
  7049. fi
  7050. if test "x${FLEX}" = "x:" ; then
  7051. PBX_FLEX=0
  7052. else
  7053. PBX_FLEX=1
  7054. fi
  7055. if test -n "$ac_tool_prefix"; then
  7056. # Extract the first word of "${ac_tool_prefix}soxmix", so it can be a program name with args.
  7057. set dummy ${ac_tool_prefix}soxmix; ac_word=$2
  7058. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  7059. $as_echo_n "checking for $ac_word... " >&6; }
  7060. if ${ac_cv_prog_SOXMIX+:} false; then :
  7061. $as_echo_n "(cached) " >&6
  7062. else
  7063. if test -n "$SOXMIX"; then
  7064. ac_cv_prog_SOXMIX="$SOXMIX" # Let the user override the test.
  7065. else
  7066. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  7067. for as_dir in $PATH
  7068. do
  7069. IFS=$as_save_IFS
  7070. test -z "$as_dir" && as_dir=.
  7071. for ac_exec_ext in '' $ac_executable_extensions; do
  7072. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  7073. ac_cv_prog_SOXMIX="${ac_tool_prefix}soxmix"
  7074. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  7075. break 2
  7076. fi
  7077. done
  7078. done
  7079. IFS=$as_save_IFS
  7080. fi
  7081. fi
  7082. SOXMIX=$ac_cv_prog_SOXMIX
  7083. if test -n "$SOXMIX"; then
  7084. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SOXMIX" >&5
  7085. $as_echo "$SOXMIX" >&6; }
  7086. else
  7087. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  7088. $as_echo "no" >&6; }
  7089. fi
  7090. fi
  7091. if test -z "$ac_cv_prog_SOXMIX"; then
  7092. ac_ct_SOXMIX=$SOXMIX
  7093. # Extract the first word of "soxmix", so it can be a program name with args.
  7094. set dummy soxmix; ac_word=$2
  7095. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  7096. $as_echo_n "checking for $ac_word... " >&6; }
  7097. if ${ac_cv_prog_ac_ct_SOXMIX+:} false; then :
  7098. $as_echo_n "(cached) " >&6
  7099. else
  7100. if test -n "$ac_ct_SOXMIX"; then
  7101. ac_cv_prog_ac_ct_SOXMIX="$ac_ct_SOXMIX" # Let the user override the test.
  7102. else
  7103. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  7104. for as_dir in $PATH
  7105. do
  7106. IFS=$as_save_IFS
  7107. test -z "$as_dir" && as_dir=.
  7108. for ac_exec_ext in '' $ac_executable_extensions; do
  7109. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  7110. ac_cv_prog_ac_ct_SOXMIX="soxmix"
  7111. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  7112. break 2
  7113. fi
  7114. done
  7115. done
  7116. IFS=$as_save_IFS
  7117. fi
  7118. fi
  7119. ac_ct_SOXMIX=$ac_cv_prog_ac_ct_SOXMIX
  7120. if test -n "$ac_ct_SOXMIX"; then
  7121. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_SOXMIX" >&5
  7122. $as_echo "$ac_ct_SOXMIX" >&6; }
  7123. else
  7124. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  7125. $as_echo "no" >&6; }
  7126. fi
  7127. if test "x$ac_ct_SOXMIX" = x; then
  7128. SOXMIX=":"
  7129. else
  7130. case $cross_compiling:$ac_tool_warned in
  7131. yes:)
  7132. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  7133. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  7134. ac_tool_warned=yes ;;
  7135. esac
  7136. SOXMIX=$ac_ct_SOXMIX
  7137. fi
  7138. else
  7139. SOXMIX="$ac_cv_prog_SOXMIX"
  7140. fi
  7141. if test "${SOXMIX}" != ":" ; then
  7142. $as_echo "#define HAVE_SOXMIX 1" >>confdefs.h
  7143. fi
  7144. for ac_prog in md5 md5sum gmd5sum digest
  7145. do
  7146. # Extract the first word of "$ac_prog", so it can be a program name with args.
  7147. set dummy $ac_prog; ac_word=$2
  7148. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  7149. $as_echo_n "checking for $ac_word... " >&6; }
  7150. if ${ac_cv_prog_MD5+:} false; then :
  7151. $as_echo_n "(cached) " >&6
  7152. else
  7153. if test -n "$MD5"; then
  7154. ac_cv_prog_MD5="$MD5" # Let the user override the test.
  7155. else
  7156. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  7157. for as_dir in $PATH
  7158. do
  7159. IFS=$as_save_IFS
  7160. test -z "$as_dir" && as_dir=.
  7161. for ac_exec_ext in '' $ac_executable_extensions; do
  7162. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  7163. ac_cv_prog_MD5="$ac_prog"
  7164. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  7165. break 2
  7166. fi
  7167. done
  7168. done
  7169. IFS=$as_save_IFS
  7170. fi
  7171. fi
  7172. MD5=$ac_cv_prog_MD5
  7173. if test -n "$MD5"; then
  7174. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MD5" >&5
  7175. $as_echo "$MD5" >&6; }
  7176. else
  7177. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  7178. $as_echo "no" >&6; }
  7179. fi
  7180. test -n "$MD5" && break
  7181. done
  7182. if test "${MD5}" = "digest" ; then
  7183. MD5="${MD5} -a md5"
  7184. fi
  7185. ac_ext=c
  7186. ac_cpp='$CPP $CPPFLAGS'
  7187. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  7188. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  7189. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  7190. acx_pthread_ok=no
  7191. # We used to check for pthread.h first, but this fails if pthread.h
  7192. # requires special compiler flags (e.g. on True64 or Sequent).
  7193. # It gets checked for in the link test anyway.
  7194. # First of all, check if the user has set any of the PTHREAD_LIBS,
  7195. # etcetera environment variables, and if threads linking works using
  7196. # them:
  7197. if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
  7198. save_CFLAGS="$CFLAGS"
  7199. CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
  7200. save_LIBS="$LIBS"
  7201. LIBS="$PTHREAD_LIBS $LIBS"
  7202. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
  7203. $as_echo_n "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... " >&6; }
  7204. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  7205. /* end confdefs.h. */
  7206. /* Override any GCC internal prototype to avoid an error.
  7207. Use char because int might match the return type of a GCC
  7208. builtin and then its argument prototype would still apply. */
  7209. #ifdef __cplusplus
  7210. extern "C"
  7211. #endif
  7212. char pthread_join ();
  7213. int
  7214. main ()
  7215. {
  7216. return pthread_join ();
  7217. ;
  7218. return 0;
  7219. }
  7220. _ACEOF
  7221. if ac_fn_c_try_link "$LINENO"; then :
  7222. acx_pthread_ok=yes
  7223. fi
  7224. rm -f core conftest.err conftest.$ac_objext \
  7225. conftest$ac_exeext conftest.$ac_ext
  7226. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_pthread_ok" >&5
  7227. $as_echo "$acx_pthread_ok" >&6; }
  7228. if test x"$acx_pthread_ok" = xno; then
  7229. PTHREAD_LIBS=""
  7230. PTHREAD_CFLAGS=""
  7231. fi
  7232. LIBS="$save_LIBS"
  7233. CFLAGS="$save_CFLAGS"
  7234. fi
  7235. # We must check for the threads library under a number of different
  7236. # names; the ordering is very important because some systems
  7237. # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
  7238. # libraries is broken (non-POSIX).
  7239. # Create a list of thread flags to try. Items starting with a "-" are
  7240. # C compiler flags, and other items are library names, except for "none"
  7241. # which indicates that we try without any flags at all, and "pthread-config"
  7242. # which is a program returning the flags for the Pth emulation library.
  7243. acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
  7244. # The ordering *is* (sometimes) important. Some notes on the
  7245. # individual items follow:
  7246. # pthreads: AIX (must check this before -lpthread)
  7247. # none: in case threads are in libc; should be tried before -Kthread and
  7248. # other compiler flags to prevent continual compiler warnings
  7249. # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
  7250. # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
  7251. # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
  7252. # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
  7253. # -pthreads: Solaris/gcc
  7254. # -mthreads: Mingw32/gcc, Lynx/gcc
  7255. # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
  7256. # doesn't hurt to check since this sometimes defines pthreads too;
  7257. # also defines -D_REENTRANT)
  7258. # ... -mt is also the pthreads flag for HP/aCC
  7259. # pthread: Linux, etcetera
  7260. # --thread-safe: KAI C++
  7261. # pthread-config: use pthread-config program (for GNU Pth library)
  7262. case "${host_cpu}-${host_os}" in
  7263. *solaris*)
  7264. # On Solaris (at least, for some versions), libc contains stubbed
  7265. # (non-functional) versions of the pthreads routines, so link-based
  7266. # tests will erroneously succeed. (We need to link with -pthreads/-mt/
  7267. # -lpthread.) (The stubs are missing pthread_cleanup_push, or rather
  7268. # a function called by this macro, so we could check for that, but
  7269. # who knows whether they'll stub that too in a future libc.) So,
  7270. # we'll just look for -pthreads and -lpthread first:
  7271. acx_pthread_flags="-pthreads pthread -mt -pthread $acx_pthread_flags"
  7272. ;;
  7273. esac
  7274. if test x"$acx_pthread_ok" = xno; then
  7275. for flag in $acx_pthread_flags; do
  7276. case $flag in
  7277. none)
  7278. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
  7279. $as_echo_n "checking whether pthreads work without any flags... " >&6; }
  7280. ;;
  7281. -*)
  7282. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $flag" >&5
  7283. $as_echo_n "checking whether pthreads work with $flag... " >&6; }
  7284. PTHREAD_CFLAGS="$flag"
  7285. ;;
  7286. pthread-config)
  7287. # Extract the first word of "pthread-config", so it can be a program name with args.
  7288. set dummy pthread-config; ac_word=$2
  7289. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  7290. $as_echo_n "checking for $ac_word... " >&6; }
  7291. if ${ac_cv_prog_acx_pthread_config+:} false; then :
  7292. $as_echo_n "(cached) " >&6
  7293. else
  7294. if test -n "$acx_pthread_config"; then
  7295. ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
  7296. else
  7297. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  7298. for as_dir in $PATH
  7299. do
  7300. IFS=$as_save_IFS
  7301. test -z "$as_dir" && as_dir=.
  7302. for ac_exec_ext in '' $ac_executable_extensions; do
  7303. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  7304. ac_cv_prog_acx_pthread_config="yes"
  7305. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  7306. break 2
  7307. fi
  7308. done
  7309. done
  7310. IFS=$as_save_IFS
  7311. test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
  7312. fi
  7313. fi
  7314. acx_pthread_config=$ac_cv_prog_acx_pthread_config
  7315. if test -n "$acx_pthread_config"; then
  7316. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_pthread_config" >&5
  7317. $as_echo "$acx_pthread_config" >&6; }
  7318. else
  7319. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  7320. $as_echo "no" >&6; }
  7321. fi
  7322. if test x"$acx_pthread_config" = xno; then continue; fi
  7323. PTHREAD_CFLAGS="`pthread-config --cflags`"
  7324. PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
  7325. ;;
  7326. *)
  7327. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$flag" >&5
  7328. $as_echo_n "checking for the pthreads library -l$flag... " >&6; }
  7329. PTHREAD_LIBS="-l$flag"
  7330. ;;
  7331. esac
  7332. save_LIBS="$LIBS"
  7333. save_CFLAGS="$CFLAGS"
  7334. LIBS="$PTHREAD_LIBS $LIBS"
  7335. CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
  7336. # Check for various functions. We must include pthread.h,
  7337. # since some functions may be macros. (On the Sequent, we
  7338. # need a special flag -Kthread to make this header compile.)
  7339. # We check for pthread_join because it is in -lpthread on IRIX
  7340. # while pthread_create is in libc. We check for pthread_attr_init
  7341. # due to DEC craziness with -lpthreads. We check for
  7342. # pthread_cleanup_push because it is one of the few pthread
  7343. # functions on Solaris that doesn't have a non-functional libc stub.
  7344. # We try pthread_create on general principles.
  7345. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  7346. /* end confdefs.h. */
  7347. #include <pthread.h>
  7348. int
  7349. main ()
  7350. {
  7351. pthread_t th; pthread_join(th, 0);
  7352. pthread_attr_init(0); pthread_cleanup_push(0, 0);
  7353. pthread_create(0,0,0,0); pthread_cleanup_pop(0);
  7354. ;
  7355. return 0;
  7356. }
  7357. _ACEOF
  7358. if ac_fn_c_try_link "$LINENO"; then :
  7359. acx_pthread_ok=yes
  7360. fi
  7361. rm -f core conftest.err conftest.$ac_objext \
  7362. conftest$ac_exeext conftest.$ac_ext
  7363. LIBS="$save_LIBS"
  7364. CFLAGS="$save_CFLAGS"
  7365. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_pthread_ok" >&5
  7366. $as_echo "$acx_pthread_ok" >&6; }
  7367. if test "x$acx_pthread_ok" = xyes; then
  7368. break;
  7369. fi
  7370. PTHREAD_LIBS=""
  7371. PTHREAD_CFLAGS=""
  7372. done
  7373. fi
  7374. # Various other checks:
  7375. if test "x$acx_pthread_ok" = xyes; then
  7376. save_LIBS="$LIBS"
  7377. LIBS="$PTHREAD_LIBS $LIBS"
  7378. save_CFLAGS="$CFLAGS"
  7379. CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
  7380. # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
  7381. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
  7382. $as_echo_n "checking for joinable pthread attribute... " >&6; }
  7383. attr_name=unknown
  7384. for attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
  7385. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  7386. /* end confdefs.h. */
  7387. #include <pthread.h>
  7388. int
  7389. main ()
  7390. {
  7391. int attr=$attr; return attr;
  7392. ;
  7393. return 0;
  7394. }
  7395. _ACEOF
  7396. if ac_fn_c_try_link "$LINENO"; then :
  7397. attr_name=$attr; break
  7398. fi
  7399. rm -f core conftest.err conftest.$ac_objext \
  7400. conftest$ac_exeext conftest.$ac_ext
  7401. done
  7402. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $attr_name" >&5
  7403. $as_echo "$attr_name" >&6; }
  7404. if test "$attr_name" != PTHREAD_CREATE_JOINABLE; then
  7405. cat >>confdefs.h <<_ACEOF
  7406. #define PTHREAD_CREATE_JOINABLE $attr_name
  7407. _ACEOF
  7408. fi
  7409. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if more special flags are required for pthreads" >&5
  7410. $as_echo_n "checking if more special flags are required for pthreads... " >&6; }
  7411. flag=no
  7412. case "${host_cpu}-${host_os}" in
  7413. *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
  7414. *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
  7415. esac
  7416. { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${flag}" >&5
  7417. $as_echo "${flag}" >&6; }
  7418. if test "x$flag" != xno; then
  7419. PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
  7420. fi
  7421. LIBS="$save_LIBS"
  7422. CFLAGS="$save_CFLAGS"
  7423. # More AIX lossage: must compile with xlc_r or cc_r
  7424. if test x"$GCC" != xyes; then
  7425. for ac_prog in xlc_r cc_r
  7426. do
  7427. # Extract the first word of "$ac_prog", so it can be a program name with args.
  7428. set dummy $ac_prog; ac_word=$2
  7429. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  7430. $as_echo_n "checking for $ac_word... " >&6; }
  7431. if ${ac_cv_prog_PTHREAD_CC+:} false; then :
  7432. $as_echo_n "(cached) " >&6
  7433. else
  7434. if test -n "$PTHREAD_CC"; then
  7435. ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
  7436. else
  7437. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  7438. for as_dir in $PATH
  7439. do
  7440. IFS=$as_save_IFS
  7441. test -z "$as_dir" && as_dir=.
  7442. for ac_exec_ext in '' $ac_executable_extensions; do
  7443. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  7444. ac_cv_prog_PTHREAD_CC="$ac_prog"
  7445. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  7446. break 2
  7447. fi
  7448. done
  7449. done
  7450. IFS=$as_save_IFS
  7451. fi
  7452. fi
  7453. PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
  7454. if test -n "$PTHREAD_CC"; then
  7455. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
  7456. $as_echo "$PTHREAD_CC" >&6; }
  7457. else
  7458. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  7459. $as_echo "no" >&6; }
  7460. fi
  7461. test -n "$PTHREAD_CC" && break
  7462. done
  7463. test -n "$PTHREAD_CC" || PTHREAD_CC="${CC}"
  7464. else
  7465. PTHREAD_CC=$CC
  7466. fi
  7467. else
  7468. PTHREAD_CC="$CC"
  7469. fi
  7470. # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
  7471. if test x"$acx_pthread_ok" = xyes; then
  7472. $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
  7473. :
  7474. else
  7475. acx_pthread_ok=no
  7476. fi
  7477. ac_ext=c
  7478. ac_cpp='$CPP $CPPFLAGS'
  7479. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  7480. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  7481. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  7482. ac_ext=c
  7483. ac_cpp='$CPP $CPPFLAGS'
  7484. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  7485. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  7486. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  7487. # Check whether --enable-dev-mode was given.
  7488. if test "${enable_dev_mode+set}" = set; then :
  7489. enableval=$enable_dev_mode; case "${enableval}" in
  7490. y|ye|yes) AST_DEVMODE=yes ;;
  7491. n|no) AST_DEVMODE=no ;;
  7492. noisy)
  7493. AST_DEVMODE=yes
  7494. NOISY_BUILD=yes
  7495. ;;
  7496. strict)
  7497. AST_DEVMODE=yes
  7498. AST_DEVMODE_STRICT=yes
  7499. ;;
  7500. *) as_fn_error $? "bad value ${enableval} for --enable-dev-mode" "$LINENO" 5 ;;
  7501. esac
  7502. fi
  7503. AST_CODE_COVERAGE=no
  7504. # Check whether --enable-coverage was given.
  7505. if test "${enable_coverage+set}" = set; then :
  7506. enableval=$enable_coverage; case "${enableval}" in
  7507. y|ye|yes) AST_CODE_COVERAGE=yes ;;
  7508. n|no) AST_CODE_COVERAGE=no ;;
  7509. *) as_fn_error $? "bad value ${enableval} for --enable-coverage" "$LINENO" 5 ;;
  7510. esac
  7511. fi
  7512. # AST_EXT_LIB_SETUP is used to tell configure to handle variables for
  7513. # various packages.
  7514. # $1 is the prefix for the variables in makeopts and autoconfig.h
  7515. # $2 is the short comment, $4 is the long comment
  7516. # $3 is the name used in --with- or --without- flags for configure.
  7517. #
  7518. # Package option names should be in alphabetical order
  7519. # by the --with option name (the third field),
  7520. # to make things easier for the users.
  7521. ALSA_DESCRIP="Advanced Linux Sound Architecture"
  7522. ALSA_OPTION="asound"
  7523. PBX_ALSA=0
  7524. # Check whether --with-asound was given.
  7525. if test "${with_asound+set}" = set; then :
  7526. withval=$with_asound;
  7527. case ${withval} in
  7528. n|no)
  7529. USE_ALSA=no
  7530. # -1 is a magic value used by menuselect to know that the package
  7531. # was disabled, other than 'not found'
  7532. PBX_ALSA=-1
  7533. ;;
  7534. y|ye|yes)
  7535. ac_mandatory_list="${ac_mandatory_list} ALSA"
  7536. ;;
  7537. *)
  7538. ALSA_DIR="${withval}"
  7539. ac_mandatory_list="${ac_mandatory_list} ALSA"
  7540. ;;
  7541. esac
  7542. fi
  7543. BFD_DESCRIP="Debug symbol decoding"
  7544. BFD_OPTION="bfd"
  7545. PBX_BFD=0
  7546. # Check whether --with-bfd was given.
  7547. if test "${with_bfd+set}" = set; then :
  7548. withval=$with_bfd;
  7549. case ${withval} in
  7550. n|no)
  7551. USE_BFD=no
  7552. # -1 is a magic value used by menuselect to know that the package
  7553. # was disabled, other than 'not found'
  7554. PBX_BFD=-1
  7555. ;;
  7556. y|ye|yes)
  7557. ac_mandatory_list="${ac_mandatory_list} BFD"
  7558. ;;
  7559. *)
  7560. BFD_DIR="${withval}"
  7561. ac_mandatory_list="${ac_mandatory_list} BFD"
  7562. ;;
  7563. esac
  7564. fi
  7565. # BKTR is used for backtrace support on platforms that do not
  7566. # have it natively.
  7567. BKTR_DESCRIP="Stack Backtrace"
  7568. BKTR_OPTION="execinfo"
  7569. PBX_BKTR=0
  7570. # Check whether --with-execinfo was given.
  7571. if test "${with_execinfo+set}" = set; then :
  7572. withval=$with_execinfo;
  7573. case ${withval} in
  7574. n|no)
  7575. USE_BKTR=no
  7576. # -1 is a magic value used by menuselect to know that the package
  7577. # was disabled, other than 'not found'
  7578. PBX_BKTR=-1
  7579. ;;
  7580. y|ye|yes)
  7581. ac_mandatory_list="${ac_mandatory_list} BKTR"
  7582. ;;
  7583. *)
  7584. BKTR_DIR="${withval}"
  7585. ac_mandatory_list="${ac_mandatory_list} BKTR"
  7586. ;;
  7587. esac
  7588. fi
  7589. BLUETOOTH_DESCRIP="Bluetooth"
  7590. BLUETOOTH_OPTION="bluetooth"
  7591. PBX_BLUETOOTH=0
  7592. # Check whether --with-bluetooth was given.
  7593. if test "${with_bluetooth+set}" = set; then :
  7594. withval=$with_bluetooth;
  7595. case ${withval} in
  7596. n|no)
  7597. USE_BLUETOOTH=no
  7598. # -1 is a magic value used by menuselect to know that the package
  7599. # was disabled, other than 'not found'
  7600. PBX_BLUETOOTH=-1
  7601. ;;
  7602. y|ye|yes)
  7603. ac_mandatory_list="${ac_mandatory_list} BLUETOOTH"
  7604. ;;
  7605. *)
  7606. BLUETOOTH_DIR="${withval}"
  7607. ac_mandatory_list="${ac_mandatory_list} BLUETOOTH"
  7608. ;;
  7609. esac
  7610. fi
  7611. CAP_DESCRIP="POSIX 1.e capabilities"
  7612. CAP_OPTION="cap"
  7613. PBX_CAP=0
  7614. # Check whether --with-cap was given.
  7615. if test "${with_cap+set}" = set; then :
  7616. withval=$with_cap;
  7617. case ${withval} in
  7618. n|no)
  7619. USE_CAP=no
  7620. # -1 is a magic value used by menuselect to know that the package
  7621. # was disabled, other than 'not found'
  7622. PBX_CAP=-1
  7623. ;;
  7624. y|ye|yes)
  7625. ac_mandatory_list="${ac_mandatory_list} CAP"
  7626. ;;
  7627. *)
  7628. CAP_DIR="${withval}"
  7629. ac_mandatory_list="${ac_mandatory_list} CAP"
  7630. ;;
  7631. esac
  7632. fi
  7633. COROSYNC_DESCRIP="Corosync"
  7634. COROSYNC_OPTION="cpg"
  7635. PBX_COROSYNC=0
  7636. # Check whether --with-cpg was given.
  7637. if test "${with_cpg+set}" = set; then :
  7638. withval=$with_cpg;
  7639. case ${withval} in
  7640. n|no)
  7641. USE_COROSYNC=no
  7642. # -1 is a magic value used by menuselect to know that the package
  7643. # was disabled, other than 'not found'
  7644. PBX_COROSYNC=-1
  7645. ;;
  7646. y|ye|yes)
  7647. ac_mandatory_list="${ac_mandatory_list} COROSYNC"
  7648. ;;
  7649. *)
  7650. COROSYNC_DIR="${withval}"
  7651. ac_mandatory_list="${ac_mandatory_list} COROSYNC"
  7652. ;;
  7653. esac
  7654. fi
  7655. COROSYNC_CFG_STATE_TRACK_DESCRIP="A callback only in corosync 1.x"
  7656. COROSYNC_CFG_STATE_TRACK_OPTION=cfg
  7657. COROSYNC_CFG_STATE_TRACK_DIR=${COROSYNC_DIR}
  7658. PBX_COROSYNC_CFG_STATE_TRACK=0
  7659. CURSES_DESCRIP="curses"
  7660. CURSES_OPTION="curses"
  7661. PBX_CURSES=0
  7662. # Check whether --with-curses was given.
  7663. if test "${with_curses+set}" = set; then :
  7664. withval=$with_curses;
  7665. case ${withval} in
  7666. n|no)
  7667. USE_CURSES=no
  7668. # -1 is a magic value used by menuselect to know that the package
  7669. # was disabled, other than 'not found'
  7670. PBX_CURSES=-1
  7671. ;;
  7672. y|ye|yes)
  7673. ac_mandatory_list="${ac_mandatory_list} CURSES"
  7674. ;;
  7675. *)
  7676. CURSES_DIR="${withval}"
  7677. ac_mandatory_list="${ac_mandatory_list} CURSES"
  7678. ;;
  7679. esac
  7680. fi
  7681. CRYPT_DESCRIP="password and data encryption"
  7682. CRYPT_OPTION="crypt"
  7683. PBX_CRYPT=0
  7684. # Check whether --with-crypt was given.
  7685. if test "${with_crypt+set}" = set; then :
  7686. withval=$with_crypt;
  7687. case ${withval} in
  7688. n|no)
  7689. USE_CRYPT=no
  7690. # -1 is a magic value used by menuselect to know that the package
  7691. # was disabled, other than 'not found'
  7692. PBX_CRYPT=-1
  7693. ;;
  7694. y|ye|yes)
  7695. ac_mandatory_list="${ac_mandatory_list} CRYPT"
  7696. ;;
  7697. *)
  7698. CRYPT_DIR="${withval}"
  7699. ac_mandatory_list="${ac_mandatory_list} CRYPT"
  7700. ;;
  7701. esac
  7702. fi
  7703. CRYPTO_DESCRIP="OpenSSL Cryptography"
  7704. CRYPTO_OPTION="crypto"
  7705. PBX_CRYPTO=0
  7706. # Check whether --with-crypto was given.
  7707. if test "${with_crypto+set}" = set; then :
  7708. withval=$with_crypto;
  7709. case ${withval} in
  7710. n|no)
  7711. USE_CRYPTO=no
  7712. # -1 is a magic value used by menuselect to know that the package
  7713. # was disabled, other than 'not found'
  7714. PBX_CRYPTO=-1
  7715. ;;
  7716. y|ye|yes)
  7717. ac_mandatory_list="${ac_mandatory_list} CRYPTO"
  7718. ;;
  7719. *)
  7720. CRYPTO_DIR="${withval}"
  7721. ac_mandatory_list="${ac_mandatory_list} CRYPTO"
  7722. ;;
  7723. esac
  7724. fi
  7725. OPENSSL_SRTP_DESCRIP="OpenSSL SRTP Extension Support"
  7726. OPENSSL_SRTP_OPTION=crypto
  7727. OPENSSL_SRTP_DIR=${CRYPTO_DIR}
  7728. PBX_OPENSSL_SRTP=0
  7729. DAHDI_DESCRIP="DAHDI"
  7730. DAHDI_OPTION="dahdi"
  7731. PBX_DAHDI=0
  7732. # Check whether --with-dahdi was given.
  7733. if test "${with_dahdi+set}" = set; then :
  7734. withval=$with_dahdi;
  7735. case ${withval} in
  7736. n|no)
  7737. USE_DAHDI=no
  7738. # -1 is a magic value used by menuselect to know that the package
  7739. # was disabled, other than 'not found'
  7740. PBX_DAHDI=-1
  7741. ;;
  7742. y|ye|yes)
  7743. ac_mandatory_list="${ac_mandatory_list} DAHDI"
  7744. ;;
  7745. *)
  7746. DAHDI_DIR="${withval}"
  7747. ac_mandatory_list="${ac_mandatory_list} DAHDI"
  7748. ;;
  7749. esac
  7750. fi
  7751. FFMPEG_DESCRIP="Ffmpeg and avcodec"
  7752. FFMPEG_OPTION="avcodec"
  7753. PBX_FFMPEG=0
  7754. # Check whether --with-avcodec was given.
  7755. if test "${with_avcodec+set}" = set; then :
  7756. withval=$with_avcodec;
  7757. case ${withval} in
  7758. n|no)
  7759. USE_FFMPEG=no
  7760. # -1 is a magic value used by menuselect to know that the package
  7761. # was disabled, other than 'not found'
  7762. PBX_FFMPEG=-1
  7763. ;;
  7764. y|ye|yes)
  7765. ac_mandatory_list="${ac_mandatory_list} FFMPEG"
  7766. ;;
  7767. *)
  7768. FFMPEG_DIR="${withval}"
  7769. ac_mandatory_list="${ac_mandatory_list} FFMPEG"
  7770. ;;
  7771. esac
  7772. fi
  7773. GSM_DESCRIP="External GSM"
  7774. GSM_OPTION="gsm"
  7775. PBX_GSM=0
  7776. # Check whether --with-gsm was given.
  7777. if test "${with_gsm+set}" = set; then :
  7778. withval=$with_gsm;
  7779. case ${withval} in
  7780. n|no)
  7781. USE_GSM=no
  7782. # -1 is a magic value used by menuselect to know that the package
  7783. # was disabled, other than 'not found'
  7784. PBX_GSM=-1
  7785. ;;
  7786. y|ye|yes)
  7787. ac_mandatory_list="${ac_mandatory_list} GSM"
  7788. ;;
  7789. *)
  7790. GSM_DIR="${withval}"
  7791. ac_mandatory_list="${ac_mandatory_list} GSM"
  7792. ;;
  7793. esac
  7794. fi
  7795. ILBC_DESCRIP="System iLBC"
  7796. ILBC_OPTION="ilbc"
  7797. PBX_ILBC=0
  7798. # Check whether --with-ilbc was given.
  7799. if test "${with_ilbc+set}" = set; then :
  7800. withval=$with_ilbc;
  7801. case ${withval} in
  7802. n|no)
  7803. USE_ILBC=no
  7804. # -1 is a magic value used by menuselect to know that the package
  7805. # was disabled, other than 'not found'
  7806. PBX_ILBC=-1
  7807. ;;
  7808. y|ye|yes)
  7809. ac_mandatory_list="${ac_mandatory_list} ILBC"
  7810. ;;
  7811. *)
  7812. ILBC_DIR="${withval}"
  7813. ac_mandatory_list="${ac_mandatory_list} ILBC"
  7814. ;;
  7815. esac
  7816. fi
  7817. GTK2_DESCRIP="gtk2"
  7818. GTK2_OPTION="gtk2"
  7819. PBX_GTK2=0
  7820. # Check whether --with-gtk2 was given.
  7821. if test "${with_gtk2+set}" = set; then :
  7822. withval=$with_gtk2;
  7823. case ${withval} in
  7824. n|no)
  7825. USE_GTK2=no
  7826. # -1 is a magic value used by menuselect to know that the package
  7827. # was disabled, other than 'not found'
  7828. PBX_GTK2=-1
  7829. ;;
  7830. y|ye|yes)
  7831. ac_mandatory_list="${ac_mandatory_list} GTK2"
  7832. ;;
  7833. *)
  7834. GTK2_DIR="${withval}"
  7835. ac_mandatory_list="${ac_mandatory_list} GTK2"
  7836. ;;
  7837. esac
  7838. fi
  7839. GMIME_DESCRIP="GMime"
  7840. GMIME_OPTION="gmime"
  7841. PBX_GMIME=0
  7842. # Check whether --with-gmime was given.
  7843. if test "${with_gmime+set}" = set; then :
  7844. withval=$with_gmime;
  7845. case ${withval} in
  7846. n|no)
  7847. USE_GMIME=no
  7848. # -1 is a magic value used by menuselect to know that the package
  7849. # was disabled, other than 'not found'
  7850. PBX_GMIME=-1
  7851. ;;
  7852. y|ye|yes)
  7853. ac_mandatory_list="${ac_mandatory_list} GMIME"
  7854. ;;
  7855. *)
  7856. GMIME_DIR="${withval}"
  7857. ac_mandatory_list="${ac_mandatory_list} GMIME"
  7858. ;;
  7859. esac
  7860. fi
  7861. OPENH323_DESCRIP="OpenH323"
  7862. OPENH323_OPTION="h323"
  7863. PBX_OPENH323=0
  7864. # Check whether --with-h323 was given.
  7865. if test "${with_h323+set}" = set; then :
  7866. withval=$with_h323;
  7867. case ${withval} in
  7868. n|no)
  7869. USE_OPENH323=no
  7870. # -1 is a magic value used by menuselect to know that the package
  7871. # was disabled, other than 'not found'
  7872. PBX_OPENH323=-1
  7873. ;;
  7874. y|ye|yes)
  7875. ac_mandatory_list="${ac_mandatory_list} OPENH323"
  7876. ;;
  7877. *)
  7878. OPENH323_DIR="${withval}"
  7879. ac_mandatory_list="${ac_mandatory_list} OPENH323"
  7880. ;;
  7881. esac
  7882. fi
  7883. HOARD_DESCRIP="Hoard Memory Allocator"
  7884. HOARD_OPTION="hoard"
  7885. PBX_HOARD=0
  7886. # Check whether --with-hoard was given.
  7887. if test "${with_hoard+set}" = set; then :
  7888. withval=$with_hoard;
  7889. case ${withval} in
  7890. n|no)
  7891. USE_HOARD=no
  7892. # -1 is a magic value used by menuselect to know that the package
  7893. # was disabled, other than 'not found'
  7894. PBX_HOARD=-1
  7895. ;;
  7896. y|ye|yes)
  7897. ac_mandatory_list="${ac_mandatory_list} HOARD"
  7898. ;;
  7899. *)
  7900. HOARD_DIR="${withval}"
  7901. ac_mandatory_list="${ac_mandatory_list} HOARD"
  7902. ;;
  7903. esac
  7904. fi
  7905. ICAL_DESCRIP="iCal"
  7906. ICAL_OPTION="ical"
  7907. PBX_ICAL=0
  7908. # Check whether --with-ical was given.
  7909. if test "${with_ical+set}" = set; then :
  7910. withval=$with_ical;
  7911. case ${withval} in
  7912. n|no)
  7913. USE_ICAL=no
  7914. # -1 is a magic value used by menuselect to know that the package
  7915. # was disabled, other than 'not found'
  7916. PBX_ICAL=-1
  7917. ;;
  7918. y|ye|yes)
  7919. ac_mandatory_list="${ac_mandatory_list} ICAL"
  7920. ;;
  7921. *)
  7922. ICAL_DIR="${withval}"
  7923. ac_mandatory_list="${ac_mandatory_list} ICAL"
  7924. ;;
  7925. esac
  7926. fi
  7927. ICONV_DESCRIP="Iconv"
  7928. ICONV_OPTION="iconv"
  7929. PBX_ICONV=0
  7930. # Check whether --with-iconv was given.
  7931. if test "${with_iconv+set}" = set; then :
  7932. withval=$with_iconv;
  7933. case ${withval} in
  7934. n|no)
  7935. USE_ICONV=no
  7936. # -1 is a magic value used by menuselect to know that the package
  7937. # was disabled, other than 'not found'
  7938. PBX_ICONV=-1
  7939. ;;
  7940. y|ye|yes)
  7941. ac_mandatory_list="${ac_mandatory_list} ICONV"
  7942. ;;
  7943. *)
  7944. ICONV_DIR="${withval}"
  7945. ac_mandatory_list="${ac_mandatory_list} ICONV"
  7946. ;;
  7947. esac
  7948. fi
  7949. IKSEMEL_DESCRIP="Iksemel Jabber"
  7950. IKSEMEL_OPTION="iksemel"
  7951. PBX_IKSEMEL=0
  7952. # Check whether --with-iksemel was given.
  7953. if test "${with_iksemel+set}" = set; then :
  7954. withval=$with_iksemel;
  7955. case ${withval} in
  7956. n|no)
  7957. USE_IKSEMEL=no
  7958. # -1 is a magic value used by menuselect to know that the package
  7959. # was disabled, other than 'not found'
  7960. PBX_IKSEMEL=-1
  7961. ;;
  7962. y|ye|yes)
  7963. ac_mandatory_list="${ac_mandatory_list} IKSEMEL"
  7964. ;;
  7965. *)
  7966. IKSEMEL_DIR="${withval}"
  7967. ac_mandatory_list="${ac_mandatory_list} IKSEMEL"
  7968. ;;
  7969. esac
  7970. fi
  7971. IMAP_TK_DESCRIP="UW IMAP Toolkit"
  7972. IMAP_TK_OPTION="imap"
  7973. PBX_IMAP_TK=0
  7974. # Check whether --with-imap was given.
  7975. if test "${with_imap+set}" = set; then :
  7976. withval=$with_imap;
  7977. case ${withval} in
  7978. n|no)
  7979. USE_IMAP_TK=no
  7980. # -1 is a magic value used by menuselect to know that the package
  7981. # was disabled, other than 'not found'
  7982. PBX_IMAP_TK=-1
  7983. ;;
  7984. y|ye|yes)
  7985. ac_mandatory_list="${ac_mandatory_list} IMAP_TK"
  7986. ;;
  7987. *)
  7988. IMAP_TK_DIR="${withval}"
  7989. ac_mandatory_list="${ac_mandatory_list} IMAP_TK"
  7990. ;;
  7991. esac
  7992. fi
  7993. INOTIFY_DESCRIP="inotify support"
  7994. INOTIFY_OPTION="inotify"
  7995. PBX_INOTIFY=0
  7996. # Check whether --with-inotify was given.
  7997. if test "${with_inotify+set}" = set; then :
  7998. withval=$with_inotify;
  7999. case ${withval} in
  8000. n|no)
  8001. USE_INOTIFY=no
  8002. # -1 is a magic value used by menuselect to know that the package
  8003. # was disabled, other than 'not found'
  8004. PBX_INOTIFY=-1
  8005. ;;
  8006. y|ye|yes)
  8007. ac_mandatory_list="${ac_mandatory_list} INOTIFY"
  8008. ;;
  8009. *)
  8010. INOTIFY_DIR="${withval}"
  8011. ac_mandatory_list="${ac_mandatory_list} INOTIFY"
  8012. ;;
  8013. esac
  8014. fi
  8015. IODBC_DESCRIP="iODBC"
  8016. IODBC_OPTION="iodbc"
  8017. PBX_IODBC=0
  8018. # Check whether --with-iodbc was given.
  8019. if test "${with_iodbc+set}" = set; then :
  8020. withval=$with_iodbc;
  8021. case ${withval} in
  8022. n|no)
  8023. USE_IODBC=no
  8024. # -1 is a magic value used by menuselect to know that the package
  8025. # was disabled, other than 'not found'
  8026. PBX_IODBC=-1
  8027. ;;
  8028. y|ye|yes)
  8029. ac_mandatory_list="${ac_mandatory_list} IODBC"
  8030. ;;
  8031. *)
  8032. IODBC_DIR="${withval}"
  8033. ac_mandatory_list="${ac_mandatory_list} IODBC"
  8034. ;;
  8035. esac
  8036. fi
  8037. ISDNNET_DESCRIP="ISDN4Linux"
  8038. ISDNNET_OPTION="isdnnet"
  8039. PBX_ISDNNET=0
  8040. # Check whether --with-isdnnet was given.
  8041. if test "${with_isdnnet+set}" = set; then :
  8042. withval=$with_isdnnet;
  8043. case ${withval} in
  8044. n|no)
  8045. USE_ISDNNET=no
  8046. # -1 is a magic value used by menuselect to know that the package
  8047. # was disabled, other than 'not found'
  8048. PBX_ISDNNET=-1
  8049. ;;
  8050. y|ye|yes)
  8051. ac_mandatory_list="${ac_mandatory_list} ISDNNET"
  8052. ;;
  8053. *)
  8054. ISDNNET_DIR="${withval}"
  8055. ac_mandatory_list="${ac_mandatory_list} ISDNNET"
  8056. ;;
  8057. esac
  8058. fi
  8059. JACK_DESCRIP="Jack Audio Connection Kit"
  8060. JACK_OPTION="jack"
  8061. PBX_JACK=0
  8062. # Check whether --with-jack was given.
  8063. if test "${with_jack+set}" = set; then :
  8064. withval=$with_jack;
  8065. case ${withval} in
  8066. n|no)
  8067. USE_JACK=no
  8068. # -1 is a magic value used by menuselect to know that the package
  8069. # was disabled, other than 'not found'
  8070. PBX_JACK=-1
  8071. ;;
  8072. y|ye|yes)
  8073. ac_mandatory_list="${ac_mandatory_list} JACK"
  8074. ;;
  8075. *)
  8076. JACK_DIR="${withval}"
  8077. ac_mandatory_list="${ac_mandatory_list} JACK"
  8078. ;;
  8079. esac
  8080. fi
  8081. JANSSON_DESCRIP="Jansson JSON library"
  8082. JANSSON_OPTION="jansson"
  8083. PBX_JANSSON=0
  8084. # Check whether --with-jansson was given.
  8085. if test "${with_jansson+set}" = set; then :
  8086. withval=$with_jansson;
  8087. case ${withval} in
  8088. n|no)
  8089. USE_JANSSON=no
  8090. # -1 is a magic value used by menuselect to know that the package
  8091. # was disabled, other than 'not found'
  8092. PBX_JANSSON=-1
  8093. ;;
  8094. y|ye|yes)
  8095. ac_mandatory_list="${ac_mandatory_list} JANSSON"
  8096. ;;
  8097. *)
  8098. JANSSON_DIR="${withval}"
  8099. ac_mandatory_list="${ac_mandatory_list} JANSSON"
  8100. ;;
  8101. esac
  8102. fi
  8103. URIPARSER_DESCRIP="uriparser library"
  8104. URIPARSER_OPTION="uriparser"
  8105. PBX_URIPARSER=0
  8106. # Check whether --with-uriparser was given.
  8107. if test "${with_uriparser+set}" = set; then :
  8108. withval=$with_uriparser;
  8109. case ${withval} in
  8110. n|no)
  8111. USE_URIPARSER=no
  8112. # -1 is a magic value used by menuselect to know that the package
  8113. # was disabled, other than 'not found'
  8114. PBX_URIPARSER=-1
  8115. ;;
  8116. y|ye|yes)
  8117. ac_mandatory_list="${ac_mandatory_list} URIPARSER"
  8118. ;;
  8119. *)
  8120. URIPARSER_DIR="${withval}"
  8121. ac_mandatory_list="${ac_mandatory_list} URIPARSER"
  8122. ;;
  8123. esac
  8124. fi
  8125. KQUEUE_DESCRIP="kqueue support"
  8126. KQUEUE_OPTION="kqueue"
  8127. PBX_KQUEUE=0
  8128. # Check whether --with-kqueue was given.
  8129. if test "${with_kqueue+set}" = set; then :
  8130. withval=$with_kqueue;
  8131. case ${withval} in
  8132. n|no)
  8133. USE_KQUEUE=no
  8134. # -1 is a magic value used by menuselect to know that the package
  8135. # was disabled, other than 'not found'
  8136. PBX_KQUEUE=-1
  8137. ;;
  8138. y|ye|yes)
  8139. ac_mandatory_list="${ac_mandatory_list} KQUEUE"
  8140. ;;
  8141. *)
  8142. KQUEUE_DIR="${withval}"
  8143. ac_mandatory_list="${ac_mandatory_list} KQUEUE"
  8144. ;;
  8145. esac
  8146. fi
  8147. LDAP_DESCRIP="OpenLDAP"
  8148. LDAP_OPTION="ldap"
  8149. PBX_LDAP=0
  8150. # Check whether --with-ldap was given.
  8151. if test "${with_ldap+set}" = set; then :
  8152. withval=$with_ldap;
  8153. case ${withval} in
  8154. n|no)
  8155. USE_LDAP=no
  8156. # -1 is a magic value used by menuselect to know that the package
  8157. # was disabled, other than 'not found'
  8158. PBX_LDAP=-1
  8159. ;;
  8160. y|ye|yes)
  8161. ac_mandatory_list="${ac_mandatory_list} LDAP"
  8162. ;;
  8163. *)
  8164. LDAP_DIR="${withval}"
  8165. ac_mandatory_list="${ac_mandatory_list} LDAP"
  8166. ;;
  8167. esac
  8168. fi
  8169. # Check whether --with-libcurl was given.
  8170. if test "${with_libcurl+set}" = set; then :
  8171. withval=$with_libcurl; _libcurl_with=$withval
  8172. else
  8173. _libcurl_with=yes
  8174. fi
  8175. if test "$_libcurl_with" != "no" ; then
  8176. for ac_prog in gawk mawk nawk awk
  8177. do
  8178. # Extract the first word of "$ac_prog", so it can be a program name with args.
  8179. set dummy $ac_prog; ac_word=$2
  8180. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  8181. $as_echo_n "checking for $ac_word... " >&6; }
  8182. if ${ac_cv_prog_AWK+:} false; then :
  8183. $as_echo_n "(cached) " >&6
  8184. else
  8185. if test -n "$AWK"; then
  8186. ac_cv_prog_AWK="$AWK" # Let the user override the test.
  8187. else
  8188. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  8189. for as_dir in $PATH
  8190. do
  8191. IFS=$as_save_IFS
  8192. test -z "$as_dir" && as_dir=.
  8193. for ac_exec_ext in '' $ac_executable_extensions; do
  8194. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  8195. ac_cv_prog_AWK="$ac_prog"
  8196. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  8197. break 2
  8198. fi
  8199. done
  8200. done
  8201. IFS=$as_save_IFS
  8202. fi
  8203. fi
  8204. AWK=$ac_cv_prog_AWK
  8205. if test -n "$AWK"; then
  8206. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
  8207. $as_echo "$AWK" >&6; }
  8208. else
  8209. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  8210. $as_echo "no" >&6; }
  8211. fi
  8212. test -n "$AWK" && break
  8213. done
  8214. _libcurl_version_parse="eval $AWK '{split(\$NF,A,\".\"); X=256*256*A[1]+256*A[2]+A[3]; print X;}'"
  8215. _libcurl_try_link=yes
  8216. if test -d "$_libcurl_with" ; then
  8217. CURL_INCLUDE="-I$withval/include"
  8218. _libcurl_ldflags="-L$withval/lib"
  8219. # Extract the first word of "curl-config", so it can be a program name with args.
  8220. set dummy curl-config; ac_word=$2
  8221. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  8222. $as_echo_n "checking for $ac_word... " >&6; }
  8223. if ${ac_cv_path__libcurl_config+:} false; then :
  8224. $as_echo_n "(cached) " >&6
  8225. else
  8226. case $_libcurl_config in
  8227. [\\/]* | ?:[\\/]*)
  8228. ac_cv_path__libcurl_config="$_libcurl_config" # Let the user override the test with a path.
  8229. ;;
  8230. *)
  8231. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  8232. for as_dir in "$withval/bin"
  8233. do
  8234. IFS=$as_save_IFS
  8235. test -z "$as_dir" && as_dir=.
  8236. for ac_exec_ext in '' $ac_executable_extensions; do
  8237. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  8238. ac_cv_path__libcurl_config="$as_dir/$ac_word$ac_exec_ext"
  8239. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  8240. break 2
  8241. fi
  8242. done
  8243. done
  8244. IFS=$as_save_IFS
  8245. test -z "$ac_cv_path__libcurl_config" && ac_cv_path__libcurl_config=""$withval/bin""
  8246. ;;
  8247. esac
  8248. fi
  8249. _libcurl_config=$ac_cv_path__libcurl_config
  8250. if test -n "$_libcurl_config"; then
  8251. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_libcurl_config" >&5
  8252. $as_echo "$_libcurl_config" >&6; }
  8253. else
  8254. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  8255. $as_echo "no" >&6; }
  8256. fi
  8257. else
  8258. # Extract the first word of "curl-config", so it can be a program name with args.
  8259. set dummy curl-config; ac_word=$2
  8260. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  8261. $as_echo_n "checking for $ac_word... " >&6; }
  8262. if ${ac_cv_path__libcurl_config+:} false; then :
  8263. $as_echo_n "(cached) " >&6
  8264. else
  8265. case $_libcurl_config in
  8266. [\\/]* | ?:[\\/]*)
  8267. ac_cv_path__libcurl_config="$_libcurl_config" # Let the user override the test with a path.
  8268. ;;
  8269. *)
  8270. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  8271. for as_dir in $PATH
  8272. do
  8273. IFS=$as_save_IFS
  8274. test -z "$as_dir" && as_dir=.
  8275. for ac_exec_ext in '' $ac_executable_extensions; do
  8276. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  8277. ac_cv_path__libcurl_config="$as_dir/$ac_word$ac_exec_ext"
  8278. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  8279. break 2
  8280. fi
  8281. done
  8282. done
  8283. IFS=$as_save_IFS
  8284. ;;
  8285. esac
  8286. fi
  8287. _libcurl_config=$ac_cv_path__libcurl_config
  8288. if test -n "$_libcurl_config"; then
  8289. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_libcurl_config" >&5
  8290. $as_echo "$_libcurl_config" >&6; }
  8291. else
  8292. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  8293. $as_echo "no" >&6; }
  8294. fi
  8295. fi
  8296. if test x$_libcurl_config != "x" ; then
  8297. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the version of libcurl" >&5
  8298. $as_echo_n "checking for the version of libcurl... " >&6; }
  8299. if ${libcurl_cv_lib_curl_version+:} false; then :
  8300. $as_echo_n "(cached) " >&6
  8301. else
  8302. libcurl_cv_lib_curl_version=`$_libcurl_config --version | $AWK '{print $2}'`
  8303. fi
  8304. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libcurl_cv_lib_curl_version" >&5
  8305. $as_echo "$libcurl_cv_lib_curl_version" >&6; }
  8306. _libcurl_version=`echo $libcurl_cv_lib_curl_version | $_libcurl_version_parse`
  8307. _libcurl_wanted=`echo 7.10.1 | $_libcurl_version_parse`
  8308. if test $_libcurl_wanted -gt 0 ; then
  8309. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libcurl >= version 7.10.1" >&5
  8310. $as_echo_n "checking for libcurl >= version 7.10.1... " >&6; }
  8311. if ${libcurl_cv_lib_version_ok+:} false; then :
  8312. $as_echo_n "(cached) " >&6
  8313. else
  8314. if test $_libcurl_version -ge $_libcurl_wanted ; then
  8315. libcurl_cv_lib_version_ok=yes
  8316. else
  8317. libcurl_cv_lib_version_ok=no
  8318. fi
  8319. fi
  8320. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libcurl_cv_lib_version_ok" >&5
  8321. $as_echo "$libcurl_cv_lib_version_ok" >&6; }
  8322. fi
  8323. if test $_libcurl_wanted -eq 0 || test x$libcurl_cv_lib_version_ok = xyes ; then
  8324. if test x"$CURL_INCLUDE" = "x" ; then
  8325. CURL_INCLUDE=`$_libcurl_config --cflags`
  8326. fi
  8327. if test x"$CURL_LIB" = "x" ; then
  8328. CURL_LIB=`$_libcurl_config --libs`
  8329. # This is so silly, but Apple actually has a bug in their
  8330. # curl-config script. Fixed in Tiger, but there are still
  8331. # lots of Panther installs around.
  8332. case "${host}" in
  8333. powerpc-apple-darwin7*)
  8334. CURL_LIB=`echo $CURL_LIB | sed -e 's|-arch i386||g'`
  8335. ;;
  8336. esac
  8337. fi
  8338. # All curl-config scripts support --feature
  8339. _libcurl_features=`$_libcurl_config --feature`
  8340. # Is it modern enough to have --protocols? (7.12.4)
  8341. if test $_libcurl_version -ge 461828 ; then
  8342. _libcurl_protocols=`$_libcurl_config --protocols`
  8343. fi
  8344. else
  8345. _libcurl_try_link=no
  8346. fi
  8347. unset _libcurl_wanted
  8348. fi
  8349. if test $_libcurl_try_link = yes ; then
  8350. # we didn't find curl-config, so let's see if the user-supplied
  8351. # link line (or failing that, "-lcurl") is enough.
  8352. CURL_LIB=${CURL_LIB-"$_libcurl_ldflags -lcurl"}
  8353. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether libcurl is usable" >&5
  8354. $as_echo_n "checking whether libcurl is usable... " >&6; }
  8355. if ${libcurl_cv_lib_curl_usable+:} false; then :
  8356. $as_echo_n "(cached) " >&6
  8357. else
  8358. _libcurl_save_cppflags=$CPPFLAGS
  8359. CPPFLAGS="$CURL_INCLUDE $CPPFLAGS"
  8360. _libcurl_save_libs=$LIBS
  8361. LIBS="$CURL_LIB $LIBS"
  8362. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  8363. /* end confdefs.h. */
  8364. #include <curl/curl.h>
  8365. int
  8366. main ()
  8367. {
  8368. /* Try and use a few common options to force a failure if we are
  8369. missing symbols or can't link. */
  8370. int x;
  8371. curl_easy_setopt(NULL,CURLOPT_URL,NULL);
  8372. x=CURL_ERROR_SIZE;
  8373. x=CURLOPT_WRITEFUNCTION;
  8374. x=CURLOPT_FILE;
  8375. x=CURLOPT_ERRORBUFFER;
  8376. x=CURLOPT_STDERR;
  8377. x=CURLOPT_VERBOSE;
  8378. ;
  8379. return 0;
  8380. }
  8381. _ACEOF
  8382. if ac_fn_c_try_link "$LINENO"; then :
  8383. libcurl_cv_lib_curl_usable=yes
  8384. else
  8385. libcurl_cv_lib_curl_usable=no
  8386. fi
  8387. rm -f core conftest.err conftest.$ac_objext \
  8388. conftest$ac_exeext conftest.$ac_ext
  8389. CPPFLAGS=$_libcurl_save_cppflags
  8390. LIBS=$_libcurl_save_libs
  8391. unset _libcurl_save_cppflags
  8392. unset _libcurl_save_libs
  8393. fi
  8394. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libcurl_cv_lib_curl_usable" >&5
  8395. $as_echo "$libcurl_cv_lib_curl_usable" >&6; }
  8396. if test $libcurl_cv_lib_curl_usable = yes ; then
  8397. # Does curl_free() exist in this version of libcurl?
  8398. # If not, fake it with free()
  8399. _libcurl_save_cppflags=$CPPFLAGS
  8400. CPPFLAGS="$CPPFLAGS $CURL_INCLUDE"
  8401. _libcurl_save_libs=$LIBS
  8402. LIBS="$LIBS $CURL_LIB"
  8403. ac_fn_c_check_func "$LINENO" "curl_free" "ac_cv_func_curl_free"
  8404. if test "x$ac_cv_func_curl_free" = xyes; then :
  8405. else
  8406. $as_echo "#define curl_free free" >>confdefs.h
  8407. fi
  8408. CPPFLAGS=$_libcurl_save_cppflags
  8409. LIBS=$_libcurl_save_libs
  8410. unset _libcurl_save_cppflags
  8411. unset _libcurl_save_libs
  8412. $as_echo "#define HAVE_CURL 1" >>confdefs.h
  8413. PBX_CURL=1
  8414. for _libcurl_feature in $_libcurl_features ; do
  8415. cat >>confdefs.h <<_ACEOF
  8416. #define `$as_echo "libcurl_feature_$_libcurl_feature" | $as_tr_cpp` 1
  8417. _ACEOF
  8418. eval `$as_echo "libcurl_feature_$_libcurl_feature" | $as_tr_sh`=yes
  8419. done
  8420. if test "x$_libcurl_protocols" = "x" ; then
  8421. # We don't have --protocols, so just assume that all
  8422. # protocols are available
  8423. _libcurl_protocols="HTTP FTP FILE TELNET LDAP DICT"
  8424. if test x$libcurl_feature_SSL = xyes ; then
  8425. _libcurl_protocols="$_libcurl_protocols HTTPS"
  8426. # FTPS wasn't standards-compliant until version
  8427. # 7.11.0
  8428. if test $_libcurl_version -ge 461568; then
  8429. _libcurl_protocols="$_libcurl_protocols FTPS"
  8430. fi
  8431. fi
  8432. fi
  8433. for _libcurl_protocol in $_libcurl_protocols ; do
  8434. cat >>confdefs.h <<_ACEOF
  8435. #define `$as_echo "libcurl_protocol_$_libcurl_protocol" | $as_tr_cpp` 1
  8436. _ACEOF
  8437. eval `$as_echo "libcurl_protocol_$_libcurl_protocol" | $as_tr_sh`=yes
  8438. done
  8439. else
  8440. unset CURL_LIB
  8441. unset CURL_INCLUDE
  8442. PBX_CURL=0
  8443. fi
  8444. fi
  8445. unset _libcurl_try_link
  8446. unset _libcurl_version_parse
  8447. unset _libcurl_config
  8448. unset _libcurl_feature
  8449. unset _libcurl_features
  8450. unset _libcurl_protocol
  8451. unset _libcurl_protocols
  8452. unset _libcurl_version
  8453. unset _libcurl_ldflags
  8454. fi
  8455. if test x$_libcurl_with = xno || test x$libcurl_cv_lib_curl_usable != xyes ; then
  8456. # This is the IF-NO path
  8457. :
  8458. else
  8459. # This is the IF-YES path
  8460. :
  8461. fi
  8462. unset _libcurl_with
  8463. LIBEDIT_DESCRIP="NetBSD Editline library"
  8464. LIBEDIT_OPTION="libedit"
  8465. PBX_LIBEDIT=0
  8466. # Check whether --with-libedit was given.
  8467. if test "${with_libedit+set}" = set; then :
  8468. withval=$with_libedit;
  8469. case ${withval} in
  8470. n|no)
  8471. USE_LIBEDIT=no
  8472. # -1 is a magic value used by menuselect to know that the package
  8473. # was disabled, other than 'not found'
  8474. PBX_LIBEDIT=-1
  8475. ;;
  8476. y|ye|yes)
  8477. ac_mandatory_list="${ac_mandatory_list} LIBEDIT"
  8478. ;;
  8479. *)
  8480. LIBEDIT_DIR="${withval}"
  8481. ac_mandatory_list="${ac_mandatory_list} LIBEDIT"
  8482. ;;
  8483. esac
  8484. fi
  8485. LIBXML2_DESCRIP="LibXML2"
  8486. LIBXML2_OPTION="libxml2"
  8487. PBX_LIBXML2=0
  8488. # Check whether --with-libxml2 was given.
  8489. if test "${with_libxml2+set}" = set; then :
  8490. withval=$with_libxml2;
  8491. case ${withval} in
  8492. n|no)
  8493. USE_LIBXML2=no
  8494. # -1 is a magic value used by menuselect to know that the package
  8495. # was disabled, other than 'not found'
  8496. PBX_LIBXML2=-1
  8497. ;;
  8498. y|ye|yes)
  8499. ac_mandatory_list="${ac_mandatory_list} LIBXML2"
  8500. ;;
  8501. *)
  8502. LIBXML2_DIR="${withval}"
  8503. ac_mandatory_list="${ac_mandatory_list} LIBXML2"
  8504. ;;
  8505. esac
  8506. fi
  8507. LIBXSLT_DESCRIP="LibXSLT"
  8508. LIBXSLT_OPTION="libxslt"
  8509. PBX_LIBXSLT=0
  8510. # Check whether --with-libxslt was given.
  8511. if test "${with_libxslt+set}" = set; then :
  8512. withval=$with_libxslt;
  8513. case ${withval} in
  8514. n|no)
  8515. USE_LIBXSLT=no
  8516. # -1 is a magic value used by menuselect to know that the package
  8517. # was disabled, other than 'not found'
  8518. PBX_LIBXSLT=-1
  8519. ;;
  8520. y|ye|yes)
  8521. ac_mandatory_list="${ac_mandatory_list} LIBXSLT"
  8522. ;;
  8523. *)
  8524. LIBXSLT_DIR="${withval}"
  8525. ac_mandatory_list="${ac_mandatory_list} LIBXSLT"
  8526. ;;
  8527. esac
  8528. fi
  8529. LIBXSLT_CLEANUP_DESCRIP="LibXSLT Library Cleanup Function"
  8530. LIBXSLT_CLEANUP_OPTION=libxslt
  8531. LIBXSLT_CLEANUP_DIR=${LIBXSLT_DIR}
  8532. PBX_LIBXSLT_CLEANUP=0
  8533. LTDL_DESCRIP="libtool"
  8534. LTDL_OPTION="ltdl"
  8535. PBX_LTDL=0
  8536. # Check whether --with-ltdl was given.
  8537. if test "${with_ltdl+set}" = set; then :
  8538. withval=$with_ltdl;
  8539. case ${withval} in
  8540. n|no)
  8541. USE_LTDL=no
  8542. # -1 is a magic value used by menuselect to know that the package
  8543. # was disabled, other than 'not found'
  8544. PBX_LTDL=-1
  8545. ;;
  8546. y|ye|yes)
  8547. ac_mandatory_list="${ac_mandatory_list} LTDL"
  8548. ;;
  8549. *)
  8550. LTDL_DIR="${withval}"
  8551. ac_mandatory_list="${ac_mandatory_list} LTDL"
  8552. ;;
  8553. esac
  8554. fi
  8555. LUA_DESCRIP="Lua"
  8556. LUA_OPTION="lua"
  8557. PBX_LUA=0
  8558. # Check whether --with-lua was given.
  8559. if test "${with_lua+set}" = set; then :
  8560. withval=$with_lua;
  8561. case ${withval} in
  8562. n|no)
  8563. USE_LUA=no
  8564. # -1 is a magic value used by menuselect to know that the package
  8565. # was disabled, other than 'not found'
  8566. PBX_LUA=-1
  8567. ;;
  8568. y|ye|yes)
  8569. ac_mandatory_list="${ac_mandatory_list} LUA"
  8570. ;;
  8571. *)
  8572. LUA_DIR="${withval}"
  8573. ac_mandatory_list="${ac_mandatory_list} LUA"
  8574. ;;
  8575. esac
  8576. fi
  8577. MISDN_DESCRIP="mISDN user"
  8578. MISDN_OPTION="misdn"
  8579. PBX_MISDN=0
  8580. # Check whether --with-misdn was given.
  8581. if test "${with_misdn+set}" = set; then :
  8582. withval=$with_misdn;
  8583. case ${withval} in
  8584. n|no)
  8585. USE_MISDN=no
  8586. # -1 is a magic value used by menuselect to know that the package
  8587. # was disabled, other than 'not found'
  8588. PBX_MISDN=-1
  8589. ;;
  8590. y|ye|yes)
  8591. ac_mandatory_list="${ac_mandatory_list} MISDN"
  8592. ;;
  8593. *)
  8594. MISDN_DIR="${withval}"
  8595. ac_mandatory_list="${ac_mandatory_list} MISDN"
  8596. ;;
  8597. esac
  8598. fi
  8599. MYSQLCLIENT_DESCRIP="MySQL client"
  8600. MYSQLCLIENT_OPTION="mysqlclient"
  8601. PBX_MYSQLCLIENT=0
  8602. # Check whether --with-mysqlclient was given.
  8603. if test "${with_mysqlclient+set}" = set; then :
  8604. withval=$with_mysqlclient;
  8605. case ${withval} in
  8606. n|no)
  8607. USE_MYSQLCLIENT=no
  8608. # -1 is a magic value used by menuselect to know that the package
  8609. # was disabled, other than 'not found'
  8610. PBX_MYSQLCLIENT=-1
  8611. ;;
  8612. y|ye|yes)
  8613. ac_mandatory_list="${ac_mandatory_list} MYSQLCLIENT"
  8614. ;;
  8615. *)
  8616. MYSQLCLIENT_DIR="${withval}"
  8617. ac_mandatory_list="${ac_mandatory_list} MYSQLCLIENT"
  8618. ;;
  8619. esac
  8620. fi
  8621. NBS_DESCRIP="Network Broadcast Sound"
  8622. NBS_OPTION="nbs"
  8623. PBX_NBS=0
  8624. # Check whether --with-nbs was given.
  8625. if test "${with_nbs+set}" = set; then :
  8626. withval=$with_nbs;
  8627. case ${withval} in
  8628. n|no)
  8629. USE_NBS=no
  8630. # -1 is a magic value used by menuselect to know that the package
  8631. # was disabled, other than 'not found'
  8632. PBX_NBS=-1
  8633. ;;
  8634. y|ye|yes)
  8635. ac_mandatory_list="${ac_mandatory_list} NBS"
  8636. ;;
  8637. *)
  8638. NBS_DIR="${withval}"
  8639. ac_mandatory_list="${ac_mandatory_list} NBS"
  8640. ;;
  8641. esac
  8642. fi
  8643. NCURSES_DESCRIP="ncurses"
  8644. NCURSES_OPTION="ncurses"
  8645. PBX_NCURSES=0
  8646. # Check whether --with-ncurses was given.
  8647. if test "${with_ncurses+set}" = set; then :
  8648. withval=$with_ncurses;
  8649. case ${withval} in
  8650. n|no)
  8651. USE_NCURSES=no
  8652. # -1 is a magic value used by menuselect to know that the package
  8653. # was disabled, other than 'not found'
  8654. PBX_NCURSES=-1
  8655. ;;
  8656. y|ye|yes)
  8657. ac_mandatory_list="${ac_mandatory_list} NCURSES"
  8658. ;;
  8659. *)
  8660. NCURSES_DIR="${withval}"
  8661. ac_mandatory_list="${ac_mandatory_list} NCURSES"
  8662. ;;
  8663. esac
  8664. fi
  8665. NEON_DESCRIP="neon"
  8666. NEON_OPTION="neon"
  8667. PBX_NEON=0
  8668. # Check whether --with-neon was given.
  8669. if test "${with_neon+set}" = set; then :
  8670. withval=$with_neon;
  8671. case ${withval} in
  8672. n|no)
  8673. USE_NEON=no
  8674. # -1 is a magic value used by menuselect to know that the package
  8675. # was disabled, other than 'not found'
  8676. PBX_NEON=-1
  8677. ;;
  8678. y|ye|yes)
  8679. ac_mandatory_list="${ac_mandatory_list} NEON"
  8680. ;;
  8681. *)
  8682. NEON_DIR="${withval}"
  8683. ac_mandatory_list="${ac_mandatory_list} NEON"
  8684. ;;
  8685. esac
  8686. fi
  8687. NEON29_DESCRIP="neon29"
  8688. NEON29_OPTION="neon29"
  8689. PBX_NEON29=0
  8690. # Check whether --with-neon29 was given.
  8691. if test "${with_neon29+set}" = set; then :
  8692. withval=$with_neon29;
  8693. case ${withval} in
  8694. n|no)
  8695. USE_NEON29=no
  8696. # -1 is a magic value used by menuselect to know that the package
  8697. # was disabled, other than 'not found'
  8698. PBX_NEON29=-1
  8699. ;;
  8700. y|ye|yes)
  8701. ac_mandatory_list="${ac_mandatory_list} NEON29"
  8702. ;;
  8703. *)
  8704. NEON29_DIR="${withval}"
  8705. ac_mandatory_list="${ac_mandatory_list} NEON29"
  8706. ;;
  8707. esac
  8708. fi
  8709. NETSNMP_DESCRIP="Net-SNMP"
  8710. NETSNMP_OPTION="netsnmp"
  8711. PBX_NETSNMP=0
  8712. # Check whether --with-netsnmp was given.
  8713. if test "${with_netsnmp+set}" = set; then :
  8714. withval=$with_netsnmp;
  8715. case ${withval} in
  8716. n|no)
  8717. USE_NETSNMP=no
  8718. # -1 is a magic value used by menuselect to know that the package
  8719. # was disabled, other than 'not found'
  8720. PBX_NETSNMP=-1
  8721. ;;
  8722. y|ye|yes)
  8723. ac_mandatory_list="${ac_mandatory_list} NETSNMP"
  8724. ;;
  8725. *)
  8726. NETSNMP_DIR="${withval}"
  8727. ac_mandatory_list="${ac_mandatory_list} NETSNMP"
  8728. ;;
  8729. esac
  8730. fi
  8731. NEWT_DESCRIP="newt"
  8732. NEWT_OPTION="newt"
  8733. PBX_NEWT=0
  8734. # Check whether --with-newt was given.
  8735. if test "${with_newt+set}" = set; then :
  8736. withval=$with_newt;
  8737. case ${withval} in
  8738. n|no)
  8739. USE_NEWT=no
  8740. # -1 is a magic value used by menuselect to know that the package
  8741. # was disabled, other than 'not found'
  8742. PBX_NEWT=-1
  8743. ;;
  8744. y|ye|yes)
  8745. ac_mandatory_list="${ac_mandatory_list} NEWT"
  8746. ;;
  8747. *)
  8748. NEWT_DIR="${withval}"
  8749. ac_mandatory_list="${ac_mandatory_list} NEWT"
  8750. ;;
  8751. esac
  8752. fi
  8753. OGG_DESCRIP="OGG"
  8754. OGG_OPTION="ogg"
  8755. PBX_OGG=0
  8756. # Check whether --with-ogg was given.
  8757. if test "${with_ogg+set}" = set; then :
  8758. withval=$with_ogg;
  8759. case ${withval} in
  8760. n|no)
  8761. USE_OGG=no
  8762. # -1 is a magic value used by menuselect to know that the package
  8763. # was disabled, other than 'not found'
  8764. PBX_OGG=-1
  8765. ;;
  8766. y|ye|yes)
  8767. ac_mandatory_list="${ac_mandatory_list} OGG"
  8768. ;;
  8769. *)
  8770. OGG_DIR="${withval}"
  8771. ac_mandatory_list="${ac_mandatory_list} OGG"
  8772. ;;
  8773. esac
  8774. fi
  8775. OPENR2_DESCRIP="MFR2"
  8776. OPENR2_OPTION="openr2"
  8777. PBX_OPENR2=0
  8778. # Check whether --with-openr2 was given.
  8779. if test "${with_openr2+set}" = set; then :
  8780. withval=$with_openr2;
  8781. case ${withval} in
  8782. n|no)
  8783. USE_OPENR2=no
  8784. # -1 is a magic value used by menuselect to know that the package
  8785. # was disabled, other than 'not found'
  8786. PBX_OPENR2=-1
  8787. ;;
  8788. y|ye|yes)
  8789. ac_mandatory_list="${ac_mandatory_list} OPENR2"
  8790. ;;
  8791. *)
  8792. OPENR2_DIR="${withval}"
  8793. ac_mandatory_list="${ac_mandatory_list} OPENR2"
  8794. ;;
  8795. esac
  8796. fi
  8797. OSPTK_DESCRIP="OSP Toolkit"
  8798. OSPTK_OPTION="osptk"
  8799. PBX_OSPTK=0
  8800. # Check whether --with-osptk was given.
  8801. if test "${with_osptk+set}" = set; then :
  8802. withval=$with_osptk;
  8803. case ${withval} in
  8804. n|no)
  8805. USE_OSPTK=no
  8806. # -1 is a magic value used by menuselect to know that the package
  8807. # was disabled, other than 'not found'
  8808. PBX_OSPTK=-1
  8809. ;;
  8810. y|ye|yes)
  8811. ac_mandatory_list="${ac_mandatory_list} OSPTK"
  8812. ;;
  8813. *)
  8814. OSPTK_DIR="${withval}"
  8815. ac_mandatory_list="${ac_mandatory_list} OSPTK"
  8816. ;;
  8817. esac
  8818. fi
  8819. OSS_DESCRIP="Open Sound System"
  8820. OSS_OPTION="oss"
  8821. PBX_OSS=0
  8822. # Check whether --with-oss was given.
  8823. if test "${with_oss+set}" = set; then :
  8824. withval=$with_oss;
  8825. case ${withval} in
  8826. n|no)
  8827. USE_OSS=no
  8828. # -1 is a magic value used by menuselect to know that the package
  8829. # was disabled, other than 'not found'
  8830. PBX_OSS=-1
  8831. ;;
  8832. y|ye|yes)
  8833. ac_mandatory_list="${ac_mandatory_list} OSS"
  8834. ;;
  8835. *)
  8836. OSS_DIR="${withval}"
  8837. ac_mandatory_list="${ac_mandatory_list} OSS"
  8838. ;;
  8839. esac
  8840. fi
  8841. PGSQL_DESCRIP="PostgreSQL"
  8842. PGSQL_OPTION="postgres"
  8843. PBX_PGSQL=0
  8844. # Check whether --with-postgres was given.
  8845. if test "${with_postgres+set}" = set; then :
  8846. withval=$with_postgres;
  8847. case ${withval} in
  8848. n|no)
  8849. USE_PGSQL=no
  8850. # -1 is a magic value used by menuselect to know that the package
  8851. # was disabled, other than 'not found'
  8852. PBX_PGSQL=-1
  8853. ;;
  8854. y|ye|yes)
  8855. ac_mandatory_list="${ac_mandatory_list} PGSQL"
  8856. ;;
  8857. *)
  8858. PGSQL_DIR="${withval}"
  8859. ac_mandatory_list="${ac_mandatory_list} PGSQL"
  8860. ;;
  8861. esac
  8862. fi
  8863. PJPROJECT_DESCRIP="PJPROJECT"
  8864. PJPROJECT_OPTION="pjproject"
  8865. PBX_PJPROJECT=0
  8866. # Check whether --with-pjproject was given.
  8867. if test "${with_pjproject+set}" = set; then :
  8868. withval=$with_pjproject;
  8869. case ${withval} in
  8870. n|no)
  8871. USE_PJPROJECT=no
  8872. # -1 is a magic value used by menuselect to know that the package
  8873. # was disabled, other than 'not found'
  8874. PBX_PJPROJECT=-1
  8875. ;;
  8876. y|ye|yes)
  8877. ac_mandatory_list="${ac_mandatory_list} PJPROJECT"
  8878. ;;
  8879. *)
  8880. PJPROJECT_DIR="${withval}"
  8881. ac_mandatory_list="${ac_mandatory_list} PJPROJECT"
  8882. ;;
  8883. esac
  8884. fi
  8885. POPT_DESCRIP="popt"
  8886. POPT_OPTION="popt"
  8887. PBX_POPT=0
  8888. # Check whether --with-popt was given.
  8889. if test "${with_popt+set}" = set; then :
  8890. withval=$with_popt;
  8891. case ${withval} in
  8892. n|no)
  8893. USE_POPT=no
  8894. # -1 is a magic value used by menuselect to know that the package
  8895. # was disabled, other than 'not found'
  8896. PBX_POPT=-1
  8897. ;;
  8898. y|ye|yes)
  8899. ac_mandatory_list="${ac_mandatory_list} POPT"
  8900. ;;
  8901. *)
  8902. POPT_DIR="${withval}"
  8903. ac_mandatory_list="${ac_mandatory_list} POPT"
  8904. ;;
  8905. esac
  8906. fi
  8907. PJ_TRANSACTION_GRP_LOCK_DESCRIP="PJSIP Transaction Group Lock Support"
  8908. PJ_TRANSACTION_GRP_LOCK_OPTION=pjsip
  8909. PJ_TRANSACTION_GRP_LOCK_DIR=${PJPROJECT_DIR}
  8910. PBX_PJ_TRANSACTION_GRP_LOCK=0
  8911. PJSIP_REPLACE_MEDIA_STREAM_DESCRIP="PJSIP Media Stream Replacement Support"
  8912. PJSIP_REPLACE_MEDIA_STREAM_OPTION=pjsip
  8913. PJSIP_REPLACE_MEDIA_STREAM_DIR=${PJPROJECT_DIR}
  8914. PBX_PJSIP_REPLACE_MEDIA_STREAM=0
  8915. PORTAUDIO_DESCRIP="PortAudio"
  8916. PORTAUDIO_OPTION="portaudio"
  8917. PBX_PORTAUDIO=0
  8918. # Check whether --with-portaudio was given.
  8919. if test "${with_portaudio+set}" = set; then :
  8920. withval=$with_portaudio;
  8921. case ${withval} in
  8922. n|no)
  8923. USE_PORTAUDIO=no
  8924. # -1 is a magic value used by menuselect to know that the package
  8925. # was disabled, other than 'not found'
  8926. PBX_PORTAUDIO=-1
  8927. ;;
  8928. y|ye|yes)
  8929. ac_mandatory_list="${ac_mandatory_list} PORTAUDIO"
  8930. ;;
  8931. *)
  8932. PORTAUDIO_DIR="${withval}"
  8933. ac_mandatory_list="${ac_mandatory_list} PORTAUDIO"
  8934. ;;
  8935. esac
  8936. fi
  8937. PRI_DESCRIP="ISDN PRI"
  8938. PRI_OPTION="pri"
  8939. PBX_PRI=0
  8940. # Check whether --with-pri was given.
  8941. if test "${with_pri+set}" = set; then :
  8942. withval=$with_pri;
  8943. case ${withval} in
  8944. n|no)
  8945. USE_PRI=no
  8946. # -1 is a magic value used by menuselect to know that the package
  8947. # was disabled, other than 'not found'
  8948. PBX_PRI=-1
  8949. ;;
  8950. y|ye|yes)
  8951. ac_mandatory_list="${ac_mandatory_list} PRI"
  8952. ;;
  8953. *)
  8954. PRI_DIR="${withval}"
  8955. ac_mandatory_list="${ac_mandatory_list} PRI"
  8956. ;;
  8957. esac
  8958. fi
  8959. PRI_SETUP_ACK_INBAND_DESCRIP="ISDN PRI progress inband ie in SETUP ACK"
  8960. PRI_SETUP_ACK_INBAND_OPTION=pri
  8961. PRI_SETUP_ACK_INBAND_DIR=${PRI_DIR}
  8962. PBX_PRI_SETUP_ACK_INBAND=0
  8963. PRI_L2_PERSISTENCE_DESCRIP="ISDN Layer 2 persistence option"
  8964. PRI_L2_PERSISTENCE_OPTION=pri
  8965. PRI_L2_PERSISTENCE_DIR=${PRI_DIR}
  8966. PBX_PRI_L2_PERSISTENCE=0
  8967. PRI_DATETIME_SEND_DESCRIP="ISDN PRI Date/time ie send policy"
  8968. PRI_DATETIME_SEND_OPTION=pri
  8969. PRI_DATETIME_SEND_DIR=${PRI_DIR}
  8970. PBX_PRI_DATETIME_SEND=0
  8971. PRI_MWI_V2_DESCRIP="ISDN PRI Message Waiting Indication (Fixed)"
  8972. PRI_MWI_V2_OPTION=pri
  8973. PRI_MWI_V2_DIR=${PRI_DIR}
  8974. PBX_PRI_MWI_V2=0
  8975. PRI_DISPLAY_TEXT_DESCRIP="ISDN PRI user display text IE contents during call"
  8976. PRI_DISPLAY_TEXT_OPTION=pri
  8977. PRI_DISPLAY_TEXT_DIR=${PRI_DIR}
  8978. PBX_PRI_DISPLAY_TEXT=0
  8979. PRI_MWI_DESCRIP="ISDN PRI Message Waiting Indication"
  8980. PRI_MWI_OPTION=pri
  8981. PRI_MWI_DIR=${PRI_DIR}
  8982. PBX_PRI_MWI=0
  8983. PRI_MCID_DESCRIP="ISDN PRI Malicious Call ID"
  8984. PRI_MCID_OPTION=pri
  8985. PRI_MCID_DIR=${PRI_DIR}
  8986. PBX_PRI_MCID=0
  8987. PRI_CALL_WAITING_DESCRIP="ISDN PRI call waiting supplementary service"
  8988. PRI_CALL_WAITING_OPTION=pri
  8989. PRI_CALL_WAITING_DIR=${PRI_DIR}
  8990. PBX_PRI_CALL_WAITING=0
  8991. PRI_AOC_EVENTS_DESCRIP="ISDN PRI advice of charge supplementary service events"
  8992. PRI_AOC_EVENTS_OPTION=pri
  8993. PRI_AOC_EVENTS_DIR=${PRI_DIR}
  8994. PBX_PRI_AOC_EVENTS=0
  8995. PRI_TRANSFER_DESCRIP="ISDN PRI call transfer supplementary service"
  8996. PRI_TRANSFER_OPTION=pri
  8997. PRI_TRANSFER_DIR=${PRI_DIR}
  8998. PBX_PRI_TRANSFER=0
  8999. PRI_CCSS_DESCRIP="ISDN PRI call completion supplementary service"
  9000. PRI_CCSS_OPTION=pri
  9001. PRI_CCSS_DIR=${PRI_DIR}
  9002. PBX_PRI_CCSS=0
  9003. PRI_HANGUP_FIX_DESCRIP="ISDN PRI hangup fix"
  9004. PRI_HANGUP_FIX_OPTION=pri
  9005. PRI_HANGUP_FIX_DIR=${PRI_DIR}
  9006. PBX_PRI_HANGUP_FIX=0
  9007. PRI_SUBADDR_DESCRIP="ISDN PRI subaddressing"
  9008. PRI_SUBADDR_OPTION=pri
  9009. PRI_SUBADDR_DIR=${PRI_DIR}
  9010. PBX_PRI_SUBADDR=0
  9011. PRI_CALL_HOLD_DESCRIP="ISDN PRI call hold"
  9012. PRI_CALL_HOLD_OPTION=pri
  9013. PRI_CALL_HOLD_DIR=${PRI_DIR}
  9014. PBX_PRI_CALL_HOLD=0
  9015. PRI_CALL_REROUTING_DESCRIP="ISDN PRI call rerouting and call deflection"
  9016. PRI_CALL_REROUTING_OPTION=pri
  9017. PRI_CALL_REROUTING_DIR=${PRI_DIR}
  9018. PBX_PRI_CALL_REROUTING=0
  9019. PRI_SETUP_KEYPAD_DESCRIP="ISDN PRI keypad facility in SETUP"
  9020. PRI_SETUP_KEYPAD_OPTION=pri
  9021. PRI_SETUP_KEYPAD_DIR=${PRI_DIR}
  9022. PBX_PRI_SETUP_KEYPAD=0
  9023. # ------------------------------------v
  9024. # TODO: The code can be changed to always include these features now.
  9025. # These features will always be present if pri_connected_line_update is available.
  9026. PRI_INBANDDISCONNECT_DESCRIP="ISDN PRI set_inbanddisconnect"
  9027. PRI_INBANDDISCONNECT_OPTION=pri
  9028. PRI_INBANDDISCONNECT_DIR=${PRI_DIR}
  9029. PBX_PRI_INBANDDISCONNECT=0
  9030. PRI_PROG_W_CAUSE_DESCRIP="ISDN progress with cause"
  9031. PRI_PROG_W_CAUSE_OPTION=pri
  9032. PRI_PROG_W_CAUSE_DIR=${PRI_DIR}
  9033. PBX_PRI_PROG_W_CAUSE=0
  9034. PRI_SERVICE_MESSAGES_DESCRIP="ISDN service messages"
  9035. PRI_SERVICE_MESSAGES_OPTION=pri
  9036. PRI_SERVICE_MESSAGES_DIR=${PRI_DIR}
  9037. PBX_PRI_SERVICE_MESSAGES=0
  9038. PRI_REVERSE_CHARGE_DESCRIP="ISDN reverse charge"
  9039. PRI_REVERSE_CHARGE_OPTION=pri
  9040. PRI_REVERSE_CHARGE_DIR=${PRI_DIR}
  9041. PBX_PRI_REVERSE_CHARGE=0
  9042. # ------------------------------------^
  9043. PWLIB_DESCRIP="PWlib"
  9044. PWLIB_OPTION="pwlib"
  9045. PBX_PWLIB=0
  9046. # Check whether --with-pwlib was given.
  9047. if test "${with_pwlib+set}" = set; then :
  9048. withval=$with_pwlib;
  9049. case ${withval} in
  9050. n|no)
  9051. USE_PWLIB=no
  9052. # -1 is a magic value used by menuselect to know that the package
  9053. # was disabled, other than 'not found'
  9054. PBX_PWLIB=-1
  9055. ;;
  9056. y|ye|yes)
  9057. ac_mandatory_list="${ac_mandatory_list} PWLIB"
  9058. ;;
  9059. *)
  9060. PWLIB_DIR="${withval}"
  9061. ac_mandatory_list="${ac_mandatory_list} PWLIB"
  9062. ;;
  9063. esac
  9064. fi
  9065. RADIUS_DESCRIP="Radius Client"
  9066. RADIUS_OPTION="radius"
  9067. PBX_RADIUS=0
  9068. # Check whether --with-radius was given.
  9069. if test "${with_radius+set}" = set; then :
  9070. withval=$with_radius;
  9071. case ${withval} in
  9072. n|no)
  9073. USE_RADIUS=no
  9074. # -1 is a magic value used by menuselect to know that the package
  9075. # was disabled, other than 'not found'
  9076. PBX_RADIUS=-1
  9077. ;;
  9078. y|ye|yes)
  9079. ac_mandatory_list="${ac_mandatory_list} RADIUS"
  9080. ;;
  9081. *)
  9082. RADIUS_DIR="${withval}"
  9083. ac_mandatory_list="${ac_mandatory_list} RADIUS"
  9084. ;;
  9085. esac
  9086. fi
  9087. RESAMPLE_DESCRIP="LIBRESAMPLE"
  9088. RESAMPLE_OPTION="resample"
  9089. PBX_RESAMPLE=0
  9090. # Check whether --with-resample was given.
  9091. if test "${with_resample+set}" = set; then :
  9092. withval=$with_resample;
  9093. case ${withval} in
  9094. n|no)
  9095. USE_RESAMPLE=no
  9096. # -1 is a magic value used by menuselect to know that the package
  9097. # was disabled, other than 'not found'
  9098. PBX_RESAMPLE=-1
  9099. ;;
  9100. y|ye|yes)
  9101. ac_mandatory_list="${ac_mandatory_list} RESAMPLE"
  9102. ;;
  9103. *)
  9104. RESAMPLE_DIR="${withval}"
  9105. ac_mandatory_list="${ac_mandatory_list} RESAMPLE"
  9106. ;;
  9107. esac
  9108. fi
  9109. SDL_DESCRIP="Sdl"
  9110. SDL_OPTION="sdl"
  9111. PBX_SDL=0
  9112. # Check whether --with-sdl was given.
  9113. if test "${with_sdl+set}" = set; then :
  9114. withval=$with_sdl;
  9115. case ${withval} in
  9116. n|no)
  9117. USE_SDL=no
  9118. # -1 is a magic value used by menuselect to know that the package
  9119. # was disabled, other than 'not found'
  9120. PBX_SDL=-1
  9121. ;;
  9122. y|ye|yes)
  9123. ac_mandatory_list="${ac_mandatory_list} SDL"
  9124. ;;
  9125. *)
  9126. SDL_DIR="${withval}"
  9127. ac_mandatory_list="${ac_mandatory_list} SDL"
  9128. ;;
  9129. esac
  9130. fi
  9131. SDL_IMAGE_DESCRIP="Sdl Image"
  9132. SDL_IMAGE_OPTION="SDL_image"
  9133. PBX_SDL_IMAGE=0
  9134. # Check whether --with-SDL_image was given.
  9135. if test "${with_SDL_image+set}" = set; then :
  9136. withval=$with_SDL_image;
  9137. case ${withval} in
  9138. n|no)
  9139. USE_SDL_IMAGE=no
  9140. # -1 is a magic value used by menuselect to know that the package
  9141. # was disabled, other than 'not found'
  9142. PBX_SDL_IMAGE=-1
  9143. ;;
  9144. y|ye|yes)
  9145. ac_mandatory_list="${ac_mandatory_list} SDL_IMAGE"
  9146. ;;
  9147. *)
  9148. SDL_IMAGE_DIR="${withval}"
  9149. ac_mandatory_list="${ac_mandatory_list} SDL_IMAGE"
  9150. ;;
  9151. esac
  9152. fi
  9153. # Check whether --with-sounds-cache was given.
  9154. if test "${with_sounds_cache+set}" = set; then :
  9155. withval=$with_sounds_cache;
  9156. case ${withval} in
  9157. n|no)
  9158. unset SOUNDS_CACHE_DIR
  9159. ;;
  9160. *)
  9161. if test "x${withval}" = "x"; then
  9162. :
  9163. else
  9164. SOUNDS_CACHE_DIR="${withval}"
  9165. fi
  9166. ;;
  9167. esac
  9168. else
  9169. :
  9170. fi
  9171. SPANDSP_DESCRIP="SPANDSP"
  9172. SPANDSP_OPTION="spandsp"
  9173. PBX_SPANDSP=0
  9174. # Check whether --with-spandsp was given.
  9175. if test "${with_spandsp+set}" = set; then :
  9176. withval=$with_spandsp;
  9177. case ${withval} in
  9178. n|no)
  9179. USE_SPANDSP=no
  9180. # -1 is a magic value used by menuselect to know that the package
  9181. # was disabled, other than 'not found'
  9182. PBX_SPANDSP=-1
  9183. ;;
  9184. y|ye|yes)
  9185. ac_mandatory_list="${ac_mandatory_list} SPANDSP"
  9186. ;;
  9187. *)
  9188. SPANDSP_DIR="${withval}"
  9189. ac_mandatory_list="${ac_mandatory_list} SPANDSP"
  9190. ;;
  9191. esac
  9192. fi
  9193. SS7_DESCRIP="ISDN SS7"
  9194. SS7_OPTION="ss7"
  9195. PBX_SS7=0
  9196. # Check whether --with-ss7 was given.
  9197. if test "${with_ss7+set}" = set; then :
  9198. withval=$with_ss7;
  9199. case ${withval} in
  9200. n|no)
  9201. USE_SS7=no
  9202. # -1 is a magic value used by menuselect to know that the package
  9203. # was disabled, other than 'not found'
  9204. PBX_SS7=-1
  9205. ;;
  9206. y|ye|yes)
  9207. ac_mandatory_list="${ac_mandatory_list} SS7"
  9208. ;;
  9209. *)
  9210. SS7_DIR="${withval}"
  9211. ac_mandatory_list="${ac_mandatory_list} SS7"
  9212. ;;
  9213. esac
  9214. fi
  9215. SPEEX_DESCRIP="Speex"
  9216. SPEEX_OPTION="speex"
  9217. PBX_SPEEX=0
  9218. # Check whether --with-speex was given.
  9219. if test "${with_speex+set}" = set; then :
  9220. withval=$with_speex;
  9221. case ${withval} in
  9222. n|no)
  9223. USE_SPEEX=no
  9224. # -1 is a magic value used by menuselect to know that the package
  9225. # was disabled, other than 'not found'
  9226. PBX_SPEEX=-1
  9227. ;;
  9228. y|ye|yes)
  9229. ac_mandatory_list="${ac_mandatory_list} SPEEX"
  9230. ;;
  9231. *)
  9232. SPEEX_DIR="${withval}"
  9233. ac_mandatory_list="${ac_mandatory_list} SPEEX"
  9234. ;;
  9235. esac
  9236. fi
  9237. SPEEX_PREPROCESS_DESCRIP="Speex preprocess routines"
  9238. SPEEX_PREPROCESS_OPTION="speex"
  9239. PBX_SPEEX_PREPROCESS=0
  9240. # Check whether --with-speex was given.
  9241. if test "${with_speex+set}" = set; then :
  9242. withval=$with_speex;
  9243. case ${withval} in
  9244. n|no)
  9245. USE_SPEEX_PREPROCESS=no
  9246. # -1 is a magic value used by menuselect to know that the package
  9247. # was disabled, other than 'not found'
  9248. PBX_SPEEX_PREPROCESS=-1
  9249. ;;
  9250. y|ye|yes)
  9251. ac_mandatory_list="${ac_mandatory_list} SPEEX_PREPROCESS"
  9252. ;;
  9253. *)
  9254. SPEEX_PREPROCESS_DIR="${withval}"
  9255. ac_mandatory_list="${ac_mandatory_list} SPEEX_PREPROCESS"
  9256. ;;
  9257. esac
  9258. fi
  9259. SPEEXDSP_DESCRIP="SpeexDSP"
  9260. SPEEXDSP_OPTION="speexdsp"
  9261. PBX_SPEEXDSP=0
  9262. # Check whether --with-speexdsp was given.
  9263. if test "${with_speexdsp+set}" = set; then :
  9264. withval=$with_speexdsp;
  9265. case ${withval} in
  9266. n|no)
  9267. USE_SPEEXDSP=no
  9268. # -1 is a magic value used by menuselect to know that the package
  9269. # was disabled, other than 'not found'
  9270. PBX_SPEEXDSP=-1
  9271. ;;
  9272. y|ye|yes)
  9273. ac_mandatory_list="${ac_mandatory_list} SPEEXDSP"
  9274. ;;
  9275. *)
  9276. SPEEXDSP_DIR="${withval}"
  9277. ac_mandatory_list="${ac_mandatory_list} SPEEXDSP"
  9278. ;;
  9279. esac
  9280. fi
  9281. SPEEX_PREPROCESS_DESCRIP="speex_preprocess_ctl"
  9282. SPEEX_PREPROCESS_OPTION=speex
  9283. PBX_SPEEX_PREPROCESS=0
  9284. SQLITE_DESCRIP="SQLite"
  9285. SQLITE_OPTION="sqlite"
  9286. PBX_SQLITE=0
  9287. # Check whether --with-sqlite was given.
  9288. if test "${with_sqlite+set}" = set; then :
  9289. withval=$with_sqlite;
  9290. case ${withval} in
  9291. n|no)
  9292. USE_SQLITE=no
  9293. # -1 is a magic value used by menuselect to know that the package
  9294. # was disabled, other than 'not found'
  9295. PBX_SQLITE=-1
  9296. ;;
  9297. y|ye|yes)
  9298. ac_mandatory_list="${ac_mandatory_list} SQLITE"
  9299. ;;
  9300. *)
  9301. SQLITE_DIR="${withval}"
  9302. ac_mandatory_list="${ac_mandatory_list} SQLITE"
  9303. ;;
  9304. esac
  9305. fi
  9306. SQLITE3_DESCRIP="SQLite"
  9307. SQLITE3_OPTION="sqlite3"
  9308. PBX_SQLITE3=0
  9309. # Check whether --with-sqlite3 was given.
  9310. if test "${with_sqlite3+set}" = set; then :
  9311. withval=$with_sqlite3;
  9312. case ${withval} in
  9313. n|no)
  9314. USE_SQLITE3=no
  9315. # -1 is a magic value used by menuselect to know that the package
  9316. # was disabled, other than 'not found'
  9317. PBX_SQLITE3=-1
  9318. ;;
  9319. y|ye|yes)
  9320. ac_mandatory_list="${ac_mandatory_list} SQLITE3"
  9321. ;;
  9322. *)
  9323. SQLITE3_DIR="${withval}"
  9324. ac_mandatory_list="${ac_mandatory_list} SQLITE3"
  9325. ;;
  9326. esac
  9327. fi
  9328. SRTP_DESCRIP="Secure RTP"
  9329. SRTP_OPTION="srtp"
  9330. PBX_SRTP=0
  9331. # Check whether --with-srtp was given.
  9332. if test "${with_srtp+set}" = set; then :
  9333. withval=$with_srtp;
  9334. case ${withval} in
  9335. n|no)
  9336. USE_SRTP=no
  9337. # -1 is a magic value used by menuselect to know that the package
  9338. # was disabled, other than 'not found'
  9339. PBX_SRTP=-1
  9340. ;;
  9341. y|ye|yes)
  9342. ac_mandatory_list="${ac_mandatory_list} SRTP"
  9343. ;;
  9344. *)
  9345. SRTP_DIR="${withval}"
  9346. ac_mandatory_list="${ac_mandatory_list} SRTP"
  9347. ;;
  9348. esac
  9349. fi
  9350. SRTP_SHUTDOWN_DESCRIP="SRTP Library Shutdown Function"
  9351. SRTP_SHUTDOWN_OPTION=srtp
  9352. SRTP_SHUTDOWN_DIR=${SRTP_DIR}
  9353. PBX_SRTP_SHUTDOWN=0
  9354. OPENSSL_DESCRIP="OpenSSL Secure Sockets Layer"
  9355. OPENSSL_OPTION="ssl"
  9356. PBX_OPENSSL=0
  9357. # Check whether --with-ssl was given.
  9358. if test "${with_ssl+set}" = set; then :
  9359. withval=$with_ssl;
  9360. case ${withval} in
  9361. n|no)
  9362. USE_OPENSSL=no
  9363. # -1 is a magic value used by menuselect to know that the package
  9364. # was disabled, other than 'not found'
  9365. PBX_OPENSSL=-1
  9366. ;;
  9367. y|ye|yes)
  9368. ac_mandatory_list="${ac_mandatory_list} OPENSSL"
  9369. ;;
  9370. *)
  9371. OPENSSL_DIR="${withval}"
  9372. ac_mandatory_list="${ac_mandatory_list} OPENSSL"
  9373. ;;
  9374. esac
  9375. fi
  9376. SUPPSERV_DESCRIP="mISDN Supplemental Services"
  9377. SUPPSERV_OPTION="suppserv"
  9378. PBX_SUPPSERV=0
  9379. # Check whether --with-suppserv was given.
  9380. if test "${with_suppserv+set}" = set; then :
  9381. withval=$with_suppserv;
  9382. case ${withval} in
  9383. n|no)
  9384. USE_SUPPSERV=no
  9385. # -1 is a magic value used by menuselect to know that the package
  9386. # was disabled, other than 'not found'
  9387. PBX_SUPPSERV=-1
  9388. ;;
  9389. y|ye|yes)
  9390. ac_mandatory_list="${ac_mandatory_list} SUPPSERV"
  9391. ;;
  9392. *)
  9393. SUPPSERV_DIR="${withval}"
  9394. ac_mandatory_list="${ac_mandatory_list} SUPPSERV"
  9395. ;;
  9396. esac
  9397. fi
  9398. FREETDS_DESCRIP="FreeTDS"
  9399. FREETDS_OPTION="tds"
  9400. PBX_FREETDS=0
  9401. # Check whether --with-tds was given.
  9402. if test "${with_tds+set}" = set; then :
  9403. withval=$with_tds;
  9404. case ${withval} in
  9405. n|no)
  9406. USE_FREETDS=no
  9407. # -1 is a magic value used by menuselect to know that the package
  9408. # was disabled, other than 'not found'
  9409. PBX_FREETDS=-1
  9410. ;;
  9411. y|ye|yes)
  9412. ac_mandatory_list="${ac_mandatory_list} FREETDS"
  9413. ;;
  9414. *)
  9415. FREETDS_DIR="${withval}"
  9416. ac_mandatory_list="${ac_mandatory_list} FREETDS"
  9417. ;;
  9418. esac
  9419. fi
  9420. TERMCAP_DESCRIP="Termcap"
  9421. TERMCAP_OPTION="termcap"
  9422. PBX_TERMCAP=0
  9423. # Check whether --with-termcap was given.
  9424. if test "${with_termcap+set}" = set; then :
  9425. withval=$with_termcap;
  9426. case ${withval} in
  9427. n|no)
  9428. USE_TERMCAP=no
  9429. # -1 is a magic value used by menuselect to know that the package
  9430. # was disabled, other than 'not found'
  9431. PBX_TERMCAP=-1
  9432. ;;
  9433. y|ye|yes)
  9434. ac_mandatory_list="${ac_mandatory_list} TERMCAP"
  9435. ;;
  9436. *)
  9437. TERMCAP_DIR="${withval}"
  9438. ac_mandatory_list="${ac_mandatory_list} TERMCAP"
  9439. ;;
  9440. esac
  9441. fi
  9442. TIMERFD_DESCRIP="timerfd"
  9443. TIMERFD_OPTION="timerfd"
  9444. PBX_TIMERFD=0
  9445. # Check whether --with-timerfd was given.
  9446. if test "${with_timerfd+set}" = set; then :
  9447. withval=$with_timerfd;
  9448. case ${withval} in
  9449. n|no)
  9450. USE_TIMERFD=no
  9451. # -1 is a magic value used by menuselect to know that the package
  9452. # was disabled, other than 'not found'
  9453. PBX_TIMERFD=-1
  9454. ;;
  9455. y|ye|yes)
  9456. ac_mandatory_list="${ac_mandatory_list} TIMERFD"
  9457. ;;
  9458. *)
  9459. TIMERFD_DIR="${withval}"
  9460. ac_mandatory_list="${ac_mandatory_list} TIMERFD"
  9461. ;;
  9462. esac
  9463. fi
  9464. TINFO_DESCRIP="Term Info"
  9465. TINFO_OPTION="tinfo"
  9466. PBX_TINFO=0
  9467. # Check whether --with-tinfo was given.
  9468. if test "${with_tinfo+set}" = set; then :
  9469. withval=$with_tinfo;
  9470. case ${withval} in
  9471. n|no)
  9472. USE_TINFO=no
  9473. # -1 is a magic value used by menuselect to know that the package
  9474. # was disabled, other than 'not found'
  9475. PBX_TINFO=-1
  9476. ;;
  9477. y|ye|yes)
  9478. ac_mandatory_list="${ac_mandatory_list} TINFO"
  9479. ;;
  9480. *)
  9481. TINFO_DIR="${withval}"
  9482. ac_mandatory_list="${ac_mandatory_list} TINFO"
  9483. ;;
  9484. esac
  9485. fi
  9486. TONEZONE_DESCRIP="tonezone"
  9487. TONEZONE_OPTION="tonezone"
  9488. PBX_TONEZONE=0
  9489. # Check whether --with-tonezone was given.
  9490. if test "${with_tonezone+set}" = set; then :
  9491. withval=$with_tonezone;
  9492. case ${withval} in
  9493. n|no)
  9494. USE_TONEZONE=no
  9495. # -1 is a magic value used by menuselect to know that the package
  9496. # was disabled, other than 'not found'
  9497. PBX_TONEZONE=-1
  9498. ;;
  9499. y|ye|yes)
  9500. ac_mandatory_list="${ac_mandatory_list} TONEZONE"
  9501. ;;
  9502. *)
  9503. TONEZONE_DIR="${withval}"
  9504. ac_mandatory_list="${ac_mandatory_list} TONEZONE"
  9505. ;;
  9506. esac
  9507. fi
  9508. UNIXODBC_DESCRIP="unixODBC"
  9509. UNIXODBC_OPTION="unixodbc"
  9510. PBX_UNIXODBC=0
  9511. # Check whether --with-unixodbc was given.
  9512. if test "${with_unixodbc+set}" = set; then :
  9513. withval=$with_unixodbc;
  9514. case ${withval} in
  9515. n|no)
  9516. USE_UNIXODBC=no
  9517. # -1 is a magic value used by menuselect to know that the package
  9518. # was disabled, other than 'not found'
  9519. PBX_UNIXODBC=-1
  9520. ;;
  9521. y|ye|yes)
  9522. ac_mandatory_list="${ac_mandatory_list} UNIXODBC"
  9523. ;;
  9524. *)
  9525. UNIXODBC_DIR="${withval}"
  9526. ac_mandatory_list="${ac_mandatory_list} UNIXODBC"
  9527. ;;
  9528. esac
  9529. fi
  9530. VORBIS_DESCRIP="Vorbis"
  9531. VORBIS_OPTION="vorbis"
  9532. PBX_VORBIS=0
  9533. # Check whether --with-vorbis was given.
  9534. if test "${with_vorbis+set}" = set; then :
  9535. withval=$with_vorbis;
  9536. case ${withval} in
  9537. n|no)
  9538. USE_VORBIS=no
  9539. # -1 is a magic value used by menuselect to know that the package
  9540. # was disabled, other than 'not found'
  9541. PBX_VORBIS=-1
  9542. ;;
  9543. y|ye|yes)
  9544. ac_mandatory_list="${ac_mandatory_list} VORBIS"
  9545. ;;
  9546. *)
  9547. VORBIS_DIR="${withval}"
  9548. ac_mandatory_list="${ac_mandatory_list} VORBIS"
  9549. ;;
  9550. esac
  9551. fi
  9552. VPB_DESCRIP="Voicetronix API"
  9553. VPB_OPTION="vpb"
  9554. PBX_VPB=0
  9555. # Check whether --with-vpb was given.
  9556. if test "${with_vpb+set}" = set; then :
  9557. withval=$with_vpb;
  9558. case ${withval} in
  9559. n|no)
  9560. USE_VPB=no
  9561. # -1 is a magic value used by menuselect to know that the package
  9562. # was disabled, other than 'not found'
  9563. PBX_VPB=-1
  9564. ;;
  9565. y|ye|yes)
  9566. ac_mandatory_list="${ac_mandatory_list} VPB"
  9567. ;;
  9568. *)
  9569. VPB_DIR="${withval}"
  9570. ac_mandatory_list="${ac_mandatory_list} VPB"
  9571. ;;
  9572. esac
  9573. fi
  9574. X11_DESCRIP="X11"
  9575. X11_OPTION="x11"
  9576. PBX_X11=0
  9577. # Check whether --with-x11 was given.
  9578. if test "${with_x11+set}" = set; then :
  9579. withval=$with_x11;
  9580. case ${withval} in
  9581. n|no)
  9582. USE_X11=no
  9583. # -1 is a magic value used by menuselect to know that the package
  9584. # was disabled, other than 'not found'
  9585. PBX_X11=-1
  9586. ;;
  9587. y|ye|yes)
  9588. ac_mandatory_list="${ac_mandatory_list} X11"
  9589. ;;
  9590. *)
  9591. X11_DIR="${withval}"
  9592. ac_mandatory_list="${ac_mandatory_list} X11"
  9593. ;;
  9594. esac
  9595. fi
  9596. ZLIB_DESCRIP="zlib compression"
  9597. ZLIB_OPTION="z"
  9598. PBX_ZLIB=0
  9599. # Check whether --with-z was given.
  9600. if test "${with_z+set}" = set; then :
  9601. withval=$with_z;
  9602. case ${withval} in
  9603. n|no)
  9604. USE_ZLIB=no
  9605. # -1 is a magic value used by menuselect to know that the package
  9606. # was disabled, other than 'not found'
  9607. PBX_ZLIB=-1
  9608. ;;
  9609. y|ye|yes)
  9610. ac_mandatory_list="${ac_mandatory_list} ZLIB"
  9611. ;;
  9612. *)
  9613. ZLIB_DIR="${withval}"
  9614. ac_mandatory_list="${ac_mandatory_list} ZLIB"
  9615. ;;
  9616. esac
  9617. fi
  9618. # check for basic system features and functionality before
  9619. # checking for package libraries
  9620. ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
  9621. if test "x$ac_cv_type_size_t" = xyes; then :
  9622. else
  9623. cat >>confdefs.h <<_ACEOF
  9624. #define size_t unsigned int
  9625. _ACEOF
  9626. fi
  9627. # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
  9628. # for constant arguments. Useless!
  9629. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
  9630. $as_echo_n "checking for working alloca.h... " >&6; }
  9631. if ${ac_cv_working_alloca_h+:} false; then :
  9632. $as_echo_n "(cached) " >&6
  9633. else
  9634. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9635. /* end confdefs.h. */
  9636. #include <alloca.h>
  9637. int
  9638. main ()
  9639. {
  9640. char *p = (char *) alloca (2 * sizeof (int));
  9641. if (p) return 0;
  9642. ;
  9643. return 0;
  9644. }
  9645. _ACEOF
  9646. if ac_fn_c_try_link "$LINENO"; then :
  9647. ac_cv_working_alloca_h=yes
  9648. else
  9649. ac_cv_working_alloca_h=no
  9650. fi
  9651. rm -f core conftest.err conftest.$ac_objext \
  9652. conftest$ac_exeext conftest.$ac_ext
  9653. fi
  9654. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
  9655. $as_echo "$ac_cv_working_alloca_h" >&6; }
  9656. if test $ac_cv_working_alloca_h = yes; then
  9657. $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
  9658. fi
  9659. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
  9660. $as_echo_n "checking for alloca... " >&6; }
  9661. if ${ac_cv_func_alloca_works+:} false; then :
  9662. $as_echo_n "(cached) " >&6
  9663. else
  9664. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9665. /* end confdefs.h. */
  9666. #ifdef __GNUC__
  9667. # define alloca __builtin_alloca
  9668. #else
  9669. # ifdef _MSC_VER
  9670. # include <malloc.h>
  9671. # define alloca _alloca
  9672. # else
  9673. # ifdef HAVE_ALLOCA_H
  9674. # include <alloca.h>
  9675. # else
  9676. # ifdef _AIX
  9677. #pragma alloca
  9678. # else
  9679. # ifndef alloca /* predefined by HP cc +Olibcalls */
  9680. void *alloca (size_t);
  9681. # endif
  9682. # endif
  9683. # endif
  9684. # endif
  9685. #endif
  9686. int
  9687. main ()
  9688. {
  9689. char *p = (char *) alloca (1);
  9690. if (p) return 0;
  9691. ;
  9692. return 0;
  9693. }
  9694. _ACEOF
  9695. if ac_fn_c_try_link "$LINENO"; then :
  9696. ac_cv_func_alloca_works=yes
  9697. else
  9698. ac_cv_func_alloca_works=no
  9699. fi
  9700. rm -f core conftest.err conftest.$ac_objext \
  9701. conftest$ac_exeext conftest.$ac_ext
  9702. fi
  9703. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
  9704. $as_echo "$ac_cv_func_alloca_works" >&6; }
  9705. if test $ac_cv_func_alloca_works = yes; then
  9706. $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
  9707. else
  9708. # The SVR3 libPW and SVR4 libucb both contain incompatible functions
  9709. # that cause trouble. Some versions do not even contain alloca or
  9710. # contain a buggy version. If you still want to use their alloca,
  9711. # use ar to extract alloca.o from them instead of compiling alloca.c.
  9712. ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
  9713. $as_echo "#define C_ALLOCA 1" >>confdefs.h
  9714. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
  9715. $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
  9716. if ${ac_cv_os_cray+:} false; then :
  9717. $as_echo_n "(cached) " >&6
  9718. else
  9719. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9720. /* end confdefs.h. */
  9721. #if defined CRAY && ! defined CRAY2
  9722. webecray
  9723. #else
  9724. wenotbecray
  9725. #endif
  9726. _ACEOF
  9727. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  9728. $EGREP "webecray" >/dev/null 2>&1; then :
  9729. ac_cv_os_cray=yes
  9730. else
  9731. ac_cv_os_cray=no
  9732. fi
  9733. rm -f conftest*
  9734. fi
  9735. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
  9736. $as_echo "$ac_cv_os_cray" >&6; }
  9737. if test $ac_cv_os_cray = yes; then
  9738. for ac_func in _getb67 GETB67 getb67; do
  9739. as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
  9740. ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
  9741. if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
  9742. cat >>confdefs.h <<_ACEOF
  9743. #define CRAY_STACKSEG_END $ac_func
  9744. _ACEOF
  9745. break
  9746. fi
  9747. done
  9748. fi
  9749. { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
  9750. $as_echo_n "checking stack direction for C alloca... " >&6; }
  9751. if ${ac_cv_c_stack_direction+:} false; then :
  9752. $as_echo_n "(cached) " >&6
  9753. else
  9754. if test "$cross_compiling" = yes; then :
  9755. ac_cv_c_stack_direction=0
  9756. else
  9757. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9758. /* end confdefs.h. */
  9759. $ac_includes_default
  9760. int
  9761. find_stack_direction (int *addr, int depth)
  9762. {
  9763. int dir, dummy = 0;
  9764. if (! addr)
  9765. addr = &dummy;
  9766. *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
  9767. dir = depth ? find_stack_direction (addr, depth - 1) : 0;
  9768. return dir + dummy;
  9769. }
  9770. int
  9771. main (int argc, char **argv)
  9772. {
  9773. return find_stack_direction (0, argc + !argv + 20) < 0;
  9774. }
  9775. _ACEOF
  9776. if ac_fn_c_try_run "$LINENO"; then :
  9777. ac_cv_c_stack_direction=1
  9778. else
  9779. ac_cv_c_stack_direction=-1
  9780. fi
  9781. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  9782. conftest.$ac_objext conftest.beam conftest.$ac_ext
  9783. fi
  9784. fi
  9785. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
  9786. $as_echo "$ac_cv_c_stack_direction" >&6; }
  9787. cat >>confdefs.h <<_ACEOF
  9788. #define STACK_DIRECTION $ac_cv_c_stack_direction
  9789. _ACEOF
  9790. fi
  9791. ac_header_dirent=no
  9792. for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
  9793. as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
  9794. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5
  9795. $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; }
  9796. if eval \${$as_ac_Header+:} false; then :
  9797. $as_echo_n "(cached) " >&6
  9798. else
  9799. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9800. /* end confdefs.h. */
  9801. #include <sys/types.h>
  9802. #include <$ac_hdr>
  9803. int
  9804. main ()
  9805. {
  9806. if ((DIR *) 0)
  9807. return 0;
  9808. ;
  9809. return 0;
  9810. }
  9811. _ACEOF
  9812. if ac_fn_c_try_compile "$LINENO"; then :
  9813. eval "$as_ac_Header=yes"
  9814. else
  9815. eval "$as_ac_Header=no"
  9816. fi
  9817. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  9818. fi
  9819. eval ac_res=\$$as_ac_Header
  9820. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  9821. $as_echo "$ac_res" >&6; }
  9822. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  9823. cat >>confdefs.h <<_ACEOF
  9824. #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
  9825. _ACEOF
  9826. ac_header_dirent=$ac_hdr; break
  9827. fi
  9828. done
  9829. # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
  9830. if test $ac_header_dirent = dirent.h; then
  9831. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
  9832. $as_echo_n "checking for library containing opendir... " >&6; }
  9833. if ${ac_cv_search_opendir+:} false; then :
  9834. $as_echo_n "(cached) " >&6
  9835. else
  9836. ac_func_search_save_LIBS=$LIBS
  9837. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9838. /* end confdefs.h. */
  9839. /* Override any GCC internal prototype to avoid an error.
  9840. Use char because int might match the return type of a GCC
  9841. builtin and then its argument prototype would still apply. */
  9842. #ifdef __cplusplus
  9843. extern "C"
  9844. #endif
  9845. char opendir ();
  9846. int
  9847. main ()
  9848. {
  9849. return opendir ();
  9850. ;
  9851. return 0;
  9852. }
  9853. _ACEOF
  9854. for ac_lib in '' dir; do
  9855. if test -z "$ac_lib"; then
  9856. ac_res="none required"
  9857. else
  9858. ac_res=-l$ac_lib
  9859. LIBS="-l$ac_lib $ac_func_search_save_LIBS"
  9860. fi
  9861. if ac_fn_c_try_link "$LINENO"; then :
  9862. ac_cv_search_opendir=$ac_res
  9863. fi
  9864. rm -f core conftest.err conftest.$ac_objext \
  9865. conftest$ac_exeext
  9866. if ${ac_cv_search_opendir+:} false; then :
  9867. break
  9868. fi
  9869. done
  9870. if ${ac_cv_search_opendir+:} false; then :
  9871. else
  9872. ac_cv_search_opendir=no
  9873. fi
  9874. rm conftest.$ac_ext
  9875. LIBS=$ac_func_search_save_LIBS
  9876. fi
  9877. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
  9878. $as_echo "$ac_cv_search_opendir" >&6; }
  9879. ac_res=$ac_cv_search_opendir
  9880. if test "$ac_res" != no; then :
  9881. test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
  9882. fi
  9883. else
  9884. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
  9885. $as_echo_n "checking for library containing opendir... " >&6; }
  9886. if ${ac_cv_search_opendir+:} false; then :
  9887. $as_echo_n "(cached) " >&6
  9888. else
  9889. ac_func_search_save_LIBS=$LIBS
  9890. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9891. /* end confdefs.h. */
  9892. /* Override any GCC internal prototype to avoid an error.
  9893. Use char because int might match the return type of a GCC
  9894. builtin and then its argument prototype would still apply. */
  9895. #ifdef __cplusplus
  9896. extern "C"
  9897. #endif
  9898. char opendir ();
  9899. int
  9900. main ()
  9901. {
  9902. return opendir ();
  9903. ;
  9904. return 0;
  9905. }
  9906. _ACEOF
  9907. for ac_lib in '' x; do
  9908. if test -z "$ac_lib"; then
  9909. ac_res="none required"
  9910. else
  9911. ac_res=-l$ac_lib
  9912. LIBS="-l$ac_lib $ac_func_search_save_LIBS"
  9913. fi
  9914. if ac_fn_c_try_link "$LINENO"; then :
  9915. ac_cv_search_opendir=$ac_res
  9916. fi
  9917. rm -f core conftest.err conftest.$ac_objext \
  9918. conftest$ac_exeext
  9919. if ${ac_cv_search_opendir+:} false; then :
  9920. break
  9921. fi
  9922. done
  9923. if ${ac_cv_search_opendir+:} false; then :
  9924. else
  9925. ac_cv_search_opendir=no
  9926. fi
  9927. rm conftest.$ac_ext
  9928. LIBS=$ac_func_search_save_LIBS
  9929. fi
  9930. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
  9931. $as_echo "$ac_cv_search_opendir" >&6; }
  9932. ac_res=$ac_cv_search_opendir
  9933. if test "$ac_res" != no; then :
  9934. test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
  9935. fi
  9936. fi
  9937. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
  9938. $as_echo_n "checking for ANSI C header files... " >&6; }
  9939. if ${ac_cv_header_stdc+:} false; then :
  9940. $as_echo_n "(cached) " >&6
  9941. else
  9942. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9943. /* end confdefs.h. */
  9944. #include <stdlib.h>
  9945. #include <stdarg.h>
  9946. #include <string.h>
  9947. #include <float.h>
  9948. int
  9949. main ()
  9950. {
  9951. ;
  9952. return 0;
  9953. }
  9954. _ACEOF
  9955. if ac_fn_c_try_compile "$LINENO"; then :
  9956. ac_cv_header_stdc=yes
  9957. else
  9958. ac_cv_header_stdc=no
  9959. fi
  9960. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  9961. if test $ac_cv_header_stdc = yes; then
  9962. # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
  9963. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9964. /* end confdefs.h. */
  9965. #include <string.h>
  9966. _ACEOF
  9967. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  9968. $EGREP "memchr" >/dev/null 2>&1; then :
  9969. else
  9970. ac_cv_header_stdc=no
  9971. fi
  9972. rm -f conftest*
  9973. fi
  9974. if test $ac_cv_header_stdc = yes; then
  9975. # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
  9976. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9977. /* end confdefs.h. */
  9978. #include <stdlib.h>
  9979. _ACEOF
  9980. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  9981. $EGREP "free" >/dev/null 2>&1; then :
  9982. else
  9983. ac_cv_header_stdc=no
  9984. fi
  9985. rm -f conftest*
  9986. fi
  9987. if test $ac_cv_header_stdc = yes; then
  9988. # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
  9989. if test "$cross_compiling" = yes; then :
  9990. :
  9991. else
  9992. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9993. /* end confdefs.h. */
  9994. #include <ctype.h>
  9995. #include <stdlib.h>
  9996. #if ((' ' & 0x0FF) == 0x020)
  9997. # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
  9998. # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
  9999. #else
  10000. # define ISLOWER(c) \
  10001. (('a' <= (c) && (c) <= 'i') \
  10002. || ('j' <= (c) && (c) <= 'r') \
  10003. || ('s' <= (c) && (c) <= 'z'))
  10004. # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
  10005. #endif
  10006. #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
  10007. int
  10008. main ()
  10009. {
  10010. int i;
  10011. for (i = 0; i < 256; i++)
  10012. if (XOR (islower (i), ISLOWER (i))
  10013. || toupper (i) != TOUPPER (i))
  10014. return 2;
  10015. return 0;
  10016. }
  10017. _ACEOF
  10018. if ac_fn_c_try_run "$LINENO"; then :
  10019. else
  10020. ac_cv_header_stdc=no
  10021. fi
  10022. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  10023. conftest.$ac_objext conftest.beam conftest.$ac_ext
  10024. fi
  10025. fi
  10026. fi
  10027. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
  10028. $as_echo "$ac_cv_header_stdc" >&6; }
  10029. if test $ac_cv_header_stdc = yes; then
  10030. $as_echo "#define STDC_HEADERS 1" >>confdefs.h
  10031. fi
  10032. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
  10033. $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
  10034. if ${ac_cv_header_sys_wait_h+:} false; then :
  10035. $as_echo_n "(cached) " >&6
  10036. else
  10037. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10038. /* end confdefs.h. */
  10039. #include <sys/types.h>
  10040. #include <sys/wait.h>
  10041. #ifndef WEXITSTATUS
  10042. # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
  10043. #endif
  10044. #ifndef WIFEXITED
  10045. # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
  10046. #endif
  10047. int
  10048. main ()
  10049. {
  10050. int s;
  10051. wait (&s);
  10052. s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
  10053. ;
  10054. return 0;
  10055. }
  10056. _ACEOF
  10057. if ac_fn_c_try_compile "$LINENO"; then :
  10058. ac_cv_header_sys_wait_h=yes
  10059. else
  10060. ac_cv_header_sys_wait_h=no
  10061. fi
  10062. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  10063. fi
  10064. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
  10065. $as_echo "$ac_cv_header_sys_wait_h" >&6; }
  10066. if test $ac_cv_header_sys_wait_h = yes; then
  10067. $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
  10068. fi
  10069. for ac_header in arpa/inet.h fcntl.h inttypes.h libintl.h limits.h locale.h malloc.h netdb.h netinet/in.h stddef.h stdint.h stdlib.h string.h strings.h sys/event.h sys/file.h sys/ioctl.h sys/param.h sys/socket.h sys/time.h syslog.h termios.h unistd.h utime.h arpa/nameser.h sys/io.h
  10070. do :
  10071. as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
  10072. ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
  10073. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  10074. cat >>confdefs.h <<_ACEOF
  10075. #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
  10076. _ACEOF
  10077. fi
  10078. done
  10079. # Any one of these packages support a mandatory requirement, so we want to check on them as early as possible.
  10080. if test "x${PBX_TERMCAP}" != "x1" -a "${USE_TERMCAP}" != "no"; then
  10081. pbxlibdir=""
  10082. # if --with-TERMCAP=DIR has been specified, use it.
  10083. if test "x${TERMCAP_DIR}" != "x"; then
  10084. if test -d ${TERMCAP_DIR}/lib; then
  10085. pbxlibdir="-L${TERMCAP_DIR}/lib"
  10086. else
  10087. pbxlibdir="-L${TERMCAP_DIR}"
  10088. fi
  10089. fi
  10090. pbxfuncname="tgetent"
  10091. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  10092. AST_TERMCAP_FOUND=yes
  10093. else
  10094. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  10095. CFLAGS="${CFLAGS} "
  10096. as_ac_Lib=`$as_echo "ac_cv_lib_termcap_${pbxfuncname}" | $as_tr_sh`
  10097. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -ltermcap" >&5
  10098. $as_echo_n "checking for ${pbxfuncname} in -ltermcap... " >&6; }
  10099. if eval \${$as_ac_Lib+:} false; then :
  10100. $as_echo_n "(cached) " >&6
  10101. else
  10102. ac_check_lib_save_LIBS=$LIBS
  10103. LIBS="-ltermcap ${pbxlibdir} $LIBS"
  10104. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10105. /* end confdefs.h. */
  10106. /* Override any GCC internal prototype to avoid an error.
  10107. Use char because int might match the return type of a GCC
  10108. builtin and then its argument prototype would still apply. */
  10109. #ifdef __cplusplus
  10110. extern "C"
  10111. #endif
  10112. char ${pbxfuncname} ();
  10113. int
  10114. main ()
  10115. {
  10116. return ${pbxfuncname} ();
  10117. ;
  10118. return 0;
  10119. }
  10120. _ACEOF
  10121. if ac_fn_c_try_link "$LINENO"; then :
  10122. eval "$as_ac_Lib=yes"
  10123. else
  10124. eval "$as_ac_Lib=no"
  10125. fi
  10126. rm -f core conftest.err conftest.$ac_objext \
  10127. conftest$ac_exeext conftest.$ac_ext
  10128. LIBS=$ac_check_lib_save_LIBS
  10129. fi
  10130. eval ac_res=\$$as_ac_Lib
  10131. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  10132. $as_echo "$ac_res" >&6; }
  10133. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  10134. AST_TERMCAP_FOUND=yes
  10135. else
  10136. AST_TERMCAP_FOUND=no
  10137. fi
  10138. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  10139. fi
  10140. # now check for the header.
  10141. if test "${AST_TERMCAP_FOUND}" = "yes"; then
  10142. TERMCAP_LIB="${pbxlibdir} -ltermcap "
  10143. # if --with-TERMCAP=DIR has been specified, use it.
  10144. if test "x${TERMCAP_DIR}" != "x"; then
  10145. TERMCAP_INCLUDE="-I${TERMCAP_DIR}/include"
  10146. fi
  10147. TERMCAP_INCLUDE="${TERMCAP_INCLUDE} "
  10148. if test "x" = "x" ; then # no header, assume found
  10149. TERMCAP_HEADER_FOUND="1"
  10150. else # check for the header
  10151. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  10152. CPPFLAGS="${CPPFLAGS} ${TERMCAP_INCLUDE}"
  10153. ac_fn_c_check_header_mongrel "$LINENO" "" "ac_cv_header_" "$ac_includes_default"
  10154. if test "x$ac_cv_header_" = xyes; then :
  10155. TERMCAP_HEADER_FOUND=1
  10156. else
  10157. TERMCAP_HEADER_FOUND=0
  10158. fi
  10159. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  10160. fi
  10161. if test "x${TERMCAP_HEADER_FOUND}" = "x0" ; then
  10162. TERMCAP_LIB=""
  10163. TERMCAP_INCLUDE=""
  10164. else
  10165. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  10166. TERMCAP_LIB=""
  10167. fi
  10168. PBX_TERMCAP=1
  10169. cat >>confdefs.h <<_ACEOF
  10170. #define HAVE_TERMCAP 1
  10171. _ACEOF
  10172. fi
  10173. fi
  10174. fi
  10175. if test "x${PBX_TINFO}" != "x1" -a "${USE_TINFO}" != "no"; then
  10176. pbxlibdir=""
  10177. # if --with-TINFO=DIR has been specified, use it.
  10178. if test "x${TINFO_DIR}" != "x"; then
  10179. if test -d ${TINFO_DIR}/lib; then
  10180. pbxlibdir="-L${TINFO_DIR}/lib"
  10181. else
  10182. pbxlibdir="-L${TINFO_DIR}"
  10183. fi
  10184. fi
  10185. pbxfuncname="tgetent"
  10186. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  10187. AST_TINFO_FOUND=yes
  10188. else
  10189. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  10190. CFLAGS="${CFLAGS} "
  10191. as_ac_Lib=`$as_echo "ac_cv_lib_tinfo_${pbxfuncname}" | $as_tr_sh`
  10192. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -ltinfo" >&5
  10193. $as_echo_n "checking for ${pbxfuncname} in -ltinfo... " >&6; }
  10194. if eval \${$as_ac_Lib+:} false; then :
  10195. $as_echo_n "(cached) " >&6
  10196. else
  10197. ac_check_lib_save_LIBS=$LIBS
  10198. LIBS="-ltinfo ${pbxlibdir} $LIBS"
  10199. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10200. /* end confdefs.h. */
  10201. /* Override any GCC internal prototype to avoid an error.
  10202. Use char because int might match the return type of a GCC
  10203. builtin and then its argument prototype would still apply. */
  10204. #ifdef __cplusplus
  10205. extern "C"
  10206. #endif
  10207. char ${pbxfuncname} ();
  10208. int
  10209. main ()
  10210. {
  10211. return ${pbxfuncname} ();
  10212. ;
  10213. return 0;
  10214. }
  10215. _ACEOF
  10216. if ac_fn_c_try_link "$LINENO"; then :
  10217. eval "$as_ac_Lib=yes"
  10218. else
  10219. eval "$as_ac_Lib=no"
  10220. fi
  10221. rm -f core conftest.err conftest.$ac_objext \
  10222. conftest$ac_exeext conftest.$ac_ext
  10223. LIBS=$ac_check_lib_save_LIBS
  10224. fi
  10225. eval ac_res=\$$as_ac_Lib
  10226. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  10227. $as_echo "$ac_res" >&6; }
  10228. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  10229. AST_TINFO_FOUND=yes
  10230. else
  10231. AST_TINFO_FOUND=no
  10232. fi
  10233. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  10234. fi
  10235. # now check for the header.
  10236. if test "${AST_TINFO_FOUND}" = "yes"; then
  10237. TINFO_LIB="${pbxlibdir} -ltinfo "
  10238. # if --with-TINFO=DIR has been specified, use it.
  10239. if test "x${TINFO_DIR}" != "x"; then
  10240. TINFO_INCLUDE="-I${TINFO_DIR}/include"
  10241. fi
  10242. TINFO_INCLUDE="${TINFO_INCLUDE} "
  10243. if test "x" = "x" ; then # no header, assume found
  10244. TINFO_HEADER_FOUND="1"
  10245. else # check for the header
  10246. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  10247. CPPFLAGS="${CPPFLAGS} ${TINFO_INCLUDE}"
  10248. ac_fn_c_check_header_mongrel "$LINENO" "" "ac_cv_header_" "$ac_includes_default"
  10249. if test "x$ac_cv_header_" = xyes; then :
  10250. TINFO_HEADER_FOUND=1
  10251. else
  10252. TINFO_HEADER_FOUND=0
  10253. fi
  10254. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  10255. fi
  10256. if test "x${TINFO_HEADER_FOUND}" = "x0" ; then
  10257. TINFO_LIB=""
  10258. TINFO_INCLUDE=""
  10259. else
  10260. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  10261. TINFO_LIB=""
  10262. fi
  10263. PBX_TINFO=1
  10264. cat >>confdefs.h <<_ACEOF
  10265. #define HAVE_TINFO 1
  10266. _ACEOF
  10267. fi
  10268. fi
  10269. fi
  10270. if test "x${PBX_CURSES}" != "x1" -a "${USE_CURSES}" != "no"; then
  10271. pbxlibdir=""
  10272. # if --with-CURSES=DIR has been specified, use it.
  10273. if test "x${CURSES_DIR}" != "x"; then
  10274. if test -d ${CURSES_DIR}/lib; then
  10275. pbxlibdir="-L${CURSES_DIR}/lib"
  10276. else
  10277. pbxlibdir="-L${CURSES_DIR}"
  10278. fi
  10279. fi
  10280. pbxfuncname="initscr"
  10281. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  10282. AST_CURSES_FOUND=yes
  10283. else
  10284. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  10285. CFLAGS="${CFLAGS} "
  10286. as_ac_Lib=`$as_echo "ac_cv_lib_curses_${pbxfuncname}" | $as_tr_sh`
  10287. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lcurses" >&5
  10288. $as_echo_n "checking for ${pbxfuncname} in -lcurses... " >&6; }
  10289. if eval \${$as_ac_Lib+:} false; then :
  10290. $as_echo_n "(cached) " >&6
  10291. else
  10292. ac_check_lib_save_LIBS=$LIBS
  10293. LIBS="-lcurses ${pbxlibdir} $LIBS"
  10294. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10295. /* end confdefs.h. */
  10296. /* Override any GCC internal prototype to avoid an error.
  10297. Use char because int might match the return type of a GCC
  10298. builtin and then its argument prototype would still apply. */
  10299. #ifdef __cplusplus
  10300. extern "C"
  10301. #endif
  10302. char ${pbxfuncname} ();
  10303. int
  10304. main ()
  10305. {
  10306. return ${pbxfuncname} ();
  10307. ;
  10308. return 0;
  10309. }
  10310. _ACEOF
  10311. if ac_fn_c_try_link "$LINENO"; then :
  10312. eval "$as_ac_Lib=yes"
  10313. else
  10314. eval "$as_ac_Lib=no"
  10315. fi
  10316. rm -f core conftest.err conftest.$ac_objext \
  10317. conftest$ac_exeext conftest.$ac_ext
  10318. LIBS=$ac_check_lib_save_LIBS
  10319. fi
  10320. eval ac_res=\$$as_ac_Lib
  10321. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  10322. $as_echo "$ac_res" >&6; }
  10323. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  10324. AST_CURSES_FOUND=yes
  10325. else
  10326. AST_CURSES_FOUND=no
  10327. fi
  10328. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  10329. fi
  10330. # now check for the header.
  10331. if test "${AST_CURSES_FOUND}" = "yes"; then
  10332. CURSES_LIB="${pbxlibdir} -lcurses "
  10333. # if --with-CURSES=DIR has been specified, use it.
  10334. if test "x${CURSES_DIR}" != "x"; then
  10335. CURSES_INCLUDE="-I${CURSES_DIR}/include"
  10336. fi
  10337. CURSES_INCLUDE="${CURSES_INCLUDE} "
  10338. if test "xcurses.h" = "x" ; then # no header, assume found
  10339. CURSES_HEADER_FOUND="1"
  10340. else # check for the header
  10341. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  10342. CPPFLAGS="${CPPFLAGS} ${CURSES_INCLUDE}"
  10343. ac_fn_c_check_header_mongrel "$LINENO" "curses.h" "ac_cv_header_curses_h" "$ac_includes_default"
  10344. if test "x$ac_cv_header_curses_h" = xyes; then :
  10345. CURSES_HEADER_FOUND=1
  10346. else
  10347. CURSES_HEADER_FOUND=0
  10348. fi
  10349. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  10350. fi
  10351. if test "x${CURSES_HEADER_FOUND}" = "x0" ; then
  10352. CURSES_LIB=""
  10353. CURSES_INCLUDE=""
  10354. else
  10355. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  10356. CURSES_LIB=""
  10357. fi
  10358. PBX_CURSES=1
  10359. cat >>confdefs.h <<_ACEOF
  10360. #define HAVE_CURSES 1
  10361. _ACEOF
  10362. fi
  10363. fi
  10364. fi
  10365. if test "x${PBX_NCURSES}" != "x1" -a "${USE_NCURSES}" != "no"; then
  10366. pbxlibdir=""
  10367. # if --with-NCURSES=DIR has been specified, use it.
  10368. if test "x${NCURSES_DIR}" != "x"; then
  10369. if test -d ${NCURSES_DIR}/lib; then
  10370. pbxlibdir="-L${NCURSES_DIR}/lib"
  10371. else
  10372. pbxlibdir="-L${NCURSES_DIR}"
  10373. fi
  10374. fi
  10375. pbxfuncname="initscr"
  10376. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  10377. AST_NCURSES_FOUND=yes
  10378. else
  10379. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  10380. CFLAGS="${CFLAGS} "
  10381. as_ac_Lib=`$as_echo "ac_cv_lib_ncurses_${pbxfuncname}" | $as_tr_sh`
  10382. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lncurses" >&5
  10383. $as_echo_n "checking for ${pbxfuncname} in -lncurses... " >&6; }
  10384. if eval \${$as_ac_Lib+:} false; then :
  10385. $as_echo_n "(cached) " >&6
  10386. else
  10387. ac_check_lib_save_LIBS=$LIBS
  10388. LIBS="-lncurses ${pbxlibdir} $LIBS"
  10389. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10390. /* end confdefs.h. */
  10391. /* Override any GCC internal prototype to avoid an error.
  10392. Use char because int might match the return type of a GCC
  10393. builtin and then its argument prototype would still apply. */
  10394. #ifdef __cplusplus
  10395. extern "C"
  10396. #endif
  10397. char ${pbxfuncname} ();
  10398. int
  10399. main ()
  10400. {
  10401. return ${pbxfuncname} ();
  10402. ;
  10403. return 0;
  10404. }
  10405. _ACEOF
  10406. if ac_fn_c_try_link "$LINENO"; then :
  10407. eval "$as_ac_Lib=yes"
  10408. else
  10409. eval "$as_ac_Lib=no"
  10410. fi
  10411. rm -f core conftest.err conftest.$ac_objext \
  10412. conftest$ac_exeext conftest.$ac_ext
  10413. LIBS=$ac_check_lib_save_LIBS
  10414. fi
  10415. eval ac_res=\$$as_ac_Lib
  10416. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  10417. $as_echo "$ac_res" >&6; }
  10418. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  10419. AST_NCURSES_FOUND=yes
  10420. else
  10421. AST_NCURSES_FOUND=no
  10422. fi
  10423. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  10424. fi
  10425. # now check for the header.
  10426. if test "${AST_NCURSES_FOUND}" = "yes"; then
  10427. NCURSES_LIB="${pbxlibdir} -lncurses "
  10428. # if --with-NCURSES=DIR has been specified, use it.
  10429. if test "x${NCURSES_DIR}" != "x"; then
  10430. NCURSES_INCLUDE="-I${NCURSES_DIR}/include"
  10431. fi
  10432. NCURSES_INCLUDE="${NCURSES_INCLUDE} "
  10433. if test "xcurses.h" = "x" ; then # no header, assume found
  10434. NCURSES_HEADER_FOUND="1"
  10435. else # check for the header
  10436. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  10437. CPPFLAGS="${CPPFLAGS} ${NCURSES_INCLUDE}"
  10438. ac_fn_c_check_header_mongrel "$LINENO" "curses.h" "ac_cv_header_curses_h" "$ac_includes_default"
  10439. if test "x$ac_cv_header_curses_h" = xyes; then :
  10440. NCURSES_HEADER_FOUND=1
  10441. else
  10442. NCURSES_HEADER_FOUND=0
  10443. fi
  10444. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  10445. fi
  10446. if test "x${NCURSES_HEADER_FOUND}" = "x0" ; then
  10447. NCURSES_LIB=""
  10448. NCURSES_INCLUDE=""
  10449. else
  10450. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  10451. NCURSES_LIB=""
  10452. fi
  10453. PBX_NCURSES=1
  10454. cat >>confdefs.h <<_ACEOF
  10455. #define HAVE_NCURSES 1
  10456. _ACEOF
  10457. fi
  10458. fi
  10459. fi
  10460. EDITLINE_LIB=""
  10461. if test "x$TERMCAP_LIB" != "x" ; then
  10462. EDITLINE_LIB="$TERMCAP_LIB"
  10463. elif test "x$TINFO_LIB" != "x" ; then
  10464. EDITLINE_LIB="$TINFO_LIB"
  10465. elif test "x$CURSES_LIB" != "x" ; then
  10466. EDITLINE_LIB="$CURSES_LIB"
  10467. elif test "x$NCURSES_LIB" != "x" ; then
  10468. EDITLINE_LIB="$NCURSES_LIB"
  10469. else
  10470. as_fn_error $? "*** termcap support not found (on modern systems, this typically means the ncurses development package is missing)" "$LINENO" 5
  10471. fi
  10472. # Find required UUID support.
  10473. # * -luuid on Linux
  10474. # * -le2fs-uuid on OpenBSD
  10475. # * in libsystem on OS X
  10476. if test "x${PBX_LIBUUID}" != "x1" -a "${USE_LIBUUID}" != "no"; then
  10477. pbxlibdir=""
  10478. # if --with-LIBUUID=DIR has been specified, use it.
  10479. if test "x${LIBUUID_DIR}" != "x"; then
  10480. if test -d ${LIBUUID_DIR}/lib; then
  10481. pbxlibdir="-L${LIBUUID_DIR}/lib"
  10482. else
  10483. pbxlibdir="-L${LIBUUID_DIR}"
  10484. fi
  10485. fi
  10486. pbxfuncname="uuid_generate_random"
  10487. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  10488. AST_LIBUUID_FOUND=yes
  10489. else
  10490. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  10491. CFLAGS="${CFLAGS} "
  10492. as_ac_Lib=`$as_echo "ac_cv_lib_uuid_${pbxfuncname}" | $as_tr_sh`
  10493. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -luuid" >&5
  10494. $as_echo_n "checking for ${pbxfuncname} in -luuid... " >&6; }
  10495. if eval \${$as_ac_Lib+:} false; then :
  10496. $as_echo_n "(cached) " >&6
  10497. else
  10498. ac_check_lib_save_LIBS=$LIBS
  10499. LIBS="-luuid ${pbxlibdir} $LIBS"
  10500. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10501. /* end confdefs.h. */
  10502. /* Override any GCC internal prototype to avoid an error.
  10503. Use char because int might match the return type of a GCC
  10504. builtin and then its argument prototype would still apply. */
  10505. #ifdef __cplusplus
  10506. extern "C"
  10507. #endif
  10508. char ${pbxfuncname} ();
  10509. int
  10510. main ()
  10511. {
  10512. return ${pbxfuncname} ();
  10513. ;
  10514. return 0;
  10515. }
  10516. _ACEOF
  10517. if ac_fn_c_try_link "$LINENO"; then :
  10518. eval "$as_ac_Lib=yes"
  10519. else
  10520. eval "$as_ac_Lib=no"
  10521. fi
  10522. rm -f core conftest.err conftest.$ac_objext \
  10523. conftest$ac_exeext conftest.$ac_ext
  10524. LIBS=$ac_check_lib_save_LIBS
  10525. fi
  10526. eval ac_res=\$$as_ac_Lib
  10527. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  10528. $as_echo "$ac_res" >&6; }
  10529. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  10530. AST_LIBUUID_FOUND=yes
  10531. else
  10532. AST_LIBUUID_FOUND=no
  10533. fi
  10534. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  10535. fi
  10536. # now check for the header.
  10537. if test "${AST_LIBUUID_FOUND}" = "yes"; then
  10538. LIBUUID_LIB="${pbxlibdir} -luuid "
  10539. # if --with-LIBUUID=DIR has been specified, use it.
  10540. if test "x${LIBUUID_DIR}" != "x"; then
  10541. LIBUUID_INCLUDE="-I${LIBUUID_DIR}/include"
  10542. fi
  10543. LIBUUID_INCLUDE="${LIBUUID_INCLUDE} "
  10544. if test "xuuid/uuid.h" = "x" ; then # no header, assume found
  10545. LIBUUID_HEADER_FOUND="1"
  10546. else # check for the header
  10547. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  10548. CPPFLAGS="${CPPFLAGS} ${LIBUUID_INCLUDE}"
  10549. ac_fn_c_check_header_mongrel "$LINENO" "uuid/uuid.h" "ac_cv_header_uuid_uuid_h" "$ac_includes_default"
  10550. if test "x$ac_cv_header_uuid_uuid_h" = xyes; then :
  10551. LIBUUID_HEADER_FOUND=1
  10552. else
  10553. LIBUUID_HEADER_FOUND=0
  10554. fi
  10555. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  10556. fi
  10557. if test "x${LIBUUID_HEADER_FOUND}" = "x0" ; then
  10558. LIBUUID_LIB=""
  10559. LIBUUID_INCLUDE=""
  10560. else
  10561. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  10562. LIBUUID_LIB=""
  10563. fi
  10564. PBX_LIBUUID=1
  10565. cat >>confdefs.h <<_ACEOF
  10566. #define HAVE_LIBUUID 1
  10567. _ACEOF
  10568. fi
  10569. fi
  10570. fi
  10571. if test "x${PBX_E2FSUUID}" != "x1" -a "${USE_E2FSUUID}" != "no"; then
  10572. pbxlibdir=""
  10573. # if --with-E2FSUUID=DIR has been specified, use it.
  10574. if test "x${E2FSUUID_DIR}" != "x"; then
  10575. if test -d ${E2FSUUID_DIR}/lib; then
  10576. pbxlibdir="-L${E2FSUUID_DIR}/lib"
  10577. else
  10578. pbxlibdir="-L${E2FSUUID_DIR}"
  10579. fi
  10580. fi
  10581. pbxfuncname="uuid_generate_random"
  10582. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  10583. AST_E2FSUUID_FOUND=yes
  10584. else
  10585. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  10586. CFLAGS="${CFLAGS} "
  10587. as_ac_Lib=`$as_echo "ac_cv_lib_e2fs-uuid_${pbxfuncname}" | $as_tr_sh`
  10588. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -le2fs-uuid" >&5
  10589. $as_echo_n "checking for ${pbxfuncname} in -le2fs-uuid... " >&6; }
  10590. if eval \${$as_ac_Lib+:} false; then :
  10591. $as_echo_n "(cached) " >&6
  10592. else
  10593. ac_check_lib_save_LIBS=$LIBS
  10594. LIBS="-le2fs-uuid ${pbxlibdir} $LIBS"
  10595. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10596. /* end confdefs.h. */
  10597. /* Override any GCC internal prototype to avoid an error.
  10598. Use char because int might match the return type of a GCC
  10599. builtin and then its argument prototype would still apply. */
  10600. #ifdef __cplusplus
  10601. extern "C"
  10602. #endif
  10603. char ${pbxfuncname} ();
  10604. int
  10605. main ()
  10606. {
  10607. return ${pbxfuncname} ();
  10608. ;
  10609. return 0;
  10610. }
  10611. _ACEOF
  10612. if ac_fn_c_try_link "$LINENO"; then :
  10613. eval "$as_ac_Lib=yes"
  10614. else
  10615. eval "$as_ac_Lib=no"
  10616. fi
  10617. rm -f core conftest.err conftest.$ac_objext \
  10618. conftest$ac_exeext conftest.$ac_ext
  10619. LIBS=$ac_check_lib_save_LIBS
  10620. fi
  10621. eval ac_res=\$$as_ac_Lib
  10622. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  10623. $as_echo "$ac_res" >&6; }
  10624. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  10625. AST_E2FSUUID_FOUND=yes
  10626. else
  10627. AST_E2FSUUID_FOUND=no
  10628. fi
  10629. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  10630. fi
  10631. # now check for the header.
  10632. if test "${AST_E2FSUUID_FOUND}" = "yes"; then
  10633. E2FSUUID_LIB="${pbxlibdir} -le2fs-uuid "
  10634. # if --with-E2FSUUID=DIR has been specified, use it.
  10635. if test "x${E2FSUUID_DIR}" != "x"; then
  10636. E2FSUUID_INCLUDE="-I${E2FSUUID_DIR}/include"
  10637. fi
  10638. E2FSUUID_INCLUDE="${E2FSUUID_INCLUDE} "
  10639. if test "xuuid/uuid.h" = "x" ; then # no header, assume found
  10640. E2FSUUID_HEADER_FOUND="1"
  10641. else # check for the header
  10642. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  10643. CPPFLAGS="${CPPFLAGS} ${E2FSUUID_INCLUDE}"
  10644. ac_fn_c_check_header_mongrel "$LINENO" "uuid/uuid.h" "ac_cv_header_uuid_uuid_h" "$ac_includes_default"
  10645. if test "x$ac_cv_header_uuid_uuid_h" = xyes; then :
  10646. E2FSUUID_HEADER_FOUND=1
  10647. else
  10648. E2FSUUID_HEADER_FOUND=0
  10649. fi
  10650. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  10651. fi
  10652. if test "x${E2FSUUID_HEADER_FOUND}" = "x0" ; then
  10653. E2FSUUID_LIB=""
  10654. E2FSUUID_INCLUDE=""
  10655. else
  10656. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  10657. E2FSUUID_LIB=""
  10658. fi
  10659. PBX_E2FSUUID=1
  10660. cat >>confdefs.h <<_ACEOF
  10661. #define HAVE_E2FSUUID 1
  10662. _ACEOF
  10663. fi
  10664. fi
  10665. fi
  10666. for ac_func in uuid_generate_random
  10667. do :
  10668. ac_fn_c_check_func "$LINENO" "uuid_generate_random" "ac_cv_func_uuid_generate_random"
  10669. if test "x$ac_cv_func_uuid_generate_random" = xyes; then :
  10670. cat >>confdefs.h <<_ACEOF
  10671. #define HAVE_UUID_GENERATE_RANDOM 1
  10672. _ACEOF
  10673. SYSUUID=true
  10674. else
  10675. SYSUUID=""
  10676. fi
  10677. done
  10678. if test "x$LIBUUID_LIB" != "x" ; then
  10679. UUID_INCLUDE="$LIBUUID_INCLUDE"
  10680. UUID_LIB="$LIBUUID_LIB"
  10681. elif test "x$E2FSUUID_LIB" != "x" ; then
  10682. UUID_INCLUDE="$E2FSUUID_INCLUDE"
  10683. UUID_LIB="$E2FSUUID_LIB"
  10684. elif test "x$SYSUUID" != "x" ; then
  10685. UUID_INCLUDE=""
  10686. UUID_LIB=""
  10687. else
  10688. as_fn_error $? "*** uuid support not found (this typically means the uuid development package is missing)" "$LINENO" 5
  10689. fi
  10690. # Find required JSON support.
  10691. if test "x${PBX_JANSSON}" != "x1" -a "${USE_JANSSON}" != "no"; then
  10692. pbxlibdir=""
  10693. # if --with-JANSSON=DIR has been specified, use it.
  10694. if test "x${JANSSON_DIR}" != "x"; then
  10695. if test -d ${JANSSON_DIR}/lib; then
  10696. pbxlibdir="-L${JANSSON_DIR}/lib"
  10697. else
  10698. pbxlibdir="-L${JANSSON_DIR}"
  10699. fi
  10700. fi
  10701. pbxfuncname="json_dumps"
  10702. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  10703. AST_JANSSON_FOUND=yes
  10704. else
  10705. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  10706. CFLAGS="${CFLAGS} "
  10707. as_ac_Lib=`$as_echo "ac_cv_lib_jansson_${pbxfuncname}" | $as_tr_sh`
  10708. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -ljansson" >&5
  10709. $as_echo_n "checking for ${pbxfuncname} in -ljansson... " >&6; }
  10710. if eval \${$as_ac_Lib+:} false; then :
  10711. $as_echo_n "(cached) " >&6
  10712. else
  10713. ac_check_lib_save_LIBS=$LIBS
  10714. LIBS="-ljansson ${pbxlibdir} $LIBS"
  10715. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10716. /* end confdefs.h. */
  10717. /* Override any GCC internal prototype to avoid an error.
  10718. Use char because int might match the return type of a GCC
  10719. builtin and then its argument prototype would still apply. */
  10720. #ifdef __cplusplus
  10721. extern "C"
  10722. #endif
  10723. char ${pbxfuncname} ();
  10724. int
  10725. main ()
  10726. {
  10727. return ${pbxfuncname} ();
  10728. ;
  10729. return 0;
  10730. }
  10731. _ACEOF
  10732. if ac_fn_c_try_link "$LINENO"; then :
  10733. eval "$as_ac_Lib=yes"
  10734. else
  10735. eval "$as_ac_Lib=no"
  10736. fi
  10737. rm -f core conftest.err conftest.$ac_objext \
  10738. conftest$ac_exeext conftest.$ac_ext
  10739. LIBS=$ac_check_lib_save_LIBS
  10740. fi
  10741. eval ac_res=\$$as_ac_Lib
  10742. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  10743. $as_echo "$ac_res" >&6; }
  10744. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  10745. AST_JANSSON_FOUND=yes
  10746. else
  10747. AST_JANSSON_FOUND=no
  10748. fi
  10749. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  10750. fi
  10751. # now check for the header.
  10752. if test "${AST_JANSSON_FOUND}" = "yes"; then
  10753. JANSSON_LIB="${pbxlibdir} -ljansson "
  10754. # if --with-JANSSON=DIR has been specified, use it.
  10755. if test "x${JANSSON_DIR}" != "x"; then
  10756. JANSSON_INCLUDE="-I${JANSSON_DIR}/include"
  10757. fi
  10758. JANSSON_INCLUDE="${JANSSON_INCLUDE} "
  10759. if test "xjansson.h" = "x" ; then # no header, assume found
  10760. JANSSON_HEADER_FOUND="1"
  10761. else # check for the header
  10762. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  10763. CPPFLAGS="${CPPFLAGS} ${JANSSON_INCLUDE}"
  10764. ac_fn_c_check_header_mongrel "$LINENO" "jansson.h" "ac_cv_header_jansson_h" "$ac_includes_default"
  10765. if test "x$ac_cv_header_jansson_h" = xyes; then :
  10766. JANSSON_HEADER_FOUND=1
  10767. else
  10768. JANSSON_HEADER_FOUND=0
  10769. fi
  10770. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  10771. fi
  10772. if test "x${JANSSON_HEADER_FOUND}" = "x0" ; then
  10773. JANSSON_LIB=""
  10774. JANSSON_INCLUDE=""
  10775. else
  10776. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  10777. JANSSON_LIB=""
  10778. fi
  10779. PBX_JANSSON=1
  10780. cat >>confdefs.h <<_ACEOF
  10781. #define HAVE_JANSSON 1
  10782. _ACEOF
  10783. fi
  10784. fi
  10785. fi
  10786. if test "x$JANSSON_LIB" == "x"; then
  10787. as_fn_error $? "*** JSON support not found (this typically means the libjansson development package is missing)" "$LINENO" 5
  10788. fi
  10789. if test "x${PBX_URIPARSER}" != "x1" -a "${USE_URIPARSER}" != "no"; then
  10790. pbxlibdir=""
  10791. # if --with-URIPARSER=DIR has been specified, use it.
  10792. if test "x${URIPARSER_DIR}" != "x"; then
  10793. if test -d ${URIPARSER_DIR}/lib; then
  10794. pbxlibdir="-L${URIPARSER_DIR}/lib"
  10795. else
  10796. pbxlibdir="-L${URIPARSER_DIR}"
  10797. fi
  10798. fi
  10799. pbxfuncname="uriParseUriA"
  10800. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  10801. AST_URIPARSER_FOUND=yes
  10802. else
  10803. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  10804. CFLAGS="${CFLAGS} "
  10805. as_ac_Lib=`$as_echo "ac_cv_lib_uriparser_${pbxfuncname}" | $as_tr_sh`
  10806. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -luriparser" >&5
  10807. $as_echo_n "checking for ${pbxfuncname} in -luriparser... " >&6; }
  10808. if eval \${$as_ac_Lib+:} false; then :
  10809. $as_echo_n "(cached) " >&6
  10810. else
  10811. ac_check_lib_save_LIBS=$LIBS
  10812. LIBS="-luriparser ${pbxlibdir} $LIBS"
  10813. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10814. /* end confdefs.h. */
  10815. /* Override any GCC internal prototype to avoid an error.
  10816. Use char because int might match the return type of a GCC
  10817. builtin and then its argument prototype would still apply. */
  10818. #ifdef __cplusplus
  10819. extern "C"
  10820. #endif
  10821. char ${pbxfuncname} ();
  10822. int
  10823. main ()
  10824. {
  10825. return ${pbxfuncname} ();
  10826. ;
  10827. return 0;
  10828. }
  10829. _ACEOF
  10830. if ac_fn_c_try_link "$LINENO"; then :
  10831. eval "$as_ac_Lib=yes"
  10832. else
  10833. eval "$as_ac_Lib=no"
  10834. fi
  10835. rm -f core conftest.err conftest.$ac_objext \
  10836. conftest$ac_exeext conftest.$ac_ext
  10837. LIBS=$ac_check_lib_save_LIBS
  10838. fi
  10839. eval ac_res=\$$as_ac_Lib
  10840. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  10841. $as_echo "$ac_res" >&6; }
  10842. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  10843. AST_URIPARSER_FOUND=yes
  10844. else
  10845. AST_URIPARSER_FOUND=no
  10846. fi
  10847. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  10848. fi
  10849. # now check for the header.
  10850. if test "${AST_URIPARSER_FOUND}" = "yes"; then
  10851. URIPARSER_LIB="${pbxlibdir} -luriparser "
  10852. # if --with-URIPARSER=DIR has been specified, use it.
  10853. if test "x${URIPARSER_DIR}" != "x"; then
  10854. URIPARSER_INCLUDE="-I${URIPARSER_DIR}/include"
  10855. fi
  10856. URIPARSER_INCLUDE="${URIPARSER_INCLUDE} "
  10857. if test "xuriparser/Uri.h" = "x" ; then # no header, assume found
  10858. URIPARSER_HEADER_FOUND="1"
  10859. else # check for the header
  10860. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  10861. CPPFLAGS="${CPPFLAGS} ${URIPARSER_INCLUDE}"
  10862. ac_fn_c_check_header_mongrel "$LINENO" "uriparser/Uri.h" "ac_cv_header_uriparser_Uri_h" "$ac_includes_default"
  10863. if test "x$ac_cv_header_uriparser_Uri_h" = xyes; then :
  10864. URIPARSER_HEADER_FOUND=1
  10865. else
  10866. URIPARSER_HEADER_FOUND=0
  10867. fi
  10868. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  10869. fi
  10870. if test "x${URIPARSER_HEADER_FOUND}" = "x0" ; then
  10871. URIPARSER_LIB=""
  10872. URIPARSER_INCLUDE=""
  10873. else
  10874. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  10875. URIPARSER_LIB=""
  10876. fi
  10877. PBX_URIPARSER=1
  10878. cat >>confdefs.h <<_ACEOF
  10879. #define HAVE_URIPARSER 1
  10880. _ACEOF
  10881. fi
  10882. fi
  10883. fi
  10884. # Another mandatory item (unless it's explicitly disabled)
  10885. # Check whether --enable-xmldoc was given.
  10886. if test "${enable_xmldoc+set}" = set; then :
  10887. enableval=$enable_xmldoc; case "${enableval}" in
  10888. y|ye|yes) disable_xmldoc=no ;;
  10889. n|no) disable_xmldoc=yes ;;
  10890. *) as_fn_error $? "bad value ${enableval} for --disable-xmldoc" "$LINENO" 5 ;;
  10891. esac
  10892. else
  10893. disable_xmldoc=no
  10894. fi
  10895. if test "${disable_xmldoc}" != "yes"; then
  10896. if test "x${PBX_LIBXML2}" != "x1" -a "${USE_LIBXML2}" != "no"; then
  10897. PBX_LIBXML2=0
  10898. if test -n "$ac_tool_prefix"; then
  10899. # Extract the first word of "${ac_tool_prefix}xml2-config", so it can be a program name with args.
  10900. set dummy ${ac_tool_prefix}xml2-config; ac_word=$2
  10901. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  10902. $as_echo_n "checking for $ac_word... " >&6; }
  10903. if ${ac_cv_path_CONFIG_LIBXML2+:} false; then :
  10904. $as_echo_n "(cached) " >&6
  10905. else
  10906. case $CONFIG_LIBXML2 in
  10907. [\\/]* | ?:[\\/]*)
  10908. ac_cv_path_CONFIG_LIBXML2="$CONFIG_LIBXML2" # Let the user override the test with a path.
  10909. ;;
  10910. *)
  10911. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  10912. as_dummy="${LIBXML2_DIR}/bin:$PATH"
  10913. for as_dir in $as_dummy
  10914. do
  10915. IFS=$as_save_IFS
  10916. test -z "$as_dir" && as_dir=.
  10917. for ac_exec_ext in '' $ac_executable_extensions; do
  10918. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  10919. ac_cv_path_CONFIG_LIBXML2="$as_dir/$ac_word$ac_exec_ext"
  10920. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  10921. break 2
  10922. fi
  10923. done
  10924. done
  10925. IFS=$as_save_IFS
  10926. ;;
  10927. esac
  10928. fi
  10929. CONFIG_LIBXML2=$ac_cv_path_CONFIG_LIBXML2
  10930. if test -n "$CONFIG_LIBXML2"; then
  10931. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONFIG_LIBXML2" >&5
  10932. $as_echo "$CONFIG_LIBXML2" >&6; }
  10933. else
  10934. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  10935. $as_echo "no" >&6; }
  10936. fi
  10937. fi
  10938. if test -z "$ac_cv_path_CONFIG_LIBXML2"; then
  10939. ac_pt_CONFIG_LIBXML2=$CONFIG_LIBXML2
  10940. # Extract the first word of "xml2-config", so it can be a program name with args.
  10941. set dummy xml2-config; ac_word=$2
  10942. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  10943. $as_echo_n "checking for $ac_word... " >&6; }
  10944. if ${ac_cv_path_ac_pt_CONFIG_LIBXML2+:} false; then :
  10945. $as_echo_n "(cached) " >&6
  10946. else
  10947. case $ac_pt_CONFIG_LIBXML2 in
  10948. [\\/]* | ?:[\\/]*)
  10949. ac_cv_path_ac_pt_CONFIG_LIBXML2="$ac_pt_CONFIG_LIBXML2" # Let the user override the test with a path.
  10950. ;;
  10951. *)
  10952. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  10953. as_dummy="${LIBXML2_DIR}/bin:$PATH"
  10954. for as_dir in $as_dummy
  10955. do
  10956. IFS=$as_save_IFS
  10957. test -z "$as_dir" && as_dir=.
  10958. for ac_exec_ext in '' $ac_executable_extensions; do
  10959. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  10960. ac_cv_path_ac_pt_CONFIG_LIBXML2="$as_dir/$ac_word$ac_exec_ext"
  10961. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  10962. break 2
  10963. fi
  10964. done
  10965. done
  10966. IFS=$as_save_IFS
  10967. ;;
  10968. esac
  10969. fi
  10970. ac_pt_CONFIG_LIBXML2=$ac_cv_path_ac_pt_CONFIG_LIBXML2
  10971. if test -n "$ac_pt_CONFIG_LIBXML2"; then
  10972. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CONFIG_LIBXML2" >&5
  10973. $as_echo "$ac_pt_CONFIG_LIBXML2" >&6; }
  10974. else
  10975. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  10976. $as_echo "no" >&6; }
  10977. fi
  10978. if test "x$ac_pt_CONFIG_LIBXML2" = x; then
  10979. CONFIG_LIBXML2="No"
  10980. else
  10981. case $cross_compiling:$ac_tool_warned in
  10982. yes:)
  10983. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  10984. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  10985. ac_tool_warned=yes ;;
  10986. esac
  10987. CONFIG_LIBXML2=$ac_pt_CONFIG_LIBXML2
  10988. fi
  10989. else
  10990. CONFIG_LIBXML2="$ac_cv_path_CONFIG_LIBXML2"
  10991. fi
  10992. if test ! "x${CONFIG_LIBXML2}" = xNo; then
  10993. if test x"" = x ; then A=--cflags ; else A="" ; fi
  10994. LIBXML2_INCLUDE=$(${CONFIG_LIBXML2} $A)
  10995. LIBXML2_INCLUDE=$(echo ${LIBXML2_INCLUDE} | $SED -e "s|-I|-I${LIBXML2_DIR}|g")
  10996. if test x"" = x ; then A=--libs ; else A="" ; fi
  10997. LIBXML2_LIB=$(${CONFIG_LIBXML2} $A)
  10998. LIBXML2_LIB=$(echo ${LIBXML2_LIB} | $SED -e "s|-L|-L${LIBXML2_DIR}|g")
  10999. if test x"#include <libxml/tree.h>
  11000. #include <libxml/parser.h>" != x ; then
  11001. saved_cppflags="${CPPFLAGS}"
  11002. CPPFLAGS="${CPPFLAGS} ${LIBXML2_INCLUDE}"
  11003. saved_libs="${LIBS}"
  11004. LIBS=${LIBXML2_LIB}
  11005. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11006. /* end confdefs.h. */
  11007. #include <libxml/tree.h>
  11008. #include <libxml/parser.h>
  11009. int
  11010. main ()
  11011. {
  11012. LIBXML_TEST_VERSION;
  11013. ;
  11014. return 0;
  11015. }
  11016. _ACEOF
  11017. if ac_fn_c_try_link "$LINENO"; then :
  11018. PBX_LIBXML2=1
  11019. $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
  11020. fi
  11021. rm -f core conftest.err conftest.$ac_objext \
  11022. conftest$ac_exeext conftest.$ac_ext
  11023. CPPFLAGS="${saved_cppflags}"
  11024. LIBS="${saved_libs}"
  11025. else
  11026. PBX_LIBXML2=1
  11027. $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
  11028. fi
  11029. fi
  11030. fi
  11031. if test "${PBX_LIBXML2}" != 1; then
  11032. { $as_echo "$as_me:${as_lineno-$LINENO}: *** XML documentation will not be available because the 'libxml2' development package is missing." >&5
  11033. $as_echo "$as_me: *** XML documentation will not be available because the 'libxml2' development package is missing." >&6;}
  11034. { $as_echo "$as_me:${as_lineno-$LINENO}: *** Please run the 'configure' script with the '--disable-xmldoc' parameter option" >&5
  11035. $as_echo "$as_me: *** Please run the 'configure' script with the '--disable-xmldoc' parameter option" >&6;}
  11036. { $as_echo "$as_me:${as_lineno-$LINENO}: *** or install the 'libxml2' development package." >&5
  11037. $as_echo "$as_me: *** or install the 'libxml2' development package." >&6;}
  11038. exit 1
  11039. fi
  11040. if test "x${PBX_LIBXSLT}" != "x1" -a "${USE_LIBXSLT}" != "no"; then
  11041. pbxlibdir=""
  11042. # if --with-LIBXSLT=DIR has been specified, use it.
  11043. if test "x${LIBXSLT_DIR}" != "x"; then
  11044. if test -d ${LIBXSLT_DIR}/lib; then
  11045. pbxlibdir="-L${LIBXSLT_DIR}/lib"
  11046. else
  11047. pbxlibdir="-L${LIBXSLT_DIR}"
  11048. fi
  11049. fi
  11050. pbxfuncname="xsltLoadStylesheetPI"
  11051. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  11052. AST_LIBXSLT_FOUND=yes
  11053. else
  11054. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  11055. CFLAGS="${CFLAGS} ${LIBXML2_INCLUDE}"
  11056. as_ac_Lib=`$as_echo "ac_cv_lib_xslt_${pbxfuncname}" | $as_tr_sh`
  11057. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lxslt" >&5
  11058. $as_echo_n "checking for ${pbxfuncname} in -lxslt... " >&6; }
  11059. if eval \${$as_ac_Lib+:} false; then :
  11060. $as_echo_n "(cached) " >&6
  11061. else
  11062. ac_check_lib_save_LIBS=$LIBS
  11063. LIBS="-lxslt ${pbxlibdir} ${LIBXML2_LIB} $LIBS"
  11064. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11065. /* end confdefs.h. */
  11066. /* Override any GCC internal prototype to avoid an error.
  11067. Use char because int might match the return type of a GCC
  11068. builtin and then its argument prototype would still apply. */
  11069. #ifdef __cplusplus
  11070. extern "C"
  11071. #endif
  11072. char ${pbxfuncname} ();
  11073. int
  11074. main ()
  11075. {
  11076. return ${pbxfuncname} ();
  11077. ;
  11078. return 0;
  11079. }
  11080. _ACEOF
  11081. if ac_fn_c_try_link "$LINENO"; then :
  11082. eval "$as_ac_Lib=yes"
  11083. else
  11084. eval "$as_ac_Lib=no"
  11085. fi
  11086. rm -f core conftest.err conftest.$ac_objext \
  11087. conftest$ac_exeext conftest.$ac_ext
  11088. LIBS=$ac_check_lib_save_LIBS
  11089. fi
  11090. eval ac_res=\$$as_ac_Lib
  11091. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  11092. $as_echo "$ac_res" >&6; }
  11093. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  11094. AST_LIBXSLT_FOUND=yes
  11095. else
  11096. AST_LIBXSLT_FOUND=no
  11097. fi
  11098. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  11099. fi
  11100. # now check for the header.
  11101. if test "${AST_LIBXSLT_FOUND}" = "yes"; then
  11102. LIBXSLT_LIB="${pbxlibdir} -lxslt ${LIBXML2_LIB}"
  11103. # if --with-LIBXSLT=DIR has been specified, use it.
  11104. if test "x${LIBXSLT_DIR}" != "x"; then
  11105. LIBXSLT_INCLUDE="-I${LIBXSLT_DIR}/include"
  11106. fi
  11107. LIBXSLT_INCLUDE="${LIBXSLT_INCLUDE} ${LIBXML2_INCLUDE}"
  11108. if test "xlibxslt/xsltInternals.h" = "x" ; then # no header, assume found
  11109. LIBXSLT_HEADER_FOUND="1"
  11110. else # check for the header
  11111. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  11112. CPPFLAGS="${CPPFLAGS} ${LIBXSLT_INCLUDE}"
  11113. ac_fn_c_check_header_mongrel "$LINENO" "libxslt/xsltInternals.h" "ac_cv_header_libxslt_xsltInternals_h" "$ac_includes_default"
  11114. if test "x$ac_cv_header_libxslt_xsltInternals_h" = xyes; then :
  11115. LIBXSLT_HEADER_FOUND=1
  11116. else
  11117. LIBXSLT_HEADER_FOUND=0
  11118. fi
  11119. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  11120. fi
  11121. if test "x${LIBXSLT_HEADER_FOUND}" = "x0" ; then
  11122. LIBXSLT_LIB=""
  11123. LIBXSLT_INCLUDE=""
  11124. else
  11125. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  11126. LIBXSLT_LIB=""
  11127. fi
  11128. PBX_LIBXSLT=1
  11129. cat >>confdefs.h <<_ACEOF
  11130. #define HAVE_LIBXSLT 1
  11131. _ACEOF
  11132. fi
  11133. fi
  11134. fi
  11135. if test "x${PBX_LIBXSLT_CLEANUP}" != "x1" -a "${USE_LIBXSLT_CLEANUP}" != "no"; then
  11136. pbxlibdir=""
  11137. # if --with-LIBXSLT_CLEANUP=DIR has been specified, use it.
  11138. if test "x${LIBXSLT_CLEANUP_DIR}" != "x"; then
  11139. if test -d ${LIBXSLT_CLEANUP_DIR}/lib; then
  11140. pbxlibdir="-L${LIBXSLT_CLEANUP_DIR}/lib"
  11141. else
  11142. pbxlibdir="-L${LIBXSLT_CLEANUP_DIR}"
  11143. fi
  11144. fi
  11145. pbxfuncname="xsltCleanupGlobals"
  11146. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  11147. AST_LIBXSLT_CLEANUP_FOUND=yes
  11148. else
  11149. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  11150. CFLAGS="${CFLAGS} ${LIBXML2_INCLUDE}"
  11151. as_ac_Lib=`$as_echo "ac_cv_lib_xslt_${pbxfuncname}" | $as_tr_sh`
  11152. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lxslt" >&5
  11153. $as_echo_n "checking for ${pbxfuncname} in -lxslt... " >&6; }
  11154. if eval \${$as_ac_Lib+:} false; then :
  11155. $as_echo_n "(cached) " >&6
  11156. else
  11157. ac_check_lib_save_LIBS=$LIBS
  11158. LIBS="-lxslt ${pbxlibdir} ${LIBXML2_LIB} $LIBS"
  11159. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11160. /* end confdefs.h. */
  11161. /* Override any GCC internal prototype to avoid an error.
  11162. Use char because int might match the return type of a GCC
  11163. builtin and then its argument prototype would still apply. */
  11164. #ifdef __cplusplus
  11165. extern "C"
  11166. #endif
  11167. char ${pbxfuncname} ();
  11168. int
  11169. main ()
  11170. {
  11171. return ${pbxfuncname} ();
  11172. ;
  11173. return 0;
  11174. }
  11175. _ACEOF
  11176. if ac_fn_c_try_link "$LINENO"; then :
  11177. eval "$as_ac_Lib=yes"
  11178. else
  11179. eval "$as_ac_Lib=no"
  11180. fi
  11181. rm -f core conftest.err conftest.$ac_objext \
  11182. conftest$ac_exeext conftest.$ac_ext
  11183. LIBS=$ac_check_lib_save_LIBS
  11184. fi
  11185. eval ac_res=\$$as_ac_Lib
  11186. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  11187. $as_echo "$ac_res" >&6; }
  11188. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  11189. AST_LIBXSLT_CLEANUP_FOUND=yes
  11190. else
  11191. AST_LIBXSLT_CLEANUP_FOUND=no
  11192. fi
  11193. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  11194. fi
  11195. # now check for the header.
  11196. if test "${AST_LIBXSLT_CLEANUP_FOUND}" = "yes"; then
  11197. LIBXSLT_CLEANUP_LIB="${pbxlibdir} -lxslt ${LIBXML2_LIB}"
  11198. # if --with-LIBXSLT_CLEANUP=DIR has been specified, use it.
  11199. if test "x${LIBXSLT_CLEANUP_DIR}" != "x"; then
  11200. LIBXSLT_CLEANUP_INCLUDE="-I${LIBXSLT_CLEANUP_DIR}/include"
  11201. fi
  11202. LIBXSLT_CLEANUP_INCLUDE="${LIBXSLT_CLEANUP_INCLUDE} ${LIBXML2_INCLUDE}"
  11203. if test "xlibxslt/xsltInternals.h" = "x" ; then # no header, assume found
  11204. LIBXSLT_CLEANUP_HEADER_FOUND="1"
  11205. else # check for the header
  11206. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  11207. CPPFLAGS="${CPPFLAGS} ${LIBXSLT_CLEANUP_INCLUDE}"
  11208. ac_fn_c_check_header_mongrel "$LINENO" "libxslt/xsltInternals.h" "ac_cv_header_libxslt_xsltInternals_h" "$ac_includes_default"
  11209. if test "x$ac_cv_header_libxslt_xsltInternals_h" = xyes; then :
  11210. LIBXSLT_CLEANUP_HEADER_FOUND=1
  11211. else
  11212. LIBXSLT_CLEANUP_HEADER_FOUND=0
  11213. fi
  11214. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  11215. fi
  11216. if test "x${LIBXSLT_CLEANUP_HEADER_FOUND}" = "x0" ; then
  11217. LIBXSLT_CLEANUP_LIB=""
  11218. LIBXSLT_CLEANUP_INCLUDE=""
  11219. else
  11220. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  11221. LIBXSLT_CLEANUP_LIB=""
  11222. fi
  11223. PBX_LIBXSLT_CLEANUP=1
  11224. cat >>confdefs.h <<_ACEOF
  11225. #define HAVE_LIBXSLT_CLEANUP 1
  11226. _ACEOF
  11227. fi
  11228. fi
  11229. fi
  11230. fi
  11231. # some embedded systems omit internationalization (locale) support
  11232. for ac_header in xlocale.h
  11233. do :
  11234. ac_fn_c_check_header_mongrel "$LINENO" "xlocale.h" "ac_cv_header_xlocale_h" "$ac_includes_default"
  11235. if test "x$ac_cv_header_xlocale_h" = xyes; then :
  11236. cat >>confdefs.h <<_ACEOF
  11237. #define HAVE_XLOCALE_H 1
  11238. _ACEOF
  11239. fi
  11240. done
  11241. for ac_header in winsock.h winsock2.h
  11242. do :
  11243. as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
  11244. ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
  11245. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  11246. cat >>confdefs.h <<_ACEOF
  11247. #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
  11248. _ACEOF
  11249. fi
  11250. done
  11251. ac_fn_c_check_header_mongrel "$LINENO" "sys/poll.h" "ac_cv_header_sys_poll_h" "$ac_includes_default"
  11252. if test "x$ac_cv_header_sys_poll_h" = xyes; then :
  11253. else
  11254. $as_echo "#define AST_POLL_COMPAT 1" >>confdefs.h
  11255. fi
  11256. # Check whether --enable-largefile was given.
  11257. if test "${enable_largefile+set}" = set; then :
  11258. enableval=$enable_largefile;
  11259. fi
  11260. if test "$enable_largefile" != no; then
  11261. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
  11262. $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
  11263. if ${ac_cv_sys_largefile_CC+:} false; then :
  11264. $as_echo_n "(cached) " >&6
  11265. else
  11266. ac_cv_sys_largefile_CC=no
  11267. if test "$GCC" != yes; then
  11268. ac_save_CC=$CC
  11269. while :; do
  11270. # IRIX 6.2 and later do not support large files by default,
  11271. # so use the C compiler's -n32 option if that helps.
  11272. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11273. /* end confdefs.h. */
  11274. #include <sys/types.h>
  11275. /* Check that off_t can represent 2**63 - 1 correctly.
  11276. We can't simply define LARGE_OFF_T to be 9223372036854775807,
  11277. since some C++ compilers masquerading as C compilers
  11278. incorrectly reject 9223372036854775807. */
  11279. #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
  11280. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  11281. && LARGE_OFF_T % 2147483647 == 1)
  11282. ? 1 : -1];
  11283. int
  11284. main ()
  11285. {
  11286. ;
  11287. return 0;
  11288. }
  11289. _ACEOF
  11290. if ac_fn_c_try_compile "$LINENO"; then :
  11291. break
  11292. fi
  11293. rm -f core conftest.err conftest.$ac_objext
  11294. CC="$CC -n32"
  11295. if ac_fn_c_try_compile "$LINENO"; then :
  11296. ac_cv_sys_largefile_CC=' -n32'; break
  11297. fi
  11298. rm -f core conftest.err conftest.$ac_objext
  11299. break
  11300. done
  11301. CC=$ac_save_CC
  11302. rm -f conftest.$ac_ext
  11303. fi
  11304. fi
  11305. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
  11306. $as_echo "$ac_cv_sys_largefile_CC" >&6; }
  11307. if test "$ac_cv_sys_largefile_CC" != no; then
  11308. CC=$CC$ac_cv_sys_largefile_CC
  11309. fi
  11310. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
  11311. $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
  11312. if ${ac_cv_sys_file_offset_bits+:} false; then :
  11313. $as_echo_n "(cached) " >&6
  11314. else
  11315. while :; do
  11316. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11317. /* end confdefs.h. */
  11318. #include <sys/types.h>
  11319. /* Check that off_t can represent 2**63 - 1 correctly.
  11320. We can't simply define LARGE_OFF_T to be 9223372036854775807,
  11321. since some C++ compilers masquerading as C compilers
  11322. incorrectly reject 9223372036854775807. */
  11323. #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
  11324. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  11325. && LARGE_OFF_T % 2147483647 == 1)
  11326. ? 1 : -1];
  11327. int
  11328. main ()
  11329. {
  11330. ;
  11331. return 0;
  11332. }
  11333. _ACEOF
  11334. if ac_fn_c_try_compile "$LINENO"; then :
  11335. ac_cv_sys_file_offset_bits=no; break
  11336. fi
  11337. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11338. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11339. /* end confdefs.h. */
  11340. #define _FILE_OFFSET_BITS 64
  11341. #include <sys/types.h>
  11342. /* Check that off_t can represent 2**63 - 1 correctly.
  11343. We can't simply define LARGE_OFF_T to be 9223372036854775807,
  11344. since some C++ compilers masquerading as C compilers
  11345. incorrectly reject 9223372036854775807. */
  11346. #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
  11347. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  11348. && LARGE_OFF_T % 2147483647 == 1)
  11349. ? 1 : -1];
  11350. int
  11351. main ()
  11352. {
  11353. ;
  11354. return 0;
  11355. }
  11356. _ACEOF
  11357. if ac_fn_c_try_compile "$LINENO"; then :
  11358. ac_cv_sys_file_offset_bits=64; break
  11359. fi
  11360. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11361. ac_cv_sys_file_offset_bits=unknown
  11362. break
  11363. done
  11364. fi
  11365. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
  11366. $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
  11367. case $ac_cv_sys_file_offset_bits in #(
  11368. no | unknown) ;;
  11369. *)
  11370. cat >>confdefs.h <<_ACEOF
  11371. #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
  11372. _ACEOF
  11373. ;;
  11374. esac
  11375. rm -rf conftest*
  11376. if test $ac_cv_sys_file_offset_bits = unknown; then
  11377. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
  11378. $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
  11379. if ${ac_cv_sys_large_files+:} false; then :
  11380. $as_echo_n "(cached) " >&6
  11381. else
  11382. while :; do
  11383. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11384. /* end confdefs.h. */
  11385. #include <sys/types.h>
  11386. /* Check that off_t can represent 2**63 - 1 correctly.
  11387. We can't simply define LARGE_OFF_T to be 9223372036854775807,
  11388. since some C++ compilers masquerading as C compilers
  11389. incorrectly reject 9223372036854775807. */
  11390. #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
  11391. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  11392. && LARGE_OFF_T % 2147483647 == 1)
  11393. ? 1 : -1];
  11394. int
  11395. main ()
  11396. {
  11397. ;
  11398. return 0;
  11399. }
  11400. _ACEOF
  11401. if ac_fn_c_try_compile "$LINENO"; then :
  11402. ac_cv_sys_large_files=no; break
  11403. fi
  11404. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11405. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11406. /* end confdefs.h. */
  11407. #define _LARGE_FILES 1
  11408. #include <sys/types.h>
  11409. /* Check that off_t can represent 2**63 - 1 correctly.
  11410. We can't simply define LARGE_OFF_T to be 9223372036854775807,
  11411. since some C++ compilers masquerading as C compilers
  11412. incorrectly reject 9223372036854775807. */
  11413. #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
  11414. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  11415. && LARGE_OFF_T % 2147483647 == 1)
  11416. ? 1 : -1];
  11417. int
  11418. main ()
  11419. {
  11420. ;
  11421. return 0;
  11422. }
  11423. _ACEOF
  11424. if ac_fn_c_try_compile "$LINENO"; then :
  11425. ac_cv_sys_large_files=1; break
  11426. fi
  11427. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11428. ac_cv_sys_large_files=unknown
  11429. break
  11430. done
  11431. fi
  11432. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
  11433. $as_echo "$ac_cv_sys_large_files" >&6; }
  11434. case $ac_cv_sys_large_files in #(
  11435. no | unknown) ;;
  11436. *)
  11437. cat >>confdefs.h <<_ACEOF
  11438. #define _LARGE_FILES $ac_cv_sys_large_files
  11439. _ACEOF
  11440. ;;
  11441. esac
  11442. rm -rf conftest*
  11443. fi
  11444. fi
  11445. # Checks for typedefs, structures, and compiler characteristics.
  11446. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
  11447. $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
  11448. if ${ac_cv_header_stdbool_h+:} false; then :
  11449. $as_echo_n "(cached) " >&6
  11450. else
  11451. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11452. /* end confdefs.h. */
  11453. #include <stdbool.h>
  11454. #ifndef bool
  11455. "error: bool is not defined"
  11456. #endif
  11457. #ifndef false
  11458. "error: false is not defined"
  11459. #endif
  11460. #if false
  11461. "error: false is not 0"
  11462. #endif
  11463. #ifndef true
  11464. "error: true is not defined"
  11465. #endif
  11466. #if true != 1
  11467. "error: true is not 1"
  11468. #endif
  11469. #ifndef __bool_true_false_are_defined
  11470. "error: __bool_true_false_are_defined is not defined"
  11471. #endif
  11472. struct s { _Bool s: 1; _Bool t; } s;
  11473. char a[true == 1 ? 1 : -1];
  11474. char b[false == 0 ? 1 : -1];
  11475. char c[__bool_true_false_are_defined == 1 ? 1 : -1];
  11476. char d[(bool) 0.5 == true ? 1 : -1];
  11477. /* See body of main program for 'e'. */
  11478. char f[(_Bool) 0.0 == false ? 1 : -1];
  11479. char g[true];
  11480. char h[sizeof (_Bool)];
  11481. char i[sizeof s.t];
  11482. enum { j = false, k = true, l = false * true, m = true * 256 };
  11483. /* The following fails for
  11484. HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
  11485. _Bool n[m];
  11486. char o[sizeof n == m * sizeof n[0] ? 1 : -1];
  11487. char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
  11488. /* Catch a bug in an HP-UX C compiler. See
  11489. http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
  11490. http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
  11491. */
  11492. _Bool q = true;
  11493. _Bool *pq = &q;
  11494. int
  11495. main ()
  11496. {
  11497. bool e = &s;
  11498. *pq |= q;
  11499. *pq |= ! q;
  11500. /* Refer to every declared value, to avoid compiler optimizations. */
  11501. return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
  11502. + !m + !n + !o + !p + !q + !pq);
  11503. ;
  11504. return 0;
  11505. }
  11506. _ACEOF
  11507. if ac_fn_c_try_compile "$LINENO"; then :
  11508. ac_cv_header_stdbool_h=yes
  11509. else
  11510. ac_cv_header_stdbool_h=no
  11511. fi
  11512. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11513. fi
  11514. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
  11515. $as_echo "$ac_cv_header_stdbool_h" >&6; }
  11516. ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
  11517. if test "x$ac_cv_type__Bool" = xyes; then :
  11518. cat >>confdefs.h <<_ACEOF
  11519. #define HAVE__BOOL 1
  11520. _ACEOF
  11521. fi
  11522. if test $ac_cv_header_stdbool_h = yes; then
  11523. $as_echo "#define HAVE_STDBOOL_H 1" >>confdefs.h
  11524. fi
  11525. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
  11526. $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
  11527. if ${ac_cv_c_const+:} false; then :
  11528. $as_echo_n "(cached) " >&6
  11529. else
  11530. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11531. /* end confdefs.h. */
  11532. int
  11533. main ()
  11534. {
  11535. #ifndef __cplusplus
  11536. /* Ultrix mips cc rejects this sort of thing. */
  11537. typedef int charset[2];
  11538. const charset cs = { 0, 0 };
  11539. /* SunOS 4.1.1 cc rejects this. */
  11540. char const *const *pcpcc;
  11541. char **ppc;
  11542. /* NEC SVR4.0.2 mips cc rejects this. */
  11543. struct point {int x, y;};
  11544. static struct point const zero = {0,0};
  11545. /* AIX XL C 1.02.0.0 rejects this.
  11546. It does not let you subtract one const X* pointer from another in
  11547. an arm of an if-expression whose if-part is not a constant
  11548. expression */
  11549. const char *g = "string";
  11550. pcpcc = &g + (g ? g-g : 0);
  11551. /* HPUX 7.0 cc rejects these. */
  11552. ++pcpcc;
  11553. ppc = (char**) pcpcc;
  11554. pcpcc = (char const *const *) ppc;
  11555. { /* SCO 3.2v4 cc rejects this sort of thing. */
  11556. char tx;
  11557. char *t = &tx;
  11558. char const *s = 0 ? (char *) 0 : (char const *) 0;
  11559. *t++ = 0;
  11560. if (s) return 0;
  11561. }
  11562. { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
  11563. int x[] = {25, 17};
  11564. const int *foo = &x[0];
  11565. ++foo;
  11566. }
  11567. { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
  11568. typedef const int *iptr;
  11569. iptr p = 0;
  11570. ++p;
  11571. }
  11572. { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
  11573. "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
  11574. struct s { int j; const int *ap[3]; } bx;
  11575. struct s *b = &bx; b->j = 5;
  11576. }
  11577. { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
  11578. const int foo = 10;
  11579. if (!foo) return 0;
  11580. }
  11581. return !cs[0] && !zero.x;
  11582. #endif
  11583. ;
  11584. return 0;
  11585. }
  11586. _ACEOF
  11587. if ac_fn_c_try_compile "$LINENO"; then :
  11588. ac_cv_c_const=yes
  11589. else
  11590. ac_cv_c_const=no
  11591. fi
  11592. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11593. fi
  11594. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
  11595. $as_echo "$ac_cv_c_const" >&6; }
  11596. if test $ac_cv_c_const = no; then
  11597. $as_echo "#define const /**/" >>confdefs.h
  11598. fi
  11599. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
  11600. $as_echo_n "checking for uid_t in sys/types.h... " >&6; }
  11601. if ${ac_cv_type_uid_t+:} false; then :
  11602. $as_echo_n "(cached) " >&6
  11603. else
  11604. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11605. /* end confdefs.h. */
  11606. #include <sys/types.h>
  11607. _ACEOF
  11608. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  11609. $EGREP "uid_t" >/dev/null 2>&1; then :
  11610. ac_cv_type_uid_t=yes
  11611. else
  11612. ac_cv_type_uid_t=no
  11613. fi
  11614. rm -f conftest*
  11615. fi
  11616. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
  11617. $as_echo "$ac_cv_type_uid_t" >&6; }
  11618. if test $ac_cv_type_uid_t = no; then
  11619. $as_echo "#define uid_t int" >>confdefs.h
  11620. $as_echo "#define gid_t int" >>confdefs.h
  11621. fi
  11622. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
  11623. $as_echo_n "checking for inline... " >&6; }
  11624. if ${ac_cv_c_inline+:} false; then :
  11625. $as_echo_n "(cached) " >&6
  11626. else
  11627. ac_cv_c_inline=no
  11628. for ac_kw in inline __inline__ __inline; do
  11629. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11630. /* end confdefs.h. */
  11631. #ifndef __cplusplus
  11632. typedef int foo_t;
  11633. static $ac_kw foo_t static_foo () {return 0; }
  11634. $ac_kw foo_t foo () {return 0; }
  11635. #endif
  11636. _ACEOF
  11637. if ac_fn_c_try_compile "$LINENO"; then :
  11638. ac_cv_c_inline=$ac_kw
  11639. fi
  11640. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11641. test "$ac_cv_c_inline" != no && break
  11642. done
  11643. fi
  11644. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
  11645. $as_echo "$ac_cv_c_inline" >&6; }
  11646. case $ac_cv_c_inline in
  11647. inline | yes) ;;
  11648. *)
  11649. case $ac_cv_c_inline in
  11650. no) ac_val=;;
  11651. *) ac_val=$ac_cv_c_inline;;
  11652. esac
  11653. cat >>confdefs.h <<_ACEOF
  11654. #ifndef __cplusplus
  11655. #define inline $ac_val
  11656. #endif
  11657. _ACEOF
  11658. ;;
  11659. esac
  11660. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double with more range or precision than double" >&5
  11661. $as_echo_n "checking for long double with more range or precision than double... " >&6; }
  11662. if ${ac_cv_type_long_double_wider+:} false; then :
  11663. $as_echo_n "(cached) " >&6
  11664. else
  11665. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11666. /* end confdefs.h. */
  11667. #include <float.h>
  11668. long double const a[] =
  11669. {
  11670. 0.0L, DBL_MIN, DBL_MAX, DBL_EPSILON,
  11671. LDBL_MIN, LDBL_MAX, LDBL_EPSILON
  11672. };
  11673. long double
  11674. f (long double x)
  11675. {
  11676. return ((x + (unsigned long int) 10) * (-1 / x) + a[0]
  11677. + (x ? f (x) : 'c'));
  11678. }
  11679. int
  11680. main ()
  11681. {
  11682. static int test_array [1 - 2 * !((0 < ((DBL_MAX_EXP < LDBL_MAX_EXP)
  11683. + (DBL_MANT_DIG < LDBL_MANT_DIG)
  11684. - (LDBL_MAX_EXP < DBL_MAX_EXP)
  11685. - (LDBL_MANT_DIG < DBL_MANT_DIG)))
  11686. && (int) LDBL_EPSILON == 0
  11687. )];
  11688. test_array [0] = 0;
  11689. return test_array [0];
  11690. ;
  11691. return 0;
  11692. }
  11693. _ACEOF
  11694. if ac_fn_c_try_compile "$LINENO"; then :
  11695. ac_cv_type_long_double_wider=yes
  11696. else
  11697. ac_cv_type_long_double_wider=no
  11698. fi
  11699. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11700. fi
  11701. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_double_wider" >&5
  11702. $as_echo "$ac_cv_type_long_double_wider" >&6; }
  11703. if test $ac_cv_type_long_double_wider = yes; then
  11704. $as_echo "#define HAVE_LONG_DOUBLE_WIDER 1" >>confdefs.h
  11705. fi
  11706. ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
  11707. if test "x$ac_cv_type_mode_t" = xyes; then :
  11708. else
  11709. cat >>confdefs.h <<_ACEOF
  11710. #define mode_t int
  11711. _ACEOF
  11712. fi
  11713. ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
  11714. if test "x$ac_cv_type_off_t" = xyes; then :
  11715. else
  11716. cat >>confdefs.h <<_ACEOF
  11717. #define off_t long int
  11718. _ACEOF
  11719. fi
  11720. ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
  11721. if test "x$ac_cv_type_pid_t" = xyes; then :
  11722. else
  11723. cat >>confdefs.h <<_ACEOF
  11724. #define pid_t int
  11725. _ACEOF
  11726. fi
  11727. ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
  11728. if test "x$ac_cv_type_size_t" = xyes; then :
  11729. else
  11730. cat >>confdefs.h <<_ACEOF
  11731. #define size_t unsigned int
  11732. _ACEOF
  11733. fi
  11734. ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
  11735. if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then :
  11736. cat >>confdefs.h <<_ACEOF
  11737. #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
  11738. _ACEOF
  11739. fi
  11740. ac_fn_c_check_member "$LINENO" "struct ucred" "uid" "ac_cv_member_struct_ucred_uid" "#include <sys/types.h>
  11741. #include <sys/socket.h>
  11742. "
  11743. if test "x$ac_cv_member_struct_ucred_uid" = xyes; then :
  11744. cat >>confdefs.h <<_ACEOF
  11745. #define HAVE_STRUCT_UCRED_UID 1
  11746. _ACEOF
  11747. fi
  11748. ac_fn_c_check_member "$LINENO" "struct ucred" "cr_uid" "ac_cv_member_struct_ucred_cr_uid" "#include <sys/types.h>
  11749. #include <sys/socket.h>
  11750. "
  11751. if test "x$ac_cv_member_struct_ucred_cr_uid" = xyes; then :
  11752. cat >>confdefs.h <<_ACEOF
  11753. #define HAVE_STRUCT_UCRED_CR_UID 1
  11754. _ACEOF
  11755. fi
  11756. ac_fn_c_check_member "$LINENO" "struct sockpeercred" "uid" "ac_cv_member_struct_sockpeercred_uid" "#include <sys/types.h>
  11757. #include <sys/socket.h>
  11758. "
  11759. if test "x$ac_cv_member_struct_sockpeercred_uid" = xyes; then :
  11760. cat >>confdefs.h <<_ACEOF
  11761. #define HAVE_STRUCT_SOCKPEERCRED_UID 1
  11762. _ACEOF
  11763. fi
  11764. ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_ifru.ifru_hwaddr" "ac_cv_member_struct_ifreq_ifr_ifru_ifru_hwaddr" "#include <net/if.h>
  11765. "
  11766. if test "x$ac_cv_member_struct_ifreq_ifr_ifru_ifru_hwaddr" = xyes; then :
  11767. cat >>confdefs.h <<_ACEOF
  11768. #define HAVE_STRUCT_IFREQ_IFR_IFRU_IFRU_HWADDR 1
  11769. _ACEOF
  11770. fi
  11771. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
  11772. $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
  11773. if ${ac_cv_header_time+:} false; then :
  11774. $as_echo_n "(cached) " >&6
  11775. else
  11776. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11777. /* end confdefs.h. */
  11778. #include <sys/types.h>
  11779. #include <sys/time.h>
  11780. #include <time.h>
  11781. int
  11782. main ()
  11783. {
  11784. if ((struct tm *) 0)
  11785. return 0;
  11786. ;
  11787. return 0;
  11788. }
  11789. _ACEOF
  11790. if ac_fn_c_try_compile "$LINENO"; then :
  11791. ac_cv_header_time=yes
  11792. else
  11793. ac_cv_header_time=no
  11794. fi
  11795. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11796. fi
  11797. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
  11798. $as_echo "$ac_cv_header_time" >&6; }
  11799. if test $ac_cv_header_time = yes; then
  11800. $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
  11801. fi
  11802. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
  11803. $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
  11804. if ${ac_cv_struct_tm+:} false; then :
  11805. $as_echo_n "(cached) " >&6
  11806. else
  11807. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11808. /* end confdefs.h. */
  11809. #include <sys/types.h>
  11810. #include <time.h>
  11811. int
  11812. main ()
  11813. {
  11814. struct tm tm;
  11815. int *p = &tm.tm_sec;
  11816. return !p;
  11817. ;
  11818. return 0;
  11819. }
  11820. _ACEOF
  11821. if ac_fn_c_try_compile "$LINENO"; then :
  11822. ac_cv_struct_tm=time.h
  11823. else
  11824. ac_cv_struct_tm=sys/time.h
  11825. fi
  11826. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11827. fi
  11828. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
  11829. $as_echo "$ac_cv_struct_tm" >&6; }
  11830. if test $ac_cv_struct_tm = sys/time.h; then
  11831. $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
  11832. fi
  11833. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5
  11834. $as_echo_n "checking for working volatile... " >&6; }
  11835. if ${ac_cv_c_volatile+:} false; then :
  11836. $as_echo_n "(cached) " >&6
  11837. else
  11838. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11839. /* end confdefs.h. */
  11840. int
  11841. main ()
  11842. {
  11843. volatile int x;
  11844. int * volatile y = (int *) 0;
  11845. return !x && !y;
  11846. ;
  11847. return 0;
  11848. }
  11849. _ACEOF
  11850. if ac_fn_c_try_compile "$LINENO"; then :
  11851. ac_cv_c_volatile=yes
  11852. else
  11853. ac_cv_c_volatile=no
  11854. fi
  11855. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11856. fi
  11857. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5
  11858. $as_echo "$ac_cv_c_volatile" >&6; }
  11859. if test $ac_cv_c_volatile = no; then
  11860. $as_echo "#define volatile /**/" >>confdefs.h
  11861. fi
  11862. ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
  11863. if test "x$ac_cv_type_ptrdiff_t" = xyes; then :
  11864. cat >>confdefs.h <<_ACEOF
  11865. #define HAVE_PTRDIFF_T 1
  11866. _ACEOF
  11867. fi
  11868. stat_nsec_found=no
  11869. ac_fn_c_check_member "$LINENO" "struct stat" "st_mtim" "ac_cv_member_struct_stat_st_mtim" "#include <sys/stat.h>
  11870. "
  11871. if test "x$ac_cv_member_struct_stat_st_mtim" = xyes; then :
  11872. cat >>confdefs.h <<_ACEOF
  11873. #define HAVE_STRUCT_STAT_ST_MTIM 1
  11874. _ACEOF
  11875. stat_nsec_found=yes
  11876. fi
  11877. ac_fn_c_check_member "$LINENO" "struct stat" "st_mtimensec" "ac_cv_member_struct_stat_st_mtimensec" "#include <sys/stat.h>
  11878. "
  11879. if test "x$ac_cv_member_struct_stat_st_mtimensec" = xyes; then :
  11880. cat >>confdefs.h <<_ACEOF
  11881. #define HAVE_STRUCT_STAT_ST_MTIMENSEC 1
  11882. _ACEOF
  11883. stat_nsec_found=yes
  11884. fi
  11885. ac_fn_c_check_member "$LINENO" "struct stat" "st_mtimespec" "ac_cv_member_struct_stat_st_mtimespec" "#include <sys/stat.h>
  11886. "
  11887. if test "x$ac_cv_member_struct_stat_st_mtimespec" = xyes; then :
  11888. cat >>confdefs.h <<_ACEOF
  11889. #define HAVE_STRUCT_STAT_ST_MTIMESPEC 1
  11890. _ACEOF
  11891. stat_nsec_found=yes
  11892. fi
  11893. if test "${stat_nsec_found}" != yes; then
  11894. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Cannot determine nanosecond field of struct stat" >&5
  11895. $as_echo "$as_me: WARNING: Cannot determine nanosecond field of struct stat" >&2;}
  11896. fi
  11897. # Checks for library functions.
  11898. for ac_header in unistd.h
  11899. do :
  11900. ac_fn_c_check_header_mongrel "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default"
  11901. if test "x$ac_cv_header_unistd_h" = xyes; then :
  11902. cat >>confdefs.h <<_ACEOF
  11903. #define HAVE_UNISTD_H 1
  11904. _ACEOF
  11905. fi
  11906. done
  11907. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working chown" >&5
  11908. $as_echo_n "checking for working chown... " >&6; }
  11909. if ${ac_cv_func_chown_works+:} false; then :
  11910. $as_echo_n "(cached) " >&6
  11911. else
  11912. if test "$cross_compiling" = yes; then :
  11913. ac_cv_func_chown_works=no
  11914. else
  11915. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11916. /* end confdefs.h. */
  11917. $ac_includes_default
  11918. #include <fcntl.h>
  11919. int
  11920. main ()
  11921. {
  11922. char *f = "conftest.chown";
  11923. struct stat before, after;
  11924. if (creat (f, 0600) < 0)
  11925. return 1;
  11926. if (stat (f, &before) < 0)
  11927. return 1;
  11928. if (chown (f, (uid_t) -1, (gid_t) -1) == -1)
  11929. return 1;
  11930. if (stat (f, &after) < 0)
  11931. return 1;
  11932. return ! (before.st_uid == after.st_uid && before.st_gid == after.st_gid);
  11933. ;
  11934. return 0;
  11935. }
  11936. _ACEOF
  11937. if ac_fn_c_try_run "$LINENO"; then :
  11938. ac_cv_func_chown_works=yes
  11939. else
  11940. ac_cv_func_chown_works=no
  11941. fi
  11942. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  11943. conftest.$ac_objext conftest.beam conftest.$ac_ext
  11944. fi
  11945. rm -f conftest.chown
  11946. fi
  11947. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_chown_works" >&5
  11948. $as_echo "$ac_cv_func_chown_works" >&6; }
  11949. if test $ac_cv_func_chown_works = yes; then
  11950. $as_echo "#define HAVE_CHOWN 1" >>confdefs.h
  11951. fi
  11952. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether closedir returns void" >&5
  11953. $as_echo_n "checking whether closedir returns void... " >&6; }
  11954. if ${ac_cv_func_closedir_void+:} false; then :
  11955. $as_echo_n "(cached) " >&6
  11956. else
  11957. if test "$cross_compiling" = yes; then :
  11958. ac_cv_func_closedir_void=yes
  11959. else
  11960. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11961. /* end confdefs.h. */
  11962. $ac_includes_default
  11963. #include <$ac_header_dirent>
  11964. #ifndef __cplusplus
  11965. int closedir ();
  11966. #endif
  11967. int
  11968. main ()
  11969. {
  11970. return closedir (opendir (".")) != 0;
  11971. ;
  11972. return 0;
  11973. }
  11974. _ACEOF
  11975. if ac_fn_c_try_run "$LINENO"; then :
  11976. ac_cv_func_closedir_void=no
  11977. else
  11978. ac_cv_func_closedir_void=yes
  11979. fi
  11980. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  11981. conftest.$ac_objext conftest.beam conftest.$ac_ext
  11982. fi
  11983. fi
  11984. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_closedir_void" >&5
  11985. $as_echo "$ac_cv_func_closedir_void" >&6; }
  11986. if test $ac_cv_func_closedir_void = yes; then
  11987. $as_echo "#define CLOSEDIR_VOID 1" >>confdefs.h
  11988. fi
  11989. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for error_at_line" >&5
  11990. $as_echo_n "checking for error_at_line... " >&6; }
  11991. if ${ac_cv_lib_error_at_line+:} false; then :
  11992. $as_echo_n "(cached) " >&6
  11993. else
  11994. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11995. /* end confdefs.h. */
  11996. #include <error.h>
  11997. int
  11998. main ()
  11999. {
  12000. error_at_line (0, 0, "", 0, "an error occurred");
  12001. ;
  12002. return 0;
  12003. }
  12004. _ACEOF
  12005. if ac_fn_c_try_link "$LINENO"; then :
  12006. ac_cv_lib_error_at_line=yes
  12007. else
  12008. ac_cv_lib_error_at_line=no
  12009. fi
  12010. rm -f core conftest.err conftest.$ac_objext \
  12011. conftest$ac_exeext conftest.$ac_ext
  12012. fi
  12013. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_error_at_line" >&5
  12014. $as_echo "$ac_cv_lib_error_at_line" >&6; }
  12015. if test $ac_cv_lib_error_at_line = no; then
  12016. case " $LIBOBJS " in
  12017. *" error.$ac_objext "* ) ;;
  12018. *) LIBOBJS="$LIBOBJS error.$ac_objext"
  12019. ;;
  12020. esac
  12021. fi
  12022. for ac_header in vfork.h
  12023. do :
  12024. ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
  12025. if test "x$ac_cv_header_vfork_h" = xyes; then :
  12026. cat >>confdefs.h <<_ACEOF
  12027. #define HAVE_VFORK_H 1
  12028. _ACEOF
  12029. fi
  12030. done
  12031. for ac_func in fork vfork
  12032. do :
  12033. as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
  12034. ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
  12035. if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
  12036. cat >>confdefs.h <<_ACEOF
  12037. #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
  12038. _ACEOF
  12039. fi
  12040. done
  12041. if test "x$ac_cv_func_fork" = xyes; then
  12042. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
  12043. $as_echo_n "checking for working fork... " >&6; }
  12044. if ${ac_cv_func_fork_works+:} false; then :
  12045. $as_echo_n "(cached) " >&6
  12046. else
  12047. if test "$cross_compiling" = yes; then :
  12048. ac_cv_func_fork_works=cross
  12049. else
  12050. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12051. /* end confdefs.h. */
  12052. $ac_includes_default
  12053. int
  12054. main ()
  12055. {
  12056. /* By Ruediger Kuhlmann. */
  12057. return fork () < 0;
  12058. ;
  12059. return 0;
  12060. }
  12061. _ACEOF
  12062. if ac_fn_c_try_run "$LINENO"; then :
  12063. ac_cv_func_fork_works=yes
  12064. else
  12065. ac_cv_func_fork_works=no
  12066. fi
  12067. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12068. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12069. fi
  12070. fi
  12071. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
  12072. $as_echo "$ac_cv_func_fork_works" >&6; }
  12073. else
  12074. ac_cv_func_fork_works=$ac_cv_func_fork
  12075. fi
  12076. if test "x$ac_cv_func_fork_works" = xcross; then
  12077. case $host in
  12078. *-*-amigaos* | *-*-msdosdjgpp* | *-*-uclinux* )
  12079. # Override, as these systems have only a dummy fork() stub
  12080. ac_cv_func_fork_works=no
  12081. ;;
  12082. *)
  12083. ac_cv_func_fork_works=yes
  12084. ;;
  12085. esac
  12086. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
  12087. $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
  12088. fi
  12089. ac_cv_func_vfork_works=$ac_cv_func_vfork
  12090. if test "x$ac_cv_func_vfork" = xyes; then
  12091. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
  12092. $as_echo_n "checking for working vfork... " >&6; }
  12093. if ${ac_cv_func_vfork_works+:} false; then :
  12094. $as_echo_n "(cached) " >&6
  12095. else
  12096. if test "$cross_compiling" = yes; then :
  12097. ac_cv_func_vfork_works=cross
  12098. else
  12099. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12100. /* end confdefs.h. */
  12101. /* Thanks to Paul Eggert for this test. */
  12102. $ac_includes_default
  12103. #include <sys/wait.h>
  12104. #ifdef HAVE_VFORK_H
  12105. # include <vfork.h>
  12106. #endif
  12107. /* On some sparc systems, changes by the child to local and incoming
  12108. argument registers are propagated back to the parent. The compiler
  12109. is told about this with #include <vfork.h>, but some compilers
  12110. (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
  12111. static variable whose address is put into a register that is
  12112. clobbered by the vfork. */
  12113. static void
  12114. #ifdef __cplusplus
  12115. sparc_address_test (int arg)
  12116. # else
  12117. sparc_address_test (arg) int arg;
  12118. #endif
  12119. {
  12120. static pid_t child;
  12121. if (!child) {
  12122. child = vfork ();
  12123. if (child < 0) {
  12124. perror ("vfork");
  12125. _exit(2);
  12126. }
  12127. if (!child) {
  12128. arg = getpid();
  12129. write(-1, "", 0);
  12130. _exit (arg);
  12131. }
  12132. }
  12133. }
  12134. int
  12135. main ()
  12136. {
  12137. pid_t parent = getpid ();
  12138. pid_t child;
  12139. sparc_address_test (0);
  12140. child = vfork ();
  12141. if (child == 0) {
  12142. /* Here is another test for sparc vfork register problems. This
  12143. test uses lots of local variables, at least as many local
  12144. variables as main has allocated so far including compiler
  12145. temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
  12146. 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
  12147. reuse the register of parent for one of the local variables,
  12148. since it will think that parent can't possibly be used any more
  12149. in this routine. Assigning to the local variable will thus
  12150. munge parent in the parent process. */
  12151. pid_t
  12152. p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
  12153. p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
  12154. /* Convince the compiler that p..p7 are live; otherwise, it might
  12155. use the same hardware register for all 8 local variables. */
  12156. if (p != p1 || p != p2 || p != p3 || p != p4
  12157. || p != p5 || p != p6 || p != p7)
  12158. _exit(1);
  12159. /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
  12160. from child file descriptors. If the child closes a descriptor
  12161. before it execs or exits, this munges the parent's descriptor
  12162. as well. Test for this by closing stdout in the child. */
  12163. _exit(close(fileno(stdout)) != 0);
  12164. } else {
  12165. int status;
  12166. struct stat st;
  12167. while (wait(&status) != child)
  12168. ;
  12169. return (
  12170. /* Was there some problem with vforking? */
  12171. child < 0
  12172. /* Did the child fail? (This shouldn't happen.) */
  12173. || status
  12174. /* Did the vfork/compiler bug occur? */
  12175. || parent != getpid()
  12176. /* Did the file descriptor bug occur? */
  12177. || fstat(fileno(stdout), &st) != 0
  12178. );
  12179. }
  12180. }
  12181. _ACEOF
  12182. if ac_fn_c_try_run "$LINENO"; then :
  12183. ac_cv_func_vfork_works=yes
  12184. else
  12185. ac_cv_func_vfork_works=no
  12186. fi
  12187. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12188. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12189. fi
  12190. fi
  12191. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
  12192. $as_echo "$ac_cv_func_vfork_works" >&6; }
  12193. fi;
  12194. if test "x$ac_cv_func_fork_works" = xcross; then
  12195. ac_cv_func_vfork_works=$ac_cv_func_vfork
  12196. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
  12197. $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
  12198. fi
  12199. if test "x$ac_cv_func_vfork_works" = xyes; then
  12200. $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
  12201. else
  12202. $as_echo "#define vfork fork" >>confdefs.h
  12203. fi
  12204. if test "x$ac_cv_func_fork_works" = xyes; then
  12205. $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
  12206. PBX_WORKING_FORK=1
  12207. fi
  12208. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
  12209. $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
  12210. if ${ac_cv_sys_largefile_source+:} false; then :
  12211. $as_echo_n "(cached) " >&6
  12212. else
  12213. while :; do
  12214. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12215. /* end confdefs.h. */
  12216. #include <sys/types.h> /* for off_t */
  12217. #include <stdio.h>
  12218. int
  12219. main ()
  12220. {
  12221. int (*fp) (FILE *, off_t, int) = fseeko;
  12222. return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
  12223. ;
  12224. return 0;
  12225. }
  12226. _ACEOF
  12227. if ac_fn_c_try_link "$LINENO"; then :
  12228. ac_cv_sys_largefile_source=no; break
  12229. fi
  12230. rm -f core conftest.err conftest.$ac_objext \
  12231. conftest$ac_exeext conftest.$ac_ext
  12232. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12233. /* end confdefs.h. */
  12234. #define _LARGEFILE_SOURCE 1
  12235. #include <sys/types.h> /* for off_t */
  12236. #include <stdio.h>
  12237. int
  12238. main ()
  12239. {
  12240. int (*fp) (FILE *, off_t, int) = fseeko;
  12241. return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
  12242. ;
  12243. return 0;
  12244. }
  12245. _ACEOF
  12246. if ac_fn_c_try_link "$LINENO"; then :
  12247. ac_cv_sys_largefile_source=1; break
  12248. fi
  12249. rm -f core conftest.err conftest.$ac_objext \
  12250. conftest$ac_exeext conftest.$ac_ext
  12251. ac_cv_sys_largefile_source=unknown
  12252. break
  12253. done
  12254. fi
  12255. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
  12256. $as_echo "$ac_cv_sys_largefile_source" >&6; }
  12257. case $ac_cv_sys_largefile_source in #(
  12258. no | unknown) ;;
  12259. *)
  12260. cat >>confdefs.h <<_ACEOF
  12261. #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
  12262. _ACEOF
  12263. ;;
  12264. esac
  12265. rm -rf conftest*
  12266. # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
  12267. # in glibc 2.1.3, but that breaks too many other things.
  12268. # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
  12269. if test $ac_cv_sys_largefile_source != unknown; then
  12270. $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
  12271. fi
  12272. if test $ac_cv_c_compiler_gnu = yes; then
  12273. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5
  12274. $as_echo_n "checking whether $CC needs -traditional... " >&6; }
  12275. if ${ac_cv_prog_gcc_traditional+:} false; then :
  12276. $as_echo_n "(cached) " >&6
  12277. else
  12278. ac_pattern="Autoconf.*'x'"
  12279. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12280. /* end confdefs.h. */
  12281. #include <sgtty.h>
  12282. Autoconf TIOCGETP
  12283. _ACEOF
  12284. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  12285. $EGREP "$ac_pattern" >/dev/null 2>&1; then :
  12286. ac_cv_prog_gcc_traditional=yes
  12287. else
  12288. ac_cv_prog_gcc_traditional=no
  12289. fi
  12290. rm -f conftest*
  12291. if test $ac_cv_prog_gcc_traditional = no; then
  12292. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12293. /* end confdefs.h. */
  12294. #include <termio.h>
  12295. Autoconf TCGETA
  12296. _ACEOF
  12297. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  12298. $EGREP "$ac_pattern" >/dev/null 2>&1; then :
  12299. ac_cv_prog_gcc_traditional=yes
  12300. fi
  12301. rm -f conftest*
  12302. fi
  12303. fi
  12304. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gcc_traditional" >&5
  12305. $as_echo "$ac_cv_prog_gcc_traditional" >&6; }
  12306. if test $ac_cv_prog_gcc_traditional = yes; then
  12307. CC="$CC -traditional"
  12308. fi
  12309. fi
  12310. # XXX: these are commented out until we determine whether it matters if our malloc()
  12311. # acts exactly like glibc's or not
  12312. # AC_FUNC_MALLOC
  12313. # AC_FUNC_REALLOC
  12314. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working memcmp" >&5
  12315. $as_echo_n "checking for working memcmp... " >&6; }
  12316. if ${ac_cv_func_memcmp_working+:} false; then :
  12317. $as_echo_n "(cached) " >&6
  12318. else
  12319. if test "$cross_compiling" = yes; then :
  12320. ac_cv_func_memcmp_working=no
  12321. else
  12322. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12323. /* end confdefs.h. */
  12324. $ac_includes_default
  12325. int
  12326. main ()
  12327. {
  12328. /* Some versions of memcmp are not 8-bit clean. */
  12329. char c0 = '\100', c1 = '\200', c2 = '\201';
  12330. if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
  12331. return 1;
  12332. /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
  12333. or more and with at least one buffer not starting on a 4-byte boundary.
  12334. William Lewis provided this test program. */
  12335. {
  12336. char foo[21];
  12337. char bar[21];
  12338. int i;
  12339. for (i = 0; i < 4; i++)
  12340. {
  12341. char *a = foo + i;
  12342. char *b = bar + i;
  12343. strcpy (a, "--------01111111");
  12344. strcpy (b, "--------10000000");
  12345. if (memcmp (a, b, 16) >= 0)
  12346. return 1;
  12347. }
  12348. return 0;
  12349. }
  12350. ;
  12351. return 0;
  12352. }
  12353. _ACEOF
  12354. if ac_fn_c_try_run "$LINENO"; then :
  12355. ac_cv_func_memcmp_working=yes
  12356. else
  12357. ac_cv_func_memcmp_working=no
  12358. fi
  12359. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12360. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12361. fi
  12362. fi
  12363. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_memcmp_working" >&5
  12364. $as_echo "$ac_cv_func_memcmp_working" >&6; }
  12365. test $ac_cv_func_memcmp_working = no && case " $LIBOBJS " in
  12366. *" memcmp.$ac_objext "* ) ;;
  12367. *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
  12368. ;;
  12369. esac
  12370. for ac_header in $ac_header_list
  12371. do :
  12372. as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
  12373. ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
  12374. "
  12375. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  12376. cat >>confdefs.h <<_ACEOF
  12377. #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
  12378. _ACEOF
  12379. fi
  12380. done
  12381. for ac_func in getpagesize
  12382. do :
  12383. ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
  12384. if test "x$ac_cv_func_getpagesize" = xyes; then :
  12385. cat >>confdefs.h <<_ACEOF
  12386. #define HAVE_GETPAGESIZE 1
  12387. _ACEOF
  12388. fi
  12389. done
  12390. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
  12391. $as_echo_n "checking for working mmap... " >&6; }
  12392. if ${ac_cv_func_mmap_fixed_mapped+:} false; then :
  12393. $as_echo_n "(cached) " >&6
  12394. else
  12395. if test "$cross_compiling" = yes; then :
  12396. ac_cv_func_mmap_fixed_mapped=no
  12397. else
  12398. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12399. /* end confdefs.h. */
  12400. $ac_includes_default
  12401. /* malloc might have been renamed as rpl_malloc. */
  12402. #undef malloc
  12403. /* Thanks to Mike Haertel and Jim Avera for this test.
  12404. Here is a matrix of mmap possibilities:
  12405. mmap private not fixed
  12406. mmap private fixed at somewhere currently unmapped
  12407. mmap private fixed at somewhere already mapped
  12408. mmap shared not fixed
  12409. mmap shared fixed at somewhere currently unmapped
  12410. mmap shared fixed at somewhere already mapped
  12411. For private mappings, we should verify that changes cannot be read()
  12412. back from the file, nor mmap's back from the file at a different
  12413. address. (There have been systems where private was not correctly
  12414. implemented like the infamous i386 svr4.0, and systems where the
  12415. VM page cache was not coherent with the file system buffer cache
  12416. like early versions of FreeBSD and possibly contemporary NetBSD.)
  12417. For shared mappings, we should conversely verify that changes get
  12418. propagated back to all the places they're supposed to be.
  12419. Grep wants private fixed already mapped.
  12420. The main things grep needs to know about mmap are:
  12421. * does it exist and is it safe to write into the mmap'd area
  12422. * how to use it (BSD variants) */
  12423. #include <fcntl.h>
  12424. #include <sys/mman.h>
  12425. #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
  12426. char *malloc ();
  12427. #endif
  12428. /* This mess was copied from the GNU getpagesize.h. */
  12429. #ifndef HAVE_GETPAGESIZE
  12430. # ifdef _SC_PAGESIZE
  12431. # define getpagesize() sysconf(_SC_PAGESIZE)
  12432. # else /* no _SC_PAGESIZE */
  12433. # ifdef HAVE_SYS_PARAM_H
  12434. # include <sys/param.h>
  12435. # ifdef EXEC_PAGESIZE
  12436. # define getpagesize() EXEC_PAGESIZE
  12437. # else /* no EXEC_PAGESIZE */
  12438. # ifdef NBPG
  12439. # define getpagesize() NBPG * CLSIZE
  12440. # ifndef CLSIZE
  12441. # define CLSIZE 1
  12442. # endif /* no CLSIZE */
  12443. # else /* no NBPG */
  12444. # ifdef NBPC
  12445. # define getpagesize() NBPC
  12446. # else /* no NBPC */
  12447. # ifdef PAGESIZE
  12448. # define getpagesize() PAGESIZE
  12449. # endif /* PAGESIZE */
  12450. # endif /* no NBPC */
  12451. # endif /* no NBPG */
  12452. # endif /* no EXEC_PAGESIZE */
  12453. # else /* no HAVE_SYS_PARAM_H */
  12454. # define getpagesize() 8192 /* punt totally */
  12455. # endif /* no HAVE_SYS_PARAM_H */
  12456. # endif /* no _SC_PAGESIZE */
  12457. #endif /* no HAVE_GETPAGESIZE */
  12458. int
  12459. main ()
  12460. {
  12461. char *data, *data2, *data3;
  12462. const char *cdata2;
  12463. int i, pagesize;
  12464. int fd, fd2;
  12465. pagesize = getpagesize ();
  12466. /* First, make a file with some known garbage in it. */
  12467. data = (char *) malloc (pagesize);
  12468. if (!data)
  12469. return 1;
  12470. for (i = 0; i < pagesize; ++i)
  12471. *(data + i) = rand ();
  12472. umask (0);
  12473. fd = creat ("conftest.mmap", 0600);
  12474. if (fd < 0)
  12475. return 2;
  12476. if (write (fd, data, pagesize) != pagesize)
  12477. return 3;
  12478. close (fd);
  12479. /* Next, check that the tail of a page is zero-filled. File must have
  12480. non-zero length, otherwise we risk SIGBUS for entire page. */
  12481. fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
  12482. if (fd2 < 0)
  12483. return 4;
  12484. cdata2 = "";
  12485. if (write (fd2, cdata2, 1) != 1)
  12486. return 5;
  12487. data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
  12488. if (data2 == MAP_FAILED)
  12489. return 6;
  12490. for (i = 0; i < pagesize; ++i)
  12491. if (*(data2 + i))
  12492. return 7;
  12493. close (fd2);
  12494. if (munmap (data2, pagesize))
  12495. return 8;
  12496. /* Next, try to mmap the file at a fixed address which already has
  12497. something else allocated at it. If we can, also make sure that
  12498. we see the same garbage. */
  12499. fd = open ("conftest.mmap", O_RDWR);
  12500. if (fd < 0)
  12501. return 9;
  12502. if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
  12503. MAP_PRIVATE | MAP_FIXED, fd, 0L))
  12504. return 10;
  12505. for (i = 0; i < pagesize; ++i)
  12506. if (*(data + i) != *(data2 + i))
  12507. return 11;
  12508. /* Finally, make sure that changes to the mapped area do not
  12509. percolate back to the file as seen by read(). (This is a bug on
  12510. some variants of i386 svr4.0.) */
  12511. for (i = 0; i < pagesize; ++i)
  12512. *(data2 + i) = *(data2 + i) + 1;
  12513. data3 = (char *) malloc (pagesize);
  12514. if (!data3)
  12515. return 12;
  12516. if (read (fd, data3, pagesize) != pagesize)
  12517. return 13;
  12518. for (i = 0; i < pagesize; ++i)
  12519. if (*(data + i) != *(data3 + i))
  12520. return 14;
  12521. close (fd);
  12522. return 0;
  12523. }
  12524. _ACEOF
  12525. if ac_fn_c_try_run "$LINENO"; then :
  12526. ac_cv_func_mmap_fixed_mapped=yes
  12527. else
  12528. ac_cv_func_mmap_fixed_mapped=no
  12529. fi
  12530. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12531. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12532. fi
  12533. fi
  12534. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
  12535. $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
  12536. if test $ac_cv_func_mmap_fixed_mapped = yes; then
  12537. $as_echo "#define HAVE_MMAP 1" >>confdefs.h
  12538. fi
  12539. rm -f conftest.mmap conftest.txt
  12540. for ac_header in sys/select.h sys/socket.h
  12541. do :
  12542. as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
  12543. ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
  12544. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  12545. cat >>confdefs.h <<_ACEOF
  12546. #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
  12547. _ACEOF
  12548. fi
  12549. done
  12550. { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of arguments for select" >&5
  12551. $as_echo_n "checking types of arguments for select... " >&6; }
  12552. if ${ac_cv_func_select_args+:} false; then :
  12553. $as_echo_n "(cached) " >&6
  12554. else
  12555. for ac_arg234 in 'fd_set *' 'int *' 'void *'; do
  12556. for ac_arg1 in 'int' 'size_t' 'unsigned long int' 'unsigned int'; do
  12557. for ac_arg5 in 'struct timeval *' 'const struct timeval *'; do
  12558. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12559. /* end confdefs.h. */
  12560. $ac_includes_default
  12561. #ifdef HAVE_SYS_SELECT_H
  12562. # include <sys/select.h>
  12563. #endif
  12564. #ifdef HAVE_SYS_SOCKET_H
  12565. # include <sys/socket.h>
  12566. #endif
  12567. int
  12568. main ()
  12569. {
  12570. extern int select ($ac_arg1,
  12571. $ac_arg234, $ac_arg234, $ac_arg234,
  12572. $ac_arg5);
  12573. ;
  12574. return 0;
  12575. }
  12576. _ACEOF
  12577. if ac_fn_c_try_compile "$LINENO"; then :
  12578. ac_cv_func_select_args="$ac_arg1,$ac_arg234,$ac_arg5"; break 3
  12579. fi
  12580. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  12581. done
  12582. done
  12583. done
  12584. # Provide a safe default value.
  12585. : "${ac_cv_func_select_args=int,int *,struct timeval *}"
  12586. fi
  12587. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_select_args" >&5
  12588. $as_echo "$ac_cv_func_select_args" >&6; }
  12589. ac_save_IFS=$IFS; IFS=','
  12590. set dummy `echo "$ac_cv_func_select_args" | sed 's/\*/\*/g'`
  12591. IFS=$ac_save_IFS
  12592. shift
  12593. cat >>confdefs.h <<_ACEOF
  12594. #define SELECT_TYPE_ARG1 $1
  12595. _ACEOF
  12596. cat >>confdefs.h <<_ACEOF
  12597. #define SELECT_TYPE_ARG234 ($2)
  12598. _ACEOF
  12599. cat >>confdefs.h <<_ACEOF
  12600. #define SELECT_TYPE_ARG5 ($3)
  12601. _ACEOF
  12602. rm -f conftest*
  12603. if ${ac_cv_func_setvbuf_reversed+:} false; then :
  12604. $as_echo_n "(cached) " >&6
  12605. else
  12606. ac_cv_func_setvbuf_reversed=no
  12607. fi
  12608. { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
  12609. $as_echo_n "checking return type of signal handlers... " >&6; }
  12610. if ${ac_cv_type_signal+:} false; then :
  12611. $as_echo_n "(cached) " >&6
  12612. else
  12613. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12614. /* end confdefs.h. */
  12615. #include <sys/types.h>
  12616. #include <signal.h>
  12617. int
  12618. main ()
  12619. {
  12620. return *(signal (0, 0)) (0) == 1;
  12621. ;
  12622. return 0;
  12623. }
  12624. _ACEOF
  12625. if ac_fn_c_try_compile "$LINENO"; then :
  12626. ac_cv_type_signal=int
  12627. else
  12628. ac_cv_type_signal=void
  12629. fi
  12630. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  12631. fi
  12632. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
  12633. $as_echo "$ac_cv_type_signal" >&6; }
  12634. cat >>confdefs.h <<_ACEOF
  12635. #define RETSIGTYPE $ac_cv_type_signal
  12636. _ACEOF
  12637. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
  12638. $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
  12639. if ${ac_cv_func_lstat_dereferences_slashed_symlink+:} false; then :
  12640. $as_echo_n "(cached) " >&6
  12641. else
  12642. rm -f conftest.sym conftest.file
  12643. echo >conftest.file
  12644. if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
  12645. if test "$cross_compiling" = yes; then :
  12646. ac_cv_func_lstat_dereferences_slashed_symlink=no
  12647. else
  12648. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12649. /* end confdefs.h. */
  12650. $ac_includes_default
  12651. int
  12652. main ()
  12653. {
  12654. struct stat sbuf;
  12655. /* Linux will dereference the symlink and fail, as required by POSIX.
  12656. That is better in the sense that it means we will not
  12657. have to compile and use the lstat wrapper. */
  12658. return lstat ("conftest.sym/", &sbuf) == 0;
  12659. ;
  12660. return 0;
  12661. }
  12662. _ACEOF
  12663. if ac_fn_c_try_run "$LINENO"; then :
  12664. ac_cv_func_lstat_dereferences_slashed_symlink=yes
  12665. else
  12666. ac_cv_func_lstat_dereferences_slashed_symlink=no
  12667. fi
  12668. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12669. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12670. fi
  12671. else
  12672. # If the `ln -s' command failed, then we probably don't even
  12673. # have an lstat function.
  12674. ac_cv_func_lstat_dereferences_slashed_symlink=no
  12675. fi
  12676. rm -f conftest.sym conftest.file
  12677. fi
  12678. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_lstat_dereferences_slashed_symlink" >&5
  12679. $as_echo "$ac_cv_func_lstat_dereferences_slashed_symlink" >&6; }
  12680. test $ac_cv_func_lstat_dereferences_slashed_symlink = yes &&
  12681. cat >>confdefs.h <<_ACEOF
  12682. #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
  12683. _ACEOF
  12684. if test "x$ac_cv_func_lstat_dereferences_slashed_symlink" = xno; then
  12685. case " $LIBOBJS " in
  12686. *" lstat.$ac_objext "* ) ;;
  12687. *) LIBOBJS="$LIBOBJS lstat.$ac_objext"
  12688. ;;
  12689. esac
  12690. fi
  12691. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat accepts an empty string" >&5
  12692. $as_echo_n "checking whether stat accepts an empty string... " >&6; }
  12693. if ${ac_cv_func_stat_empty_string_bug+:} false; then :
  12694. $as_echo_n "(cached) " >&6
  12695. else
  12696. if test "$cross_compiling" = yes; then :
  12697. ac_cv_func_stat_empty_string_bug=yes
  12698. else
  12699. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12700. /* end confdefs.h. */
  12701. $ac_includes_default
  12702. int
  12703. main ()
  12704. {
  12705. struct stat sbuf;
  12706. return stat ("", &sbuf) == 0;
  12707. ;
  12708. return 0;
  12709. }
  12710. _ACEOF
  12711. if ac_fn_c_try_run "$LINENO"; then :
  12712. ac_cv_func_stat_empty_string_bug=no
  12713. else
  12714. ac_cv_func_stat_empty_string_bug=yes
  12715. fi
  12716. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12717. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12718. fi
  12719. fi
  12720. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_stat_empty_string_bug" >&5
  12721. $as_echo "$ac_cv_func_stat_empty_string_bug" >&6; }
  12722. if test $ac_cv_func_stat_empty_string_bug = yes; then
  12723. case " $LIBOBJS " in
  12724. *" stat.$ac_objext "* ) ;;
  12725. *) LIBOBJS="$LIBOBJS stat.$ac_objext"
  12726. ;;
  12727. esac
  12728. cat >>confdefs.h <<_ACEOF
  12729. #define HAVE_STAT_EMPTY_STRING_BUG 1
  12730. _ACEOF
  12731. fi
  12732. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strcoll" >&5
  12733. $as_echo_n "checking for working strcoll... " >&6; }
  12734. if ${ac_cv_func_strcoll_works+:} false; then :
  12735. $as_echo_n "(cached) " >&6
  12736. else
  12737. if test "$cross_compiling" = yes; then :
  12738. ac_cv_func_strcoll_works=no
  12739. else
  12740. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12741. /* end confdefs.h. */
  12742. $ac_includes_default
  12743. int
  12744. main ()
  12745. {
  12746. return (strcoll ("abc", "def") >= 0 ||
  12747. strcoll ("ABC", "DEF") >= 0 ||
  12748. strcoll ("123", "456") >= 0)
  12749. ;
  12750. return 0;
  12751. }
  12752. _ACEOF
  12753. if ac_fn_c_try_run "$LINENO"; then :
  12754. ac_cv_func_strcoll_works=yes
  12755. else
  12756. ac_cv_func_strcoll_works=no
  12757. fi
  12758. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12759. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12760. fi
  12761. fi
  12762. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strcoll_works" >&5
  12763. $as_echo "$ac_cv_func_strcoll_works" >&6; }
  12764. if test $ac_cv_func_strcoll_works = yes; then
  12765. $as_echo "#define HAVE_STRCOLL 1" >>confdefs.h
  12766. fi
  12767. for ac_func in strftime
  12768. do :
  12769. ac_fn_c_check_func "$LINENO" "strftime" "ac_cv_func_strftime"
  12770. if test "x$ac_cv_func_strftime" = xyes; then :
  12771. cat >>confdefs.h <<_ACEOF
  12772. #define HAVE_STRFTIME 1
  12773. _ACEOF
  12774. else
  12775. # strftime is in -lintl on SCO UNIX.
  12776. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for strftime in -lintl" >&5
  12777. $as_echo_n "checking for strftime in -lintl... " >&6; }
  12778. if ${ac_cv_lib_intl_strftime+:} false; then :
  12779. $as_echo_n "(cached) " >&6
  12780. else
  12781. ac_check_lib_save_LIBS=$LIBS
  12782. LIBS="-lintl $LIBS"
  12783. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12784. /* end confdefs.h. */
  12785. /* Override any GCC internal prototype to avoid an error.
  12786. Use char because int might match the return type of a GCC
  12787. builtin and then its argument prototype would still apply. */
  12788. #ifdef __cplusplus
  12789. extern "C"
  12790. #endif
  12791. char strftime ();
  12792. int
  12793. main ()
  12794. {
  12795. return strftime ();
  12796. ;
  12797. return 0;
  12798. }
  12799. _ACEOF
  12800. if ac_fn_c_try_link "$LINENO"; then :
  12801. ac_cv_lib_intl_strftime=yes
  12802. else
  12803. ac_cv_lib_intl_strftime=no
  12804. fi
  12805. rm -f core conftest.err conftest.$ac_objext \
  12806. conftest$ac_exeext conftest.$ac_ext
  12807. LIBS=$ac_check_lib_save_LIBS
  12808. fi
  12809. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_strftime" >&5
  12810. $as_echo "$ac_cv_lib_intl_strftime" >&6; }
  12811. if test "x$ac_cv_lib_intl_strftime" = xyes; then :
  12812. $as_echo "#define HAVE_STRFTIME 1" >>confdefs.h
  12813. LIBS="-lintl $LIBS"
  12814. fi
  12815. fi
  12816. done
  12817. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strnlen" >&5
  12818. $as_echo_n "checking for working strnlen... " >&6; }
  12819. if ${ac_cv_func_strnlen_working+:} false; then :
  12820. $as_echo_n "(cached) " >&6
  12821. else
  12822. if test "$cross_compiling" = yes; then :
  12823. # Guess no on AIX systems, yes otherwise.
  12824. case "$host_os" in
  12825. aix*) ac_cv_func_strnlen_working=no;;
  12826. *) ac_cv_func_strnlen_working=yes;;
  12827. esac
  12828. else
  12829. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12830. /* end confdefs.h. */
  12831. $ac_includes_default
  12832. int
  12833. main ()
  12834. {
  12835. #define S "foobar"
  12836. #define S_LEN (sizeof S - 1)
  12837. /* At least one implementation is buggy: that of AIX 4.3 would
  12838. give strnlen (S, 1) == 3. */
  12839. int i;
  12840. for (i = 0; i < S_LEN + 1; ++i)
  12841. {
  12842. int expected = i <= S_LEN ? i : S_LEN;
  12843. if (strnlen (S, i) != expected)
  12844. return 1;
  12845. }
  12846. return 0;
  12847. ;
  12848. return 0;
  12849. }
  12850. _ACEOF
  12851. if ac_fn_c_try_run "$LINENO"; then :
  12852. ac_cv_func_strnlen_working=yes
  12853. else
  12854. ac_cv_func_strnlen_working=no
  12855. fi
  12856. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12857. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12858. fi
  12859. fi
  12860. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strnlen_working" >&5
  12861. $as_echo "$ac_cv_func_strnlen_working" >&6; }
  12862. test $ac_cv_func_strnlen_working = no && case " $LIBOBJS " in
  12863. *" strnlen.$ac_objext "* ) ;;
  12864. *) LIBOBJS="$LIBOBJS strnlen.$ac_objext"
  12865. ;;
  12866. esac
  12867. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strtod" >&5
  12868. $as_echo_n "checking for working strtod... " >&6; }
  12869. if ${ac_cv_func_strtod+:} false; then :
  12870. $as_echo_n "(cached) " >&6
  12871. else
  12872. if test "$cross_compiling" = yes; then :
  12873. ac_cv_func_strtod=no
  12874. else
  12875. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12876. /* end confdefs.h. */
  12877. $ac_includes_default
  12878. #ifndef strtod
  12879. double strtod ();
  12880. #endif
  12881. int
  12882. main()
  12883. {
  12884. {
  12885. /* Some versions of Linux strtod mis-parse strings with leading '+'. */
  12886. char *string = " +69";
  12887. char *term;
  12888. double value;
  12889. value = strtod (string, &term);
  12890. if (value != 69 || term != (string + 4))
  12891. return 1;
  12892. }
  12893. {
  12894. /* Under Solaris 2.4, strtod returns the wrong value for the
  12895. terminating character under some conditions. */
  12896. char *string = "NaN";
  12897. char *term;
  12898. strtod (string, &term);
  12899. if (term != string && *(term - 1) == 0)
  12900. return 1;
  12901. }
  12902. return 0;
  12903. }
  12904. _ACEOF
  12905. if ac_fn_c_try_run "$LINENO"; then :
  12906. ac_cv_func_strtod=yes
  12907. else
  12908. ac_cv_func_strtod=no
  12909. fi
  12910. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12911. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12912. fi
  12913. fi
  12914. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strtod" >&5
  12915. $as_echo "$ac_cv_func_strtod" >&6; }
  12916. if test $ac_cv_func_strtod = no; then
  12917. case " $LIBOBJS " in
  12918. *" strtod.$ac_objext "* ) ;;
  12919. *) LIBOBJS="$LIBOBJS strtod.$ac_objext"
  12920. ;;
  12921. esac
  12922. ac_fn_c_check_func "$LINENO" "pow" "ac_cv_func_pow"
  12923. if test "x$ac_cv_func_pow" = xyes; then :
  12924. fi
  12925. if test $ac_cv_func_pow = no; then
  12926. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pow in -lm" >&5
  12927. $as_echo_n "checking for pow in -lm... " >&6; }
  12928. if ${ac_cv_lib_m_pow+:} false; then :
  12929. $as_echo_n "(cached) " >&6
  12930. else
  12931. ac_check_lib_save_LIBS=$LIBS
  12932. LIBS="-lm $LIBS"
  12933. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12934. /* end confdefs.h. */
  12935. /* Override any GCC internal prototype to avoid an error.
  12936. Use char because int might match the return type of a GCC
  12937. builtin and then its argument prototype would still apply. */
  12938. #ifdef __cplusplus
  12939. extern "C"
  12940. #endif
  12941. char pow ();
  12942. int
  12943. main ()
  12944. {
  12945. return pow ();
  12946. ;
  12947. return 0;
  12948. }
  12949. _ACEOF
  12950. if ac_fn_c_try_link "$LINENO"; then :
  12951. ac_cv_lib_m_pow=yes
  12952. else
  12953. ac_cv_lib_m_pow=no
  12954. fi
  12955. rm -f core conftest.err conftest.$ac_objext \
  12956. conftest$ac_exeext conftest.$ac_ext
  12957. LIBS=$ac_check_lib_save_LIBS
  12958. fi
  12959. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_pow" >&5
  12960. $as_echo "$ac_cv_lib_m_pow" >&6; }
  12961. if test "x$ac_cv_lib_m_pow" = xyes; then :
  12962. POW_LIB=-lm
  12963. else
  12964. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot find library containing definition of pow" >&5
  12965. $as_echo "$as_me: WARNING: cannot find library containing definition of pow" >&2;}
  12966. fi
  12967. fi
  12968. fi
  12969. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether utime accepts a null argument" >&5
  12970. $as_echo_n "checking whether utime accepts a null argument... " >&6; }
  12971. if ${ac_cv_func_utime_null+:} false; then :
  12972. $as_echo_n "(cached) " >&6
  12973. else
  12974. rm -f conftest.data; >conftest.data
  12975. # Sequent interprets utime(file, 0) to mean use start of epoch. Wrong.
  12976. if test "$cross_compiling" = yes; then :
  12977. ac_cv_func_utime_null='guessing yes'
  12978. else
  12979. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12980. /* end confdefs.h. */
  12981. $ac_includes_default
  12982. #ifdef HAVE_UTIME_H
  12983. # include <utime.h>
  12984. #endif
  12985. int
  12986. main ()
  12987. {
  12988. struct stat s, t;
  12989. return ! (stat ("conftest.data", &s) == 0
  12990. && utime ("conftest.data", 0) == 0
  12991. && stat ("conftest.data", &t) == 0
  12992. && t.st_mtime >= s.st_mtime
  12993. && t.st_mtime - s.st_mtime < 120);
  12994. ;
  12995. return 0;
  12996. }
  12997. _ACEOF
  12998. if ac_fn_c_try_run "$LINENO"; then :
  12999. ac_cv_func_utime_null=yes
  13000. else
  13001. ac_cv_func_utime_null=no
  13002. fi
  13003. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  13004. conftest.$ac_objext conftest.beam conftest.$ac_ext
  13005. fi
  13006. fi
  13007. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_utime_null" >&5
  13008. $as_echo "$ac_cv_func_utime_null" >&6; }
  13009. if test "x$ac_cv_func_utime_null" != xno; then
  13010. ac_cv_func_utime_null=yes
  13011. $as_echo "#define HAVE_UTIME_NULL 1" >>confdefs.h
  13012. fi
  13013. rm -f conftest.data
  13014. for ac_func in vprintf
  13015. do :
  13016. ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf"
  13017. if test "x$ac_cv_func_vprintf" = xyes; then :
  13018. cat >>confdefs.h <<_ACEOF
  13019. #define HAVE_VPRINTF 1
  13020. _ACEOF
  13021. ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt"
  13022. if test "x$ac_cv_func__doprnt" = xyes; then :
  13023. $as_echo "#define HAVE_DOPRNT 1" >>confdefs.h
  13024. fi
  13025. fi
  13026. done
  13027. for ac_func in asprintf atexit closefrom dup2 eaccess endpwent euidaccess ffsll ftruncate getcwd gethostbyname gethostname getloadavg gettimeofday glob htonll ioperm inet_ntoa isascii memchr memmove memset mkdir mkdtemp munmap ntohll newlocale ppoll putenv re_comp regcomp select setenv socket strcasecmp strcasestr strchr strcspn strdup strerror strlcat strlcpy strncasecmp strndup strnlen strrchr strsep strspn strstr strtod strtol strtold strtoq unsetenv utime vasprintf getpeereid sysctl swapctl
  13028. do :
  13029. as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
  13030. ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
  13031. if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
  13032. cat >>confdefs.h <<_ACEOF
  13033. #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
  13034. _ACEOF
  13035. fi
  13036. done
  13037. # NOTE: we use AC_CHECK_LIB to get -lm into the arguments for later checks,
  13038. # so that AC_CHECK_FUNCS can detect functions in that library.
  13039. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
  13040. $as_echo_n "checking for sqrt in -lm... " >&6; }
  13041. if ${ac_cv_lib_m_sqrt+:} false; then :
  13042. $as_echo_n "(cached) " >&6
  13043. else
  13044. ac_check_lib_save_LIBS=$LIBS
  13045. LIBS="-lm $LIBS"
  13046. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13047. /* end confdefs.h. */
  13048. /* Override any GCC internal prototype to avoid an error.
  13049. Use char because int might match the return type of a GCC
  13050. builtin and then its argument prototype would still apply. */
  13051. #ifdef __cplusplus
  13052. extern "C"
  13053. #endif
  13054. char sqrt ();
  13055. int
  13056. main ()
  13057. {
  13058. return sqrt ();
  13059. ;
  13060. return 0;
  13061. }
  13062. _ACEOF
  13063. if ac_fn_c_try_link "$LINENO"; then :
  13064. ac_cv_lib_m_sqrt=yes
  13065. else
  13066. ac_cv_lib_m_sqrt=no
  13067. fi
  13068. rm -f core conftest.err conftest.$ac_objext \
  13069. conftest$ac_exeext conftest.$ac_ext
  13070. LIBS=$ac_check_lib_save_LIBS
  13071. fi
  13072. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
  13073. $as_echo "$ac_cv_lib_m_sqrt" >&6; }
  13074. if test "x$ac_cv_lib_m_sqrt" = xyes; then :
  13075. cat >>confdefs.h <<_ACEOF
  13076. #define HAVE_LIBM 1
  13077. _ACEOF
  13078. LIBS="-lm $LIBS"
  13079. fi
  13080. # BSD might not have exp2, and/or log2
  13081. for ac_func in exp2 log2 exp10 log10 sin cos tan asin acos atan atan2 pow rint exp log remainder fmod round roundf trunc floor ceil
  13082. do :
  13083. as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
  13084. ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
  13085. if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
  13086. cat >>confdefs.h <<_ACEOF
  13087. #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
  13088. _ACEOF
  13089. fi
  13090. done
  13091. # Certain architectures don't really have long double, even though
  13092. # AC_CHECK_FUNCS would otherwise find the following functions.
  13093. if test "x${ac_cv_type_long_double_wider}" = "xyes" ; then
  13094. for ac_func in exp2l log2l exp10l log10l sinl cosl tanl asinl acosl atanl atan2l powl sqrtl rintl expl logl remainderl fmodl roundl truncl floorl ceill
  13095. do :
  13096. as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
  13097. ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
  13098. if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
  13099. cat >>confdefs.h <<_ACEOF
  13100. #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
  13101. _ACEOF
  13102. fi
  13103. done
  13104. fi
  13105. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LLONG_MAX in limits.h" >&5
  13106. $as_echo_n "checking for LLONG_MAX in limits.h... " >&6; }
  13107. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13108. /* end confdefs.h. */
  13109. #include <limits.h>
  13110. int
  13111. main ()
  13112. {
  13113. long long foo = LLONG_MAX
  13114. ;
  13115. return 0;
  13116. }
  13117. _ACEOF
  13118. if ac_fn_c_try_link "$LINENO"; then :
  13119. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13120. $as_echo "yes" >&6; }
  13121. $as_echo "#define HAVE_LLONG_MAX 1" >>confdefs.h
  13122. else
  13123. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13124. $as_echo "no" >&6; }
  13125. fi
  13126. rm -f core conftest.err conftest.$ac_objext \
  13127. conftest$ac_exeext conftest.$ac_ext
  13128. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for timersub in time.h" >&5
  13129. $as_echo_n "checking for timersub in time.h... " >&6; }
  13130. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13131. /* end confdefs.h. */
  13132. #include <sys/time.h>
  13133. int
  13134. main ()
  13135. {
  13136. struct timeval *a; timersub(a, a, a);
  13137. ;
  13138. return 0;
  13139. }
  13140. _ACEOF
  13141. if ac_fn_c_try_link "$LINENO"; then :
  13142. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13143. $as_echo "yes" >&6; }
  13144. $as_echo "#define HAVE_TIMERSUB 1" >>confdefs.h
  13145. else
  13146. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13147. $as_echo "no" >&6; }
  13148. fi
  13149. rm -f core conftest.err conftest.$ac_objext \
  13150. conftest$ac_exeext conftest.$ac_ext
  13151. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of GNU ld that supports the --dynamic-list flag" >&5
  13152. $as_echo_n "checking for a version of GNU ld that supports the --dynamic-list flag... " >&6; }
  13153. old_LDFLAGS=${LDFLAGS}
  13154. cat >conftest.dynamics <<_ACEOF
  13155. {
  13156. *ast_*;
  13157. };
  13158. _ACEOF
  13159. LDFLAGS="${LDFLAGS} -Wl,--dynamic-list,conftest.dynamics"
  13160. PBX_DYNAMIC_LIST=0
  13161. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13162. /* end confdefs.h. */
  13163. int
  13164. main ()
  13165. {
  13166. ;
  13167. return 0;
  13168. }
  13169. _ACEOF
  13170. if ac_fn_c_try_link "$LINENO"; then :
  13171. PBX_DYNAMIC_LIST=1
  13172. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13173. $as_echo "yes" >&6; }
  13174. else
  13175. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13176. $as_echo "no" >&6; }
  13177. fi
  13178. rm -f core conftest.err conftest.$ac_objext \
  13179. conftest$ac_exeext conftest.$ac_ext
  13180. LDFLAGS=${old_LDFLAGS}
  13181. rm -f conftest.dynamics
  13182. ac_fn_c_check_header_mongrel "$LINENO" "sys/poll.h" "ac_cv_header_sys_poll_h" "$ac_includes_default"
  13183. if test "x$ac_cv_header_sys_poll_h" = xyes; then :
  13184. HAS_POLL=1
  13185. $as_echo "#define HAVE_SYS_POLL_H 1" >>confdefs.h
  13186. fi
  13187. # Check whether --enable-internal-poll was given.
  13188. if test "${enable_internal_poll+set}" = set; then :
  13189. enableval=$enable_internal_poll; case "${enableval}" in
  13190. y|ye|yes) HAS_POLL="";;
  13191. n|no) HAS_POLL="${HAS_POLL}" ;;
  13192. *) as_fn_error $? "bad value ${enableval} for --enable-internal-poll" "$LINENO" 5 ;;
  13193. esac
  13194. fi
  13195. # Check whether --enable-asteriskssl was given.
  13196. if test "${enable_asteriskssl+set}" = set; then :
  13197. enableval=$enable_asteriskssl; case "${enableval}" in
  13198. y|ye|yes) AST_ASTERISKSSL=yes ;;
  13199. n|no) AST_ASTERISKSSL=no ;;
  13200. *) as_fn_error $? "bad value ${enableval} for --disable-asteriskssl" "$LINENO" 5 ;;
  13201. esac
  13202. else
  13203. AST_ASTERISKSSL=yes
  13204. fi
  13205. # https support (in main/http.c) uses funopen on BSD systems,
  13206. # fopencookie on linux
  13207. for ac_func in funopen fopencookie
  13208. do :
  13209. as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
  13210. ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
  13211. if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
  13212. cat >>confdefs.h <<_ACEOF
  13213. #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
  13214. _ACEOF
  13215. fi
  13216. done
  13217. for ac_func in inet_aton
  13218. do :
  13219. ac_fn_c_check_func "$LINENO" "inet_aton" "ac_cv_func_inet_aton"
  13220. if test "x$ac_cv_func_inet_aton" = xyes; then :
  13221. cat >>confdefs.h <<_ACEOF
  13222. #define HAVE_INET_ATON 1
  13223. _ACEOF
  13224. fi
  13225. done
  13226. # check if we have IP_PKTINFO constant defined
  13227. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IP_PKTINFO" >&5
  13228. $as_echo_n "checking for IP_PKTINFO... " >&6; }
  13229. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13230. /* end confdefs.h. */
  13231. #include <netinet/in.h>
  13232. int
  13233. main ()
  13234. {
  13235. int pi = IP_PKTINFO;
  13236. ;
  13237. return 0;
  13238. }
  13239. _ACEOF
  13240. if ac_fn_c_try_link "$LINENO"; then :
  13241. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13242. $as_echo "yes" >&6; }
  13243. $as_echo "#define HAVE_PKTINFO 1" >>confdefs.h
  13244. else
  13245. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13246. $as_echo "no" >&6; }
  13247. fi
  13248. rm -f core conftest.err conftest.$ac_objext \
  13249. conftest$ac_exeext conftest.$ac_ext
  13250. # some systems already have gethostbyname_r so we don't need to build ours in main/utils.c
  13251. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname_r" >&5
  13252. $as_echo_n "checking for library containing gethostbyname_r... " >&6; }
  13253. if ${ac_cv_search_gethostbyname_r+:} false; then :
  13254. $as_echo_n "(cached) " >&6
  13255. else
  13256. ac_func_search_save_LIBS=$LIBS
  13257. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13258. /* end confdefs.h. */
  13259. /* Override any GCC internal prototype to avoid an error.
  13260. Use char because int might match the return type of a GCC
  13261. builtin and then its argument prototype would still apply. */
  13262. #ifdef __cplusplus
  13263. extern "C"
  13264. #endif
  13265. char gethostbyname_r ();
  13266. int
  13267. main ()
  13268. {
  13269. return gethostbyname_r ();
  13270. ;
  13271. return 0;
  13272. }
  13273. _ACEOF
  13274. for ac_lib in '' socket nsl; do
  13275. if test -z "$ac_lib"; then
  13276. ac_res="none required"
  13277. else
  13278. ac_res=-l$ac_lib
  13279. LIBS="-l$ac_lib $ac_func_search_save_LIBS"
  13280. fi
  13281. if ac_fn_c_try_link "$LINENO"; then :
  13282. ac_cv_search_gethostbyname_r=$ac_res
  13283. fi
  13284. rm -f core conftest.err conftest.$ac_objext \
  13285. conftest$ac_exeext
  13286. if ${ac_cv_search_gethostbyname_r+:} false; then :
  13287. break
  13288. fi
  13289. done
  13290. if ${ac_cv_search_gethostbyname_r+:} false; then :
  13291. else
  13292. ac_cv_search_gethostbyname_r=no
  13293. fi
  13294. rm conftest.$ac_ext
  13295. LIBS=$ac_func_search_save_LIBS
  13296. fi
  13297. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname_r" >&5
  13298. $as_echo "$ac_cv_search_gethostbyname_r" >&6; }
  13299. ac_res=$ac_cv_search_gethostbyname_r
  13300. if test "$ac_res" != no; then :
  13301. test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
  13302. fi
  13303. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname_r with 6 arguments" >&5
  13304. $as_echo_n "checking for gethostbyname_r with 6 arguments... " >&6; }
  13305. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13306. /* end confdefs.h. */
  13307. #include <stdlib.h>
  13308. #include <netdb.h>
  13309. int
  13310. main ()
  13311. {
  13312. struct hostent *he = gethostbyname_r((const char *)NULL, (struct hostent *)NULL, (char *)NULL, (int)0, (struct hostent **)NULL, (int *)NULL);
  13313. ;
  13314. return 0;
  13315. }
  13316. _ACEOF
  13317. if ac_fn_c_try_link "$LINENO"; then :
  13318. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13319. $as_echo "yes" >&6; }
  13320. $as_echo "#define HAVE_GETHOSTBYNAME_R_6 1" >>confdefs.h
  13321. else
  13322. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13323. $as_echo "no" >&6; }
  13324. fi
  13325. rm -f core conftest.err conftest.$ac_objext \
  13326. conftest$ac_exeext conftest.$ac_ext
  13327. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname_r with 5 arguments" >&5
  13328. $as_echo_n "checking for gethostbyname_r with 5 arguments... " >&6; }
  13329. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13330. /* end confdefs.h. */
  13331. #include <stdlib.h>
  13332. #include <netdb.h>
  13333. int
  13334. main ()
  13335. {
  13336. struct hostent *he = gethostbyname_r((const char *)NULL, (struct hostent *)NULL, (char *)NULL, (int)0, (int *)NULL);
  13337. ;
  13338. return 0;
  13339. }
  13340. _ACEOF
  13341. if ac_fn_c_try_link "$LINENO"; then :
  13342. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13343. $as_echo "yes" >&6; }
  13344. $as_echo "#define HAVE_GETHOSTBYNAME_R_5 1" >>confdefs.h
  13345. else
  13346. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13347. $as_echo "no" >&6; }
  13348. fi
  13349. rm -f core conftest.err conftest.$ac_objext \
  13350. conftest$ac_exeext conftest.$ac_ext
  13351. ac_fn_c_check_header_mongrel "$LINENO" "byteswap.h" "ac_cv_header_byteswap_h" "$ac_includes_default"
  13352. if test "x$ac_cv_header_byteswap_h" = xyes; then :
  13353. cat >>confdefs.h <<_ACEOF
  13354. #define HAVE_BYTESWAP_H 1
  13355. _ACEOF
  13356. fi
  13357. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __swap16 variant of <sys/endian.h> byteswapping macros" >&5
  13358. $as_echo_n "checking for __swap16 variant of <sys/endian.h> byteswapping macros... " >&6; }
  13359. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13360. /* end confdefs.h. */
  13361. #include <sys/endian.h>
  13362. int
  13363. main ()
  13364. {
  13365. int a = 1; int b = __swap16(a);
  13366. ;
  13367. return 0;
  13368. }
  13369. _ACEOF
  13370. if ac_fn_c_try_link "$LINENO"; then :
  13371. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13372. $as_echo "yes" >&6; }
  13373. $as_echo "#define HAVE_SYS_ENDIAN_SWAP16 1" >>confdefs.h
  13374. else
  13375. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13376. $as_echo "no" >&6; }
  13377. fi
  13378. rm -f core conftest.err conftest.$ac_objext \
  13379. conftest$ac_exeext conftest.$ac_ext
  13380. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bswap16 variant of <sys/endian.h> byteswapping macros" >&5
  13381. $as_echo_n "checking for bswap16 variant of <sys/endian.h> byteswapping macros... " >&6; }
  13382. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13383. /* end confdefs.h. */
  13384. #include <sys/endian.h>
  13385. int
  13386. main ()
  13387. {
  13388. int a = 1; int b = bswap16(a);
  13389. ;
  13390. return 0;
  13391. }
  13392. _ACEOF
  13393. if ac_fn_c_try_link "$LINENO"; then :
  13394. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13395. $as_echo "yes" >&6; }
  13396. $as_echo "#define HAVE_SYS_ENDIAN_BSWAP16 1" >>confdefs.h
  13397. else
  13398. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13399. $as_echo "no" >&6; }
  13400. fi
  13401. rm -f core conftest.err conftest.$ac_objext \
  13402. conftest$ac_exeext conftest.$ac_ext
  13403. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for locale_t in locale.h" >&5
  13404. $as_echo_n "checking for locale_t in locale.h... " >&6; }
  13405. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13406. /* end confdefs.h. */
  13407. #include <locale.h>
  13408. int
  13409. main ()
  13410. {
  13411. locale_t lt = NULL
  13412. ;
  13413. return 0;
  13414. }
  13415. _ACEOF
  13416. if ac_fn_c_try_link "$LINENO"; then :
  13417. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13418. $as_echo "yes" >&6; }
  13419. $as_echo "#define HAVE_LOCALE_T_IN_LOCALE_H 1" >>confdefs.h
  13420. else
  13421. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13422. $as_echo "no" >&6; }
  13423. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for locale_t in xlocale.h" >&5
  13424. $as_echo_n "checking for locale_t in xlocale.h... " >&6; }
  13425. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13426. /* end confdefs.h. */
  13427. #include <xlocale.h>
  13428. int
  13429. main ()
  13430. {
  13431. locale_t lt = NULL
  13432. ;
  13433. return 0;
  13434. }
  13435. _ACEOF
  13436. if ac_fn_c_try_link "$LINENO"; then :
  13437. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13438. $as_echo "yes" >&6; }
  13439. $as_echo "#define HAVE_LOCALE_T_IN_XLOCALE_H 1" >>confdefs.h
  13440. else
  13441. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13442. $as_echo "no" >&6; }
  13443. fi
  13444. rm -f core conftest.err conftest.$ac_objext \
  13445. conftest$ac_exeext conftest.$ac_ext
  13446. fi
  13447. rm -f core conftest.err conftest.$ac_objext \
  13448. conftest$ac_exeext conftest.$ac_ext
  13449. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for O_EVTONLY in fcntl.h" >&5
  13450. $as_echo_n "checking for O_EVTONLY in fcntl.h... " >&6; }
  13451. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13452. /* end confdefs.h. */
  13453. #include <fcntl.h>
  13454. int
  13455. main ()
  13456. {
  13457. int a = O_EVTONLY;
  13458. ;
  13459. return 0;
  13460. }
  13461. _ACEOF
  13462. if ac_fn_c_try_link "$LINENO"; then :
  13463. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13464. $as_echo "yes" >&6; }
  13465. $as_echo "#define HAVE_O_EVTONLY 1" >>confdefs.h
  13466. else
  13467. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13468. $as_echo "no" >&6; }
  13469. fi
  13470. rm -f core conftest.err conftest.$ac_objext \
  13471. conftest$ac_exeext conftest.$ac_ext
  13472. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for O_SYMLINK in fcntl.h" >&5
  13473. $as_echo_n "checking for O_SYMLINK in fcntl.h... " >&6; }
  13474. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13475. /* end confdefs.h. */
  13476. #include <fcntl.h>
  13477. int
  13478. main ()
  13479. {
  13480. int a = O_SYMLINK;
  13481. ;
  13482. return 0;
  13483. }
  13484. _ACEOF
  13485. if ac_fn_c_try_link "$LINENO"; then :
  13486. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13487. $as_echo "yes" >&6; }
  13488. $as_echo "#define HAVE_O_SYMLINK 1" >>confdefs.h
  13489. else
  13490. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13491. $as_echo "no" >&6; }
  13492. fi
  13493. rm -f core conftest.err conftest.$ac_objext \
  13494. conftest$ac_exeext conftest.$ac_ext
  13495. if test "x${PBX_PTHREAD_RWLOCK_INITIALIZER}" != "x1"; then
  13496. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_RWLOCK_INITIALIZER in pthread.h" >&5
  13497. $as_echo_n "checking for PTHREAD_RWLOCK_INITIALIZER in pthread.h... " >&6; }
  13498. saved_cppflags="${CPPFLAGS}"
  13499. if test "x${PTHREAD_RWLOCK_INITIALIZER_DIR}" != "x"; then
  13500. PTHREAD_RWLOCK_INITIALIZER_INCLUDE="-I${PTHREAD_RWLOCK_INITIALIZER_DIR}/include"
  13501. fi
  13502. CPPFLAGS="${CPPFLAGS} ${PTHREAD_RWLOCK_INITIALIZER_INCLUDE}"
  13503. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13504. /* end confdefs.h. */
  13505. #include <pthread.h>
  13506. int
  13507. main ()
  13508. {
  13509. #if defined(PTHREAD_RWLOCK_INITIALIZER)
  13510. int foo = 0;
  13511. #else
  13512. int foo = bar;
  13513. #endif
  13514. 0
  13515. ;
  13516. return 0;
  13517. }
  13518. _ACEOF
  13519. if ac_fn_c_try_compile "$LINENO"; then :
  13520. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13521. $as_echo "yes" >&6; }
  13522. PBX_PTHREAD_RWLOCK_INITIALIZER=1
  13523. $as_echo "#define HAVE_PTHREAD_RWLOCK_INITIALIZER 1" >>confdefs.h
  13524. else
  13525. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13526. $as_echo "no" >&6; }
  13527. fi
  13528. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  13529. CPPFLAGS="${saved_cppflags}"
  13530. fi
  13531. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_RWLOCK_PREFER_WRITER_NP in pthread.h" >&5
  13532. $as_echo_n "checking for PTHREAD_RWLOCK_PREFER_WRITER_NP in pthread.h... " >&6; }
  13533. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13534. /* end confdefs.h. */
  13535. #include <pthread.h>
  13536. int
  13537. main ()
  13538. {
  13539. int a = PTHREAD_RWLOCK_PREFER_WRITER_NP;
  13540. ;
  13541. return 0;
  13542. }
  13543. _ACEOF
  13544. if ac_fn_c_try_link "$LINENO"; then :
  13545. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13546. $as_echo "yes" >&6; }
  13547. $as_echo "#define HAVE_PTHREAD_RWLOCK_PREFER_WRITER_NP 1" >>confdefs.h
  13548. else
  13549. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13550. $as_echo "no" >&6; }
  13551. fi
  13552. rm -f core conftest.err conftest.$ac_objext \
  13553. conftest$ac_exeext conftest.$ac_ext
  13554. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_MUTEX_RECURSIVE_NP in pthread.h" >&5
  13555. $as_echo_n "checking for PTHREAD_MUTEX_RECURSIVE_NP in pthread.h... " >&6; }
  13556. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13557. /* end confdefs.h. */
  13558. #include <pthread.h>
  13559. int
  13560. main ()
  13561. {
  13562. int a = PTHREAD_MUTEX_RECURSIVE_NP;
  13563. ;
  13564. return 0;
  13565. }
  13566. _ACEOF
  13567. if ac_fn_c_try_link "$LINENO"; then :
  13568. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13569. $as_echo "yes" >&6; }
  13570. $as_echo "#define HAVE_PTHREAD_MUTEX_RECURSIVE_NP 1" >>confdefs.h
  13571. else
  13572. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13573. $as_echo "no" >&6; }
  13574. fi
  13575. rm -f core conftest.err conftest.$ac_objext \
  13576. conftest$ac_exeext conftest.$ac_ext
  13577. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_MUTEX_ADAPTIVE_NP in pthread.h" >&5
  13578. $as_echo_n "checking for PTHREAD_MUTEX_ADAPTIVE_NP in pthread.h... " >&6; }
  13579. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13580. /* end confdefs.h. */
  13581. #include <pthread.h>
  13582. int
  13583. main ()
  13584. {
  13585. int a = PTHREAD_MUTEX_ADAPTIVE_NP;
  13586. ;
  13587. return 0;
  13588. }
  13589. _ACEOF
  13590. if ac_fn_c_try_link "$LINENO"; then :
  13591. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13592. $as_echo "yes" >&6; }
  13593. $as_echo "#define HAVE_PTHREAD_MUTEX_ADAPTIVE_NP 1" >>confdefs.h
  13594. else
  13595. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13596. $as_echo "no" >&6; }
  13597. fi
  13598. rm -f core conftest.err conftest.$ac_objext \
  13599. conftest$ac_exeext conftest.$ac_ext
  13600. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_spinlock_t in pthread.h" >&5
  13601. $as_echo_n "checking for pthread_spinlock_t in pthread.h... " >&6; }
  13602. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13603. /* end confdefs.h. */
  13604. #include <pthread.h>
  13605. int
  13606. main ()
  13607. {
  13608. pthread_spinlock_t spin;
  13609. ;
  13610. return 0;
  13611. }
  13612. _ACEOF
  13613. if ac_fn_c_try_link "$LINENO"; then :
  13614. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13615. $as_echo "yes" >&6; }
  13616. $as_echo "#define HAVE_PTHREAD_SPINLOCK 1" >>confdefs.h
  13617. else
  13618. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13619. $as_echo "no" >&6; }
  13620. fi
  13621. rm -f core conftest.err conftest.$ac_objext \
  13622. conftest$ac_exeext conftest.$ac_ext
  13623. save_LIBS="$LIBS"
  13624. save_CFLAGS="$CFLAGS"
  13625. LIBS="$PTHREAD_LIBS $LIBS"
  13626. CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
  13627. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_rwlock_timedwrlock() in pthread.h" >&5
  13628. $as_echo_n "checking for pthread_rwlock_timedwrlock() in pthread.h... " >&6; }
  13629. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13630. /* end confdefs.h. */
  13631. #include <pthread.h>
  13632. #include <time.h>
  13633. int
  13634. main ()
  13635. {
  13636. pthread_rwlock_t foo; struct timespec bar; pthread_rwlock_timedwrlock(&foo, &bar)
  13637. ;
  13638. return 0;
  13639. }
  13640. _ACEOF
  13641. if ac_fn_c_try_link "$LINENO"; then :
  13642. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13643. $as_echo "yes" >&6; }
  13644. ac_cv_pthread_rwlock_timedwrlock="yes"
  13645. else
  13646. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13647. $as_echo "no" >&6; }
  13648. ac_cv_pthread_rwlock_timedwrlock="no"
  13649. fi
  13650. rm -f core conftest.err conftest.$ac_objext \
  13651. conftest$ac_exeext conftest.$ac_ext
  13652. # Some platforms define sem_init(), but only support sem_open(). joyous.
  13653. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working unnamed semaphores" >&5
  13654. $as_echo_n "checking for working unnamed semaphores... " >&6; }
  13655. if test "$cross_compiling" = yes; then :
  13656. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  13657. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  13658. as_fn_error $? "cannot run test program while cross compiling
  13659. See \`config.log' for more details" "$LINENO" 5; }
  13660. else
  13661. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13662. /* end confdefs.h. */
  13663. #include <semaphore.h>
  13664. int
  13665. main ()
  13666. {
  13667. sem_t sem; return sem_init(&sem, 0, 0);
  13668. ;
  13669. return 0;
  13670. }
  13671. _ACEOF
  13672. if ac_fn_c_try_run "$LINENO"; then :
  13673. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13674. $as_echo "yes" >&6; }
  13675. $as_echo "#define HAS_WORKING_SEMAPHORE 1" >>confdefs.h
  13676. else
  13677. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13678. $as_echo "no" >&6; }
  13679. fi
  13680. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  13681. conftest.$ac_objext conftest.beam conftest.$ac_ext
  13682. fi
  13683. LIBS="$save_LIBS"
  13684. CFLAGS="$save_CFLAGS"
  13685. if test "${ac_cv_pthread_rwlock_timedwrlock}" = "yes"; then
  13686. $as_echo "#define HAVE_PTHREAD_RWLOCK_TIMEDWRLOCK 1" >>confdefs.h
  13687. fi
  13688. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if PTHREAD_ONCE_INIT needs braces" >&5
  13689. $as_echo_n "checking if PTHREAD_ONCE_INIT needs braces... " >&6; }
  13690. saved_CFLAGS="${CFLAGS}"
  13691. CFLAGS="${CFLAGS} -Werror -Wmissing-braces"
  13692. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13693. /* end confdefs.h. */
  13694. #include <pthread.h>
  13695. void empty(){}
  13696. int
  13697. main ()
  13698. {
  13699. pthread_once_t once = PTHREAD_ONCE_INIT; pthread_once(&once, empty);
  13700. ;
  13701. return 0;
  13702. }
  13703. _ACEOF
  13704. if ac_fn_c_try_compile "$LINENO"; then :
  13705. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13706. $as_echo "no" >&6; }
  13707. ac_cv_pthread_once_needsbraces="no"
  13708. else
  13709. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13710. $as_echo "yes" >&6; }
  13711. ac_cv_pthread_once_needsbraces="yes"
  13712. fi
  13713. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  13714. CFLAGS="${saved_CFLAGS}"
  13715. if test "${ac_cv_pthread_once_needsbraces}" = "yes"; then
  13716. $as_echo "#define PTHREAD_ONCE_INIT_NEEDS_BRACES 1" >>confdefs.h
  13717. fi
  13718. if test "x${PBX_PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP}" != "x1"; then
  13719. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP in pthread.h" >&5
  13720. $as_echo_n "checking for PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP in pthread.h... " >&6; }
  13721. saved_cppflags="${CPPFLAGS}"
  13722. if test "x${PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP_DIR}" != "x"; then
  13723. PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP_INCLUDE="-I${PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP_DIR}/include"
  13724. fi
  13725. CPPFLAGS="${CPPFLAGS} ${PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP_INCLUDE}"
  13726. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13727. /* end confdefs.h. */
  13728. #include <pthread.h>
  13729. int
  13730. main ()
  13731. {
  13732. #if defined(PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP)
  13733. int foo = 0;
  13734. #else
  13735. int foo = bar;
  13736. #endif
  13737. 0
  13738. ;
  13739. return 0;
  13740. }
  13741. _ACEOF
  13742. if ac_fn_c_try_compile "$LINENO"; then :
  13743. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13744. $as_echo "yes" >&6; }
  13745. PBX_PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP=1
  13746. $as_echo "#define HAVE_PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP 1" >>confdefs.h
  13747. else
  13748. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13749. $as_echo "no" >&6; }
  13750. fi
  13751. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  13752. CPPFLAGS="${saved_cppflags}"
  13753. fi
  13754. # Can we compare a mutex to its initial value?
  13755. # Generally yes on OpenBSD/FreeBSD and no on Mac OS X.
  13756. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can compare a mutex to its initial value" >&5
  13757. $as_echo_n "checking whether we can compare a mutex to its initial value... " >&6; }
  13758. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13759. /* end confdefs.h. */
  13760. #include <pthread.h>
  13761. int
  13762. main ()
  13763. {
  13764. pthread_mutex_t lock;
  13765. if ((lock) != ((pthread_mutex_t) PTHREAD_MUTEX_INITIALIZER)) {
  13766. return 0;
  13767. }
  13768. return 0
  13769. ;
  13770. return 0;
  13771. }
  13772. _ACEOF
  13773. if ac_fn_c_try_link "$LINENO"; then :
  13774. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13775. $as_echo "yes" >&6; }
  13776. $as_echo "#define CAN_COMPARE_MUTEX_TO_INIT_VALUE 1" >>confdefs.h
  13777. else
  13778. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13779. $as_echo "no" >&6; }
  13780. fi
  13781. rm -f core conftest.err conftest.$ac_objext \
  13782. conftest$ac_exeext conftest.$ac_ext
  13783. #if test "${cross_compiling}" = "no";
  13784. #then
  13785. #AC_MSG_CHECKING(for working epoll support)
  13786. #AC_LINK_IFELSE(
  13787. #AC_LANG_PROGRAM([#include <sys/epoll.h>], [int res = epoll_create(10);
  13788. # if (res < 0)
  13789. # return 1;
  13790. # close (res);
  13791. # return 0;]),
  13792. #AC_MSG_RESULT(yes)
  13793. #AC_DEFINE([HAVE_EPOLL], 1, [Define to 1 if your system has working epoll support.]),
  13794. #AC_MSG_RESULT(no)
  13795. #)
  13796. #fi
  13797. # for FreeBSD thr_self
  13798. for ac_header in sys/thr.h
  13799. do :
  13800. ac_fn_c_check_header_mongrel "$LINENO" "sys/thr.h" "ac_cv_header_sys_thr_h" "$ac_includes_default"
  13801. if test "x$ac_cv_header_sys_thr_h" = xyes; then :
  13802. cat >>confdefs.h <<_ACEOF
  13803. #define HAVE_SYS_THR_H 1
  13804. _ACEOF
  13805. fi
  13806. done
  13807. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler atomic operations" >&5
  13808. $as_echo_n "checking for compiler atomic operations... " >&6; }
  13809. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13810. /* end confdefs.h. */
  13811. int
  13812. main ()
  13813. {
  13814. int foo1; int foo2 = __sync_fetch_and_add(&foo1, 1);
  13815. ;
  13816. return 0;
  13817. }
  13818. _ACEOF
  13819. if ac_fn_c_try_link "$LINENO"; then :
  13820. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13821. $as_echo "yes" >&6; }
  13822. $as_echo "#define HAVE_GCC_ATOMICS 1" >>confdefs.h
  13823. else
  13824. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13825. $as_echo "no" >&6; }
  13826. fi
  13827. rm -f core conftest.err conftest.$ac_objext \
  13828. conftest$ac_exeext conftest.$ac_ext
  13829. # glibc, AFAIK, is the only C library that makes printing a NULL to a string safe.
  13830. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if your system printf is NULL-safe." >&5
  13831. $as_echo_n "checking if your system printf is NULL-safe.... " >&6; }
  13832. if test "$cross_compiling" = yes; then :
  13833. # It's unlikely an embedded system will have this.
  13834. { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5
  13835. $as_echo "unknown" >&6; }
  13836. else
  13837. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13838. /* end confdefs.h. */
  13839. #include <stdio.h>
  13840. int
  13841. main ()
  13842. {
  13843. printf("%s", NULL)
  13844. ;
  13845. return 0;
  13846. }
  13847. _ACEOF
  13848. if ac_fn_c_try_run "$LINENO"; then :
  13849. $as_echo "#define HAVE_NULLSAFE_PRINTF 1" >>confdefs.h
  13850. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13851. $as_echo "yes" >&6; }
  13852. else
  13853. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13854. $as_echo "no" >&6; }
  13855. fi
  13856. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  13857. conftest.$ac_objext conftest.beam conftest.$ac_ext
  13858. fi
  13859. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can increase the maximum select-able file descriptor" >&5
  13860. $as_echo_n "checking if we can increase the maximum select-able file descriptor... " >&6; }
  13861. if test "$cross_compiling" = yes; then :
  13862. { $as_echo "$as_me:${as_lineno-$LINENO}: result: cross-compile" >&5
  13863. $as_echo "cross-compile" >&6; }
  13864. else
  13865. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13866. /* end confdefs.h. */
  13867. #include <stdio.h>
  13868. #include <sys/select.h>
  13869. #include <sys/time.h>
  13870. #include <sys/resource.h>
  13871. #include <string.h>
  13872. #include <errno.h>
  13873. #include <stdlib.h>
  13874. #include <sys/types.h>
  13875. #include <sys/stat.h>
  13876. #include <fcntl.h>
  13877. #include <unistd.h>
  13878. int
  13879. main ()
  13880. {
  13881. struct rlimit rlim = { FD_SETSIZE * 2, FD_SETSIZE * 2 };
  13882. int fd0, fd1;
  13883. struct timeval tv = { 0, };
  13884. struct ast_fdset { long fds_bits[[1024]]; } fds = { { 0, } };
  13885. if (setrlimit(RLIMIT_NOFILE, &rlim)) { exit(1); }
  13886. if ((fd0 = open("/dev/null", O_RDONLY)) < 0) { exit(1); }
  13887. if (dup2(fd0, (fd1 = FD_SETSIZE + 1)) < 0) { exit(1); }
  13888. FD_SET(fd0, (fd_set *) &fds);
  13889. FD_SET(fd1, (fd_set *) &fds);
  13890. if (select(FD_SETSIZE + 2, (fd_set *) &fds, NULL, NULL, &tv) < 0) { exit(1); }
  13891. exit(0)
  13892. ;
  13893. return 0;
  13894. }
  13895. _ACEOF
  13896. if ac_fn_c_try_run "$LINENO"; then :
  13897. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13898. $as_echo "yes" >&6; }
  13899. $as_echo "#define HAVE_VARIABLE_FDSET 1" >>confdefs.h
  13900. else
  13901. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13902. $as_echo "no" >&6; }
  13903. fi
  13904. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  13905. conftest.$ac_objext conftest.beam conftest.$ac_ext
  13906. fi
  13907. if test "${ac_cv_have_variable_fdset}x" = "0x"; then
  13908. if test "$cross_compiling" = yes; then :
  13909. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  13910. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  13911. as_fn_error $? "cannot run test program while cross compiling
  13912. See \`config.log' for more details" "$LINENO" 5; }
  13913. else
  13914. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13915. /* end confdefs.h. */
  13916. #include <unistd.h>
  13917. #include <sys/types.h>
  13918. #include <stdlib.h>
  13919. int
  13920. main ()
  13921. {
  13922. if (getuid() != 0) { exit(1); }
  13923. ;
  13924. return 0;
  13925. }
  13926. _ACEOF
  13927. if ac_fn_c_try_run "$LINENO"; then :
  13928. $as_echo "#define CONFIGURE_RAN_AS_ROOT 1" >>confdefs.h
  13929. fi
  13930. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  13931. conftest.$ac_objext conftest.beam conftest.$ac_ext
  13932. fi
  13933. fi
  13934. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute pure' support" >&5
  13935. $as_echo_n "checking for compiler 'attribute pure' support... " >&6; }
  13936. saved_CFLAGS="$CFLAGS"
  13937. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  13938. if test "x" = "x"
  13939. then
  13940. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13941. /* end confdefs.h. */
  13942. void __attribute__((pure)) *test(void *muffin, ...) {return (void *) 0;}
  13943. int
  13944. main ()
  13945. {
  13946. ;
  13947. return 0;
  13948. }
  13949. _ACEOF
  13950. if ac_fn_c_try_compile "$LINENO"; then :
  13951. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13952. $as_echo "yes" >&6; }
  13953. cat >>confdefs.h <<_ACEOF
  13954. #define HAVE_ATTRIBUTE_pure 1
  13955. _ACEOF
  13956. else
  13957. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13958. $as_echo "no" >&6; }
  13959. fi
  13960. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  13961. else
  13962. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13963. /* end confdefs.h. */
  13964. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  13965. int
  13966. main ()
  13967. {
  13968. ;
  13969. return 0;
  13970. }
  13971. _ACEOF
  13972. if ac_fn_c_try_compile "$LINENO"; then :
  13973. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13974. $as_echo "yes" >&6; }
  13975. cat >>confdefs.h <<_ACEOF
  13976. #define HAVE_ATTRIBUTE_pure 1
  13977. _ACEOF
  13978. else
  13979. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13980. $as_echo "no" >&6; }
  13981. fi
  13982. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  13983. fi
  13984. CFLAGS="$saved_CFLAGS"
  13985. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute malloc' support" >&5
  13986. $as_echo_n "checking for compiler 'attribute malloc' support... " >&6; }
  13987. saved_CFLAGS="$CFLAGS"
  13988. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  13989. if test "x" = "x"
  13990. then
  13991. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13992. /* end confdefs.h. */
  13993. void __attribute__((malloc)) *test(void *muffin, ...) {return (void *) 0;}
  13994. int
  13995. main ()
  13996. {
  13997. ;
  13998. return 0;
  13999. }
  14000. _ACEOF
  14001. if ac_fn_c_try_compile "$LINENO"; then :
  14002. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14003. $as_echo "yes" >&6; }
  14004. cat >>confdefs.h <<_ACEOF
  14005. #define HAVE_ATTRIBUTE_malloc 1
  14006. _ACEOF
  14007. else
  14008. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14009. $as_echo "no" >&6; }
  14010. fi
  14011. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14012. else
  14013. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14014. /* end confdefs.h. */
  14015. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14016. int
  14017. main ()
  14018. {
  14019. ;
  14020. return 0;
  14021. }
  14022. _ACEOF
  14023. if ac_fn_c_try_compile "$LINENO"; then :
  14024. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14025. $as_echo "yes" >&6; }
  14026. cat >>confdefs.h <<_ACEOF
  14027. #define HAVE_ATTRIBUTE_malloc 1
  14028. _ACEOF
  14029. else
  14030. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14031. $as_echo "no" >&6; }
  14032. fi
  14033. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14034. fi
  14035. CFLAGS="$saved_CFLAGS"
  14036. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute const' support" >&5
  14037. $as_echo_n "checking for compiler 'attribute const' support... " >&6; }
  14038. saved_CFLAGS="$CFLAGS"
  14039. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14040. if test "x" = "x"
  14041. then
  14042. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14043. /* end confdefs.h. */
  14044. void __attribute__((const)) *test(void *muffin, ...) {return (void *) 0;}
  14045. int
  14046. main ()
  14047. {
  14048. ;
  14049. return 0;
  14050. }
  14051. _ACEOF
  14052. if ac_fn_c_try_compile "$LINENO"; then :
  14053. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14054. $as_echo "yes" >&6; }
  14055. cat >>confdefs.h <<_ACEOF
  14056. #define HAVE_ATTRIBUTE_const 1
  14057. _ACEOF
  14058. else
  14059. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14060. $as_echo "no" >&6; }
  14061. fi
  14062. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14063. else
  14064. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14065. /* end confdefs.h. */
  14066. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14067. int
  14068. main ()
  14069. {
  14070. ;
  14071. return 0;
  14072. }
  14073. _ACEOF
  14074. if ac_fn_c_try_compile "$LINENO"; then :
  14075. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14076. $as_echo "yes" >&6; }
  14077. cat >>confdefs.h <<_ACEOF
  14078. #define HAVE_ATTRIBUTE_const 1
  14079. _ACEOF
  14080. else
  14081. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14082. $as_echo "no" >&6; }
  14083. fi
  14084. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14085. fi
  14086. CFLAGS="$saved_CFLAGS"
  14087. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute unused' support" >&5
  14088. $as_echo_n "checking for compiler 'attribute unused' support... " >&6; }
  14089. saved_CFLAGS="$CFLAGS"
  14090. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14091. if test "x" = "x"
  14092. then
  14093. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14094. /* end confdefs.h. */
  14095. void __attribute__((unused)) *test(void *muffin, ...) {return (void *) 0;}
  14096. int
  14097. main ()
  14098. {
  14099. ;
  14100. return 0;
  14101. }
  14102. _ACEOF
  14103. if ac_fn_c_try_compile "$LINENO"; then :
  14104. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14105. $as_echo "yes" >&6; }
  14106. cat >>confdefs.h <<_ACEOF
  14107. #define HAVE_ATTRIBUTE_unused 1
  14108. _ACEOF
  14109. else
  14110. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14111. $as_echo "no" >&6; }
  14112. fi
  14113. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14114. else
  14115. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14116. /* end confdefs.h. */
  14117. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14118. int
  14119. main ()
  14120. {
  14121. ;
  14122. return 0;
  14123. }
  14124. _ACEOF
  14125. if ac_fn_c_try_compile "$LINENO"; then :
  14126. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14127. $as_echo "yes" >&6; }
  14128. cat >>confdefs.h <<_ACEOF
  14129. #define HAVE_ATTRIBUTE_unused 1
  14130. _ACEOF
  14131. else
  14132. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14133. $as_echo "no" >&6; }
  14134. fi
  14135. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14136. fi
  14137. CFLAGS="$saved_CFLAGS"
  14138. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute always_inline' support" >&5
  14139. $as_echo_n "checking for compiler 'attribute always_inline' support... " >&6; }
  14140. saved_CFLAGS="$CFLAGS"
  14141. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14142. if test "x" = "x"
  14143. then
  14144. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14145. /* end confdefs.h. */
  14146. void __attribute__((always_inline)) *test(void *muffin, ...) {return (void *) 0;}
  14147. int
  14148. main ()
  14149. {
  14150. ;
  14151. return 0;
  14152. }
  14153. _ACEOF
  14154. if ac_fn_c_try_compile "$LINENO"; then :
  14155. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14156. $as_echo "yes" >&6; }
  14157. cat >>confdefs.h <<_ACEOF
  14158. #define HAVE_ATTRIBUTE_always_inline 1
  14159. _ACEOF
  14160. else
  14161. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14162. $as_echo "no" >&6; }
  14163. fi
  14164. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14165. else
  14166. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14167. /* end confdefs.h. */
  14168. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14169. int
  14170. main ()
  14171. {
  14172. ;
  14173. return 0;
  14174. }
  14175. _ACEOF
  14176. if ac_fn_c_try_compile "$LINENO"; then :
  14177. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14178. $as_echo "yes" >&6; }
  14179. cat >>confdefs.h <<_ACEOF
  14180. #define HAVE_ATTRIBUTE_always_inline 1
  14181. _ACEOF
  14182. else
  14183. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14184. $as_echo "no" >&6; }
  14185. fi
  14186. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14187. fi
  14188. CFLAGS="$saved_CFLAGS"
  14189. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute deprecated' support" >&5
  14190. $as_echo_n "checking for compiler 'attribute deprecated' support... " >&6; }
  14191. saved_CFLAGS="$CFLAGS"
  14192. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14193. if test "x" = "x"
  14194. then
  14195. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14196. /* end confdefs.h. */
  14197. void __attribute__((deprecated)) *test(void *muffin, ...) {return (void *) 0;}
  14198. int
  14199. main ()
  14200. {
  14201. ;
  14202. return 0;
  14203. }
  14204. _ACEOF
  14205. if ac_fn_c_try_compile "$LINENO"; then :
  14206. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14207. $as_echo "yes" >&6; }
  14208. cat >>confdefs.h <<_ACEOF
  14209. #define HAVE_ATTRIBUTE_deprecated 1
  14210. _ACEOF
  14211. else
  14212. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14213. $as_echo "no" >&6; }
  14214. fi
  14215. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14216. else
  14217. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14218. /* end confdefs.h. */
  14219. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14220. int
  14221. main ()
  14222. {
  14223. ;
  14224. return 0;
  14225. }
  14226. _ACEOF
  14227. if ac_fn_c_try_compile "$LINENO"; then :
  14228. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14229. $as_echo "yes" >&6; }
  14230. cat >>confdefs.h <<_ACEOF
  14231. #define HAVE_ATTRIBUTE_deprecated 1
  14232. _ACEOF
  14233. else
  14234. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14235. $as_echo "no" >&6; }
  14236. fi
  14237. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14238. fi
  14239. CFLAGS="$saved_CFLAGS"
  14240. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute sentinel' support" >&5
  14241. $as_echo_n "checking for compiler 'attribute sentinel' support... " >&6; }
  14242. saved_CFLAGS="$CFLAGS"
  14243. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14244. if test "x" = "x"
  14245. then
  14246. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14247. /* end confdefs.h. */
  14248. void __attribute__((sentinel)) *test(void *muffin, ...) {return (void *) 0;}
  14249. int
  14250. main ()
  14251. {
  14252. ;
  14253. return 0;
  14254. }
  14255. _ACEOF
  14256. if ac_fn_c_try_compile "$LINENO"; then :
  14257. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14258. $as_echo "yes" >&6; }
  14259. cat >>confdefs.h <<_ACEOF
  14260. #define HAVE_ATTRIBUTE_sentinel 1
  14261. _ACEOF
  14262. else
  14263. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14264. $as_echo "no" >&6; }
  14265. fi
  14266. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14267. else
  14268. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14269. /* end confdefs.h. */
  14270. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14271. int
  14272. main ()
  14273. {
  14274. ;
  14275. return 0;
  14276. }
  14277. _ACEOF
  14278. if ac_fn_c_try_compile "$LINENO"; then :
  14279. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14280. $as_echo "yes" >&6; }
  14281. cat >>confdefs.h <<_ACEOF
  14282. #define HAVE_ATTRIBUTE_sentinel 1
  14283. _ACEOF
  14284. else
  14285. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14286. $as_echo "no" >&6; }
  14287. fi
  14288. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14289. fi
  14290. CFLAGS="$saved_CFLAGS"
  14291. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute warn_unused_result' support" >&5
  14292. $as_echo_n "checking for compiler 'attribute warn_unused_result' support... " >&6; }
  14293. saved_CFLAGS="$CFLAGS"
  14294. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14295. if test "x" = "x"
  14296. then
  14297. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14298. /* end confdefs.h. */
  14299. void __attribute__((warn_unused_result)) *test(void *muffin, ...) {return (void *) 0;}
  14300. int
  14301. main ()
  14302. {
  14303. ;
  14304. return 0;
  14305. }
  14306. _ACEOF
  14307. if ac_fn_c_try_compile "$LINENO"; then :
  14308. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14309. $as_echo "yes" >&6; }
  14310. cat >>confdefs.h <<_ACEOF
  14311. #define HAVE_ATTRIBUTE_warn_unused_result 1
  14312. _ACEOF
  14313. else
  14314. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14315. $as_echo "no" >&6; }
  14316. fi
  14317. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14318. else
  14319. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14320. /* end confdefs.h. */
  14321. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14322. int
  14323. main ()
  14324. {
  14325. ;
  14326. return 0;
  14327. }
  14328. _ACEOF
  14329. if ac_fn_c_try_compile "$LINENO"; then :
  14330. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14331. $as_echo "yes" >&6; }
  14332. cat >>confdefs.h <<_ACEOF
  14333. #define HAVE_ATTRIBUTE_warn_unused_result 1
  14334. _ACEOF
  14335. else
  14336. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14337. $as_echo "no" >&6; }
  14338. fi
  14339. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14340. fi
  14341. CFLAGS="$saved_CFLAGS"
  14342. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute may_alias' support" >&5
  14343. $as_echo_n "checking for compiler 'attribute may_alias' support... " >&6; }
  14344. saved_CFLAGS="$CFLAGS"
  14345. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14346. if test "x" = "x"
  14347. then
  14348. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14349. /* end confdefs.h. */
  14350. void __attribute__((may_alias)) *test(void *muffin, ...) {return (void *) 0;}
  14351. int
  14352. main ()
  14353. {
  14354. ;
  14355. return 0;
  14356. }
  14357. _ACEOF
  14358. if ac_fn_c_try_compile "$LINENO"; then :
  14359. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14360. $as_echo "yes" >&6; }
  14361. cat >>confdefs.h <<_ACEOF
  14362. #define HAVE_ATTRIBUTE_may_alias 1
  14363. _ACEOF
  14364. else
  14365. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14366. $as_echo "no" >&6; }
  14367. fi
  14368. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14369. else
  14370. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14371. /* end confdefs.h. */
  14372. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14373. int
  14374. main ()
  14375. {
  14376. ;
  14377. return 0;
  14378. }
  14379. _ACEOF
  14380. if ac_fn_c_try_compile "$LINENO"; then :
  14381. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14382. $as_echo "yes" >&6; }
  14383. cat >>confdefs.h <<_ACEOF
  14384. #define HAVE_ATTRIBUTE_may_alias 1
  14385. _ACEOF
  14386. else
  14387. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14388. $as_echo "no" >&6; }
  14389. fi
  14390. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14391. fi
  14392. CFLAGS="$saved_CFLAGS"
  14393. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute constructor' support" >&5
  14394. $as_echo_n "checking for compiler 'attribute constructor' support... " >&6; }
  14395. saved_CFLAGS="$CFLAGS"
  14396. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14397. if test "x" = "x"
  14398. then
  14399. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14400. /* end confdefs.h. */
  14401. void __attribute__((constructor)) *test(void *muffin, ...) {return (void *) 0;}
  14402. int
  14403. main ()
  14404. {
  14405. ;
  14406. return 0;
  14407. }
  14408. _ACEOF
  14409. if ac_fn_c_try_compile "$LINENO"; then :
  14410. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14411. $as_echo "yes" >&6; }
  14412. cat >>confdefs.h <<_ACEOF
  14413. #define HAVE_ATTRIBUTE_constructor 1
  14414. _ACEOF
  14415. else
  14416. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14417. $as_echo "no" >&6; }
  14418. fi
  14419. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14420. else
  14421. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14422. /* end confdefs.h. */
  14423. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14424. int
  14425. main ()
  14426. {
  14427. ;
  14428. return 0;
  14429. }
  14430. _ACEOF
  14431. if ac_fn_c_try_compile "$LINENO"; then :
  14432. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14433. $as_echo "yes" >&6; }
  14434. cat >>confdefs.h <<_ACEOF
  14435. #define HAVE_ATTRIBUTE_constructor 1
  14436. _ACEOF
  14437. else
  14438. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14439. $as_echo "no" >&6; }
  14440. fi
  14441. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14442. fi
  14443. CFLAGS="$saved_CFLAGS"
  14444. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute destructor' support" >&5
  14445. $as_echo_n "checking for compiler 'attribute destructor' support... " >&6; }
  14446. saved_CFLAGS="$CFLAGS"
  14447. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14448. if test "x" = "x"
  14449. then
  14450. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14451. /* end confdefs.h. */
  14452. void __attribute__((destructor)) *test(void *muffin, ...) {return (void *) 0;}
  14453. int
  14454. main ()
  14455. {
  14456. ;
  14457. return 0;
  14458. }
  14459. _ACEOF
  14460. if ac_fn_c_try_compile "$LINENO"; then :
  14461. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14462. $as_echo "yes" >&6; }
  14463. cat >>confdefs.h <<_ACEOF
  14464. #define HAVE_ATTRIBUTE_destructor 1
  14465. _ACEOF
  14466. else
  14467. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14468. $as_echo "no" >&6; }
  14469. fi
  14470. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14471. else
  14472. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14473. /* end confdefs.h. */
  14474. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14475. int
  14476. main ()
  14477. {
  14478. ;
  14479. return 0;
  14480. }
  14481. _ACEOF
  14482. if ac_fn_c_try_compile "$LINENO"; then :
  14483. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14484. $as_echo "yes" >&6; }
  14485. cat >>confdefs.h <<_ACEOF
  14486. #define HAVE_ATTRIBUTE_destructor 1
  14487. _ACEOF
  14488. else
  14489. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14490. $as_echo "no" >&6; }
  14491. fi
  14492. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14493. fi
  14494. CFLAGS="$saved_CFLAGS"
  14495. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -ffunction-sections support" >&5
  14496. $as_echo_n "checking for -ffunction-sections support... " >&6; }
  14497. saved_CFLAGS="${CFLAGS}"
  14498. CFLAGS="${CFLAGS} -ffunction-sections"
  14499. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14500. /* end confdefs.h. */
  14501. int
  14502. main ()
  14503. {
  14504. int x = 1;
  14505. ;
  14506. return 0;
  14507. }
  14508. _ACEOF
  14509. if ac_fn_c_try_compile "$LINENO"; then :
  14510. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14511. $as_echo "yes" >&6; }
  14512. saved_LDFLAGS="${LDFLAGS}"
  14513. LDFLAGS="${LDFLAGS} -Wl,--gc-sections"
  14514. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --gc-sections support" >&5
  14515. $as_echo_n "checking for --gc-sections support... " >&6; }
  14516. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14517. /* end confdefs.h. */
  14518. int
  14519. main ()
  14520. {
  14521. int x = 1;
  14522. ;
  14523. return 0;
  14524. }
  14525. _ACEOF
  14526. if ac_fn_c_try_link "$LINENO"; then :
  14527. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14528. $as_echo "yes" >&6; }
  14529. GC_CFLAGS="-ffunction-sections"
  14530. GC_LDFLAGS="-Wl,--gc-sections"
  14531. else
  14532. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14533. $as_echo "no" >&6; }
  14534. fi
  14535. rm -f core conftest.err conftest.$ac_objext \
  14536. conftest$ac_exeext conftest.$ac_ext
  14537. LDFLAGS="${saved_LDFLAGS}"
  14538. else
  14539. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14540. $as_echo "no" >&6; }
  14541. fi
  14542. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14543. CFLAGS="${saved_CFLAGS}"
  14544. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Wdeclaration-after-statement support" >&5
  14545. $as_echo_n "checking for -Wdeclaration-after-statement support... " >&6; }
  14546. if $(${CC} -Wdeclaration-after-statement -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
  14547. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14548. $as_echo "yes" >&6; }
  14549. AST_DECLARATION_AFTER_STATEMENT=-Wdeclaration-after-statement
  14550. else
  14551. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14552. $as_echo "no" >&6; }
  14553. AST_DECLARATION_AFTER_STATEMENT=
  14554. fi
  14555. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Wtrampolines support" >&5
  14556. $as_echo_n "checking for -Wtrampolines support... " >&6; }
  14557. if $(${CC} -Wtrampolines -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
  14558. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14559. $as_echo "yes" >&6; }
  14560. AST_TRAMPOLINES=-Wtrampolines
  14561. else
  14562. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14563. $as_echo "no" >&6; }
  14564. AST_TRAMPOLINES=
  14565. fi
  14566. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FORTIFY_SOURCE support" >&5
  14567. $as_echo_n "checking for _FORTIFY_SOURCE support... " >&6; }
  14568. if $(${CC} -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
  14569. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14570. $as_echo "yes" >&6; }
  14571. AST_FORTIFY_SOURCE="-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2"
  14572. else
  14573. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14574. $as_echo "no" >&6; }
  14575. AST_FORTIFY_SOURCE=
  14576. fi
  14577. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -fno-strict-overflow" >&5
  14578. $as_echo_n "checking for -fno-strict-overflow... " >&6; }
  14579. if $(${CC} -O2 -fno-strict-overflow -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
  14580. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14581. $as_echo "yes" >&6; }
  14582. AST_NO_STRICT_OVERFLOW=-fno-strict-overflow
  14583. else
  14584. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14585. $as_echo "no" >&6; }
  14586. AST_NO_STRICT_OVERFLOW=
  14587. fi
  14588. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Wshadow" >&5
  14589. $as_echo_n "checking for -Wshadow... " >&6; }
  14590. if $(${CC} -Wshadow -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
  14591. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14592. $as_echo "yes" >&6; }
  14593. AST_SHADOW_WARNINGS=-Wshadow
  14594. else
  14595. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14596. $as_echo "no" >&6; }
  14597. AST_SHADOW_WARNINGS=
  14598. fi
  14599. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -march=native support" >&5
  14600. $as_echo_n "checking for -march=native support... " >&6; }
  14601. if $(${CC} -march=native -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
  14602. if test "${CONFIG_CFLAGS}" = ""; then
  14603. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14604. $as_echo "yes" >&6; }
  14605. AST_NATIVE_ARCH=1
  14606. else
  14607. { $as_echo "$as_me:${as_lineno-$LINENO}: result: user CFLAGS present" >&5
  14608. $as_echo "user CFLAGS present" >&6; }
  14609. AST_NATIVE_ARCH=
  14610. fi
  14611. else
  14612. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14613. $as_echo "no" >&6; }
  14614. AST_NATIVE_ARCH=
  14615. fi
  14616. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -fnested-functions" >&5
  14617. $as_echo_n "checking for -fnested-functions... " >&6; }
  14618. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14619. /* end confdefs.h. */
  14620. int
  14621. main ()
  14622. {
  14623. auto void foo(void); void foo(void) {}
  14624. ;
  14625. return 0;
  14626. }
  14627. _ACEOF
  14628. if ac_fn_c_try_compile "$LINENO"; then :
  14629. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14630. $as_echo "no" >&6; }
  14631. AST_NESTED_FUNCTIONS=
  14632. else
  14633. { $as_echo "$as_me:${as_lineno-$LINENO}: result: required" >&5
  14634. $as_echo "required" >&6; }
  14635. AST_NESTED_FUNCTIONS=-fnested-functions
  14636. fi
  14637. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14638. # Check whether --enable-rpath was given.
  14639. if test "${enable_rpath+set}" = set; then :
  14640. enableval=$enable_rpath; case "${enableval}" in
  14641. y|ye|yes) check_rpath=yes ;;
  14642. n|no) check_rpath=no ;;
  14643. *) as_fn_error $? "bad value ${enableval} for --disable-rpath" "$LINENO" 5 ;;
  14644. esac
  14645. else
  14646. check_rpath=yes
  14647. fi
  14648. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use rpath" >&5
  14649. $as_echo_n "checking whether to use rpath... " >&6; }
  14650. AST_RPATH=
  14651. if test "${check_rpath}" != yes; then
  14652. { $as_echo "$as_me:${as_lineno-$LINENO}: result: skipped" >&5
  14653. $as_echo "skipped" >&6; }
  14654. elif test "${prefix}" = /usr || test "${prefix}" = NONE; then
  14655. { $as_echo "$as_me:${as_lineno-$LINENO}: result: not needed" >&5
  14656. $as_echo "not needed" >&6; }
  14657. else
  14658. AST_RPATH="-Wl,-rpath,${libdir}"
  14659. fi
  14660. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysinfo" >&5
  14661. $as_echo_n "checking for sysinfo... " >&6; }
  14662. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14663. /* end confdefs.h. */
  14664. #include <sys/sysinfo.h>
  14665. int
  14666. main ()
  14667. {
  14668. struct sysinfo sys_info; int uptime = sys_info.uptime
  14669. ;
  14670. return 0;
  14671. }
  14672. _ACEOF
  14673. if ac_fn_c_try_link "$LINENO"; then :
  14674. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14675. $as_echo "yes" >&6; }
  14676. $as_echo "#define HAVE_SYSINFO 1" >>confdefs.h
  14677. else
  14678. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14679. $as_echo "no" >&6; }
  14680. fi
  14681. rm -f core conftest.err conftest.$ac_objext \
  14682. conftest$ac_exeext conftest.$ac_ext
  14683. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_9_ninit" >&5
  14684. $as_echo_n "checking for library containing res_9_ninit... " >&6; }
  14685. if ${ac_cv_search_res_9_ninit+:} false; then :
  14686. $as_echo_n "(cached) " >&6
  14687. else
  14688. ac_func_search_save_LIBS=$LIBS
  14689. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14690. /* end confdefs.h. */
  14691. /* Override any GCC internal prototype to avoid an error.
  14692. Use char because int might match the return type of a GCC
  14693. builtin and then its argument prototype would still apply. */
  14694. #ifdef __cplusplus
  14695. extern "C"
  14696. #endif
  14697. char res_9_ninit ();
  14698. int
  14699. main ()
  14700. {
  14701. return res_9_ninit ();
  14702. ;
  14703. return 0;
  14704. }
  14705. _ACEOF
  14706. for ac_lib in '' resolv; do
  14707. if test -z "$ac_lib"; then
  14708. ac_res="none required"
  14709. else
  14710. ac_res=-l$ac_lib
  14711. LIBS="-l$ac_lib $ac_func_search_save_LIBS"
  14712. fi
  14713. if ac_fn_c_try_link "$LINENO"; then :
  14714. ac_cv_search_res_9_ninit=$ac_res
  14715. fi
  14716. rm -f core conftest.err conftest.$ac_objext \
  14717. conftest$ac_exeext
  14718. if ${ac_cv_search_res_9_ninit+:} false; then :
  14719. break
  14720. fi
  14721. done
  14722. if ${ac_cv_search_res_9_ninit+:} false; then :
  14723. else
  14724. ac_cv_search_res_9_ninit=no
  14725. fi
  14726. rm conftest.$ac_ext
  14727. LIBS=$ac_func_search_save_LIBS
  14728. fi
  14729. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_9_ninit" >&5
  14730. $as_echo "$ac_cv_search_res_9_ninit" >&6; }
  14731. ac_res=$ac_cv_search_res_9_ninit
  14732. if test "$ac_res" != no; then :
  14733. test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
  14734. fi
  14735. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_ninit" >&5
  14736. $as_echo_n "checking for res_ninit... " >&6; }
  14737. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14738. /* end confdefs.h. */
  14739. #ifdef HAVE_SYS_SOCKET_H
  14740. #include <sys/socket.h>
  14741. #endif
  14742. #ifdef HAVE_NETINET_IN_H
  14743. #include <netinet/in.h>
  14744. #endif
  14745. #ifdef HAVE_ARPA_NAMESER_H
  14746. #include <arpa/nameser.h>
  14747. #endif
  14748. #include <resolv.h>
  14749. int
  14750. main ()
  14751. {
  14752. int foo = res_ninit(NULL);
  14753. ;
  14754. return 0;
  14755. }
  14756. _ACEOF
  14757. if ac_fn_c_try_link "$LINENO"; then :
  14758. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14759. $as_echo "yes" >&6; }
  14760. $as_echo "#define HAVE_RES_NINIT 1" >>confdefs.h
  14761. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_9_ndestroy" >&5
  14762. $as_echo_n "checking for library containing res_9_ndestroy... " >&6; }
  14763. if ${ac_cv_search_res_9_ndestroy+:} false; then :
  14764. $as_echo_n "(cached) " >&6
  14765. else
  14766. ac_func_search_save_LIBS=$LIBS
  14767. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14768. /* end confdefs.h. */
  14769. /* Override any GCC internal prototype to avoid an error.
  14770. Use char because int might match the return type of a GCC
  14771. builtin and then its argument prototype would still apply. */
  14772. #ifdef __cplusplus
  14773. extern "C"
  14774. #endif
  14775. char res_9_ndestroy ();
  14776. int
  14777. main ()
  14778. {
  14779. return res_9_ndestroy ();
  14780. ;
  14781. return 0;
  14782. }
  14783. _ACEOF
  14784. for ac_lib in '' resolv; do
  14785. if test -z "$ac_lib"; then
  14786. ac_res="none required"
  14787. else
  14788. ac_res=-l$ac_lib
  14789. LIBS="-l$ac_lib $ac_func_search_save_LIBS"
  14790. fi
  14791. if ac_fn_c_try_link "$LINENO"; then :
  14792. ac_cv_search_res_9_ndestroy=$ac_res
  14793. fi
  14794. rm -f core conftest.err conftest.$ac_objext \
  14795. conftest$ac_exeext
  14796. if ${ac_cv_search_res_9_ndestroy+:} false; then :
  14797. break
  14798. fi
  14799. done
  14800. if ${ac_cv_search_res_9_ndestroy+:} false; then :
  14801. else
  14802. ac_cv_search_res_9_ndestroy=no
  14803. fi
  14804. rm conftest.$ac_ext
  14805. LIBS=$ac_func_search_save_LIBS
  14806. fi
  14807. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_9_ndestroy" >&5
  14808. $as_echo "$ac_cv_search_res_9_ndestroy" >&6; }
  14809. ac_res=$ac_cv_search_res_9_ndestroy
  14810. if test "$ac_res" != no; then :
  14811. test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
  14812. fi
  14813. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_ndestroy" >&5
  14814. $as_echo_n "checking for res_ndestroy... " >&6; }
  14815. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14816. /* end confdefs.h. */
  14817. #ifdef HAVE_SYS_SOCKET_H
  14818. #include <sys/socket.h>
  14819. #endif
  14820. #ifdef HAVE_NETINET_IN_H
  14821. #include <netinet/in.h>
  14822. #endif
  14823. #ifdef HAVE_ARPA_NAMESER_H
  14824. #include <arpa/nameser.h>
  14825. #endif
  14826. #include <resolv.h>
  14827. int
  14828. main ()
  14829. {
  14830. res_ndestroy(NULL);
  14831. ;
  14832. return 0;
  14833. }
  14834. _ACEOF
  14835. if ac_fn_c_try_link "$LINENO"; then :
  14836. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14837. $as_echo "yes" >&6; }
  14838. $as_echo "#define HAVE_RES_NDESTROY 1" >>confdefs.h
  14839. else
  14840. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14841. $as_echo "no" >&6; }
  14842. fi
  14843. rm -f core conftest.err conftest.$ac_objext \
  14844. conftest$ac_exeext conftest.$ac_ext
  14845. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_9_close" >&5
  14846. $as_echo_n "checking for library containing res_9_close... " >&6; }
  14847. if ${ac_cv_search_res_9_close+:} false; then :
  14848. $as_echo_n "(cached) " >&6
  14849. else
  14850. ac_func_search_save_LIBS=$LIBS
  14851. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14852. /* end confdefs.h. */
  14853. /* Override any GCC internal prototype to avoid an error.
  14854. Use char because int might match the return type of a GCC
  14855. builtin and then its argument prototype would still apply. */
  14856. #ifdef __cplusplus
  14857. extern "C"
  14858. #endif
  14859. char res_9_close ();
  14860. int
  14861. main ()
  14862. {
  14863. return res_9_close ();
  14864. ;
  14865. return 0;
  14866. }
  14867. _ACEOF
  14868. for ac_lib in '' resolv; do
  14869. if test -z "$ac_lib"; then
  14870. ac_res="none required"
  14871. else
  14872. ac_res=-l$ac_lib
  14873. LIBS="-l$ac_lib $ac_func_search_save_LIBS"
  14874. fi
  14875. if ac_fn_c_try_link "$LINENO"; then :
  14876. ac_cv_search_res_9_close=$ac_res
  14877. fi
  14878. rm -f core conftest.err conftest.$ac_objext \
  14879. conftest$ac_exeext
  14880. if ${ac_cv_search_res_9_close+:} false; then :
  14881. break
  14882. fi
  14883. done
  14884. if ${ac_cv_search_res_9_close+:} false; then :
  14885. else
  14886. ac_cv_search_res_9_close=no
  14887. fi
  14888. rm conftest.$ac_ext
  14889. LIBS=$ac_func_search_save_LIBS
  14890. fi
  14891. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_9_close" >&5
  14892. $as_echo "$ac_cv_search_res_9_close" >&6; }
  14893. ac_res=$ac_cv_search_res_9_close
  14894. if test "$ac_res" != no; then :
  14895. test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
  14896. fi
  14897. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_close" >&5
  14898. $as_echo_n "checking for res_close... " >&6; }
  14899. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14900. /* end confdefs.h. */
  14901. #ifdef HAVE_SYS_SOCKET_H
  14902. #include <sys/socket.h>
  14903. #endif
  14904. #ifdef HAVE_NETINET_IN_H
  14905. #include <netinet/in.h>
  14906. #endif
  14907. #ifdef HAVE_ARPA_NAMESER_H
  14908. #include <arpa/nameser.h>
  14909. #endif
  14910. #include <resolv.h>
  14911. int
  14912. main ()
  14913. {
  14914. res_close();
  14915. ;
  14916. return 0;
  14917. }
  14918. _ACEOF
  14919. if ac_fn_c_try_link "$LINENO"; then :
  14920. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14921. $as_echo "yes" >&6; }
  14922. $as_echo "#define HAVE_RES_CLOSE 1" >>confdefs.h
  14923. else
  14924. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14925. $as_echo "no" >&6; }
  14926. fi
  14927. rm -f core conftest.err conftest.$ac_objext \
  14928. conftest$ac_exeext conftest.$ac_ext
  14929. else
  14930. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14931. $as_echo "no" >&6; }
  14932. fi
  14933. rm -f core conftest.err conftest.$ac_objext \
  14934. conftest$ac_exeext conftest.$ac_ext
  14935. if test "x${PBX_GLOB_NOMAGIC}" != "x1"; then
  14936. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GLOB_NOMAGIC in glob.h" >&5
  14937. $as_echo_n "checking for GLOB_NOMAGIC in glob.h... " >&6; }
  14938. saved_cppflags="${CPPFLAGS}"
  14939. if test "x${GLOB_NOMAGIC_DIR}" != "x"; then
  14940. GLOB_NOMAGIC_INCLUDE="-I${GLOB_NOMAGIC_DIR}/include"
  14941. fi
  14942. CPPFLAGS="${CPPFLAGS} ${GLOB_NOMAGIC_INCLUDE}"
  14943. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14944. /* end confdefs.h. */
  14945. #include <glob.h>
  14946. int
  14947. main ()
  14948. {
  14949. #if defined(GLOB_NOMAGIC)
  14950. int foo = 0;
  14951. #else
  14952. int foo = bar;
  14953. #endif
  14954. 0
  14955. ;
  14956. return 0;
  14957. }
  14958. _ACEOF
  14959. if ac_fn_c_try_compile "$LINENO"; then :
  14960. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14961. $as_echo "yes" >&6; }
  14962. PBX_GLOB_NOMAGIC=1
  14963. $as_echo "#define HAVE_GLOB_NOMAGIC 1" >>confdefs.h
  14964. else
  14965. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14966. $as_echo "no" >&6; }
  14967. fi
  14968. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14969. CPPFLAGS="${saved_cppflags}"
  14970. fi
  14971. if test "x${PBX_GLOB_BRACE}" != "x1"; then
  14972. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GLOB_BRACE in glob.h" >&5
  14973. $as_echo_n "checking for GLOB_BRACE in glob.h... " >&6; }
  14974. saved_cppflags="${CPPFLAGS}"
  14975. if test "x${GLOB_BRACE_DIR}" != "x"; then
  14976. GLOB_BRACE_INCLUDE="-I${GLOB_BRACE_DIR}/include"
  14977. fi
  14978. CPPFLAGS="${CPPFLAGS} ${GLOB_BRACE_INCLUDE}"
  14979. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14980. /* end confdefs.h. */
  14981. #include <glob.h>
  14982. int
  14983. main ()
  14984. {
  14985. #if defined(GLOB_BRACE)
  14986. int foo = 0;
  14987. #else
  14988. int foo = bar;
  14989. #endif
  14990. 0
  14991. ;
  14992. return 0;
  14993. }
  14994. _ACEOF
  14995. if ac_fn_c_try_compile "$LINENO"; then :
  14996. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14997. $as_echo "yes" >&6; }
  14998. PBX_GLOB_BRACE=1
  14999. $as_echo "#define HAVE_GLOB_BRACE 1" >>confdefs.h
  15000. else
  15001. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15002. $as_echo "no" >&6; }
  15003. fi
  15004. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  15005. CPPFLAGS="${saved_cppflags}"
  15006. fi
  15007. if test "x${PBX_RTLD_NOLOAD}" != "x1"; then
  15008. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RTLD_NOLOAD in dlfcn.h" >&5
  15009. $as_echo_n "checking for RTLD_NOLOAD in dlfcn.h... " >&6; }
  15010. saved_cppflags="${CPPFLAGS}"
  15011. if test "x${RTLD_NOLOAD_DIR}" != "x"; then
  15012. RTLD_NOLOAD_INCLUDE="-I${RTLD_NOLOAD_DIR}/include"
  15013. fi
  15014. CPPFLAGS="${CPPFLAGS} ${RTLD_NOLOAD_INCLUDE}"
  15015. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15016. /* end confdefs.h. */
  15017. #include <dlfcn.h>
  15018. int
  15019. main ()
  15020. {
  15021. #if defined(RTLD_NOLOAD)
  15022. int foo = 0;
  15023. #else
  15024. int foo = bar;
  15025. #endif
  15026. 0
  15027. ;
  15028. return 0;
  15029. }
  15030. _ACEOF
  15031. if ac_fn_c_try_compile "$LINENO"; then :
  15032. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  15033. $as_echo "yes" >&6; }
  15034. PBX_RTLD_NOLOAD=1
  15035. $as_echo "#define HAVE_RTLD_NOLOAD 1" >>confdefs.h
  15036. else
  15037. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15038. $as_echo "no" >&6; }
  15039. fi
  15040. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  15041. CPPFLAGS="${saved_cppflags}"
  15042. fi
  15043. if test "x${PBX_IP_MTU_DISCOVER}" != "x1"; then
  15044. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IP_MTU_DISCOVER in netinet/in.h" >&5
  15045. $as_echo_n "checking for IP_MTU_DISCOVER in netinet/in.h... " >&6; }
  15046. saved_cppflags="${CPPFLAGS}"
  15047. if test "x${IP_MTU_DISCOVER_DIR}" != "x"; then
  15048. IP_MTU_DISCOVER_INCLUDE="-I${IP_MTU_DISCOVER_DIR}/include"
  15049. fi
  15050. CPPFLAGS="${CPPFLAGS} ${IP_MTU_DISCOVER_INCLUDE}"
  15051. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15052. /* end confdefs.h. */
  15053. #include <netinet/in.h>
  15054. int
  15055. main ()
  15056. {
  15057. #if defined(IP_MTU_DISCOVER)
  15058. int foo = 0;
  15059. #else
  15060. int foo = bar;
  15061. #endif
  15062. 0
  15063. ;
  15064. return 0;
  15065. }
  15066. _ACEOF
  15067. if ac_fn_c_try_compile "$LINENO"; then :
  15068. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  15069. $as_echo "yes" >&6; }
  15070. PBX_IP_MTU_DISCOVER=1
  15071. $as_echo "#define HAVE_IP_MTU_DISCOVER 1" >>confdefs.h
  15072. else
  15073. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15074. $as_echo "no" >&6; }
  15075. fi
  15076. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  15077. CPPFLAGS="${saved_cppflags}"
  15078. fi
  15079. ac_fn_c_check_header_mongrel "$LINENO" "libkern/OSAtomic.h" "ac_cv_header_libkern_OSAtomic_h" "$ac_includes_default"
  15080. if test "x$ac_cv_header_libkern_OSAtomic_h" = xyes; then :
  15081. cat >>confdefs.h <<_ACEOF
  15082. #define HAVE_OSX_ATOMICS 1
  15083. _ACEOF
  15084. fi
  15085. # The cast to long int works around a bug in the HP C Compiler
  15086. # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
  15087. # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
  15088. # This bug is HP SR number 8606223364.
  15089. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
  15090. $as_echo_n "checking size of int... " >&6; }
  15091. if ${ac_cv_sizeof_int+:} false; then :
  15092. $as_echo_n "(cached) " >&6
  15093. else
  15094. if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then :
  15095. else
  15096. if test "$ac_cv_type_int" = yes; then
  15097. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  15098. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  15099. as_fn_error 77 "cannot compute sizeof (int)
  15100. See \`config.log' for more details" "$LINENO" 5; }
  15101. else
  15102. ac_cv_sizeof_int=0
  15103. fi
  15104. fi
  15105. fi
  15106. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
  15107. $as_echo "$ac_cv_sizeof_int" >&6; }
  15108. cat >>confdefs.h <<_ACEOF
  15109. #define SIZEOF_INT $ac_cv_sizeof_int
  15110. _ACEOF
  15111. # The cast to long int works around a bug in the HP C Compiler
  15112. # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
  15113. # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
  15114. # This bug is HP SR number 8606223364.
  15115. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
  15116. $as_echo_n "checking size of long... " >&6; }
  15117. if ${ac_cv_sizeof_long+:} false; then :
  15118. $as_echo_n "(cached) " >&6
  15119. else
  15120. if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then :
  15121. else
  15122. if test "$ac_cv_type_long" = yes; then
  15123. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  15124. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  15125. as_fn_error 77 "cannot compute sizeof (long)
  15126. See \`config.log' for more details" "$LINENO" 5; }
  15127. else
  15128. ac_cv_sizeof_long=0
  15129. fi
  15130. fi
  15131. fi
  15132. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
  15133. $as_echo "$ac_cv_sizeof_long" >&6; }
  15134. cat >>confdefs.h <<_ACEOF
  15135. #define SIZEOF_LONG $ac_cv_sizeof_long
  15136. _ACEOF
  15137. # The cast to long int works around a bug in the HP C Compiler
  15138. # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
  15139. # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
  15140. # This bug is HP SR number 8606223364.
  15141. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
  15142. $as_echo_n "checking size of long long... " >&6; }
  15143. if ${ac_cv_sizeof_long_long+:} false; then :
  15144. $as_echo_n "(cached) " >&6
  15145. else
  15146. if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then :
  15147. else
  15148. if test "$ac_cv_type_long_long" = yes; then
  15149. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  15150. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  15151. as_fn_error 77 "cannot compute sizeof (long long)
  15152. See \`config.log' for more details" "$LINENO" 5; }
  15153. else
  15154. ac_cv_sizeof_long_long=0
  15155. fi
  15156. fi
  15157. fi
  15158. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
  15159. $as_echo "$ac_cv_sizeof_long_long" >&6; }
  15160. cat >>confdefs.h <<_ACEOF
  15161. #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
  15162. _ACEOF
  15163. # The cast to long int works around a bug in the HP C Compiler
  15164. # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
  15165. # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
  15166. # This bug is HP SR number 8606223364.
  15167. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char *" >&5
  15168. $as_echo_n "checking size of char *... " >&6; }
  15169. if ${ac_cv_sizeof_char_p+:} false; then :
  15170. $as_echo_n "(cached) " >&6
  15171. else
  15172. if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char *))" "ac_cv_sizeof_char_p" "$ac_includes_default"; then :
  15173. else
  15174. if test "$ac_cv_type_char_p" = yes; then
  15175. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  15176. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  15177. as_fn_error 77 "cannot compute sizeof (char *)
  15178. See \`config.log' for more details" "$LINENO" 5; }
  15179. else
  15180. ac_cv_sizeof_char_p=0
  15181. fi
  15182. fi
  15183. fi
  15184. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_char_p" >&5
  15185. $as_echo "$ac_cv_sizeof_char_p" >&6; }
  15186. cat >>confdefs.h <<_ACEOF
  15187. #define SIZEOF_CHAR_P $ac_cv_sizeof_char_p
  15188. _ACEOF
  15189. # The cast to long int works around a bug in the HP C Compiler
  15190. # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
  15191. # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
  15192. # This bug is HP SR number 8606223364.
  15193. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
  15194. $as_echo_n "checking size of long... " >&6; }
  15195. if ${ac_cv_sizeof_long+:} false; then :
  15196. $as_echo_n "(cached) " >&6
  15197. else
  15198. if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then :
  15199. else
  15200. if test "$ac_cv_type_long" = yes; then
  15201. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  15202. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  15203. as_fn_error 77 "cannot compute sizeof (long)
  15204. See \`config.log' for more details" "$LINENO" 5; }
  15205. else
  15206. ac_cv_sizeof_long=0
  15207. fi
  15208. fi
  15209. fi
  15210. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
  15211. $as_echo "$ac_cv_sizeof_long" >&6; }
  15212. cat >>confdefs.h <<_ACEOF
  15213. #define SIZEOF_LONG $ac_cv_sizeof_long
  15214. _ACEOF
  15215. # The cast to long int works around a bug in the HP C Compiler
  15216. # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
  15217. # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
  15218. # This bug is HP SR number 8606223364.
  15219. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
  15220. $as_echo_n "checking size of long long... " >&6; }
  15221. if ${ac_cv_sizeof_long_long+:} false; then :
  15222. $as_echo_n "(cached) " >&6
  15223. else
  15224. if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then :
  15225. else
  15226. if test "$ac_cv_type_long_long" = yes; then
  15227. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  15228. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  15229. as_fn_error 77 "cannot compute sizeof (long long)
  15230. See \`config.log' for more details" "$LINENO" 5; }
  15231. else
  15232. ac_cv_sizeof_long_long=0
  15233. fi
  15234. fi
  15235. fi
  15236. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
  15237. $as_echo "$ac_cv_sizeof_long_long" >&6; }
  15238. cat >>confdefs.h <<_ACEOF
  15239. #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
  15240. _ACEOF
  15241. if ac_fn_c_compute_int "$LINENO" "sizeof(foo.fds_bits[0])" "ac_cv_sizeof_fd_set_fds_bits" "$ac_includes_default
  15242. fd_set foo;"; then :
  15243. fi
  15244. # This doesn't actually work; what it does is to use the variable set in the
  15245. # previous test as a cached value to set the right output variables.
  15246. # The cast to long int works around a bug in the HP C Compiler
  15247. # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
  15248. # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
  15249. # This bug is HP SR number 8606223364.
  15250. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of fd_set.fds_bits" >&5
  15251. $as_echo_n "checking size of fd_set.fds_bits... " >&6; }
  15252. if ${ac_cv_sizeof_fd_set_fds_bits+:} false; then :
  15253. $as_echo_n "(cached) " >&6
  15254. else
  15255. if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (fd_set.fds_bits))" "ac_cv_sizeof_fd_set_fds_bits" "$ac_includes_default"; then :
  15256. else
  15257. if test "$ac_cv_type_fd_set_fds_bits" = yes; then
  15258. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  15259. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  15260. as_fn_error 77 "cannot compute sizeof (fd_set.fds_bits)
  15261. See \`config.log' for more details" "$LINENO" 5; }
  15262. else
  15263. ac_cv_sizeof_fd_set_fds_bits=0
  15264. fi
  15265. fi
  15266. fi
  15267. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_fd_set_fds_bits" >&5
  15268. $as_echo "$ac_cv_sizeof_fd_set_fds_bits" >&6; }
  15269. cat >>confdefs.h <<_ACEOF
  15270. #define SIZEOF_FD_SET_FDS_BITS $ac_cv_sizeof_fd_set_fds_bits
  15271. _ACEOF
  15272. # Set a type compatible with the previous. We cannot just use a generic type
  15273. # for these bits, because on big-endian systems, the bits won't match up
  15274. # correctly if the size is wrong.
  15275. if test $ac_cv_sizeof_int = $ac_cv_sizeof_fd_set_fds_bits; then
  15276. $as_echo "#define TYPEOF_FD_SET_FDS_BITS int" >>confdefs.h
  15277. else if test $ac_cv_sizeof_long = $ac_cv_sizeof_fd_set_fds_bits; then
  15278. $as_echo "#define TYPEOF_FD_SET_FDS_BITS long" >>confdefs.h
  15279. else if test $ac_cv_sizeof_long_long = $ac_cv_sizeof_fd_set_fds_bits; then
  15280. $as_echo "#define TYPEOF_FD_SET_FDS_BITS long long" >>confdefs.h
  15281. fi ; fi ; fi
  15282. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dladdr in dlfcn.h" >&5
  15283. $as_echo_n "checking for dladdr in dlfcn.h... " >&6; }
  15284. PBX_DLADDR=0
  15285. old_LIBS=${LIBS}
  15286. LIBS="${LIBS} -ldl"
  15287. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15288. /* end confdefs.h. */
  15289. #define _GNU_SOURCE 1
  15290. #include <dlfcn.h>
  15291. int
  15292. main ()
  15293. {
  15294. dladdr((void *)0, (void *)0)
  15295. ;
  15296. return 0;
  15297. }
  15298. _ACEOF
  15299. if ac_fn_c_try_link "$LINENO"; then :
  15300. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  15301. $as_echo "yes" >&6; }
  15302. PBX_DLADDR=1
  15303. $as_echo "#define HAVE_DLADDR 1" >>confdefs.h
  15304. else
  15305. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15306. $as_echo "no" >&6; }
  15307. fi
  15308. rm -f core conftest.err conftest.$ac_objext \
  15309. conftest$ac_exeext conftest.$ac_ext
  15310. LIBS=${old_LIBS}
  15311. # PKGCONFIG is used in later tests
  15312. if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
  15313. if test -n "$ac_tool_prefix"; then
  15314. # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
  15315. set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
  15316. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  15317. $as_echo_n "checking for $ac_word... " >&6; }
  15318. if ${ac_cv_path_PKG_CONFIG+:} false; then :
  15319. $as_echo_n "(cached) " >&6
  15320. else
  15321. case $PKG_CONFIG in
  15322. [\\/]* | ?:[\\/]*)
  15323. ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
  15324. ;;
  15325. *)
  15326. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  15327. for as_dir in $PATH
  15328. do
  15329. IFS=$as_save_IFS
  15330. test -z "$as_dir" && as_dir=.
  15331. for ac_exec_ext in '' $ac_executable_extensions; do
  15332. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  15333. ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
  15334. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  15335. break 2
  15336. fi
  15337. done
  15338. done
  15339. IFS=$as_save_IFS
  15340. ;;
  15341. esac
  15342. fi
  15343. PKG_CONFIG=$ac_cv_path_PKG_CONFIG
  15344. if test -n "$PKG_CONFIG"; then
  15345. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
  15346. $as_echo "$PKG_CONFIG" >&6; }
  15347. else
  15348. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15349. $as_echo "no" >&6; }
  15350. fi
  15351. fi
  15352. if test -z "$ac_cv_path_PKG_CONFIG"; then
  15353. ac_pt_PKG_CONFIG=$PKG_CONFIG
  15354. # Extract the first word of "pkg-config", so it can be a program name with args.
  15355. set dummy pkg-config; ac_word=$2
  15356. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  15357. $as_echo_n "checking for $ac_word... " >&6; }
  15358. if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
  15359. $as_echo_n "(cached) " >&6
  15360. else
  15361. case $ac_pt_PKG_CONFIG in
  15362. [\\/]* | ?:[\\/]*)
  15363. ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
  15364. ;;
  15365. *)
  15366. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  15367. for as_dir in $PATH
  15368. do
  15369. IFS=$as_save_IFS
  15370. test -z "$as_dir" && as_dir=.
  15371. for ac_exec_ext in '' $ac_executable_extensions; do
  15372. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  15373. ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
  15374. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  15375. break 2
  15376. fi
  15377. done
  15378. done
  15379. IFS=$as_save_IFS
  15380. ;;
  15381. esac
  15382. fi
  15383. ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
  15384. if test -n "$ac_pt_PKG_CONFIG"; then
  15385. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
  15386. $as_echo "$ac_pt_PKG_CONFIG" >&6; }
  15387. else
  15388. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15389. $as_echo "no" >&6; }
  15390. fi
  15391. if test "x$ac_pt_PKG_CONFIG" = x; then
  15392. PKG_CONFIG=""
  15393. else
  15394. case $cross_compiling:$ac_tool_warned in
  15395. yes:)
  15396. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  15397. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  15398. ac_tool_warned=yes ;;
  15399. esac
  15400. PKG_CONFIG=$ac_pt_PKG_CONFIG
  15401. fi
  15402. else
  15403. PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
  15404. fi
  15405. fi
  15406. if test -n "$PKG_CONFIG"; then
  15407. _pkg_min_version=0.9.0
  15408. { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
  15409. $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
  15410. if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
  15411. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  15412. $as_echo "yes" >&6; }
  15413. else
  15414. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15415. $as_echo "no" >&6; }
  15416. PKG_CONFIG=""
  15417. fi
  15418. fi
  15419. # do the package library checks now
  15420. if test "x${PBX_ALSA}" != "x1" -a "${USE_ALSA}" != "no"; then
  15421. pbxlibdir=""
  15422. # if --with-ALSA=DIR has been specified, use it.
  15423. if test "x${ALSA_DIR}" != "x"; then
  15424. if test -d ${ALSA_DIR}/lib; then
  15425. pbxlibdir="-L${ALSA_DIR}/lib"
  15426. else
  15427. pbxlibdir="-L${ALSA_DIR}"
  15428. fi
  15429. fi
  15430. pbxfuncname="snd_spcm_init"
  15431. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  15432. AST_ALSA_FOUND=yes
  15433. else
  15434. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  15435. CFLAGS="${CFLAGS} "
  15436. as_ac_Lib=`$as_echo "ac_cv_lib_asound_${pbxfuncname}" | $as_tr_sh`
  15437. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lasound" >&5
  15438. $as_echo_n "checking for ${pbxfuncname} in -lasound... " >&6; }
  15439. if eval \${$as_ac_Lib+:} false; then :
  15440. $as_echo_n "(cached) " >&6
  15441. else
  15442. ac_check_lib_save_LIBS=$LIBS
  15443. LIBS="-lasound ${pbxlibdir} -lm -ldl $LIBS"
  15444. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15445. /* end confdefs.h. */
  15446. /* Override any GCC internal prototype to avoid an error.
  15447. Use char because int might match the return type of a GCC
  15448. builtin and then its argument prototype would still apply. */
  15449. #ifdef __cplusplus
  15450. extern "C"
  15451. #endif
  15452. char ${pbxfuncname} ();
  15453. int
  15454. main ()
  15455. {
  15456. return ${pbxfuncname} ();
  15457. ;
  15458. return 0;
  15459. }
  15460. _ACEOF
  15461. if ac_fn_c_try_link "$LINENO"; then :
  15462. eval "$as_ac_Lib=yes"
  15463. else
  15464. eval "$as_ac_Lib=no"
  15465. fi
  15466. rm -f core conftest.err conftest.$ac_objext \
  15467. conftest$ac_exeext conftest.$ac_ext
  15468. LIBS=$ac_check_lib_save_LIBS
  15469. fi
  15470. eval ac_res=\$$as_ac_Lib
  15471. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  15472. $as_echo "$ac_res" >&6; }
  15473. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  15474. AST_ALSA_FOUND=yes
  15475. else
  15476. AST_ALSA_FOUND=no
  15477. fi
  15478. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  15479. fi
  15480. # now check for the header.
  15481. if test "${AST_ALSA_FOUND}" = "yes"; then
  15482. ALSA_LIB="${pbxlibdir} -lasound -lm -ldl"
  15483. # if --with-ALSA=DIR has been specified, use it.
  15484. if test "x${ALSA_DIR}" != "x"; then
  15485. ALSA_INCLUDE="-I${ALSA_DIR}/include"
  15486. fi
  15487. ALSA_INCLUDE="${ALSA_INCLUDE} "
  15488. if test "xalsa/asoundlib.h" = "x" ; then # no header, assume found
  15489. ALSA_HEADER_FOUND="1"
  15490. else # check for the header
  15491. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  15492. CPPFLAGS="${CPPFLAGS} ${ALSA_INCLUDE}"
  15493. ac_fn_c_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default"
  15494. if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then :
  15495. ALSA_HEADER_FOUND=1
  15496. else
  15497. ALSA_HEADER_FOUND=0
  15498. fi
  15499. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  15500. fi
  15501. if test "x${ALSA_HEADER_FOUND}" = "x0" ; then
  15502. ALSA_LIB=""
  15503. ALSA_INCLUDE=""
  15504. else
  15505. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  15506. ALSA_LIB=""
  15507. fi
  15508. PBX_ALSA=1
  15509. cat >>confdefs.h <<_ACEOF
  15510. #define HAVE_ALSA 1
  15511. _ACEOF
  15512. fi
  15513. fi
  15514. fi
  15515. if test "x${PBX_BFD}" != "x1" -a "${USE_BFD}" != "no"; then
  15516. pbxlibdir=""
  15517. # if --with-BFD=DIR has been specified, use it.
  15518. if test "x${BFD_DIR}" != "x"; then
  15519. if test -d ${BFD_DIR}/lib; then
  15520. pbxlibdir="-L${BFD_DIR}/lib"
  15521. else
  15522. pbxlibdir="-L${BFD_DIR}"
  15523. fi
  15524. fi
  15525. pbxfuncname="bfd_openr"
  15526. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  15527. AST_BFD_FOUND=yes
  15528. else
  15529. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  15530. CFLAGS="${CFLAGS} "
  15531. as_ac_Lib=`$as_echo "ac_cv_lib_bfd_${pbxfuncname}" | $as_tr_sh`
  15532. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lbfd" >&5
  15533. $as_echo_n "checking for ${pbxfuncname} in -lbfd... " >&6; }
  15534. if eval \${$as_ac_Lib+:} false; then :
  15535. $as_echo_n "(cached) " >&6
  15536. else
  15537. ac_check_lib_save_LIBS=$LIBS
  15538. LIBS="-lbfd ${pbxlibdir} $LIBS"
  15539. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15540. /* end confdefs.h. */
  15541. /* Override any GCC internal prototype to avoid an error.
  15542. Use char because int might match the return type of a GCC
  15543. builtin and then its argument prototype would still apply. */
  15544. #ifdef __cplusplus
  15545. extern "C"
  15546. #endif
  15547. char ${pbxfuncname} ();
  15548. int
  15549. main ()
  15550. {
  15551. return ${pbxfuncname} ();
  15552. ;
  15553. return 0;
  15554. }
  15555. _ACEOF
  15556. if ac_fn_c_try_link "$LINENO"; then :
  15557. eval "$as_ac_Lib=yes"
  15558. else
  15559. eval "$as_ac_Lib=no"
  15560. fi
  15561. rm -f core conftest.err conftest.$ac_objext \
  15562. conftest$ac_exeext conftest.$ac_ext
  15563. LIBS=$ac_check_lib_save_LIBS
  15564. fi
  15565. eval ac_res=\$$as_ac_Lib
  15566. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  15567. $as_echo "$ac_res" >&6; }
  15568. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  15569. AST_BFD_FOUND=yes
  15570. else
  15571. AST_BFD_FOUND=no
  15572. fi
  15573. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  15574. fi
  15575. # now check for the header.
  15576. if test "${AST_BFD_FOUND}" = "yes"; then
  15577. BFD_LIB="${pbxlibdir} -lbfd "
  15578. # if --with-BFD=DIR has been specified, use it.
  15579. if test "x${BFD_DIR}" != "x"; then
  15580. BFD_INCLUDE="-I${BFD_DIR}/include"
  15581. fi
  15582. BFD_INCLUDE="${BFD_INCLUDE} "
  15583. if test "xbfd.h" = "x" ; then # no header, assume found
  15584. BFD_HEADER_FOUND="1"
  15585. else # check for the header
  15586. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  15587. CPPFLAGS="${CPPFLAGS} ${BFD_INCLUDE}"
  15588. ac_fn_c_check_header_mongrel "$LINENO" "bfd.h" "ac_cv_header_bfd_h" "$ac_includes_default"
  15589. if test "x$ac_cv_header_bfd_h" = xyes; then :
  15590. BFD_HEADER_FOUND=1
  15591. else
  15592. BFD_HEADER_FOUND=0
  15593. fi
  15594. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  15595. fi
  15596. if test "x${BFD_HEADER_FOUND}" = "x0" ; then
  15597. BFD_LIB=""
  15598. BFD_INCLUDE=""
  15599. else
  15600. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  15601. BFD_LIB=""
  15602. fi
  15603. PBX_BFD=1
  15604. cat >>confdefs.h <<_ACEOF
  15605. #define HAVE_BFD 1
  15606. _ACEOF
  15607. fi
  15608. fi
  15609. fi
  15610. if test "${PBX_BFD}" = "0"; then
  15611. # Fedora/RedHat/CentOS require extra libraries
  15612. if test "x${PBX_BFD}" != "x1" -a "${USE_BFD}" != "no"; then
  15613. pbxlibdir=""
  15614. # if --with-BFD=DIR has been specified, use it.
  15615. if test "x${BFD_DIR}" != "x"; then
  15616. if test -d ${BFD_DIR}/lib; then
  15617. pbxlibdir="-L${BFD_DIR}/lib"
  15618. else
  15619. pbxlibdir="-L${BFD_DIR}"
  15620. fi
  15621. fi
  15622. pbxfuncname="bfd_check_format"
  15623. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  15624. AST_BFD_FOUND=yes
  15625. else
  15626. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  15627. CFLAGS="${CFLAGS} "
  15628. as_ac_Lib=`$as_echo "ac_cv_lib_bfd_${pbxfuncname}" | $as_tr_sh`
  15629. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lbfd" >&5
  15630. $as_echo_n "checking for ${pbxfuncname} in -lbfd... " >&6; }
  15631. if eval \${$as_ac_Lib+:} false; then :
  15632. $as_echo_n "(cached) " >&6
  15633. else
  15634. ac_check_lib_save_LIBS=$LIBS
  15635. LIBS="-lbfd ${pbxlibdir} -ldl -liberty $LIBS"
  15636. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15637. /* end confdefs.h. */
  15638. /* Override any GCC internal prototype to avoid an error.
  15639. Use char because int might match the return type of a GCC
  15640. builtin and then its argument prototype would still apply. */
  15641. #ifdef __cplusplus
  15642. extern "C"
  15643. #endif
  15644. char ${pbxfuncname} ();
  15645. int
  15646. main ()
  15647. {
  15648. return ${pbxfuncname} ();
  15649. ;
  15650. return 0;
  15651. }
  15652. _ACEOF
  15653. if ac_fn_c_try_link "$LINENO"; then :
  15654. eval "$as_ac_Lib=yes"
  15655. else
  15656. eval "$as_ac_Lib=no"
  15657. fi
  15658. rm -f core conftest.err conftest.$ac_objext \
  15659. conftest$ac_exeext conftest.$ac_ext
  15660. LIBS=$ac_check_lib_save_LIBS
  15661. fi
  15662. eval ac_res=\$$as_ac_Lib
  15663. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  15664. $as_echo "$ac_res" >&6; }
  15665. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  15666. AST_BFD_FOUND=yes
  15667. else
  15668. AST_BFD_FOUND=no
  15669. fi
  15670. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  15671. fi
  15672. # now check for the header.
  15673. if test "${AST_BFD_FOUND}" = "yes"; then
  15674. BFD_LIB="${pbxlibdir} -lbfd -ldl -liberty"
  15675. # if --with-BFD=DIR has been specified, use it.
  15676. if test "x${BFD_DIR}" != "x"; then
  15677. BFD_INCLUDE="-I${BFD_DIR}/include"
  15678. fi
  15679. BFD_INCLUDE="${BFD_INCLUDE} "
  15680. if test "xbfd.h" = "x" ; then # no header, assume found
  15681. BFD_HEADER_FOUND="1"
  15682. else # check for the header
  15683. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  15684. CPPFLAGS="${CPPFLAGS} ${BFD_INCLUDE}"
  15685. ac_fn_c_check_header_mongrel "$LINENO" "bfd.h" "ac_cv_header_bfd_h" "$ac_includes_default"
  15686. if test "x$ac_cv_header_bfd_h" = xyes; then :
  15687. BFD_HEADER_FOUND=1
  15688. else
  15689. BFD_HEADER_FOUND=0
  15690. fi
  15691. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  15692. fi
  15693. if test "x${BFD_HEADER_FOUND}" = "x0" ; then
  15694. BFD_LIB=""
  15695. BFD_INCLUDE=""
  15696. else
  15697. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  15698. BFD_LIB=""
  15699. fi
  15700. PBX_BFD=1
  15701. cat >>confdefs.h <<_ACEOF
  15702. #define HAVE_BFD 1
  15703. _ACEOF
  15704. fi
  15705. fi
  15706. fi
  15707. fi
  15708. if test "${PBX_BFD}" = "0"; then
  15709. # openSUSE requires -lz
  15710. if test "x${PBX_BFD}" != "x1" -a "${USE_BFD}" != "no"; then
  15711. pbxlibdir=""
  15712. # if --with-BFD=DIR has been specified, use it.
  15713. if test "x${BFD_DIR}" != "x"; then
  15714. if test -d ${BFD_DIR}/lib; then
  15715. pbxlibdir="-L${BFD_DIR}/lib"
  15716. else
  15717. pbxlibdir="-L${BFD_DIR}"
  15718. fi
  15719. fi
  15720. pbxfuncname="bfd_check_format"
  15721. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  15722. AST_BFD_FOUND=yes
  15723. else
  15724. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  15725. CFLAGS="${CFLAGS} "
  15726. as_ac_Lib=`$as_echo "ac_cv_lib_bfd_${pbxfuncname}" | $as_tr_sh`
  15727. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lbfd" >&5
  15728. $as_echo_n "checking for ${pbxfuncname} in -lbfd... " >&6; }
  15729. if eval \${$as_ac_Lib+:} false; then :
  15730. $as_echo_n "(cached) " >&6
  15731. else
  15732. ac_check_lib_save_LIBS=$LIBS
  15733. LIBS="-lbfd ${pbxlibdir} -ldl -liberty -lz $LIBS"
  15734. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15735. /* end confdefs.h. */
  15736. /* Override any GCC internal prototype to avoid an error.
  15737. Use char because int might match the return type of a GCC
  15738. builtin and then its argument prototype would still apply. */
  15739. #ifdef __cplusplus
  15740. extern "C"
  15741. #endif
  15742. char ${pbxfuncname} ();
  15743. int
  15744. main ()
  15745. {
  15746. return ${pbxfuncname} ();
  15747. ;
  15748. return 0;
  15749. }
  15750. _ACEOF
  15751. if ac_fn_c_try_link "$LINENO"; then :
  15752. eval "$as_ac_Lib=yes"
  15753. else
  15754. eval "$as_ac_Lib=no"
  15755. fi
  15756. rm -f core conftest.err conftest.$ac_objext \
  15757. conftest$ac_exeext conftest.$ac_ext
  15758. LIBS=$ac_check_lib_save_LIBS
  15759. fi
  15760. eval ac_res=\$$as_ac_Lib
  15761. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  15762. $as_echo "$ac_res" >&6; }
  15763. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  15764. AST_BFD_FOUND=yes
  15765. else
  15766. AST_BFD_FOUND=no
  15767. fi
  15768. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  15769. fi
  15770. # now check for the header.
  15771. if test "${AST_BFD_FOUND}" = "yes"; then
  15772. BFD_LIB="${pbxlibdir} -lbfd -ldl -liberty -lz"
  15773. # if --with-BFD=DIR has been specified, use it.
  15774. if test "x${BFD_DIR}" != "x"; then
  15775. BFD_INCLUDE="-I${BFD_DIR}/include"
  15776. fi
  15777. BFD_INCLUDE="${BFD_INCLUDE} "
  15778. if test "xbfd.h" = "x" ; then # no header, assume found
  15779. BFD_HEADER_FOUND="1"
  15780. else # check for the header
  15781. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  15782. CPPFLAGS="${CPPFLAGS} ${BFD_INCLUDE}"
  15783. ac_fn_c_check_header_mongrel "$LINENO" "bfd.h" "ac_cv_header_bfd_h" "$ac_includes_default"
  15784. if test "x$ac_cv_header_bfd_h" = xyes; then :
  15785. BFD_HEADER_FOUND=1
  15786. else
  15787. BFD_HEADER_FOUND=0
  15788. fi
  15789. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  15790. fi
  15791. if test "x${BFD_HEADER_FOUND}" = "x0" ; then
  15792. BFD_LIB=""
  15793. BFD_INCLUDE=""
  15794. else
  15795. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  15796. BFD_LIB=""
  15797. fi
  15798. PBX_BFD=1
  15799. cat >>confdefs.h <<_ACEOF
  15800. #define HAVE_BFD 1
  15801. _ACEOF
  15802. fi
  15803. fi
  15804. fi
  15805. fi
  15806. if test "x${OSARCH}" = "xlinux-gnu" ; then
  15807. if test "x${PBX_CAP}" != "x1" -a "${USE_CAP}" != "no"; then
  15808. pbxlibdir=""
  15809. # if --with-CAP=DIR has been specified, use it.
  15810. if test "x${CAP_DIR}" != "x"; then
  15811. if test -d ${CAP_DIR}/lib; then
  15812. pbxlibdir="-L${CAP_DIR}/lib"
  15813. else
  15814. pbxlibdir="-L${CAP_DIR}"
  15815. fi
  15816. fi
  15817. pbxfuncname="cap_from_text"
  15818. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  15819. AST_CAP_FOUND=yes
  15820. else
  15821. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  15822. CFLAGS="${CFLAGS} "
  15823. as_ac_Lib=`$as_echo "ac_cv_lib_cap_${pbxfuncname}" | $as_tr_sh`
  15824. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lcap" >&5
  15825. $as_echo_n "checking for ${pbxfuncname} in -lcap... " >&6; }
  15826. if eval \${$as_ac_Lib+:} false; then :
  15827. $as_echo_n "(cached) " >&6
  15828. else
  15829. ac_check_lib_save_LIBS=$LIBS
  15830. LIBS="-lcap ${pbxlibdir} $LIBS"
  15831. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15832. /* end confdefs.h. */
  15833. /* Override any GCC internal prototype to avoid an error.
  15834. Use char because int might match the return type of a GCC
  15835. builtin and then its argument prototype would still apply. */
  15836. #ifdef __cplusplus
  15837. extern "C"
  15838. #endif
  15839. char ${pbxfuncname} ();
  15840. int
  15841. main ()
  15842. {
  15843. return ${pbxfuncname} ();
  15844. ;
  15845. return 0;
  15846. }
  15847. _ACEOF
  15848. if ac_fn_c_try_link "$LINENO"; then :
  15849. eval "$as_ac_Lib=yes"
  15850. else
  15851. eval "$as_ac_Lib=no"
  15852. fi
  15853. rm -f core conftest.err conftest.$ac_objext \
  15854. conftest$ac_exeext conftest.$ac_ext
  15855. LIBS=$ac_check_lib_save_LIBS
  15856. fi
  15857. eval ac_res=\$$as_ac_Lib
  15858. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  15859. $as_echo "$ac_res" >&6; }
  15860. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  15861. AST_CAP_FOUND=yes
  15862. else
  15863. AST_CAP_FOUND=no
  15864. fi
  15865. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  15866. fi
  15867. # now check for the header.
  15868. if test "${AST_CAP_FOUND}" = "yes"; then
  15869. CAP_LIB="${pbxlibdir} -lcap "
  15870. # if --with-CAP=DIR has been specified, use it.
  15871. if test "x${CAP_DIR}" != "x"; then
  15872. CAP_INCLUDE="-I${CAP_DIR}/include"
  15873. fi
  15874. CAP_INCLUDE="${CAP_INCLUDE} "
  15875. if test "xsys/capability.h" = "x" ; then # no header, assume found
  15876. CAP_HEADER_FOUND="1"
  15877. else # check for the header
  15878. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  15879. CPPFLAGS="${CPPFLAGS} ${CAP_INCLUDE}"
  15880. ac_fn_c_check_header_mongrel "$LINENO" "sys/capability.h" "ac_cv_header_sys_capability_h" "$ac_includes_default"
  15881. if test "x$ac_cv_header_sys_capability_h" = xyes; then :
  15882. CAP_HEADER_FOUND=1
  15883. else
  15884. CAP_HEADER_FOUND=0
  15885. fi
  15886. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  15887. fi
  15888. if test "x${CAP_HEADER_FOUND}" = "x0" ; then
  15889. CAP_LIB=""
  15890. CAP_INCLUDE=""
  15891. else
  15892. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  15893. CAP_LIB=""
  15894. fi
  15895. PBX_CAP=1
  15896. cat >>confdefs.h <<_ACEOF
  15897. #define HAVE_CAP 1
  15898. _ACEOF
  15899. fi
  15900. fi
  15901. fi
  15902. fi
  15903. if test "x${PBX_DAHDI}" != "x1"; then
  15904. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DAHDI_RESET_COUNTERS in dahdi/user.h" >&5
  15905. $as_echo_n "checking for DAHDI_RESET_COUNTERS in dahdi/user.h... " >&6; }
  15906. saved_cppflags="${CPPFLAGS}"
  15907. if test "x${DAHDI_DIR}" != "x"; then
  15908. DAHDI_INCLUDE="-I${DAHDI_DIR}/include"
  15909. fi
  15910. CPPFLAGS="${CPPFLAGS} ${DAHDI_INCLUDE}"
  15911. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15912. /* end confdefs.h. */
  15913. #include <dahdi/user.h>
  15914. int
  15915. main ()
  15916. {
  15917. #if defined(DAHDI_RESET_COUNTERS)
  15918. int foo = 0;
  15919. #else
  15920. int foo = bar;
  15921. #endif
  15922. 0
  15923. ;
  15924. return 0;
  15925. }
  15926. _ACEOF
  15927. if ac_fn_c_try_compile "$LINENO"; then :
  15928. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  15929. $as_echo "yes" >&6; }
  15930. PBX_DAHDI=1
  15931. $as_echo "#define HAVE_DAHDI 1" >>confdefs.h
  15932. $as_echo "#define HAVE_DAHDI_VERSION 230" >>confdefs.h
  15933. else
  15934. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15935. $as_echo "no" >&6; }
  15936. fi
  15937. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  15938. CPPFLAGS="${saved_cppflags}"
  15939. fi
  15940. if test "x${PBX_DAHDI}" != "x1"; then
  15941. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DAHDI_DEFAULT_MTU_MRU in dahdi/user.h" >&5
  15942. $as_echo_n "checking for DAHDI_DEFAULT_MTU_MRU in dahdi/user.h... " >&6; }
  15943. saved_cppflags="${CPPFLAGS}"
  15944. if test "x${DAHDI_DIR}" != "x"; then
  15945. DAHDI_INCLUDE="-I${DAHDI_DIR}/include"
  15946. fi
  15947. CPPFLAGS="${CPPFLAGS} ${DAHDI_INCLUDE}"
  15948. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15949. /* end confdefs.h. */
  15950. #include <dahdi/user.h>
  15951. int
  15952. main ()
  15953. {
  15954. #if defined(DAHDI_DEFAULT_MTU_MRU)
  15955. int foo = 0;
  15956. #else
  15957. int foo = bar;
  15958. #endif
  15959. 0
  15960. ;
  15961. return 0;
  15962. }
  15963. _ACEOF
  15964. if ac_fn_c_try_compile "$LINENO"; then :
  15965. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  15966. $as_echo "yes" >&6; }
  15967. PBX_DAHDI=1
  15968. $as_echo "#define HAVE_DAHDI 1" >>confdefs.h
  15969. $as_echo "#define HAVE_DAHDI_VERSION 220" >>confdefs.h
  15970. else
  15971. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15972. $as_echo "no" >&6; }
  15973. fi
  15974. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  15975. CPPFLAGS="${saved_cppflags}"
  15976. fi
  15977. if test "x${PBX_DAHDI}" != "x1"; then
  15978. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DAHDI_CODE in dahdi/user.h" >&5
  15979. $as_echo_n "checking for DAHDI_CODE in dahdi/user.h... " >&6; }
  15980. saved_cppflags="${CPPFLAGS}"
  15981. if test "x${DAHDI_DIR}" != "x"; then
  15982. DAHDI_INCLUDE="-I${DAHDI_DIR}/include"
  15983. fi
  15984. CPPFLAGS="${CPPFLAGS} ${DAHDI_INCLUDE}"
  15985. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15986. /* end confdefs.h. */
  15987. #include <dahdi/user.h>
  15988. int
  15989. main ()
  15990. {
  15991. #if defined(DAHDI_CODE)
  15992. int foo = 0;
  15993. #else
  15994. int foo = bar;
  15995. #endif
  15996. 0
  15997. ;
  15998. return 0;
  15999. }
  16000. _ACEOF
  16001. if ac_fn_c_try_compile "$LINENO"; then :
  16002. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16003. $as_echo "yes" >&6; }
  16004. PBX_DAHDI=1
  16005. $as_echo "#define HAVE_DAHDI 1" >>confdefs.h
  16006. $as_echo "#define HAVE_DAHDI_VERSION 200" >>confdefs.h
  16007. else
  16008. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16009. $as_echo "no" >&6; }
  16010. fi
  16011. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  16012. CPPFLAGS="${saved_cppflags}"
  16013. fi
  16014. if test "x${PBX_DAHDI_HALF_FULL}" != "x1"; then
  16015. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DAHDI_POLICY_HALF_FULL in dahdi/user.h" >&5
  16016. $as_echo_n "checking for DAHDI_POLICY_HALF_FULL in dahdi/user.h... " >&6; }
  16017. saved_cppflags="${CPPFLAGS}"
  16018. if test "x${DAHDI_HALF_FULL_DIR}" != "x"; then
  16019. DAHDI_HALF_FULL_INCLUDE="-I${DAHDI_HALF_FULL_DIR}/include"
  16020. fi
  16021. CPPFLAGS="${CPPFLAGS} ${DAHDI_HALF_FULL_INCLUDE}"
  16022. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16023. /* end confdefs.h. */
  16024. #include <dahdi/user.h>
  16025. int
  16026. main ()
  16027. {
  16028. #if defined(DAHDI_POLICY_HALF_FULL)
  16029. int foo = 0;
  16030. #else
  16031. int foo = bar;
  16032. #endif
  16033. 0
  16034. ;
  16035. return 0;
  16036. }
  16037. _ACEOF
  16038. if ac_fn_c_try_compile "$LINENO"; then :
  16039. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16040. $as_echo "yes" >&6; }
  16041. PBX_DAHDI_HALF_FULL=1
  16042. $as_echo "#define HAVE_DAHDI_HALF_FULL 1" >>confdefs.h
  16043. else
  16044. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16045. $as_echo "no" >&6; }
  16046. fi
  16047. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  16048. CPPFLAGS="${saved_cppflags}"
  16049. fi
  16050. if test "x${PBX_DAHDI_LINEREVERSE_VMWI}" != "x1" -a "${USE_DAHDI_LINEREVERSE_VMWI}" != "no"; then
  16051. if test "xenhanced dahdi vmwi support" != "x"; then
  16052. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for enhanced dahdi vmwi support" >&5
  16053. $as_echo_n "checking for enhanced dahdi vmwi support... " >&6; }
  16054. else
  16055. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if \"struct dahdi_vmwi_info booger\" compiles using dahdi/user.h" >&5
  16056. $as_echo_n "checking if \"struct dahdi_vmwi_info booger\" compiles using dahdi/user.h... " >&6; }
  16057. fi
  16058. saved_cppflags="${CPPFLAGS}"
  16059. if test "x${DAHDI_LINEREVERSE_VMWI_DIR}" != "x"; then
  16060. DAHDI_LINEREVERSE_VMWI_INCLUDE="-I${DAHDI_LINEREVERSE_VMWI_DIR}/include"
  16061. fi
  16062. CPPFLAGS="${CPPFLAGS} ${DAHDI_LINEREVERSE_VMWI_INCLUDE}"
  16063. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16064. /* end confdefs.h. */
  16065. #include <dahdi/user.h>
  16066. int
  16067. main ()
  16068. {
  16069. struct dahdi_vmwi_info booger;
  16070. ;
  16071. return 0;
  16072. }
  16073. _ACEOF
  16074. if ac_fn_c_try_compile "$LINENO"; then :
  16075. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16076. $as_echo "yes" >&6; }
  16077. PBX_DAHDI_LINEREVERSE_VMWI=1
  16078. $as_echo "#define HAVE_DAHDI_LINEREVERSE_VMWI 1" >>confdefs.h
  16079. else
  16080. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16081. $as_echo "no" >&6; }
  16082. fi
  16083. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  16084. CPPFLAGS="${saved_cppflags}"
  16085. fi
  16086. if test "x${PBX_DAHDI_ECHOCANCEL_FAX_MODE}" != "x1" -a "${USE_DAHDI_ECHOCANCEL_FAX_MODE}" != "no"; then
  16087. if test "x" != "x"; then
  16088. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for " >&5
  16089. $as_echo_n "checking for ... " >&6; }
  16090. else
  16091. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if \"int foo = DAHDI_ECHOCANCEL_FAX_MODE\" compiles using dahdi/user.h" >&5
  16092. $as_echo_n "checking if \"int foo = DAHDI_ECHOCANCEL_FAX_MODE\" compiles using dahdi/user.h... " >&6; }
  16093. fi
  16094. saved_cppflags="${CPPFLAGS}"
  16095. if test "x${DAHDI_ECHOCANCEL_FAX_MODE_DIR}" != "x"; then
  16096. DAHDI_ECHOCANCEL_FAX_MODE_INCLUDE="-I${DAHDI_ECHOCANCEL_FAX_MODE_DIR}/include"
  16097. fi
  16098. CPPFLAGS="${CPPFLAGS} ${DAHDI_ECHOCANCEL_FAX_MODE_INCLUDE}"
  16099. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16100. /* end confdefs.h. */
  16101. #include <dahdi/user.h>
  16102. int
  16103. main ()
  16104. {
  16105. int foo = DAHDI_ECHOCANCEL_FAX_MODE;
  16106. ;
  16107. return 0;
  16108. }
  16109. _ACEOF
  16110. if ac_fn_c_try_compile "$LINENO"; then :
  16111. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16112. $as_echo "yes" >&6; }
  16113. PBX_DAHDI_ECHOCANCEL_FAX_MODE=1
  16114. $as_echo "#define HAVE_DAHDI_ECHOCANCEL_FAX_MODE 1" >>confdefs.h
  16115. else
  16116. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16117. $as_echo "no" >&6; }
  16118. fi
  16119. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  16120. CPPFLAGS="${saved_cppflags}"
  16121. fi
  16122. if test "x${PBX_GETIFADDRS}" != "x1" -a "${USE_GETIFADDRS}" != "no"; then
  16123. if test "xgetifaddrs() support" != "x"; then
  16124. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getifaddrs() support" >&5
  16125. $as_echo_n "checking for getifaddrs() support... " >&6; }
  16126. else
  16127. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if \"struct ifaddrs *p; getifaddrs(&p)\" compiles using ifaddrs.h" >&5
  16128. $as_echo_n "checking if \"struct ifaddrs *p; getifaddrs(&p)\" compiles using ifaddrs.h... " >&6; }
  16129. fi
  16130. saved_cppflags="${CPPFLAGS}"
  16131. if test "x${GETIFADDRS_DIR}" != "x"; then
  16132. GETIFADDRS_INCLUDE="-I${GETIFADDRS_DIR}/include"
  16133. fi
  16134. CPPFLAGS="${CPPFLAGS} ${GETIFADDRS_INCLUDE}"
  16135. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16136. /* end confdefs.h. */
  16137. #include <ifaddrs.h>
  16138. int
  16139. main ()
  16140. {
  16141. struct ifaddrs *p; getifaddrs(&p);
  16142. ;
  16143. return 0;
  16144. }
  16145. _ACEOF
  16146. if ac_fn_c_try_compile "$LINENO"; then :
  16147. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16148. $as_echo "yes" >&6; }
  16149. PBX_GETIFADDRS=1
  16150. $as_echo "#define HAVE_GETIFADDRS 1" >>confdefs.h
  16151. else
  16152. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16153. $as_echo "no" >&6; }
  16154. fi
  16155. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  16156. CPPFLAGS="${saved_cppflags}"
  16157. fi
  16158. if test "x${PBX_TIMERFD}" != "x1" -a "${USE_TIMERFD}" != "no"; then
  16159. if test "xtimerfd support" != "x"; then
  16160. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for timerfd support" >&5
  16161. $as_echo_n "checking for timerfd support... " >&6; }
  16162. else
  16163. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if \"timerfd_create(0,0); timerfd_settime(0,0,NULL,NULL);\" compiles using sys/timerfd.h" >&5
  16164. $as_echo_n "checking if \"timerfd_create(0,0); timerfd_settime(0,0,NULL,NULL);\" compiles using sys/timerfd.h... " >&6; }
  16165. fi
  16166. saved_cppflags="${CPPFLAGS}"
  16167. if test "x${TIMERFD_DIR}" != "x"; then
  16168. TIMERFD_INCLUDE="-I${TIMERFD_DIR}/include"
  16169. fi
  16170. CPPFLAGS="${CPPFLAGS} ${TIMERFD_INCLUDE}"
  16171. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16172. /* end confdefs.h. */
  16173. #include <sys/timerfd.h>
  16174. int
  16175. main ()
  16176. {
  16177. timerfd_create(0,0); timerfd_settime(0,0,NULL,NULL);;
  16178. ;
  16179. return 0;
  16180. }
  16181. _ACEOF
  16182. if ac_fn_c_try_compile "$LINENO"; then :
  16183. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16184. $as_echo "yes" >&6; }
  16185. PBX_TIMERFD=1
  16186. $as_echo "#define HAVE_TIMERFD 1" >>confdefs.h
  16187. else
  16188. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16189. $as_echo "no" >&6; }
  16190. fi
  16191. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  16192. CPPFLAGS="${saved_cppflags}"
  16193. fi
  16194. GSM_INTERNAL="yes"
  16195. GSM_SYSTEM="yes"
  16196. if test "${USE_GSM}" != "no"; then
  16197. if test "${GSM_DIR}" = "internal"; then
  16198. GSM_SYSTEM="no"
  16199. elif test "${GSM_DIR}" != ""; then
  16200. GSM_INTERNAL="no"
  16201. fi
  16202. if test "${GSM_SYSTEM}" = "yes"; then
  16203. gsmlibdir=""
  16204. if test "x${GSM_DIR}" != "x"; then
  16205. if test -d ${GSM_DIR}/lib; then
  16206. gsmlibdir="-L${GSM_DIR}/lib"
  16207. else
  16208. gsmlibdir="-L${GSM_DIR}"
  16209. fi
  16210. fi
  16211. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gsm_create in -lgsm" >&5
  16212. $as_echo_n "checking for gsm_create in -lgsm... " >&6; }
  16213. if ${ac_cv_lib_gsm_gsm_create+:} false; then :
  16214. $as_echo_n "(cached) " >&6
  16215. else
  16216. ac_check_lib_save_LIBS=$LIBS
  16217. LIBS="-lgsm ${gsmlibdir} $LIBS"
  16218. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16219. /* end confdefs.h. */
  16220. /* Override any GCC internal prototype to avoid an error.
  16221. Use char because int might match the return type of a GCC
  16222. builtin and then its argument prototype would still apply. */
  16223. #ifdef __cplusplus
  16224. extern "C"
  16225. #endif
  16226. char gsm_create ();
  16227. int
  16228. main ()
  16229. {
  16230. return gsm_create ();
  16231. ;
  16232. return 0;
  16233. }
  16234. _ACEOF
  16235. if ac_fn_c_try_link "$LINENO"; then :
  16236. ac_cv_lib_gsm_gsm_create=yes
  16237. else
  16238. ac_cv_lib_gsm_gsm_create=no
  16239. fi
  16240. rm -f core conftest.err conftest.$ac_objext \
  16241. conftest$ac_exeext conftest.$ac_ext
  16242. LIBS=$ac_check_lib_save_LIBS
  16243. fi
  16244. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gsm_gsm_create" >&5
  16245. $as_echo "$ac_cv_lib_gsm_gsm_create" >&6; }
  16246. if test "x$ac_cv_lib_gsm_gsm_create" = xyes; then :
  16247. cat >>confdefs.h <<_ACEOF
  16248. #define HAVE_GSM 1
  16249. _ACEOF
  16250. fi
  16251. if test "${ac_cv_lib_gsm_gsm_create}" = "yes"; then
  16252. if test "x${GSM_DIR}" != "x" ; then
  16253. as_ac_Header=`$as_echo "ac_cv_header_${GSM_DIR}/include/gsm.h" | $as_tr_sh`
  16254. ac_fn_c_check_header_mongrel "$LINENO" "${GSM_DIR}/include/gsm.h" "$as_ac_Header" "$ac_includes_default"
  16255. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  16256. GSM_HEADER_FOUND=1
  16257. else
  16258. GSM_HEADER_FOUND=0
  16259. fi
  16260. as_ac_Header=`$as_echo "ac_cv_header_${GSM_DIR}/include/gsm/gsm.h" | $as_tr_sh`
  16261. ac_fn_c_check_header_mongrel "$LINENO" "${GSM_DIR}/include/gsm/gsm.h" "$as_ac_Header" "$ac_includes_default"
  16262. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  16263. GSM_GSM_HEADER_FOUND=1
  16264. else
  16265. GSM_GSM_HEADER_FOUND=0
  16266. fi
  16267. else
  16268. ac_fn_c_check_header_mongrel "$LINENO" "gsm.h" "ac_cv_header_gsm_h" "$ac_includes_default"
  16269. if test "x$ac_cv_header_gsm_h" = xyes; then :
  16270. GSM_HEADER_FOUND=1
  16271. else
  16272. GSM_HEADER_FOUND=0
  16273. fi
  16274. ac_fn_c_check_header_mongrel "$LINENO" "gsm/gsm.h" "ac_cv_header_gsm_gsm_h" "$ac_includes_default"
  16275. if test "x$ac_cv_header_gsm_gsm_h" = xyes; then :
  16276. GSM_GSM_HEADER_FOUND=1
  16277. else
  16278. GSM_GSM_HEADER_FOUND=0
  16279. fi
  16280. fi
  16281. if test "${GSM_HEADER_FOUND}" = "0" ; then
  16282. if test "{GSM_GSM_HEADER_FOUND}" = "0" ; then
  16283. if test "x${GSM_MANDATORY}" = "xyes" ; then
  16284. { $as_echo "$as_me:${as_lineno-$LINENO}: ***" >&5
  16285. $as_echo "$as_me: ***" >&6;}
  16286. { $as_echo "$as_me:${as_lineno-$LINENO}: *** It appears that you do not have the gsm development package installed." >&5
  16287. $as_echo "$as_me: *** It appears that you do not have the gsm development package installed." >&6;}
  16288. { $as_echo "$as_me:${as_lineno-$LINENO}: *** Please install it to include ${GSM_DESCRIP} support, or re-run configure" >&5
  16289. $as_echo "$as_me: *** Please install it to include ${GSM_DESCRIP} support, or re-run configure" >&6;}
  16290. { $as_echo "$as_me:${as_lineno-$LINENO}: *** without explicitly specifying --with-${GSM_OPTION}" >&5
  16291. $as_echo "$as_me: *** without explicitly specifying --with-${GSM_OPTION}" >&6;}
  16292. exit 1
  16293. fi
  16294. fi
  16295. fi
  16296. GSM_OK=0
  16297. if test "${GSM_HEADER_FOUND}" = "1" ; then
  16298. cat >>confdefs.h <<_ACEOF
  16299. #define HAVE_GSM_HEADER 1
  16300. _ACEOF
  16301. GSM_OK=1
  16302. else
  16303. if test "${GSM_GSM_HEADER_FOUND}" = "1" ; then
  16304. cat >>confdefs.h <<_ACEOF
  16305. #define HAVE_GSM_GSM_HEADER 1
  16306. _ACEOF
  16307. GSM_OK=1
  16308. fi
  16309. fi
  16310. if test "${GSM_OK}" = "1" ; then
  16311. GSM_LIB="-lgsm"
  16312. if test "x${GSM_DIR}" != "x"; then
  16313. GSM_LIB="${gsmlibdir} ${GSM_LIB}"
  16314. GSM_INCLUDE="-I${GSM_DIR}/include"
  16315. fi
  16316. PBX_GSM=1
  16317. GSM_INTERNAL="no"
  16318. fi
  16319. fi
  16320. fi
  16321. if test "${GSM_INTERNAL}" = "yes"; then
  16322. PBX_GSM=1
  16323. cat >>confdefs.h <<_ACEOF
  16324. #define HAVE_GSM_HEADER 1
  16325. _ACEOF
  16326. fi
  16327. fi
  16328. ILBC_INTERNAL="yes"
  16329. ILBC_SYSTEM="yes"
  16330. if test "${USE_ILBC}" != "no"; then
  16331. if test "${ILBC_DIR}" = "internal"; then
  16332. ILBC_SYSTEM="no"
  16333. elif test "${ILBC_DIR}" != ""; then
  16334. ILBC_INTERNAL="no"
  16335. fi
  16336. if test "${ILBC_SYSTEM}" = "yes"; then
  16337. if test "x${PBX_ILBC}" != "x1" -a "${USE_ILBC}" != "no"; then
  16338. pkg_failed=no
  16339. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ILBC" >&5
  16340. $as_echo_n "checking for ILBC... " >&6; }
  16341. if test -n "$ILBC_CFLAGS"; then
  16342. pkg_cv_ILBC_CFLAGS="$ILBC_CFLAGS"
  16343. elif test -n "$PKG_CONFIG"; then
  16344. if test -n "$PKG_CONFIG" && \
  16345. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libilbc\""; } >&5
  16346. ($PKG_CONFIG --exists --print-errors "libilbc") 2>&5
  16347. ac_status=$?
  16348. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  16349. test $ac_status = 0; }; then
  16350. pkg_cv_ILBC_CFLAGS=`$PKG_CONFIG --cflags "libilbc" 2>/dev/null`
  16351. test "x$?" != "x0" && pkg_failed=yes
  16352. else
  16353. pkg_failed=yes
  16354. fi
  16355. else
  16356. pkg_failed=untried
  16357. fi
  16358. if test -n "$ILBC_LIBS"; then
  16359. pkg_cv_ILBC_LIBS="$ILBC_LIBS"
  16360. elif test -n "$PKG_CONFIG"; then
  16361. if test -n "$PKG_CONFIG" && \
  16362. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libilbc\""; } >&5
  16363. ($PKG_CONFIG --exists --print-errors "libilbc") 2>&5
  16364. ac_status=$?
  16365. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  16366. test $ac_status = 0; }; then
  16367. pkg_cv_ILBC_LIBS=`$PKG_CONFIG --libs "libilbc" 2>/dev/null`
  16368. test "x$?" != "x0" && pkg_failed=yes
  16369. else
  16370. pkg_failed=yes
  16371. fi
  16372. else
  16373. pkg_failed=untried
  16374. fi
  16375. if test $pkg_failed = yes; then
  16376. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16377. $as_echo "no" >&6; }
  16378. if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
  16379. _pkg_short_errors_supported=yes
  16380. else
  16381. _pkg_short_errors_supported=no
  16382. fi
  16383. if test $_pkg_short_errors_supported = yes; then
  16384. ILBC_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libilbc" 2>&1`
  16385. else
  16386. ILBC_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libilbc" 2>&1`
  16387. fi
  16388. # Put the nasty error message in config.log where it belongs
  16389. echo "$ILBC_PKG_ERRORS" >&5
  16390. PBX_ILBC=0
  16391. elif test $pkg_failed = untried; then
  16392. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16393. $as_echo "no" >&6; }
  16394. PBX_ILBC=0
  16395. else
  16396. ILBC_CFLAGS=$pkg_cv_ILBC_CFLAGS
  16397. ILBC_LIBS=$pkg_cv_ILBC_LIBS
  16398. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16399. $as_echo "yes" >&6; }
  16400. PBX_ILBC=1
  16401. ILBC_INCLUDE="$ILBC_CFLAGS"
  16402. ILBC_LIB="$ILBC_LIBS"
  16403. $as_echo "#define HAVE_ILBC 1" >>confdefs.h
  16404. fi
  16405. fi
  16406. if test "$PBX_ILBC" = "1"; then
  16407. ILBC_INTERNAL="no"
  16408. fi
  16409. fi
  16410. if test "${ILBC_INTERNAL}" = "yes"; then
  16411. PBX_ILBC=1
  16412. fi
  16413. fi
  16414. LIBEDIT_INTERNAL="yes"
  16415. LIBEDIT_SYSTEM="yes"
  16416. if test "${USE_LIBEDIT}" != "no"; then
  16417. if test "${LIBEDIT_DIR}" = "internal"; then
  16418. LIBEDIT_SYSTEM="no"
  16419. elif test "${LIBEDIT_DIR}" != ""; then
  16420. LIBEDIT_INTERNAL="no"
  16421. fi
  16422. if test "${LIBEDIT_SYSTEM}" = "yes"; then
  16423. if test "x${PBX_LIBEDIT}" != "x1" -a "${USE_LIBEDIT}" != "no"; then
  16424. pkg_failed=no
  16425. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBEDIT" >&5
  16426. $as_echo_n "checking for LIBEDIT... " >&6; }
  16427. if test -n "$LIBEDIT_CFLAGS"; then
  16428. pkg_cv_LIBEDIT_CFLAGS="$LIBEDIT_CFLAGS"
  16429. elif test -n "$PKG_CONFIG"; then
  16430. if test -n "$PKG_CONFIG" && \
  16431. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libedit\""; } >&5
  16432. ($PKG_CONFIG --exists --print-errors "libedit") 2>&5
  16433. ac_status=$?
  16434. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  16435. test $ac_status = 0; }; then
  16436. pkg_cv_LIBEDIT_CFLAGS=`$PKG_CONFIG --cflags "libedit" 2>/dev/null`
  16437. test "x$?" != "x0" && pkg_failed=yes
  16438. else
  16439. pkg_failed=yes
  16440. fi
  16441. else
  16442. pkg_failed=untried
  16443. fi
  16444. if test -n "$LIBEDIT_LIBS"; then
  16445. pkg_cv_LIBEDIT_LIBS="$LIBEDIT_LIBS"
  16446. elif test -n "$PKG_CONFIG"; then
  16447. if test -n "$PKG_CONFIG" && \
  16448. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libedit\""; } >&5
  16449. ($PKG_CONFIG --exists --print-errors "libedit") 2>&5
  16450. ac_status=$?
  16451. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  16452. test $ac_status = 0; }; then
  16453. pkg_cv_LIBEDIT_LIBS=`$PKG_CONFIG --libs "libedit" 2>/dev/null`
  16454. test "x$?" != "x0" && pkg_failed=yes
  16455. else
  16456. pkg_failed=yes
  16457. fi
  16458. else
  16459. pkg_failed=untried
  16460. fi
  16461. if test $pkg_failed = yes; then
  16462. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16463. $as_echo "no" >&6; }
  16464. if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
  16465. _pkg_short_errors_supported=yes
  16466. else
  16467. _pkg_short_errors_supported=no
  16468. fi
  16469. if test $_pkg_short_errors_supported = yes; then
  16470. LIBEDIT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libedit" 2>&1`
  16471. else
  16472. LIBEDIT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libedit" 2>&1`
  16473. fi
  16474. # Put the nasty error message in config.log where it belongs
  16475. echo "$LIBEDIT_PKG_ERRORS" >&5
  16476. PBX_LIBEDIT=0
  16477. elif test $pkg_failed = untried; then
  16478. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16479. $as_echo "no" >&6; }
  16480. PBX_LIBEDIT=0
  16481. else
  16482. LIBEDIT_CFLAGS=$pkg_cv_LIBEDIT_CFLAGS
  16483. LIBEDIT_LIBS=$pkg_cv_LIBEDIT_LIBS
  16484. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16485. $as_echo "yes" >&6; }
  16486. PBX_LIBEDIT=1
  16487. LIBEDIT_INCLUDE="$LIBEDIT_CFLAGS"
  16488. LIBEDIT_LIB="$LIBEDIT_LIBS"
  16489. $as_echo "#define HAVE_LIBEDIT 1" >>confdefs.h
  16490. fi
  16491. fi
  16492. if test "$PBX_LIBEDIT" = "1"; then
  16493. LIBEDIT_INTERNAL="no"
  16494. fi
  16495. fi
  16496. if test "${LIBEDIT_INTERNAL}" = "yes"; then
  16497. PBX_LIBEDIT=1
  16498. fi
  16499. fi
  16500. if test "x${PBX_ICONV}" != "x1" -a "${USE_ICONV}" != "no"; then
  16501. pbxlibdir=""
  16502. # if --with-ICONV=DIR has been specified, use it.
  16503. if test "x${ICONV_DIR}" != "x"; then
  16504. if test -d ${ICONV_DIR}/lib; then
  16505. pbxlibdir="-L${ICONV_DIR}/lib"
  16506. else
  16507. pbxlibdir="-L${ICONV_DIR}"
  16508. fi
  16509. fi
  16510. pbxfuncname="iconv_open"
  16511. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  16512. AST_ICONV_FOUND=yes
  16513. else
  16514. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  16515. CFLAGS="${CFLAGS} "
  16516. as_ac_Lib=`$as_echo "ac_cv_lib_iconv_${pbxfuncname}" | $as_tr_sh`
  16517. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -liconv" >&5
  16518. $as_echo_n "checking for ${pbxfuncname} in -liconv... " >&6; }
  16519. if eval \${$as_ac_Lib+:} false; then :
  16520. $as_echo_n "(cached) " >&6
  16521. else
  16522. ac_check_lib_save_LIBS=$LIBS
  16523. LIBS="-liconv ${pbxlibdir} $LIBS"
  16524. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16525. /* end confdefs.h. */
  16526. /* Override any GCC internal prototype to avoid an error.
  16527. Use char because int might match the return type of a GCC
  16528. builtin and then its argument prototype would still apply. */
  16529. #ifdef __cplusplus
  16530. extern "C"
  16531. #endif
  16532. char ${pbxfuncname} ();
  16533. int
  16534. main ()
  16535. {
  16536. return ${pbxfuncname} ();
  16537. ;
  16538. return 0;
  16539. }
  16540. _ACEOF
  16541. if ac_fn_c_try_link "$LINENO"; then :
  16542. eval "$as_ac_Lib=yes"
  16543. else
  16544. eval "$as_ac_Lib=no"
  16545. fi
  16546. rm -f core conftest.err conftest.$ac_objext \
  16547. conftest$ac_exeext conftest.$ac_ext
  16548. LIBS=$ac_check_lib_save_LIBS
  16549. fi
  16550. eval ac_res=\$$as_ac_Lib
  16551. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  16552. $as_echo "$ac_res" >&6; }
  16553. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  16554. AST_ICONV_FOUND=yes
  16555. else
  16556. AST_ICONV_FOUND=no
  16557. fi
  16558. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  16559. fi
  16560. # now check for the header.
  16561. if test "${AST_ICONV_FOUND}" = "yes"; then
  16562. ICONV_LIB="${pbxlibdir} -liconv "
  16563. # if --with-ICONV=DIR has been specified, use it.
  16564. if test "x${ICONV_DIR}" != "x"; then
  16565. ICONV_INCLUDE="-I${ICONV_DIR}/include"
  16566. fi
  16567. ICONV_INCLUDE="${ICONV_INCLUDE} "
  16568. if test "xiconv.h" = "x" ; then # no header, assume found
  16569. ICONV_HEADER_FOUND="1"
  16570. else # check for the header
  16571. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  16572. CPPFLAGS="${CPPFLAGS} ${ICONV_INCLUDE}"
  16573. ac_fn_c_check_header_mongrel "$LINENO" "iconv.h" "ac_cv_header_iconv_h" "$ac_includes_default"
  16574. if test "x$ac_cv_header_iconv_h" = xyes; then :
  16575. ICONV_HEADER_FOUND=1
  16576. else
  16577. ICONV_HEADER_FOUND=0
  16578. fi
  16579. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  16580. fi
  16581. if test "x${ICONV_HEADER_FOUND}" = "x0" ; then
  16582. ICONV_LIB=""
  16583. ICONV_INCLUDE=""
  16584. else
  16585. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  16586. ICONV_LIB=""
  16587. fi
  16588. PBX_ICONV=1
  16589. cat >>confdefs.h <<_ACEOF
  16590. #define HAVE_ICONV 1
  16591. _ACEOF
  16592. fi
  16593. fi
  16594. fi
  16595. # GNU libiconv #define's iconv_open to libiconv_open, so we need to search for that symbol
  16596. if test "x${PBX_ICONV}" != "x1" -a "${USE_ICONV}" != "no"; then
  16597. pbxlibdir=""
  16598. # if --with-ICONV=DIR has been specified, use it.
  16599. if test "x${ICONV_DIR}" != "x"; then
  16600. if test -d ${ICONV_DIR}/lib; then
  16601. pbxlibdir="-L${ICONV_DIR}/lib"
  16602. else
  16603. pbxlibdir="-L${ICONV_DIR}"
  16604. fi
  16605. fi
  16606. pbxfuncname="libiconv_open"
  16607. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  16608. AST_ICONV_FOUND=yes
  16609. else
  16610. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  16611. CFLAGS="${CFLAGS} "
  16612. as_ac_Lib=`$as_echo "ac_cv_lib_iconv_${pbxfuncname}" | $as_tr_sh`
  16613. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -liconv" >&5
  16614. $as_echo_n "checking for ${pbxfuncname} in -liconv... " >&6; }
  16615. if eval \${$as_ac_Lib+:} false; then :
  16616. $as_echo_n "(cached) " >&6
  16617. else
  16618. ac_check_lib_save_LIBS=$LIBS
  16619. LIBS="-liconv ${pbxlibdir} $LIBS"
  16620. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16621. /* end confdefs.h. */
  16622. /* Override any GCC internal prototype to avoid an error.
  16623. Use char because int might match the return type of a GCC
  16624. builtin and then its argument prototype would still apply. */
  16625. #ifdef __cplusplus
  16626. extern "C"
  16627. #endif
  16628. char ${pbxfuncname} ();
  16629. int
  16630. main ()
  16631. {
  16632. return ${pbxfuncname} ();
  16633. ;
  16634. return 0;
  16635. }
  16636. _ACEOF
  16637. if ac_fn_c_try_link "$LINENO"; then :
  16638. eval "$as_ac_Lib=yes"
  16639. else
  16640. eval "$as_ac_Lib=no"
  16641. fi
  16642. rm -f core conftest.err conftest.$ac_objext \
  16643. conftest$ac_exeext conftest.$ac_ext
  16644. LIBS=$ac_check_lib_save_LIBS
  16645. fi
  16646. eval ac_res=\$$as_ac_Lib
  16647. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  16648. $as_echo "$ac_res" >&6; }
  16649. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  16650. AST_ICONV_FOUND=yes
  16651. else
  16652. AST_ICONV_FOUND=no
  16653. fi
  16654. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  16655. fi
  16656. # now check for the header.
  16657. if test "${AST_ICONV_FOUND}" = "yes"; then
  16658. ICONV_LIB="${pbxlibdir} -liconv "
  16659. # if --with-ICONV=DIR has been specified, use it.
  16660. if test "x${ICONV_DIR}" != "x"; then
  16661. ICONV_INCLUDE="-I${ICONV_DIR}/include"
  16662. fi
  16663. ICONV_INCLUDE="${ICONV_INCLUDE} "
  16664. if test "xiconv.h" = "x" ; then # no header, assume found
  16665. ICONV_HEADER_FOUND="1"
  16666. else # check for the header
  16667. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  16668. CPPFLAGS="${CPPFLAGS} ${ICONV_INCLUDE}"
  16669. ac_fn_c_check_header_mongrel "$LINENO" "iconv.h" "ac_cv_header_iconv_h" "$ac_includes_default"
  16670. if test "x$ac_cv_header_iconv_h" = xyes; then :
  16671. ICONV_HEADER_FOUND=1
  16672. else
  16673. ICONV_HEADER_FOUND=0
  16674. fi
  16675. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  16676. fi
  16677. if test "x${ICONV_HEADER_FOUND}" = "x0" ; then
  16678. ICONV_LIB=""
  16679. ICONV_INCLUDE=""
  16680. else
  16681. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  16682. ICONV_LIB=""
  16683. fi
  16684. PBX_ICONV=1
  16685. cat >>confdefs.h <<_ACEOF
  16686. #define HAVE_ICONV 1
  16687. _ACEOF
  16688. fi
  16689. fi
  16690. fi
  16691. # Some versions of Linux package iconv in glibc
  16692. if test "x${PBX_ICONV}" != "x1" -a "${USE_ICONV}" != "no"; then
  16693. pbxlibdir=""
  16694. # if --with-ICONV=DIR has been specified, use it.
  16695. if test "x${ICONV_DIR}" != "x"; then
  16696. if test -d ${ICONV_DIR}/lib; then
  16697. pbxlibdir="-L${ICONV_DIR}/lib"
  16698. else
  16699. pbxlibdir="-L${ICONV_DIR}"
  16700. fi
  16701. fi
  16702. pbxfuncname="iconv_close"
  16703. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  16704. AST_ICONV_FOUND=yes
  16705. else
  16706. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  16707. CFLAGS="${CFLAGS} "
  16708. as_ac_Lib=`$as_echo "ac_cv_lib_c_${pbxfuncname}" | $as_tr_sh`
  16709. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lc" >&5
  16710. $as_echo_n "checking for ${pbxfuncname} in -lc... " >&6; }
  16711. if eval \${$as_ac_Lib+:} false; then :
  16712. $as_echo_n "(cached) " >&6
  16713. else
  16714. ac_check_lib_save_LIBS=$LIBS
  16715. LIBS="-lc ${pbxlibdir} $LIBS"
  16716. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16717. /* end confdefs.h. */
  16718. /* Override any GCC internal prototype to avoid an error.
  16719. Use char because int might match the return type of a GCC
  16720. builtin and then its argument prototype would still apply. */
  16721. #ifdef __cplusplus
  16722. extern "C"
  16723. #endif
  16724. char ${pbxfuncname} ();
  16725. int
  16726. main ()
  16727. {
  16728. return ${pbxfuncname} ();
  16729. ;
  16730. return 0;
  16731. }
  16732. _ACEOF
  16733. if ac_fn_c_try_link "$LINENO"; then :
  16734. eval "$as_ac_Lib=yes"
  16735. else
  16736. eval "$as_ac_Lib=no"
  16737. fi
  16738. rm -f core conftest.err conftest.$ac_objext \
  16739. conftest$ac_exeext conftest.$ac_ext
  16740. LIBS=$ac_check_lib_save_LIBS
  16741. fi
  16742. eval ac_res=\$$as_ac_Lib
  16743. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  16744. $as_echo "$ac_res" >&6; }
  16745. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  16746. AST_ICONV_FOUND=yes
  16747. else
  16748. AST_ICONV_FOUND=no
  16749. fi
  16750. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  16751. fi
  16752. # now check for the header.
  16753. if test "${AST_ICONV_FOUND}" = "yes"; then
  16754. ICONV_LIB="${pbxlibdir} -lc "
  16755. # if --with-ICONV=DIR has been specified, use it.
  16756. if test "x${ICONV_DIR}" != "x"; then
  16757. ICONV_INCLUDE="-I${ICONV_DIR}/include"
  16758. fi
  16759. ICONV_INCLUDE="${ICONV_INCLUDE} "
  16760. if test "xiconv.h" = "x" ; then # no header, assume found
  16761. ICONV_HEADER_FOUND="1"
  16762. else # check for the header
  16763. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  16764. CPPFLAGS="${CPPFLAGS} ${ICONV_INCLUDE}"
  16765. ac_fn_c_check_header_mongrel "$LINENO" "iconv.h" "ac_cv_header_iconv_h" "$ac_includes_default"
  16766. if test "x$ac_cv_header_iconv_h" = xyes; then :
  16767. ICONV_HEADER_FOUND=1
  16768. else
  16769. ICONV_HEADER_FOUND=0
  16770. fi
  16771. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  16772. fi
  16773. if test "x${ICONV_HEADER_FOUND}" = "x0" ; then
  16774. ICONV_LIB=""
  16775. ICONV_INCLUDE=""
  16776. else
  16777. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  16778. ICONV_LIB=""
  16779. fi
  16780. PBX_ICONV=1
  16781. cat >>confdefs.h <<_ACEOF
  16782. #define HAVE_ICONV 1
  16783. _ACEOF
  16784. fi
  16785. fi
  16786. fi
  16787. # If ical.h is NOT in the libical directory, then it is of a version insufficient for us.
  16788. if test "x${PBX_ICAL}" != "x1" -a "${USE_ICAL}" != "no"; then
  16789. pbxlibdir=""
  16790. # if --with-ICAL=DIR has been specified, use it.
  16791. if test "x${ICAL_DIR}" != "x"; then
  16792. if test -d ${ICAL_DIR}/lib; then
  16793. pbxlibdir="-L${ICAL_DIR}/lib"
  16794. else
  16795. pbxlibdir="-L${ICAL_DIR}"
  16796. fi
  16797. fi
  16798. pbxfuncname="icaltimezone_get_utc_timezone"
  16799. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  16800. AST_ICAL_FOUND=yes
  16801. else
  16802. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  16803. CFLAGS="${CFLAGS} ${PTHREAD_CFLAGS}"
  16804. as_ac_Lib=`$as_echo "ac_cv_lib_ical_${pbxfuncname}" | $as_tr_sh`
  16805. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lical" >&5
  16806. $as_echo_n "checking for ${pbxfuncname} in -lical... " >&6; }
  16807. if eval \${$as_ac_Lib+:} false; then :
  16808. $as_echo_n "(cached) " >&6
  16809. else
  16810. ac_check_lib_save_LIBS=$LIBS
  16811. LIBS="-lical ${pbxlibdir} ${PTHREAD_LIBS} $LIBS"
  16812. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16813. /* end confdefs.h. */
  16814. /* Override any GCC internal prototype to avoid an error.
  16815. Use char because int might match the return type of a GCC
  16816. builtin and then its argument prototype would still apply. */
  16817. #ifdef __cplusplus
  16818. extern "C"
  16819. #endif
  16820. char ${pbxfuncname} ();
  16821. int
  16822. main ()
  16823. {
  16824. return ${pbxfuncname} ();
  16825. ;
  16826. return 0;
  16827. }
  16828. _ACEOF
  16829. if ac_fn_c_try_link "$LINENO"; then :
  16830. eval "$as_ac_Lib=yes"
  16831. else
  16832. eval "$as_ac_Lib=no"
  16833. fi
  16834. rm -f core conftest.err conftest.$ac_objext \
  16835. conftest$ac_exeext conftest.$ac_ext
  16836. LIBS=$ac_check_lib_save_LIBS
  16837. fi
  16838. eval ac_res=\$$as_ac_Lib
  16839. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  16840. $as_echo "$ac_res" >&6; }
  16841. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  16842. AST_ICAL_FOUND=yes
  16843. else
  16844. AST_ICAL_FOUND=no
  16845. fi
  16846. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  16847. fi
  16848. # now check for the header.
  16849. if test "${AST_ICAL_FOUND}" = "yes"; then
  16850. ICAL_LIB="${pbxlibdir} -lical ${PTHREAD_LIBS}"
  16851. # if --with-ICAL=DIR has been specified, use it.
  16852. if test "x${ICAL_DIR}" != "x"; then
  16853. ICAL_INCLUDE="-I${ICAL_DIR}/include"
  16854. fi
  16855. ICAL_INCLUDE="${ICAL_INCLUDE} ${PTHREAD_CFLAGS}"
  16856. if test "xlibical/ical.h" = "x" ; then # no header, assume found
  16857. ICAL_HEADER_FOUND="1"
  16858. else # check for the header
  16859. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  16860. CPPFLAGS="${CPPFLAGS} ${ICAL_INCLUDE}"
  16861. ac_fn_c_check_header_mongrel "$LINENO" "libical/ical.h" "ac_cv_header_libical_ical_h" "$ac_includes_default"
  16862. if test "x$ac_cv_header_libical_ical_h" = xyes; then :
  16863. ICAL_HEADER_FOUND=1
  16864. else
  16865. ICAL_HEADER_FOUND=0
  16866. fi
  16867. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  16868. fi
  16869. if test "x${ICAL_HEADER_FOUND}" = "x0" ; then
  16870. ICAL_LIB=""
  16871. ICAL_INCLUDE=""
  16872. else
  16873. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  16874. ICAL_LIB=""
  16875. fi
  16876. PBX_ICAL=1
  16877. cat >>confdefs.h <<_ACEOF
  16878. #define HAVE_ICAL 1
  16879. _ACEOF
  16880. fi
  16881. fi
  16882. fi
  16883. if test "x${PBX_IKSEMEL}" != "x1" -a "${USE_IKSEMEL}" != "no"; then
  16884. pbxlibdir=""
  16885. # if --with-IKSEMEL=DIR has been specified, use it.
  16886. if test "x${IKSEMEL_DIR}" != "x"; then
  16887. if test -d ${IKSEMEL_DIR}/lib; then
  16888. pbxlibdir="-L${IKSEMEL_DIR}/lib"
  16889. else
  16890. pbxlibdir="-L${IKSEMEL_DIR}"
  16891. fi
  16892. fi
  16893. pbxfuncname="iks_start_sasl"
  16894. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  16895. AST_IKSEMEL_FOUND=yes
  16896. else
  16897. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  16898. CFLAGS="${CFLAGS} "
  16899. as_ac_Lib=`$as_echo "ac_cv_lib_iksemel_${pbxfuncname}" | $as_tr_sh`
  16900. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -liksemel" >&5
  16901. $as_echo_n "checking for ${pbxfuncname} in -liksemel... " >&6; }
  16902. if eval \${$as_ac_Lib+:} false; then :
  16903. $as_echo_n "(cached) " >&6
  16904. else
  16905. ac_check_lib_save_LIBS=$LIBS
  16906. LIBS="-liksemel ${pbxlibdir} $LIBS"
  16907. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16908. /* end confdefs.h. */
  16909. /* Override any GCC internal prototype to avoid an error.
  16910. Use char because int might match the return type of a GCC
  16911. builtin and then its argument prototype would still apply. */
  16912. #ifdef __cplusplus
  16913. extern "C"
  16914. #endif
  16915. char ${pbxfuncname} ();
  16916. int
  16917. main ()
  16918. {
  16919. return ${pbxfuncname} ();
  16920. ;
  16921. return 0;
  16922. }
  16923. _ACEOF
  16924. if ac_fn_c_try_link "$LINENO"; then :
  16925. eval "$as_ac_Lib=yes"
  16926. else
  16927. eval "$as_ac_Lib=no"
  16928. fi
  16929. rm -f core conftest.err conftest.$ac_objext \
  16930. conftest$ac_exeext conftest.$ac_ext
  16931. LIBS=$ac_check_lib_save_LIBS
  16932. fi
  16933. eval ac_res=\$$as_ac_Lib
  16934. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  16935. $as_echo "$ac_res" >&6; }
  16936. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  16937. AST_IKSEMEL_FOUND=yes
  16938. else
  16939. AST_IKSEMEL_FOUND=no
  16940. fi
  16941. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  16942. fi
  16943. # now check for the header.
  16944. if test "${AST_IKSEMEL_FOUND}" = "yes"; then
  16945. IKSEMEL_LIB="${pbxlibdir} -liksemel "
  16946. # if --with-IKSEMEL=DIR has been specified, use it.
  16947. if test "x${IKSEMEL_DIR}" != "x"; then
  16948. IKSEMEL_INCLUDE="-I${IKSEMEL_DIR}/include"
  16949. fi
  16950. IKSEMEL_INCLUDE="${IKSEMEL_INCLUDE} "
  16951. if test "xiksemel.h" = "x" ; then # no header, assume found
  16952. IKSEMEL_HEADER_FOUND="1"
  16953. else # check for the header
  16954. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  16955. CPPFLAGS="${CPPFLAGS} ${IKSEMEL_INCLUDE}"
  16956. ac_fn_c_check_header_mongrel "$LINENO" "iksemel.h" "ac_cv_header_iksemel_h" "$ac_includes_default"
  16957. if test "x$ac_cv_header_iksemel_h" = xyes; then :
  16958. IKSEMEL_HEADER_FOUND=1
  16959. else
  16960. IKSEMEL_HEADER_FOUND=0
  16961. fi
  16962. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  16963. fi
  16964. if test "x${IKSEMEL_HEADER_FOUND}" = "x0" ; then
  16965. IKSEMEL_LIB=""
  16966. IKSEMEL_INCLUDE=""
  16967. else
  16968. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  16969. IKSEMEL_LIB=""
  16970. fi
  16971. PBX_IKSEMEL=1
  16972. cat >>confdefs.h <<_ACEOF
  16973. #define HAVE_IKSEMEL 1
  16974. _ACEOF
  16975. fi
  16976. fi
  16977. fi
  16978. if test "${USE_IMAP_TK}" != "no"; then
  16979. saved_cppflags="${CPPFLAGS}"
  16980. saved_libs="${LIBS}"
  16981. switch_to_system_on_failure="no"
  16982. if test "${IMAP_TK_DIR}" = ""; then
  16983. IMAP_TK_DIR=`pwd`"/../imap-2004g"
  16984. switch_to_system_on_failure="yes"
  16985. fi
  16986. if test "${IMAP_TK_DIR}" != "system"; then
  16987. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UW IMAP Toolkit c-client library" >&5
  16988. $as_echo_n "checking for UW IMAP Toolkit c-client library... " >&6; }
  16989. if test -f "${IMAP_TK_DIR}/c-client/LDFLAGS"; then
  16990. imap_ldflags=`cat ${IMAP_TK_DIR}/c-client/LDFLAGS`
  16991. fi
  16992. imap_libs="${IMAP_TK_DIR}/c-client/c-client.a"
  16993. imap_include="-I${IMAP_TK_DIR}/c-client"
  16994. CPPFLAGS="${CPPFLAGS} ${imap_include}"
  16995. LIBS="${LIBS} ${imap_libs} "`echo ${imap_ldflags}`
  16996. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16997. /* end confdefs.h. */
  16998. #include "c-client.h"
  16999. void mm_searched (MAILSTREAM *stream,unsigned long number)
  17000. {
  17001. }
  17002. void mm_exists (MAILSTREAM *stream,unsigned long number)
  17003. {
  17004. }
  17005. void mm_expunged (MAILSTREAM *stream,unsigned long number)
  17006. {
  17007. }
  17008. void mm_flags (MAILSTREAM *stream,unsigned long number)
  17009. {
  17010. }
  17011. void mm_notify (MAILSTREAM *stream,char *string,long errflg)
  17012. {
  17013. }
  17014. void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17015. {
  17016. }
  17017. void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17018. {
  17019. }
  17020. void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
  17021. {
  17022. }
  17023. void mm_log (char *string,long errflg)
  17024. {
  17025. }
  17026. void mm_dlog (char *string)
  17027. {
  17028. }
  17029. void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
  17030. {
  17031. }
  17032. void mm_critical (MAILSTREAM *stream)
  17033. {
  17034. }
  17035. void mm_nocritical (MAILSTREAM *stream)
  17036. {
  17037. }
  17038. long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
  17039. {
  17040. }
  17041. void mm_fatal (char *string)
  17042. {
  17043. }
  17044. int
  17045. main ()
  17046. {
  17047. MAILSTREAM *foo = mail_open(NULL, "", 0);
  17048. ;
  17049. return 0;
  17050. }
  17051. _ACEOF
  17052. if ac_fn_c_try_link "$LINENO"; then :
  17053. ac_cv_imap_tk="yes"
  17054. else
  17055. ac_cv_imap_tk="no"
  17056. fi
  17057. rm -f core conftest.err conftest.$ac_objext \
  17058. conftest$ac_exeext conftest.$ac_ext
  17059. if test "${ac_cv_imap_tk}" = "yes"; then
  17060. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17061. /* end confdefs.h. */
  17062. #include "c-client.h"
  17063. void mm_searched (MAILSTREAM *stream,unsigned long number)
  17064. {
  17065. }
  17066. void mm_exists (MAILSTREAM *stream,unsigned long number)
  17067. {
  17068. }
  17069. void mm_expunged (MAILSTREAM *stream,unsigned long number)
  17070. {
  17071. }
  17072. void mm_flags (MAILSTREAM *stream,unsigned long number)
  17073. {
  17074. }
  17075. void mm_notify (MAILSTREAM *stream,char *string,long errflg)
  17076. {
  17077. }
  17078. void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17079. {
  17080. }
  17081. void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17082. {
  17083. }
  17084. void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
  17085. {
  17086. }
  17087. void mm_log (char *string,long errflg)
  17088. {
  17089. }
  17090. void mm_dlog (char *string)
  17091. {
  17092. }
  17093. void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
  17094. {
  17095. }
  17096. void mm_critical (MAILSTREAM *stream)
  17097. {
  17098. }
  17099. void mm_nocritical (MAILSTREAM *stream)
  17100. {
  17101. }
  17102. long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
  17103. {
  17104. }
  17105. void mm_fatal (char *string)
  17106. {
  17107. }
  17108. int
  17109. main ()
  17110. {
  17111. long check = mail_expunge_full(NULL, "", 0);
  17112. ;
  17113. return 0;
  17114. }
  17115. _ACEOF
  17116. if ac_fn_c_try_link "$LINENO"; then :
  17117. ac_cv_imap_tk2006="yes"
  17118. else
  17119. ac_cv_imap_tk2006="no"
  17120. fi
  17121. rm -f core conftest.err conftest.$ac_objext \
  17122. conftest$ac_exeext conftest.$ac_ext
  17123. fi
  17124. CPPFLAGS="${saved_cppflags}"
  17125. LIBS="${saved_libs}"
  17126. if test "${ac_cv_imap_tk}" = "no"; then
  17127. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  17128. $as_echo "no" >&6; }
  17129. if test "${switch_to_system_on_failure}" = "yes"; then
  17130. IMAP_TK_DIR="system"
  17131. else #This means they specified a directory. Search for a package installation there too
  17132. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for system c-client library..." >&5
  17133. $as_echo_n "checking for system c-client library...... " >&6; }
  17134. CPPFLAGS="${saved_cppflags}"
  17135. LIBS="${saved_libs}"
  17136. imap_include="-I${IMAP_TK_DIR}/include"
  17137. imap_ldflags="-L${IMAP_TK_DIR}/lib"
  17138. imap_libs="-lc-client"
  17139. CPPFLAGS="${CPPFLAGS} ${imap_include}"
  17140. LIBS="${LIBS} ${imap_libs} ${imap_ldflags}"
  17141. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17142. /* end confdefs.h. */
  17143. #include "c-client.h"
  17144. void mm_searched (MAILSTREAM *stream,unsigned long number)
  17145. {
  17146. }
  17147. void mm_exists (MAILSTREAM *stream,unsigned long number)
  17148. {
  17149. }
  17150. void mm_expunged (MAILSTREAM *stream,unsigned long number)
  17151. {
  17152. }
  17153. void mm_flags (MAILSTREAM *stream,unsigned long number)
  17154. {
  17155. }
  17156. void mm_notify (MAILSTREAM *stream,char *string,long errflg)
  17157. {
  17158. }
  17159. void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17160. {
  17161. }
  17162. void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17163. {
  17164. }
  17165. void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
  17166. {
  17167. }
  17168. void mm_log (char *string,long errflg)
  17169. {
  17170. }
  17171. void mm_dlog (char *string)
  17172. {
  17173. }
  17174. void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
  17175. {
  17176. }
  17177. void mm_critical (MAILSTREAM *stream)
  17178. {
  17179. }
  17180. void mm_nocritical (MAILSTREAM *stream)
  17181. {
  17182. }
  17183. long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
  17184. {
  17185. }
  17186. void mm_fatal (char *string)
  17187. {
  17188. }
  17189. int
  17190. main ()
  17191. {
  17192. MAILSTREAM *foo = mail_open(NULL, "", 0);
  17193. ;
  17194. return 0;
  17195. }
  17196. _ACEOF
  17197. if ac_fn_c_try_link "$LINENO"; then :
  17198. ac_cv_imap_tk="yes"
  17199. else
  17200. ac_cv_imap_tk="no"
  17201. fi
  17202. rm -f core conftest.err conftest.$ac_objext \
  17203. conftest$ac_exeext conftest.$ac_ext
  17204. if test "${ac_cv_imap_tk}" = "yes"; then
  17205. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17206. /* end confdefs.h. */
  17207. #include "c-client.h"
  17208. void mm_searched (MAILSTREAM *stream,unsigned long number)
  17209. {
  17210. }
  17211. void mm_exists (MAILSTREAM *stream,unsigned long number)
  17212. {
  17213. }
  17214. void mm_expunged (MAILSTREAM *stream,unsigned long number)
  17215. {
  17216. }
  17217. void mm_flags (MAILSTREAM *stream,unsigned long number)
  17218. {
  17219. }
  17220. void mm_notify (MAILSTREAM *stream,char *string,long errflg)
  17221. {
  17222. }
  17223. void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17224. {
  17225. }
  17226. void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17227. {
  17228. }
  17229. void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
  17230. {
  17231. }
  17232. void mm_log (char *string,long errflg)
  17233. {
  17234. }
  17235. void mm_dlog (char *string)
  17236. {
  17237. }
  17238. void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
  17239. {
  17240. }
  17241. void mm_critical (MAILSTREAM *stream)
  17242. {
  17243. }
  17244. void mm_nocritical (MAILSTREAM *stream)
  17245. {
  17246. }
  17247. long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
  17248. {
  17249. }
  17250. void mm_fatal (char *string)
  17251. {
  17252. }
  17253. int
  17254. main ()
  17255. {
  17256. long check = mail_expunge_full(NULL, "", 0);
  17257. ;
  17258. return 0;
  17259. }
  17260. _ACEOF
  17261. if ac_fn_c_try_link "$LINENO"; then :
  17262. ac_cv_imap_tk2006="yes"
  17263. else
  17264. ac_cv_imap_tk2006="no"
  17265. fi
  17266. rm -f core conftest.err conftest.$ac_objext \
  17267. conftest$ac_exeext conftest.$ac_ext
  17268. fi
  17269. fi
  17270. fi
  17271. fi
  17272. if test "${IMAP_TK_DIR}" = "system"; then
  17273. #We will enter here if user specified "system" or if any of above checks failed
  17274. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for system c-client library..." >&5
  17275. $as_echo_n "checking for system c-client library...... " >&6; }
  17276. CPPFLAGS="${saved_cppflags}"
  17277. LIBS="${saved_libs}"
  17278. imap_ldflags=""
  17279. imap_libs="-lc-client"
  17280. imap_include="-DUSE_SYSTEM_IMAP" #Try the imap directory first
  17281. CPPFLAGS="${CPPFLAGS} ${imap_include}"
  17282. LIBS="${LIBS} ${imap_libs} "`echo ${imap_ldflags}`
  17283. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17284. /* end confdefs.h. */
  17285. #include <stdio.h>
  17286. #include <imap/c-client.h>
  17287. void mm_searched (MAILSTREAM *stream,unsigned long number)
  17288. {
  17289. }
  17290. void mm_exists (MAILSTREAM *stream,unsigned long number)
  17291. {
  17292. }
  17293. void mm_expunged (MAILSTREAM *stream,unsigned long number)
  17294. {
  17295. }
  17296. void mm_flags (MAILSTREAM *stream,unsigned long number)
  17297. {
  17298. }
  17299. void mm_notify (MAILSTREAM *stream,char *string,long errflg)
  17300. {
  17301. }
  17302. void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17303. {
  17304. }
  17305. void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17306. {
  17307. }
  17308. void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
  17309. {
  17310. }
  17311. void mm_log (char *string,long errflg)
  17312. {
  17313. }
  17314. void mm_dlog (char *string)
  17315. {
  17316. }
  17317. void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
  17318. {
  17319. }
  17320. void mm_critical (MAILSTREAM *stream)
  17321. {
  17322. }
  17323. void mm_nocritical (MAILSTREAM *stream)
  17324. {
  17325. }
  17326. long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
  17327. {
  17328. }
  17329. void mm_fatal (char *string)
  17330. {
  17331. }
  17332. int
  17333. main ()
  17334. {
  17335. MAILSTREAM *foo = mail_open(NULL, "", 0);
  17336. ;
  17337. return 0;
  17338. }
  17339. _ACEOF
  17340. if ac_fn_c_try_link "$LINENO"; then :
  17341. ac_cv_imap_tk="yes"
  17342. else
  17343. ac_cv_imap_tk="no"
  17344. fi
  17345. rm -f core conftest.err conftest.$ac_objext \
  17346. conftest$ac_exeext conftest.$ac_ext
  17347. if test "${ac_cv_imap_tk}" = "yes"; then
  17348. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17349. /* end confdefs.h. */
  17350. #include <stdio.h>
  17351. #include <imap/c-client.h>
  17352. void mm_searched (MAILSTREAM *stream,unsigned long number)
  17353. {
  17354. }
  17355. void mm_exists (MAILSTREAM *stream,unsigned long number)
  17356. {
  17357. }
  17358. void mm_expunged (MAILSTREAM *stream,unsigned long number)
  17359. {
  17360. }
  17361. void mm_flags (MAILSTREAM *stream,unsigned long number)
  17362. {
  17363. }
  17364. void mm_notify (MAILSTREAM *stream,char *string,long errflg)
  17365. {
  17366. }
  17367. void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17368. {
  17369. }
  17370. void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17371. {
  17372. }
  17373. void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
  17374. {
  17375. }
  17376. void mm_log (char *string,long errflg)
  17377. {
  17378. }
  17379. void mm_dlog (char *string)
  17380. {
  17381. }
  17382. void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
  17383. {
  17384. }
  17385. void mm_critical (MAILSTREAM *stream)
  17386. {
  17387. }
  17388. void mm_nocritical (MAILSTREAM *stream)
  17389. {
  17390. }
  17391. long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
  17392. {
  17393. }
  17394. void mm_fatal (char *string)
  17395. {
  17396. }
  17397. int
  17398. main ()
  17399. {
  17400. long check = mail_expunge_full(NULL, "", 0);
  17401. ;
  17402. return 0;
  17403. }
  17404. _ACEOF
  17405. if ac_fn_c_try_link "$LINENO"; then :
  17406. ac_cv_imap_tk2006="yes"
  17407. else
  17408. ac_cv_imap_tk2006="no"
  17409. fi
  17410. rm -f core conftest.err conftest.$ac_objext \
  17411. conftest$ac_exeext conftest.$ac_ext
  17412. else #looking in imap directory didn't work, try c-client
  17413. imap_ldflags=""
  17414. imap_libs="-lc-client"
  17415. imap_include="-DUSE_SYSTEM_CCLIENT"
  17416. CPPFLAGS="${saved_cppflags}"
  17417. LIBS="${saved_libs}"
  17418. CPPFLAGS="${CPPFLAGS} ${imap_include}"
  17419. LIBS="${LIBS} ${imap_libs} "`echo ${imap_ldflags}`
  17420. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17421. /* end confdefs.h. */
  17422. #include <stdio.h>
  17423. #include <c-client/c-client.h>
  17424. void mm_searched (MAILSTREAM *stream,unsigned long number)
  17425. {
  17426. }
  17427. void mm_exists (MAILSTREAM *stream,unsigned long number)
  17428. {
  17429. }
  17430. void mm_expunged (MAILSTREAM *stream,unsigned long number)
  17431. {
  17432. }
  17433. void mm_flags (MAILSTREAM *stream,unsigned long number)
  17434. {
  17435. }
  17436. void mm_notify (MAILSTREAM *stream,char *string,long errflg)
  17437. {
  17438. }
  17439. void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17440. {
  17441. }
  17442. void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17443. {
  17444. }
  17445. void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
  17446. {
  17447. }
  17448. void mm_log (char *string,long errflg)
  17449. {
  17450. }
  17451. void mm_dlog (char *string)
  17452. {
  17453. }
  17454. void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
  17455. {
  17456. }
  17457. void mm_critical (MAILSTREAM *stream)
  17458. {
  17459. }
  17460. void mm_nocritical (MAILSTREAM *stream)
  17461. {
  17462. }
  17463. long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
  17464. {
  17465. }
  17466. void mm_fatal (char *string)
  17467. {
  17468. }
  17469. int
  17470. main ()
  17471. {
  17472. MAILSTREAM *foo = mail_open(NULL, "", 0);
  17473. ;
  17474. return 0;
  17475. }
  17476. _ACEOF
  17477. if ac_fn_c_try_link "$LINENO"; then :
  17478. ac_cv_imap_tk="yes"
  17479. else
  17480. ac_cv_imap_tk="no"
  17481. fi
  17482. rm -f core conftest.err conftest.$ac_objext \
  17483. conftest$ac_exeext conftest.$ac_ext
  17484. if test "${ac_cv_imap_tk}" = "yes"; then
  17485. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17486. /* end confdefs.h. */
  17487. #include <stdio.h>
  17488. #include <c-client/c-client.h>
  17489. void mm_searched (MAILSTREAM *stream,unsigned long number)
  17490. {
  17491. }
  17492. void mm_exists (MAILSTREAM *stream,unsigned long number)
  17493. {
  17494. }
  17495. void mm_expunged (MAILSTREAM *stream,unsigned long number)
  17496. {
  17497. }
  17498. void mm_flags (MAILSTREAM *stream,unsigned long number)
  17499. {
  17500. }
  17501. void mm_notify (MAILSTREAM *stream,char *string,long errflg)
  17502. {
  17503. }
  17504. void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17505. {
  17506. }
  17507. void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17508. {
  17509. }
  17510. void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
  17511. {
  17512. }
  17513. void mm_log (char *string,long errflg)
  17514. {
  17515. }
  17516. void mm_dlog (char *string)
  17517. {
  17518. }
  17519. void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
  17520. {
  17521. }
  17522. void mm_critical (MAILSTREAM *stream)
  17523. {
  17524. }
  17525. void mm_nocritical (MAILSTREAM *stream)
  17526. {
  17527. }
  17528. long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
  17529. {
  17530. }
  17531. void mm_fatal (char *string)
  17532. {
  17533. }
  17534. int
  17535. main ()
  17536. {
  17537. long check = mail_expunge_full(NULL, "", 0);
  17538. ;
  17539. return 0;
  17540. }
  17541. _ACEOF
  17542. if ac_fn_c_try_link "$LINENO"; then :
  17543. ac_cv_imap_tk2006="yes"
  17544. else
  17545. ac_cv_imap_tk2006="no"
  17546. fi
  17547. rm -f core conftest.err conftest.$ac_objext \
  17548. conftest$ac_exeext conftest.$ac_ext
  17549. fi
  17550. fi
  17551. fi
  17552. if test "${ac_cv_imap_tk}" = "yes"; then
  17553. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  17554. $as_echo "yes" >&6; }
  17555. IMAP_TK_LIB="${imap_libs} "`echo ${imap_ldflags}`
  17556. IMAP_TK_INCLUDE="${imap_include}"
  17557. PBX_IMAP_TK=1
  17558. $as_echo "#define HAVE_IMAP_TK 1" >>confdefs.h
  17559. if test "${ac_cv_imap_tk2006}" = "yes"; then
  17560. $as_echo "#define HAVE_IMAP_TK2006 1" >>confdefs.h
  17561. fi
  17562. else
  17563. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  17564. $as_echo "no" >&6; }
  17565. fi
  17566. CPPFLAGS="${saved_cppflags}"
  17567. LIBS="${saved_libs}"
  17568. fi
  17569. if test "x${PBX_IODBC}" != "x1" -a "${USE_IODBC}" != "no"; then
  17570. pbxlibdir=""
  17571. # if --with-IODBC=DIR has been specified, use it.
  17572. if test "x${IODBC_DIR}" != "x"; then
  17573. if test -d ${IODBC_DIR}/lib; then
  17574. pbxlibdir="-L${IODBC_DIR}/lib"
  17575. else
  17576. pbxlibdir="-L${IODBC_DIR}"
  17577. fi
  17578. fi
  17579. pbxfuncname="SQLConnect"
  17580. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  17581. AST_IODBC_FOUND=yes
  17582. else
  17583. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  17584. CFLAGS="${CFLAGS} ${PTHREAD_CFLAGS}"
  17585. as_ac_Lib=`$as_echo "ac_cv_lib_iodbc_${pbxfuncname}" | $as_tr_sh`
  17586. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -liodbc" >&5
  17587. $as_echo_n "checking for ${pbxfuncname} in -liodbc... " >&6; }
  17588. if eval \${$as_ac_Lib+:} false; then :
  17589. $as_echo_n "(cached) " >&6
  17590. else
  17591. ac_check_lib_save_LIBS=$LIBS
  17592. LIBS="-liodbc ${pbxlibdir} ${PTHREAD_LIBS} $LIBS"
  17593. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17594. /* end confdefs.h. */
  17595. /* Override any GCC internal prototype to avoid an error.
  17596. Use char because int might match the return type of a GCC
  17597. builtin and then its argument prototype would still apply. */
  17598. #ifdef __cplusplus
  17599. extern "C"
  17600. #endif
  17601. char ${pbxfuncname} ();
  17602. int
  17603. main ()
  17604. {
  17605. return ${pbxfuncname} ();
  17606. ;
  17607. return 0;
  17608. }
  17609. _ACEOF
  17610. if ac_fn_c_try_link "$LINENO"; then :
  17611. eval "$as_ac_Lib=yes"
  17612. else
  17613. eval "$as_ac_Lib=no"
  17614. fi
  17615. rm -f core conftest.err conftest.$ac_objext \
  17616. conftest$ac_exeext conftest.$ac_ext
  17617. LIBS=$ac_check_lib_save_LIBS
  17618. fi
  17619. eval ac_res=\$$as_ac_Lib
  17620. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  17621. $as_echo "$ac_res" >&6; }
  17622. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  17623. AST_IODBC_FOUND=yes
  17624. else
  17625. AST_IODBC_FOUND=no
  17626. fi
  17627. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  17628. fi
  17629. # now check for the header.
  17630. if test "${AST_IODBC_FOUND}" = "yes"; then
  17631. IODBC_LIB="${pbxlibdir} -liodbc ${PTHREAD_LIBS}"
  17632. # if --with-IODBC=DIR has been specified, use it.
  17633. if test "x${IODBC_DIR}" != "x"; then
  17634. IODBC_INCLUDE="-I${IODBC_DIR}/include"
  17635. fi
  17636. IODBC_INCLUDE="${IODBC_INCLUDE} ${PTHREAD_CFLAGS}"
  17637. if test "xsql.h" = "x" ; then # no header, assume found
  17638. IODBC_HEADER_FOUND="1"
  17639. else # check for the header
  17640. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  17641. CPPFLAGS="${CPPFLAGS} ${IODBC_INCLUDE}"
  17642. ac_fn_c_check_header_mongrel "$LINENO" "sql.h" "ac_cv_header_sql_h" "$ac_includes_default"
  17643. if test "x$ac_cv_header_sql_h" = xyes; then :
  17644. IODBC_HEADER_FOUND=1
  17645. else
  17646. IODBC_HEADER_FOUND=0
  17647. fi
  17648. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  17649. fi
  17650. if test "x${IODBC_HEADER_FOUND}" = "x0" ; then
  17651. IODBC_LIB=""
  17652. IODBC_INCLUDE=""
  17653. else
  17654. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  17655. IODBC_LIB=""
  17656. fi
  17657. PBX_IODBC=1
  17658. cat >>confdefs.h <<_ACEOF
  17659. #define HAVE_IODBC 1
  17660. _ACEOF
  17661. fi
  17662. fi
  17663. fi
  17664. if test "x${PBX_INOTIFY}" != "x1" -a "${USE_INOTIFY}" != "no"; then
  17665. pbxlibdir=""
  17666. # if --with-INOTIFY=DIR has been specified, use it.
  17667. if test "x${INOTIFY_DIR}" != "x"; then
  17668. if test -d ${INOTIFY_DIR}/lib; then
  17669. pbxlibdir="-L${INOTIFY_DIR}/lib"
  17670. else
  17671. pbxlibdir="-L${INOTIFY_DIR}"
  17672. fi
  17673. fi
  17674. pbxfuncname="inotify_init"
  17675. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  17676. AST_INOTIFY_FOUND=yes
  17677. else
  17678. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  17679. CFLAGS="${CFLAGS} "
  17680. as_ac_Lib=`$as_echo "ac_cv_lib_c_${pbxfuncname}" | $as_tr_sh`
  17681. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lc" >&5
  17682. $as_echo_n "checking for ${pbxfuncname} in -lc... " >&6; }
  17683. if eval \${$as_ac_Lib+:} false; then :
  17684. $as_echo_n "(cached) " >&6
  17685. else
  17686. ac_check_lib_save_LIBS=$LIBS
  17687. LIBS="-lc ${pbxlibdir} $LIBS"
  17688. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17689. /* end confdefs.h. */
  17690. /* Override any GCC internal prototype to avoid an error.
  17691. Use char because int might match the return type of a GCC
  17692. builtin and then its argument prototype would still apply. */
  17693. #ifdef __cplusplus
  17694. extern "C"
  17695. #endif
  17696. char ${pbxfuncname} ();
  17697. int
  17698. main ()
  17699. {
  17700. return ${pbxfuncname} ();
  17701. ;
  17702. return 0;
  17703. }
  17704. _ACEOF
  17705. if ac_fn_c_try_link "$LINENO"; then :
  17706. eval "$as_ac_Lib=yes"
  17707. else
  17708. eval "$as_ac_Lib=no"
  17709. fi
  17710. rm -f core conftest.err conftest.$ac_objext \
  17711. conftest$ac_exeext conftest.$ac_ext
  17712. LIBS=$ac_check_lib_save_LIBS
  17713. fi
  17714. eval ac_res=\$$as_ac_Lib
  17715. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  17716. $as_echo "$ac_res" >&6; }
  17717. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  17718. AST_INOTIFY_FOUND=yes
  17719. else
  17720. AST_INOTIFY_FOUND=no
  17721. fi
  17722. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  17723. fi
  17724. # now check for the header.
  17725. if test "${AST_INOTIFY_FOUND}" = "yes"; then
  17726. INOTIFY_LIB="${pbxlibdir} -lc "
  17727. # if --with-INOTIFY=DIR has been specified, use it.
  17728. if test "x${INOTIFY_DIR}" != "x"; then
  17729. INOTIFY_INCLUDE="-I${INOTIFY_DIR}/include"
  17730. fi
  17731. INOTIFY_INCLUDE="${INOTIFY_INCLUDE} "
  17732. if test "xsys/inotify.h" = "x" ; then # no header, assume found
  17733. INOTIFY_HEADER_FOUND="1"
  17734. else # check for the header
  17735. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  17736. CPPFLAGS="${CPPFLAGS} ${INOTIFY_INCLUDE}"
  17737. ac_fn_c_check_header_mongrel "$LINENO" "sys/inotify.h" "ac_cv_header_sys_inotify_h" "$ac_includes_default"
  17738. if test "x$ac_cv_header_sys_inotify_h" = xyes; then :
  17739. INOTIFY_HEADER_FOUND=1
  17740. else
  17741. INOTIFY_HEADER_FOUND=0
  17742. fi
  17743. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  17744. fi
  17745. if test "x${INOTIFY_HEADER_FOUND}" = "x0" ; then
  17746. INOTIFY_LIB=""
  17747. INOTIFY_INCLUDE=""
  17748. else
  17749. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  17750. INOTIFY_LIB=""
  17751. fi
  17752. PBX_INOTIFY=1
  17753. cat >>confdefs.h <<_ACEOF
  17754. #define HAVE_INOTIFY 1
  17755. _ACEOF
  17756. fi
  17757. fi
  17758. fi
  17759. if test "x${PBX_JACK}" != "x1" -a "${USE_JACK}" != "no"; then
  17760. pbxlibdir=""
  17761. # if --with-JACK=DIR has been specified, use it.
  17762. if test "x${JACK_DIR}" != "x"; then
  17763. if test -d ${JACK_DIR}/lib; then
  17764. pbxlibdir="-L${JACK_DIR}/lib"
  17765. else
  17766. pbxlibdir="-L${JACK_DIR}"
  17767. fi
  17768. fi
  17769. pbxfuncname="jack_activate"
  17770. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  17771. AST_JACK_FOUND=yes
  17772. else
  17773. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  17774. CFLAGS="${CFLAGS} "
  17775. as_ac_Lib=`$as_echo "ac_cv_lib_jack_${pbxfuncname}" | $as_tr_sh`
  17776. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -ljack" >&5
  17777. $as_echo_n "checking for ${pbxfuncname} in -ljack... " >&6; }
  17778. if eval \${$as_ac_Lib+:} false; then :
  17779. $as_echo_n "(cached) " >&6
  17780. else
  17781. ac_check_lib_save_LIBS=$LIBS
  17782. LIBS="-ljack ${pbxlibdir} $LIBS"
  17783. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17784. /* end confdefs.h. */
  17785. /* Override any GCC internal prototype to avoid an error.
  17786. Use char because int might match the return type of a GCC
  17787. builtin and then its argument prototype would still apply. */
  17788. #ifdef __cplusplus
  17789. extern "C"
  17790. #endif
  17791. char ${pbxfuncname} ();
  17792. int
  17793. main ()
  17794. {
  17795. return ${pbxfuncname} ();
  17796. ;
  17797. return 0;
  17798. }
  17799. _ACEOF
  17800. if ac_fn_c_try_link "$LINENO"; then :
  17801. eval "$as_ac_Lib=yes"
  17802. else
  17803. eval "$as_ac_Lib=no"
  17804. fi
  17805. rm -f core conftest.err conftest.$ac_objext \
  17806. conftest$ac_exeext conftest.$ac_ext
  17807. LIBS=$ac_check_lib_save_LIBS
  17808. fi
  17809. eval ac_res=\$$as_ac_Lib
  17810. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  17811. $as_echo "$ac_res" >&6; }
  17812. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  17813. AST_JACK_FOUND=yes
  17814. else
  17815. AST_JACK_FOUND=no
  17816. fi
  17817. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  17818. fi
  17819. # now check for the header.
  17820. if test "${AST_JACK_FOUND}" = "yes"; then
  17821. JACK_LIB="${pbxlibdir} -ljack "
  17822. # if --with-JACK=DIR has been specified, use it.
  17823. if test "x${JACK_DIR}" != "x"; then
  17824. JACK_INCLUDE="-I${JACK_DIR}/include"
  17825. fi
  17826. JACK_INCLUDE="${JACK_INCLUDE} "
  17827. if test "xjack/jack.h" = "x" ; then # no header, assume found
  17828. JACK_HEADER_FOUND="1"
  17829. else # check for the header
  17830. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  17831. CPPFLAGS="${CPPFLAGS} ${JACK_INCLUDE}"
  17832. ac_fn_c_check_header_mongrel "$LINENO" "jack/jack.h" "ac_cv_header_jack_jack_h" "$ac_includes_default"
  17833. if test "x$ac_cv_header_jack_jack_h" = xyes; then :
  17834. JACK_HEADER_FOUND=1
  17835. else
  17836. JACK_HEADER_FOUND=0
  17837. fi
  17838. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  17839. fi
  17840. if test "x${JACK_HEADER_FOUND}" = "x0" ; then
  17841. JACK_LIB=""
  17842. JACK_INCLUDE=""
  17843. else
  17844. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  17845. JACK_LIB=""
  17846. fi
  17847. PBX_JACK=1
  17848. cat >>confdefs.h <<_ACEOF
  17849. #define HAVE_JACK 1
  17850. _ACEOF
  17851. fi
  17852. fi
  17853. fi
  17854. # BSD (and OS X) equivalent of inotify
  17855. if test "x${PBX_KQUEUE}" != "x1" -a "${USE_KQUEUE}" != "no"; then
  17856. pbxlibdir=""
  17857. # if --with-KQUEUE=DIR has been specified, use it.
  17858. if test "x${KQUEUE_DIR}" != "x"; then
  17859. if test -d ${KQUEUE_DIR}/lib; then
  17860. pbxlibdir="-L${KQUEUE_DIR}/lib"
  17861. else
  17862. pbxlibdir="-L${KQUEUE_DIR}"
  17863. fi
  17864. fi
  17865. pbxfuncname="kqueue"
  17866. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  17867. AST_KQUEUE_FOUND=yes
  17868. else
  17869. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  17870. CFLAGS="${CFLAGS} "
  17871. as_ac_Lib=`$as_echo "ac_cv_lib_c_${pbxfuncname}" | $as_tr_sh`
  17872. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lc" >&5
  17873. $as_echo_n "checking for ${pbxfuncname} in -lc... " >&6; }
  17874. if eval \${$as_ac_Lib+:} false; then :
  17875. $as_echo_n "(cached) " >&6
  17876. else
  17877. ac_check_lib_save_LIBS=$LIBS
  17878. LIBS="-lc ${pbxlibdir} $LIBS"
  17879. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17880. /* end confdefs.h. */
  17881. /* Override any GCC internal prototype to avoid an error.
  17882. Use char because int might match the return type of a GCC
  17883. builtin and then its argument prototype would still apply. */
  17884. #ifdef __cplusplus
  17885. extern "C"
  17886. #endif
  17887. char ${pbxfuncname} ();
  17888. int
  17889. main ()
  17890. {
  17891. return ${pbxfuncname} ();
  17892. ;
  17893. return 0;
  17894. }
  17895. _ACEOF
  17896. if ac_fn_c_try_link "$LINENO"; then :
  17897. eval "$as_ac_Lib=yes"
  17898. else
  17899. eval "$as_ac_Lib=no"
  17900. fi
  17901. rm -f core conftest.err conftest.$ac_objext \
  17902. conftest$ac_exeext conftest.$ac_ext
  17903. LIBS=$ac_check_lib_save_LIBS
  17904. fi
  17905. eval ac_res=\$$as_ac_Lib
  17906. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  17907. $as_echo "$ac_res" >&6; }
  17908. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  17909. AST_KQUEUE_FOUND=yes
  17910. else
  17911. AST_KQUEUE_FOUND=no
  17912. fi
  17913. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  17914. fi
  17915. # now check for the header.
  17916. if test "${AST_KQUEUE_FOUND}" = "yes"; then
  17917. KQUEUE_LIB="${pbxlibdir} -lc "
  17918. # if --with-KQUEUE=DIR has been specified, use it.
  17919. if test "x${KQUEUE_DIR}" != "x"; then
  17920. KQUEUE_INCLUDE="-I${KQUEUE_DIR}/include"
  17921. fi
  17922. KQUEUE_INCLUDE="${KQUEUE_INCLUDE} "
  17923. if test "xsys/event.h" = "x" ; then # no header, assume found
  17924. KQUEUE_HEADER_FOUND="1"
  17925. else # check for the header
  17926. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  17927. CPPFLAGS="${CPPFLAGS} ${KQUEUE_INCLUDE}"
  17928. ac_fn_c_check_header_mongrel "$LINENO" "sys/event.h" "ac_cv_header_sys_event_h" "$ac_includes_default"
  17929. if test "x$ac_cv_header_sys_event_h" = xyes; then :
  17930. KQUEUE_HEADER_FOUND=1
  17931. else
  17932. KQUEUE_HEADER_FOUND=0
  17933. fi
  17934. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  17935. fi
  17936. if test "x${KQUEUE_HEADER_FOUND}" = "x0" ; then
  17937. KQUEUE_LIB=""
  17938. KQUEUE_INCLUDE=""
  17939. else
  17940. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  17941. KQUEUE_LIB=""
  17942. fi
  17943. PBX_KQUEUE=1
  17944. cat >>confdefs.h <<_ACEOF
  17945. #define HAVE_KQUEUE 1
  17946. _ACEOF
  17947. fi
  17948. fi
  17949. fi
  17950. # 64-bit version of kevent (from kqueue) on OS X
  17951. for ac_func in kevent64
  17952. do :
  17953. ac_fn_c_check_func "$LINENO" "kevent64" "ac_cv_func_kevent64"
  17954. if test "x$ac_cv_func_kevent64" = xyes; then :
  17955. cat >>confdefs.h <<_ACEOF
  17956. #define HAVE_KEVENT64 1
  17957. _ACEOF
  17958. fi
  17959. done
  17960. # Needed by unixodbc
  17961. if test "x${PBX_LTDL}" != "x1" -a "${USE_LTDL}" != "no"; then
  17962. pbxlibdir=""
  17963. # if --with-LTDL=DIR has been specified, use it.
  17964. if test "x${LTDL_DIR}" != "x"; then
  17965. if test -d ${LTDL_DIR}/lib; then
  17966. pbxlibdir="-L${LTDL_DIR}/lib"
  17967. else
  17968. pbxlibdir="-L${LTDL_DIR}"
  17969. fi
  17970. fi
  17971. pbxfuncname="lt_dlinit"
  17972. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  17973. AST_LTDL_FOUND=yes
  17974. else
  17975. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  17976. CFLAGS="${CFLAGS} "
  17977. as_ac_Lib=`$as_echo "ac_cv_lib_ltdl_${pbxfuncname}" | $as_tr_sh`
  17978. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lltdl" >&5
  17979. $as_echo_n "checking for ${pbxfuncname} in -lltdl... " >&6; }
  17980. if eval \${$as_ac_Lib+:} false; then :
  17981. $as_echo_n "(cached) " >&6
  17982. else
  17983. ac_check_lib_save_LIBS=$LIBS
  17984. LIBS="-lltdl ${pbxlibdir} $LIBS"
  17985. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17986. /* end confdefs.h. */
  17987. /* Override any GCC internal prototype to avoid an error.
  17988. Use char because int might match the return type of a GCC
  17989. builtin and then its argument prototype would still apply. */
  17990. #ifdef __cplusplus
  17991. extern "C"
  17992. #endif
  17993. char ${pbxfuncname} ();
  17994. int
  17995. main ()
  17996. {
  17997. return ${pbxfuncname} ();
  17998. ;
  17999. return 0;
  18000. }
  18001. _ACEOF
  18002. if ac_fn_c_try_link "$LINENO"; then :
  18003. eval "$as_ac_Lib=yes"
  18004. else
  18005. eval "$as_ac_Lib=no"
  18006. fi
  18007. rm -f core conftest.err conftest.$ac_objext \
  18008. conftest$ac_exeext conftest.$ac_ext
  18009. LIBS=$ac_check_lib_save_LIBS
  18010. fi
  18011. eval ac_res=\$$as_ac_Lib
  18012. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  18013. $as_echo "$ac_res" >&6; }
  18014. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  18015. AST_LTDL_FOUND=yes
  18016. else
  18017. AST_LTDL_FOUND=no
  18018. fi
  18019. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  18020. fi
  18021. # now check for the header.
  18022. if test "${AST_LTDL_FOUND}" = "yes"; then
  18023. LTDL_LIB="${pbxlibdir} -lltdl "
  18024. # if --with-LTDL=DIR has been specified, use it.
  18025. if test "x${LTDL_DIR}" != "x"; then
  18026. LTDL_INCLUDE="-I${LTDL_DIR}/include"
  18027. fi
  18028. LTDL_INCLUDE="${LTDL_INCLUDE} "
  18029. if test "xltdl.h" = "x" ; then # no header, assume found
  18030. LTDL_HEADER_FOUND="1"
  18031. else # check for the header
  18032. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  18033. CPPFLAGS="${CPPFLAGS} ${LTDL_INCLUDE}"
  18034. ac_fn_c_check_header_mongrel "$LINENO" "ltdl.h" "ac_cv_header_ltdl_h" "$ac_includes_default"
  18035. if test "x$ac_cv_header_ltdl_h" = xyes; then :
  18036. LTDL_HEADER_FOUND=1
  18037. else
  18038. LTDL_HEADER_FOUND=0
  18039. fi
  18040. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  18041. fi
  18042. if test "x${LTDL_HEADER_FOUND}" = "x0" ; then
  18043. LTDL_LIB=""
  18044. LTDL_INCLUDE=""
  18045. else
  18046. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  18047. LTDL_LIB=""
  18048. fi
  18049. PBX_LTDL=1
  18050. cat >>confdefs.h <<_ACEOF
  18051. #define HAVE_LTDL 1
  18052. _ACEOF
  18053. fi
  18054. fi
  18055. fi
  18056. if test "x${PBX_LDAP}" != "x1" -a "${USE_LDAP}" != "no"; then
  18057. pbxlibdir=""
  18058. # if --with-LDAP=DIR has been specified, use it.
  18059. if test "x${LDAP_DIR}" != "x"; then
  18060. if test -d ${LDAP_DIR}/lib; then
  18061. pbxlibdir="-L${LDAP_DIR}/lib"
  18062. else
  18063. pbxlibdir="-L${LDAP_DIR}"
  18064. fi
  18065. fi
  18066. pbxfuncname="ldap_initialize"
  18067. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  18068. AST_LDAP_FOUND=yes
  18069. else
  18070. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  18071. CFLAGS="${CFLAGS} "
  18072. as_ac_Lib=`$as_echo "ac_cv_lib_ldap_${pbxfuncname}" | $as_tr_sh`
  18073. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lldap" >&5
  18074. $as_echo_n "checking for ${pbxfuncname} in -lldap... " >&6; }
  18075. if eval \${$as_ac_Lib+:} false; then :
  18076. $as_echo_n "(cached) " >&6
  18077. else
  18078. ac_check_lib_save_LIBS=$LIBS
  18079. LIBS="-lldap ${pbxlibdir} $LIBS"
  18080. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18081. /* end confdefs.h. */
  18082. /* Override any GCC internal prototype to avoid an error.
  18083. Use char because int might match the return type of a GCC
  18084. builtin and then its argument prototype would still apply. */
  18085. #ifdef __cplusplus
  18086. extern "C"
  18087. #endif
  18088. char ${pbxfuncname} ();
  18089. int
  18090. main ()
  18091. {
  18092. return ${pbxfuncname} ();
  18093. ;
  18094. return 0;
  18095. }
  18096. _ACEOF
  18097. if ac_fn_c_try_link "$LINENO"; then :
  18098. eval "$as_ac_Lib=yes"
  18099. else
  18100. eval "$as_ac_Lib=no"
  18101. fi
  18102. rm -f core conftest.err conftest.$ac_objext \
  18103. conftest$ac_exeext conftest.$ac_ext
  18104. LIBS=$ac_check_lib_save_LIBS
  18105. fi
  18106. eval ac_res=\$$as_ac_Lib
  18107. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  18108. $as_echo "$ac_res" >&6; }
  18109. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  18110. AST_LDAP_FOUND=yes
  18111. else
  18112. AST_LDAP_FOUND=no
  18113. fi
  18114. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  18115. fi
  18116. # now check for the header.
  18117. if test "${AST_LDAP_FOUND}" = "yes"; then
  18118. LDAP_LIB="${pbxlibdir} -lldap "
  18119. # if --with-LDAP=DIR has been specified, use it.
  18120. if test "x${LDAP_DIR}" != "x"; then
  18121. LDAP_INCLUDE="-I${LDAP_DIR}/include"
  18122. fi
  18123. LDAP_INCLUDE="${LDAP_INCLUDE} "
  18124. if test "xldap.h" = "x" ; then # no header, assume found
  18125. LDAP_HEADER_FOUND="1"
  18126. else # check for the header
  18127. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  18128. CPPFLAGS="${CPPFLAGS} ${LDAP_INCLUDE}"
  18129. ac_fn_c_check_header_mongrel "$LINENO" "ldap.h" "ac_cv_header_ldap_h" "$ac_includes_default"
  18130. if test "x$ac_cv_header_ldap_h" = xyes; then :
  18131. LDAP_HEADER_FOUND=1
  18132. else
  18133. LDAP_HEADER_FOUND=0
  18134. fi
  18135. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  18136. fi
  18137. if test "x${LDAP_HEADER_FOUND}" = "x0" ; then
  18138. LDAP_LIB=""
  18139. LDAP_INCLUDE=""
  18140. else
  18141. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  18142. LDAP_LIB=""
  18143. fi
  18144. PBX_LDAP=1
  18145. cat >>confdefs.h <<_ACEOF
  18146. #define HAVE_LDAP 1
  18147. _ACEOF
  18148. fi
  18149. fi
  18150. fi
  18151. if test "x${PBX_MISDN}" != "x1" -a "${USE_MISDN}" != "no"; then
  18152. pbxlibdir=""
  18153. # if --with-MISDN=DIR has been specified, use it.
  18154. if test "x${MISDN_DIR}" != "x"; then
  18155. if test -d ${MISDN_DIR}/lib; then
  18156. pbxlibdir="-L${MISDN_DIR}/lib"
  18157. else
  18158. pbxlibdir="-L${MISDN_DIR}"
  18159. fi
  18160. fi
  18161. pbxfuncname="mISDN_open"
  18162. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  18163. AST_MISDN_FOUND=yes
  18164. else
  18165. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  18166. CFLAGS="${CFLAGS} "
  18167. as_ac_Lib=`$as_echo "ac_cv_lib_mISDN_${pbxfuncname}" | $as_tr_sh`
  18168. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lmISDN" >&5
  18169. $as_echo_n "checking for ${pbxfuncname} in -lmISDN... " >&6; }
  18170. if eval \${$as_ac_Lib+:} false; then :
  18171. $as_echo_n "(cached) " >&6
  18172. else
  18173. ac_check_lib_save_LIBS=$LIBS
  18174. LIBS="-lmISDN ${pbxlibdir} $LIBS"
  18175. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18176. /* end confdefs.h. */
  18177. /* Override any GCC internal prototype to avoid an error.
  18178. Use char because int might match the return type of a GCC
  18179. builtin and then its argument prototype would still apply. */
  18180. #ifdef __cplusplus
  18181. extern "C"
  18182. #endif
  18183. char ${pbxfuncname} ();
  18184. int
  18185. main ()
  18186. {
  18187. return ${pbxfuncname} ();
  18188. ;
  18189. return 0;
  18190. }
  18191. _ACEOF
  18192. if ac_fn_c_try_link "$LINENO"; then :
  18193. eval "$as_ac_Lib=yes"
  18194. else
  18195. eval "$as_ac_Lib=no"
  18196. fi
  18197. rm -f core conftest.err conftest.$ac_objext \
  18198. conftest$ac_exeext conftest.$ac_ext
  18199. LIBS=$ac_check_lib_save_LIBS
  18200. fi
  18201. eval ac_res=\$$as_ac_Lib
  18202. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  18203. $as_echo "$ac_res" >&6; }
  18204. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  18205. AST_MISDN_FOUND=yes
  18206. else
  18207. AST_MISDN_FOUND=no
  18208. fi
  18209. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  18210. fi
  18211. # now check for the header.
  18212. if test "${AST_MISDN_FOUND}" = "yes"; then
  18213. MISDN_LIB="${pbxlibdir} -lmISDN "
  18214. # if --with-MISDN=DIR has been specified, use it.
  18215. if test "x${MISDN_DIR}" != "x"; then
  18216. MISDN_INCLUDE="-I${MISDN_DIR}/include"
  18217. fi
  18218. MISDN_INCLUDE="${MISDN_INCLUDE} "
  18219. if test "xmISDNuser/mISDNlib.h" = "x" ; then # no header, assume found
  18220. MISDN_HEADER_FOUND="1"
  18221. else # check for the header
  18222. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  18223. CPPFLAGS="${CPPFLAGS} ${MISDN_INCLUDE}"
  18224. ac_fn_c_check_header_mongrel "$LINENO" "mISDNuser/mISDNlib.h" "ac_cv_header_mISDNuser_mISDNlib_h" "$ac_includes_default"
  18225. if test "x$ac_cv_header_mISDNuser_mISDNlib_h" = xyes; then :
  18226. MISDN_HEADER_FOUND=1
  18227. else
  18228. MISDN_HEADER_FOUND=0
  18229. fi
  18230. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  18231. fi
  18232. if test "x${MISDN_HEADER_FOUND}" = "x0" ; then
  18233. MISDN_LIB=""
  18234. MISDN_INCLUDE=""
  18235. else
  18236. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  18237. MISDN_LIB=""
  18238. fi
  18239. PBX_MISDN=1
  18240. cat >>confdefs.h <<_ACEOF
  18241. #define HAVE_MISDN 1
  18242. _ACEOF
  18243. fi
  18244. fi
  18245. fi
  18246. if test "${PBX_MISDN}" = 1; then
  18247. if test "x${PBX_ISDNNET}" != "x1" -a "${USE_ISDNNET}" != "no"; then
  18248. pbxlibdir=""
  18249. # if --with-ISDNNET=DIR has been specified, use it.
  18250. if test "x${ISDNNET_DIR}" != "x"; then
  18251. if test -d ${ISDNNET_DIR}/lib; then
  18252. pbxlibdir="-L${ISDNNET_DIR}/lib"
  18253. else
  18254. pbxlibdir="-L${ISDNNET_DIR}"
  18255. fi
  18256. fi
  18257. pbxfuncname="init_manager"
  18258. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  18259. AST_ISDNNET_FOUND=yes
  18260. else
  18261. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  18262. CFLAGS="${CFLAGS} "
  18263. as_ac_Lib=`$as_echo "ac_cv_lib_isdnnet_${pbxfuncname}" | $as_tr_sh`
  18264. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lisdnnet" >&5
  18265. $as_echo_n "checking for ${pbxfuncname} in -lisdnnet... " >&6; }
  18266. if eval \${$as_ac_Lib+:} false; then :
  18267. $as_echo_n "(cached) " >&6
  18268. else
  18269. ac_check_lib_save_LIBS=$LIBS
  18270. LIBS="-lisdnnet ${pbxlibdir} -lmISDN -lpthread $LIBS"
  18271. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18272. /* end confdefs.h. */
  18273. /* Override any GCC internal prototype to avoid an error.
  18274. Use char because int might match the return type of a GCC
  18275. builtin and then its argument prototype would still apply. */
  18276. #ifdef __cplusplus
  18277. extern "C"
  18278. #endif
  18279. char ${pbxfuncname} ();
  18280. int
  18281. main ()
  18282. {
  18283. return ${pbxfuncname} ();
  18284. ;
  18285. return 0;
  18286. }
  18287. _ACEOF
  18288. if ac_fn_c_try_link "$LINENO"; then :
  18289. eval "$as_ac_Lib=yes"
  18290. else
  18291. eval "$as_ac_Lib=no"
  18292. fi
  18293. rm -f core conftest.err conftest.$ac_objext \
  18294. conftest$ac_exeext conftest.$ac_ext
  18295. LIBS=$ac_check_lib_save_LIBS
  18296. fi
  18297. eval ac_res=\$$as_ac_Lib
  18298. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  18299. $as_echo "$ac_res" >&6; }
  18300. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  18301. AST_ISDNNET_FOUND=yes
  18302. else
  18303. AST_ISDNNET_FOUND=no
  18304. fi
  18305. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  18306. fi
  18307. # now check for the header.
  18308. if test "${AST_ISDNNET_FOUND}" = "yes"; then
  18309. ISDNNET_LIB="${pbxlibdir} -lisdnnet -lmISDN -lpthread"
  18310. # if --with-ISDNNET=DIR has been specified, use it.
  18311. if test "x${ISDNNET_DIR}" != "x"; then
  18312. ISDNNET_INCLUDE="-I${ISDNNET_DIR}/include"
  18313. fi
  18314. ISDNNET_INCLUDE="${ISDNNET_INCLUDE} "
  18315. if test "xmISDNuser/isdn_net.h" = "x" ; then # no header, assume found
  18316. ISDNNET_HEADER_FOUND="1"
  18317. else # check for the header
  18318. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  18319. CPPFLAGS="${CPPFLAGS} ${ISDNNET_INCLUDE}"
  18320. ac_fn_c_check_header_mongrel "$LINENO" "mISDNuser/isdn_net.h" "ac_cv_header_mISDNuser_isdn_net_h" "$ac_includes_default"
  18321. if test "x$ac_cv_header_mISDNuser_isdn_net_h" = xyes; then :
  18322. ISDNNET_HEADER_FOUND=1
  18323. else
  18324. ISDNNET_HEADER_FOUND=0
  18325. fi
  18326. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  18327. fi
  18328. if test "x${ISDNNET_HEADER_FOUND}" = "x0" ; then
  18329. ISDNNET_LIB=""
  18330. ISDNNET_INCLUDE=""
  18331. else
  18332. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  18333. ISDNNET_LIB=""
  18334. fi
  18335. PBX_ISDNNET=1
  18336. cat >>confdefs.h <<_ACEOF
  18337. #define HAVE_ISDNNET 1
  18338. _ACEOF
  18339. fi
  18340. fi
  18341. fi
  18342. if test "x${PBX_SUPPSERV}" != "x1" -a "${USE_SUPPSERV}" != "no"; then
  18343. pbxlibdir=""
  18344. # if --with-SUPPSERV=DIR has been specified, use it.
  18345. if test "x${SUPPSERV_DIR}" != "x"; then
  18346. if test -d ${SUPPSERV_DIR}/lib; then
  18347. pbxlibdir="-L${SUPPSERV_DIR}/lib"
  18348. else
  18349. pbxlibdir="-L${SUPPSERV_DIR}"
  18350. fi
  18351. fi
  18352. pbxfuncname="encodeFac"
  18353. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  18354. AST_SUPPSERV_FOUND=yes
  18355. else
  18356. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  18357. CFLAGS="${CFLAGS} "
  18358. as_ac_Lib=`$as_echo "ac_cv_lib_suppserv_${pbxfuncname}" | $as_tr_sh`
  18359. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lsuppserv" >&5
  18360. $as_echo_n "checking for ${pbxfuncname} in -lsuppserv... " >&6; }
  18361. if eval \${$as_ac_Lib+:} false; then :
  18362. $as_echo_n "(cached) " >&6
  18363. else
  18364. ac_check_lib_save_LIBS=$LIBS
  18365. LIBS="-lsuppserv ${pbxlibdir} $LIBS"
  18366. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18367. /* end confdefs.h. */
  18368. /* Override any GCC internal prototype to avoid an error.
  18369. Use char because int might match the return type of a GCC
  18370. builtin and then its argument prototype would still apply. */
  18371. #ifdef __cplusplus
  18372. extern "C"
  18373. #endif
  18374. char ${pbxfuncname} ();
  18375. int
  18376. main ()
  18377. {
  18378. return ${pbxfuncname} ();
  18379. ;
  18380. return 0;
  18381. }
  18382. _ACEOF
  18383. if ac_fn_c_try_link "$LINENO"; then :
  18384. eval "$as_ac_Lib=yes"
  18385. else
  18386. eval "$as_ac_Lib=no"
  18387. fi
  18388. rm -f core conftest.err conftest.$ac_objext \
  18389. conftest$ac_exeext conftest.$ac_ext
  18390. LIBS=$ac_check_lib_save_LIBS
  18391. fi
  18392. eval ac_res=\$$as_ac_Lib
  18393. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  18394. $as_echo "$ac_res" >&6; }
  18395. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  18396. AST_SUPPSERV_FOUND=yes
  18397. else
  18398. AST_SUPPSERV_FOUND=no
  18399. fi
  18400. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  18401. fi
  18402. # now check for the header.
  18403. if test "${AST_SUPPSERV_FOUND}" = "yes"; then
  18404. SUPPSERV_LIB="${pbxlibdir} -lsuppserv "
  18405. # if --with-SUPPSERV=DIR has been specified, use it.
  18406. if test "x${SUPPSERV_DIR}" != "x"; then
  18407. SUPPSERV_INCLUDE="-I${SUPPSERV_DIR}/include"
  18408. fi
  18409. SUPPSERV_INCLUDE="${SUPPSERV_INCLUDE} "
  18410. if test "xmISDNuser/suppserv.h" = "x" ; then # no header, assume found
  18411. SUPPSERV_HEADER_FOUND="1"
  18412. else # check for the header
  18413. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  18414. CPPFLAGS="${CPPFLAGS} ${SUPPSERV_INCLUDE}"
  18415. ac_fn_c_check_header_mongrel "$LINENO" "mISDNuser/suppserv.h" "ac_cv_header_mISDNuser_suppserv_h" "$ac_includes_default"
  18416. if test "x$ac_cv_header_mISDNuser_suppserv_h" = xyes; then :
  18417. SUPPSERV_HEADER_FOUND=1
  18418. else
  18419. SUPPSERV_HEADER_FOUND=0
  18420. fi
  18421. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  18422. fi
  18423. if test "x${SUPPSERV_HEADER_FOUND}" = "x0" ; then
  18424. SUPPSERV_LIB=""
  18425. SUPPSERV_INCLUDE=""
  18426. else
  18427. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  18428. SUPPSERV_LIB=""
  18429. fi
  18430. PBX_SUPPSERV=1
  18431. cat >>confdefs.h <<_ACEOF
  18432. #define HAVE_SUPPSERV 1
  18433. _ACEOF
  18434. fi
  18435. fi
  18436. fi
  18437. if test "x${PBX_MISDN_FAC_RESULT}" != "x1"; then
  18438. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Fac_RESULT in mISDNuser/suppserv.h" >&5
  18439. $as_echo_n "checking for Fac_RESULT in mISDNuser/suppserv.h... " >&6; }
  18440. saved_cppflags="${CPPFLAGS}"
  18441. if test "x${MISDN_FAC_RESULT_DIR}" != "x"; then
  18442. MISDN_FAC_RESULT_INCLUDE="-I${MISDN_FAC_RESULT_DIR}/include"
  18443. fi
  18444. CPPFLAGS="${CPPFLAGS} ${MISDN_FAC_RESULT_INCLUDE}"
  18445. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18446. /* end confdefs.h. */
  18447. #include <mISDNuser/suppserv.h>
  18448. int
  18449. main ()
  18450. {
  18451. #if defined(Fac_RESULT)
  18452. int foo = 0;
  18453. #else
  18454. int foo = bar;
  18455. #endif
  18456. 0
  18457. ;
  18458. return 0;
  18459. }
  18460. _ACEOF
  18461. if ac_fn_c_try_compile "$LINENO"; then :
  18462. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  18463. $as_echo "yes" >&6; }
  18464. PBX_MISDN_FAC_RESULT=1
  18465. $as_echo "#define HAVE_MISDN_FAC_RESULT 1" >>confdefs.h
  18466. else
  18467. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  18468. $as_echo "no" >&6; }
  18469. fi
  18470. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  18471. CPPFLAGS="${saved_cppflags}"
  18472. fi
  18473. if test "x${PBX_MISDN_FAC_ERROR}" != "x1"; then
  18474. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Fac_ERROR in mISDNuser/suppserv.h" >&5
  18475. $as_echo_n "checking for Fac_ERROR in mISDNuser/suppserv.h... " >&6; }
  18476. saved_cppflags="${CPPFLAGS}"
  18477. if test "x${MISDN_FAC_ERROR_DIR}" != "x"; then
  18478. MISDN_FAC_ERROR_INCLUDE="-I${MISDN_FAC_ERROR_DIR}/include"
  18479. fi
  18480. CPPFLAGS="${CPPFLAGS} ${MISDN_FAC_ERROR_INCLUDE}"
  18481. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18482. /* end confdefs.h. */
  18483. #include <mISDNuser/suppserv.h>
  18484. int
  18485. main ()
  18486. {
  18487. #if defined(Fac_ERROR)
  18488. int foo = 0;
  18489. #else
  18490. int foo = bar;
  18491. #endif
  18492. 0
  18493. ;
  18494. return 0;
  18495. }
  18496. _ACEOF
  18497. if ac_fn_c_try_compile "$LINENO"; then :
  18498. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  18499. $as_echo "yes" >&6; }
  18500. PBX_MISDN_FAC_ERROR=1
  18501. $as_echo "#define HAVE_MISDN_FAC_ERROR 1" >>confdefs.h
  18502. else
  18503. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  18504. $as_echo "no" >&6; }
  18505. fi
  18506. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  18507. CPPFLAGS="${saved_cppflags}"
  18508. fi
  18509. ac_fn_c_check_header_mongrel "$LINENO" "linux/mISDNdsp.h" "ac_cv_header_linux_mISDNdsp_h" "$ac_includes_default"
  18510. if test "x$ac_cv_header_linux_mISDNdsp_h" = xyes; then :
  18511. cat >>confdefs.h <<_ACEOF
  18512. #define MISDN_1_2 1
  18513. _ACEOF
  18514. fi
  18515. ac_fn_c_check_member "$LINENO" "Q931_info_t" "redirect_dn" "ac_cv_member_Q931_info_t_redirect_dn" "#include <mISDNuser/mISDNlib.h>
  18516. "
  18517. if test "x$ac_cv_member_Q931_info_t_redirect_dn" = xyes; then :
  18518. else
  18519. PBX_MISDN=0
  18520. fi
  18521. fi
  18522. if test "x${PBX_MYSQLCLIENT}" != "x1" -a "${USE_MYSQLCLIENT}" != "no"; then
  18523. PBX_MYSQLCLIENT=0
  18524. if test -n "$ac_tool_prefix"; then
  18525. # Extract the first word of "${ac_tool_prefix}mysql_config", so it can be a program name with args.
  18526. set dummy ${ac_tool_prefix}mysql_config; ac_word=$2
  18527. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  18528. $as_echo_n "checking for $ac_word... " >&6; }
  18529. if ${ac_cv_path_CONFIG_MYSQLCLIENT+:} false; then :
  18530. $as_echo_n "(cached) " >&6
  18531. else
  18532. case $CONFIG_MYSQLCLIENT in
  18533. [\\/]* | ?:[\\/]*)
  18534. ac_cv_path_CONFIG_MYSQLCLIENT="$CONFIG_MYSQLCLIENT" # Let the user override the test with a path.
  18535. ;;
  18536. *)
  18537. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  18538. as_dummy="${MYSQLCLIENT_DIR}/bin:$PATH"
  18539. for as_dir in $as_dummy
  18540. do
  18541. IFS=$as_save_IFS
  18542. test -z "$as_dir" && as_dir=.
  18543. for ac_exec_ext in '' $ac_executable_extensions; do
  18544. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  18545. ac_cv_path_CONFIG_MYSQLCLIENT="$as_dir/$ac_word$ac_exec_ext"
  18546. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  18547. break 2
  18548. fi
  18549. done
  18550. done
  18551. IFS=$as_save_IFS
  18552. ;;
  18553. esac
  18554. fi
  18555. CONFIG_MYSQLCLIENT=$ac_cv_path_CONFIG_MYSQLCLIENT
  18556. if test -n "$CONFIG_MYSQLCLIENT"; then
  18557. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONFIG_MYSQLCLIENT" >&5
  18558. $as_echo "$CONFIG_MYSQLCLIENT" >&6; }
  18559. else
  18560. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  18561. $as_echo "no" >&6; }
  18562. fi
  18563. fi
  18564. if test -z "$ac_cv_path_CONFIG_MYSQLCLIENT"; then
  18565. ac_pt_CONFIG_MYSQLCLIENT=$CONFIG_MYSQLCLIENT
  18566. # Extract the first word of "mysql_config", so it can be a program name with args.
  18567. set dummy mysql_config; ac_word=$2
  18568. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  18569. $as_echo_n "checking for $ac_word... " >&6; }
  18570. if ${ac_cv_path_ac_pt_CONFIG_MYSQLCLIENT+:} false; then :
  18571. $as_echo_n "(cached) " >&6
  18572. else
  18573. case $ac_pt_CONFIG_MYSQLCLIENT in
  18574. [\\/]* | ?:[\\/]*)
  18575. ac_cv_path_ac_pt_CONFIG_MYSQLCLIENT="$ac_pt_CONFIG_MYSQLCLIENT" # Let the user override the test with a path.
  18576. ;;
  18577. *)
  18578. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  18579. as_dummy="${MYSQLCLIENT_DIR}/bin:$PATH"
  18580. for as_dir in $as_dummy
  18581. do
  18582. IFS=$as_save_IFS
  18583. test -z "$as_dir" && as_dir=.
  18584. for ac_exec_ext in '' $ac_executable_extensions; do
  18585. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  18586. ac_cv_path_ac_pt_CONFIG_MYSQLCLIENT="$as_dir/$ac_word$ac_exec_ext"
  18587. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  18588. break 2
  18589. fi
  18590. done
  18591. done
  18592. IFS=$as_save_IFS
  18593. ;;
  18594. esac
  18595. fi
  18596. ac_pt_CONFIG_MYSQLCLIENT=$ac_cv_path_ac_pt_CONFIG_MYSQLCLIENT
  18597. if test -n "$ac_pt_CONFIG_MYSQLCLIENT"; then
  18598. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CONFIG_MYSQLCLIENT" >&5
  18599. $as_echo "$ac_pt_CONFIG_MYSQLCLIENT" >&6; }
  18600. else
  18601. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  18602. $as_echo "no" >&6; }
  18603. fi
  18604. if test "x$ac_pt_CONFIG_MYSQLCLIENT" = x; then
  18605. CONFIG_MYSQLCLIENT="No"
  18606. else
  18607. case $cross_compiling:$ac_tool_warned in
  18608. yes:)
  18609. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  18610. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  18611. ac_tool_warned=yes ;;
  18612. esac
  18613. CONFIG_MYSQLCLIENT=$ac_pt_CONFIG_MYSQLCLIENT
  18614. fi
  18615. else
  18616. CONFIG_MYSQLCLIENT="$ac_cv_path_CONFIG_MYSQLCLIENT"
  18617. fi
  18618. if test ! "x${CONFIG_MYSQLCLIENT}" = xNo; then
  18619. if test x"" = x ; then A=--cflags ; else A="" ; fi
  18620. MYSQLCLIENT_INCLUDE=$(${CONFIG_MYSQLCLIENT} $A)
  18621. MYSQLCLIENT_INCLUDE=$(echo ${MYSQLCLIENT_INCLUDE} | $SED -e "s|-I|-I${MYSQLCLIENT_DIR}|g")
  18622. if test x"" = x ; then A=--libs ; else A="" ; fi
  18623. MYSQLCLIENT_LIB=$(${CONFIG_MYSQLCLIENT} $A)
  18624. MYSQLCLIENT_LIB=$(echo ${MYSQLCLIENT_LIB} | $SED -e "s|-L|-L${MYSQLCLIENT_DIR}|g")
  18625. if test x"" != x ; then
  18626. saved_cppflags="${CPPFLAGS}"
  18627. CPPFLAGS="${CPPFLAGS} ${MYSQLCLIENT_INCLUDE}"
  18628. saved_libs="${LIBS}"
  18629. LIBS=${MYSQLCLIENT_LIB}
  18630. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18631. /* end confdefs.h. */
  18632. int
  18633. main ()
  18634. {
  18635. ;
  18636. ;
  18637. return 0;
  18638. }
  18639. _ACEOF
  18640. if ac_fn_c_try_link "$LINENO"; then :
  18641. PBX_MYSQLCLIENT=1
  18642. $as_echo "#define HAVE_MYSQLCLIENT 1" >>confdefs.h
  18643. fi
  18644. rm -f core conftest.err conftest.$ac_objext \
  18645. conftest$ac_exeext conftest.$ac_ext
  18646. CPPFLAGS="${saved_cppflags}"
  18647. LIBS="${saved_libs}"
  18648. else
  18649. PBX_MYSQLCLIENT=1
  18650. $as_echo "#define HAVE_MYSQLCLIENT 1" >>confdefs.h
  18651. fi
  18652. fi
  18653. fi
  18654. if test "x${PBX_NBS}" != "x1" -a "${USE_NBS}" != "no"; then
  18655. pbxlibdir=""
  18656. # if --with-NBS=DIR has been specified, use it.
  18657. if test "x${NBS_DIR}" != "x"; then
  18658. if test -d ${NBS_DIR}/lib; then
  18659. pbxlibdir="-L${NBS_DIR}/lib"
  18660. else
  18661. pbxlibdir="-L${NBS_DIR}"
  18662. fi
  18663. fi
  18664. pbxfuncname="nbs_connect"
  18665. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  18666. AST_NBS_FOUND=yes
  18667. else
  18668. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  18669. CFLAGS="${CFLAGS} "
  18670. as_ac_Lib=`$as_echo "ac_cv_lib_nbs_${pbxfuncname}" | $as_tr_sh`
  18671. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lnbs" >&5
  18672. $as_echo_n "checking for ${pbxfuncname} in -lnbs... " >&6; }
  18673. if eval \${$as_ac_Lib+:} false; then :
  18674. $as_echo_n "(cached) " >&6
  18675. else
  18676. ac_check_lib_save_LIBS=$LIBS
  18677. LIBS="-lnbs ${pbxlibdir} $LIBS"
  18678. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18679. /* end confdefs.h. */
  18680. /* Override any GCC internal prototype to avoid an error.
  18681. Use char because int might match the return type of a GCC
  18682. builtin and then its argument prototype would still apply. */
  18683. #ifdef __cplusplus
  18684. extern "C"
  18685. #endif
  18686. char ${pbxfuncname} ();
  18687. int
  18688. main ()
  18689. {
  18690. return ${pbxfuncname} ();
  18691. ;
  18692. return 0;
  18693. }
  18694. _ACEOF
  18695. if ac_fn_c_try_link "$LINENO"; then :
  18696. eval "$as_ac_Lib=yes"
  18697. else
  18698. eval "$as_ac_Lib=no"
  18699. fi
  18700. rm -f core conftest.err conftest.$ac_objext \
  18701. conftest$ac_exeext conftest.$ac_ext
  18702. LIBS=$ac_check_lib_save_LIBS
  18703. fi
  18704. eval ac_res=\$$as_ac_Lib
  18705. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  18706. $as_echo "$ac_res" >&6; }
  18707. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  18708. AST_NBS_FOUND=yes
  18709. else
  18710. AST_NBS_FOUND=no
  18711. fi
  18712. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  18713. fi
  18714. # now check for the header.
  18715. if test "${AST_NBS_FOUND}" = "yes"; then
  18716. NBS_LIB="${pbxlibdir} -lnbs "
  18717. # if --with-NBS=DIR has been specified, use it.
  18718. if test "x${NBS_DIR}" != "x"; then
  18719. NBS_INCLUDE="-I${NBS_DIR}/include"
  18720. fi
  18721. NBS_INCLUDE="${NBS_INCLUDE} "
  18722. if test "xnbs.h" = "x" ; then # no header, assume found
  18723. NBS_HEADER_FOUND="1"
  18724. else # check for the header
  18725. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  18726. CPPFLAGS="${CPPFLAGS} ${NBS_INCLUDE}"
  18727. ac_fn_c_check_header_mongrel "$LINENO" "nbs.h" "ac_cv_header_nbs_h" "$ac_includes_default"
  18728. if test "x$ac_cv_header_nbs_h" = xyes; then :
  18729. NBS_HEADER_FOUND=1
  18730. else
  18731. NBS_HEADER_FOUND=0
  18732. fi
  18733. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  18734. fi
  18735. if test "x${NBS_HEADER_FOUND}" = "x0" ; then
  18736. NBS_LIB=""
  18737. NBS_INCLUDE=""
  18738. else
  18739. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  18740. NBS_LIB=""
  18741. fi
  18742. PBX_NBS=1
  18743. cat >>confdefs.h <<_ACEOF
  18744. #define HAVE_NBS 1
  18745. _ACEOF
  18746. fi
  18747. fi
  18748. fi
  18749. if test "x${PBX_NEON}" != "x1" -a "${USE_NEON}" != "no"; then
  18750. PBX_NEON=0
  18751. if test -n "$ac_tool_prefix"; then
  18752. # Extract the first word of "${ac_tool_prefix}neon-config", so it can be a program name with args.
  18753. set dummy ${ac_tool_prefix}neon-config; ac_word=$2
  18754. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  18755. $as_echo_n "checking for $ac_word... " >&6; }
  18756. if ${ac_cv_path_CONFIG_NEON+:} false; then :
  18757. $as_echo_n "(cached) " >&6
  18758. else
  18759. case $CONFIG_NEON in
  18760. [\\/]* | ?:[\\/]*)
  18761. ac_cv_path_CONFIG_NEON="$CONFIG_NEON" # Let the user override the test with a path.
  18762. ;;
  18763. *)
  18764. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  18765. as_dummy="${NEON_DIR}/bin:$PATH"
  18766. for as_dir in $as_dummy
  18767. do
  18768. IFS=$as_save_IFS
  18769. test -z "$as_dir" && as_dir=.
  18770. for ac_exec_ext in '' $ac_executable_extensions; do
  18771. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  18772. ac_cv_path_CONFIG_NEON="$as_dir/$ac_word$ac_exec_ext"
  18773. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  18774. break 2
  18775. fi
  18776. done
  18777. done
  18778. IFS=$as_save_IFS
  18779. ;;
  18780. esac
  18781. fi
  18782. CONFIG_NEON=$ac_cv_path_CONFIG_NEON
  18783. if test -n "$CONFIG_NEON"; then
  18784. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONFIG_NEON" >&5
  18785. $as_echo "$CONFIG_NEON" >&6; }
  18786. else
  18787. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  18788. $as_echo "no" >&6; }
  18789. fi
  18790. fi
  18791. if test -z "$ac_cv_path_CONFIG_NEON"; then
  18792. ac_pt_CONFIG_NEON=$CONFIG_NEON
  18793. # Extract the first word of "neon-config", so it can be a program name with args.
  18794. set dummy neon-config; ac_word=$2
  18795. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  18796. $as_echo_n "checking for $ac_word... " >&6; }
  18797. if ${ac_cv_path_ac_pt_CONFIG_NEON+:} false; then :
  18798. $as_echo_n "(cached) " >&6
  18799. else
  18800. case $ac_pt_CONFIG_NEON in
  18801. [\\/]* | ?:[\\/]*)
  18802. ac_cv_path_ac_pt_CONFIG_NEON="$ac_pt_CONFIG_NEON" # Let the user override the test with a path.
  18803. ;;
  18804. *)
  18805. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  18806. as_dummy="${NEON_DIR}/bin:$PATH"
  18807. for as_dir in $as_dummy
  18808. do
  18809. IFS=$as_save_IFS
  18810. test -z "$as_dir" && as_dir=.
  18811. for ac_exec_ext in '' $ac_executable_extensions; do
  18812. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  18813. ac_cv_path_ac_pt_CONFIG_NEON="$as_dir/$ac_word$ac_exec_ext"
  18814. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  18815. break 2
  18816. fi
  18817. done
  18818. done
  18819. IFS=$as_save_IFS
  18820. ;;
  18821. esac
  18822. fi
  18823. ac_pt_CONFIG_NEON=$ac_cv_path_ac_pt_CONFIG_NEON
  18824. if test -n "$ac_pt_CONFIG_NEON"; then
  18825. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CONFIG_NEON" >&5
  18826. $as_echo "$ac_pt_CONFIG_NEON" >&6; }
  18827. else
  18828. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  18829. $as_echo "no" >&6; }
  18830. fi
  18831. if test "x$ac_pt_CONFIG_NEON" = x; then
  18832. CONFIG_NEON="No"
  18833. else
  18834. case $cross_compiling:$ac_tool_warned in
  18835. yes:)
  18836. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  18837. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  18838. ac_tool_warned=yes ;;
  18839. esac
  18840. CONFIG_NEON=$ac_pt_CONFIG_NEON
  18841. fi
  18842. else
  18843. CONFIG_NEON="$ac_cv_path_CONFIG_NEON"
  18844. fi
  18845. if test ! "x${CONFIG_NEON}" = xNo; then
  18846. if test x"" = x ; then A=--cflags ; else A="" ; fi
  18847. NEON_INCLUDE=$(${CONFIG_NEON} $A)
  18848. NEON_INCLUDE=$(echo ${NEON_INCLUDE} | $SED -e "s|-I|-I${NEON_DIR}|g")
  18849. if test x"" = x ; then A=--libs ; else A="" ; fi
  18850. NEON_LIB=$(${CONFIG_NEON} $A)
  18851. NEON_LIB=$(echo ${NEON_LIB} | $SED -e "s|-L|-L${NEON_DIR}|g")
  18852. if test x"" != x ; then
  18853. saved_cppflags="${CPPFLAGS}"
  18854. CPPFLAGS="${CPPFLAGS} ${NEON_INCLUDE}"
  18855. saved_libs="${LIBS}"
  18856. LIBS=${NEON_LIB}
  18857. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18858. /* end confdefs.h. */
  18859. int
  18860. main ()
  18861. {
  18862. ;
  18863. ;
  18864. return 0;
  18865. }
  18866. _ACEOF
  18867. if ac_fn_c_try_link "$LINENO"; then :
  18868. PBX_NEON=1
  18869. $as_echo "#define HAVE_NEON 1" >>confdefs.h
  18870. fi
  18871. rm -f core conftest.err conftest.$ac_objext \
  18872. conftest$ac_exeext conftest.$ac_ext
  18873. CPPFLAGS="${saved_cppflags}"
  18874. LIBS="${saved_libs}"
  18875. else
  18876. PBX_NEON=1
  18877. $as_echo "#define HAVE_NEON 1" >>confdefs.h
  18878. fi
  18879. fi
  18880. fi
  18881. if test "x${PBX_NEON29}" != "x1" -a "${USE_NEON29}" != "no"; then
  18882. PBX_NEON29=0
  18883. if test -n "$ac_tool_prefix"; then
  18884. # Extract the first word of "${ac_tool_prefix}neon-config", so it can be a program name with args.
  18885. set dummy ${ac_tool_prefix}neon-config; ac_word=$2
  18886. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  18887. $as_echo_n "checking for $ac_word... " >&6; }
  18888. if ${ac_cv_path_CONFIG_NEON29+:} false; then :
  18889. $as_echo_n "(cached) " >&6
  18890. else
  18891. case $CONFIG_NEON29 in
  18892. [\\/]* | ?:[\\/]*)
  18893. ac_cv_path_CONFIG_NEON29="$CONFIG_NEON29" # Let the user override the test with a path.
  18894. ;;
  18895. *)
  18896. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  18897. as_dummy="${NEON29_DIR}/bin:$PATH"
  18898. for as_dir in $as_dummy
  18899. do
  18900. IFS=$as_save_IFS
  18901. test -z "$as_dir" && as_dir=.
  18902. for ac_exec_ext in '' $ac_executable_extensions; do
  18903. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  18904. ac_cv_path_CONFIG_NEON29="$as_dir/$ac_word$ac_exec_ext"
  18905. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  18906. break 2
  18907. fi
  18908. done
  18909. done
  18910. IFS=$as_save_IFS
  18911. ;;
  18912. esac
  18913. fi
  18914. CONFIG_NEON29=$ac_cv_path_CONFIG_NEON29
  18915. if test -n "$CONFIG_NEON29"; then
  18916. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONFIG_NEON29" >&5
  18917. $as_echo "$CONFIG_NEON29" >&6; }
  18918. else
  18919. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  18920. $as_echo "no" >&6; }
  18921. fi
  18922. fi
  18923. if test -z "$ac_cv_path_CONFIG_NEON29"; then
  18924. ac_pt_CONFIG_NEON29=$CONFIG_NEON29
  18925. # Extract the first word of "neon-config", so it can be a program name with args.
  18926. set dummy neon-config; ac_word=$2
  18927. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  18928. $as_echo_n "checking for $ac_word... " >&6; }
  18929. if ${ac_cv_path_ac_pt_CONFIG_NEON29+:} false; then :
  18930. $as_echo_n "(cached) " >&6
  18931. else
  18932. case $ac_pt_CONFIG_NEON29 in
  18933. [\\/]* | ?:[\\/]*)
  18934. ac_cv_path_ac_pt_CONFIG_NEON29="$ac_pt_CONFIG_NEON29" # Let the user override the test with a path.
  18935. ;;
  18936. *)
  18937. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  18938. as_dummy="${NEON29_DIR}/bin:$PATH"
  18939. for as_dir in $as_dummy
  18940. do
  18941. IFS=$as_save_IFS
  18942. test -z "$as_dir" && as_dir=.
  18943. for ac_exec_ext in '' $ac_executable_extensions; do
  18944. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  18945. ac_cv_path_ac_pt_CONFIG_NEON29="$as_dir/$ac_word$ac_exec_ext"
  18946. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  18947. break 2
  18948. fi
  18949. done
  18950. done
  18951. IFS=$as_save_IFS
  18952. ;;
  18953. esac
  18954. fi
  18955. ac_pt_CONFIG_NEON29=$ac_cv_path_ac_pt_CONFIG_NEON29
  18956. if test -n "$ac_pt_CONFIG_NEON29"; then
  18957. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CONFIG_NEON29" >&5
  18958. $as_echo "$ac_pt_CONFIG_NEON29" >&6; }
  18959. else
  18960. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  18961. $as_echo "no" >&6; }
  18962. fi
  18963. if test "x$ac_pt_CONFIG_NEON29" = x; then
  18964. CONFIG_NEON29="No"
  18965. else
  18966. case $cross_compiling:$ac_tool_warned in
  18967. yes:)
  18968. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  18969. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  18970. ac_tool_warned=yes ;;
  18971. esac
  18972. CONFIG_NEON29=$ac_pt_CONFIG_NEON29
  18973. fi
  18974. else
  18975. CONFIG_NEON29="$ac_cv_path_CONFIG_NEON29"
  18976. fi
  18977. if test ! "x${CONFIG_NEON29}" = xNo; then
  18978. if test x"" = x ; then A=--cflags ; else A="" ; fi
  18979. NEON29_INCLUDE=$(${CONFIG_NEON29} $A)
  18980. NEON29_INCLUDE=$(echo ${NEON29_INCLUDE} | $SED -e "s|-I|-I${NEON29_DIR}|g")
  18981. if test x"--libs" = x ; then A=--libs ; else A="--libs" ; fi
  18982. NEON29_LIB=$(${CONFIG_NEON29} $A)
  18983. NEON29_LIB=$(echo ${NEON29_LIB} | $SED -e "s|-L|-L${NEON29_DIR}|g")
  18984. if test x"#include <ne_auth.h>" != x ; then
  18985. saved_cppflags="${CPPFLAGS}"
  18986. CPPFLAGS="${CPPFLAGS} ${NEON29_INCLUDE}"
  18987. saved_libs="${LIBS}"
  18988. LIBS=${NEON29_LIB}
  18989. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18990. /* end confdefs.h. */
  18991. #include <ne_auth.h>
  18992. int
  18993. main ()
  18994. {
  18995. #ifndef NE_AUTH_NTLM
  18996. #error Need libneon >= 0.29.0
  18997. #endif;
  18998. ;
  18999. return 0;
  19000. }
  19001. _ACEOF
  19002. if ac_fn_c_try_link "$LINENO"; then :
  19003. PBX_NEON29=1
  19004. $as_echo "#define HAVE_NEON29 1" >>confdefs.h
  19005. fi
  19006. rm -f core conftest.err conftest.$ac_objext \
  19007. conftest$ac_exeext conftest.$ac_ext
  19008. CPPFLAGS="${saved_cppflags}"
  19009. LIBS="${saved_libs}"
  19010. else
  19011. PBX_NEON29=1
  19012. $as_echo "#define HAVE_NEON29 1" >>confdefs.h
  19013. fi
  19014. fi
  19015. fi
  19016. if test "x${PBX_NETSNMP}" != "x1" -a "${USE_NETSNMP}" != "no"; then
  19017. PBX_NETSNMP=0
  19018. if test -n "$ac_tool_prefix"; then
  19019. # Extract the first word of "${ac_tool_prefix}net-snmp-config", so it can be a program name with args.
  19020. set dummy ${ac_tool_prefix}net-snmp-config; ac_word=$2
  19021. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  19022. $as_echo_n "checking for $ac_word... " >&6; }
  19023. if ${ac_cv_path_CONFIG_NETSNMP+:} false; then :
  19024. $as_echo_n "(cached) " >&6
  19025. else
  19026. case $CONFIG_NETSNMP in
  19027. [\\/]* | ?:[\\/]*)
  19028. ac_cv_path_CONFIG_NETSNMP="$CONFIG_NETSNMP" # Let the user override the test with a path.
  19029. ;;
  19030. *)
  19031. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  19032. as_dummy="${NETSNMP_DIR}/bin:$PATH"
  19033. for as_dir in $as_dummy
  19034. do
  19035. IFS=$as_save_IFS
  19036. test -z "$as_dir" && as_dir=.
  19037. for ac_exec_ext in '' $ac_executable_extensions; do
  19038. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  19039. ac_cv_path_CONFIG_NETSNMP="$as_dir/$ac_word$ac_exec_ext"
  19040. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  19041. break 2
  19042. fi
  19043. done
  19044. done
  19045. IFS=$as_save_IFS
  19046. ;;
  19047. esac
  19048. fi
  19049. CONFIG_NETSNMP=$ac_cv_path_CONFIG_NETSNMP
  19050. if test -n "$CONFIG_NETSNMP"; then
  19051. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONFIG_NETSNMP" >&5
  19052. $as_echo "$CONFIG_NETSNMP" >&6; }
  19053. else
  19054. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  19055. $as_echo "no" >&6; }
  19056. fi
  19057. fi
  19058. if test -z "$ac_cv_path_CONFIG_NETSNMP"; then
  19059. ac_pt_CONFIG_NETSNMP=$CONFIG_NETSNMP
  19060. # Extract the first word of "net-snmp-config", so it can be a program name with args.
  19061. set dummy net-snmp-config; ac_word=$2
  19062. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  19063. $as_echo_n "checking for $ac_word... " >&6; }
  19064. if ${ac_cv_path_ac_pt_CONFIG_NETSNMP+:} false; then :
  19065. $as_echo_n "(cached) " >&6
  19066. else
  19067. case $ac_pt_CONFIG_NETSNMP in
  19068. [\\/]* | ?:[\\/]*)
  19069. ac_cv_path_ac_pt_CONFIG_NETSNMP="$ac_pt_CONFIG_NETSNMP" # Let the user override the test with a path.
  19070. ;;
  19071. *)
  19072. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  19073. as_dummy="${NETSNMP_DIR}/bin:$PATH"
  19074. for as_dir in $as_dummy
  19075. do
  19076. IFS=$as_save_IFS
  19077. test -z "$as_dir" && as_dir=.
  19078. for ac_exec_ext in '' $ac_executable_extensions; do
  19079. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  19080. ac_cv_path_ac_pt_CONFIG_NETSNMP="$as_dir/$ac_word$ac_exec_ext"
  19081. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  19082. break 2
  19083. fi
  19084. done
  19085. done
  19086. IFS=$as_save_IFS
  19087. ;;
  19088. esac
  19089. fi
  19090. ac_pt_CONFIG_NETSNMP=$ac_cv_path_ac_pt_CONFIG_NETSNMP
  19091. if test -n "$ac_pt_CONFIG_NETSNMP"; then
  19092. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CONFIG_NETSNMP" >&5
  19093. $as_echo "$ac_pt_CONFIG_NETSNMP" >&6; }
  19094. else
  19095. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  19096. $as_echo "no" >&6; }
  19097. fi
  19098. if test "x$ac_pt_CONFIG_NETSNMP" = x; then
  19099. CONFIG_NETSNMP="No"
  19100. else
  19101. case $cross_compiling:$ac_tool_warned in
  19102. yes:)
  19103. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  19104. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  19105. ac_tool_warned=yes ;;
  19106. esac
  19107. CONFIG_NETSNMP=$ac_pt_CONFIG_NETSNMP
  19108. fi
  19109. else
  19110. CONFIG_NETSNMP="$ac_cv_path_CONFIG_NETSNMP"
  19111. fi
  19112. if test ! "x${CONFIG_NETSNMP}" = xNo; then
  19113. if test x"" = x ; then A=--cflags ; else A="" ; fi
  19114. NETSNMP_INCLUDE=$(${CONFIG_NETSNMP} $A)
  19115. NETSNMP_INCLUDE=$(echo ${NETSNMP_INCLUDE} | $SED -e "s|-I|-I${NETSNMP_DIR}|g")
  19116. if test x"--agent-libs" = x ; then A=--libs ; else A="--agent-libs" ; fi
  19117. NETSNMP_LIB=$(${CONFIG_NETSNMP} $A)
  19118. NETSNMP_LIB=$(echo ${NETSNMP_LIB} | $SED -e "s|-L|-L${NETSNMP_DIR}|g")
  19119. if test x"#include <net-snmp/net-snmp-config.h>
  19120. #include <net-snmp/net-snmp-includes.h>
  19121. #include <net-snmp/agent/net-snmp-agent-includes.h>" != x ; then
  19122. saved_cppflags="${CPPFLAGS}"
  19123. CPPFLAGS="${CPPFLAGS} ${NETSNMP_INCLUDE}"
  19124. saved_libs="${LIBS}"
  19125. LIBS=${NETSNMP_LIB}
  19126. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19127. /* end confdefs.h. */
  19128. #include <net-snmp/net-snmp-config.h>
  19129. #include <net-snmp/net-snmp-includes.h>
  19130. #include <net-snmp/agent/net-snmp-agent-includes.h>
  19131. int
  19132. main ()
  19133. {
  19134. int callback = snmp_register_callback(0, 0, NULL, NULL);
  19135. ;
  19136. return 0;
  19137. }
  19138. _ACEOF
  19139. if ac_fn_c_try_link "$LINENO"; then :
  19140. PBX_NETSNMP=1
  19141. $as_echo "#define HAVE_NETSNMP 1" >>confdefs.h
  19142. fi
  19143. rm -f core conftest.err conftest.$ac_objext \
  19144. conftest$ac_exeext conftest.$ac_ext
  19145. CPPFLAGS="${saved_cppflags}"
  19146. LIBS="${saved_libs}"
  19147. else
  19148. PBX_NETSNMP=1
  19149. $as_echo "#define HAVE_NETSNMP 1" >>confdefs.h
  19150. fi
  19151. fi
  19152. fi
  19153. if test "x${PBX_NEWT}" != "x1" -a "${USE_NEWT}" != "no"; then
  19154. pbxlibdir=""
  19155. # if --with-NEWT=DIR has been specified, use it.
  19156. if test "x${NEWT_DIR}" != "x"; then
  19157. if test -d ${NEWT_DIR}/lib; then
  19158. pbxlibdir="-L${NEWT_DIR}/lib"
  19159. else
  19160. pbxlibdir="-L${NEWT_DIR}"
  19161. fi
  19162. fi
  19163. pbxfuncname="newtBell"
  19164. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19165. AST_NEWT_FOUND=yes
  19166. else
  19167. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19168. CFLAGS="${CFLAGS} "
  19169. as_ac_Lib=`$as_echo "ac_cv_lib_newt_${pbxfuncname}" | $as_tr_sh`
  19170. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lnewt" >&5
  19171. $as_echo_n "checking for ${pbxfuncname} in -lnewt... " >&6; }
  19172. if eval \${$as_ac_Lib+:} false; then :
  19173. $as_echo_n "(cached) " >&6
  19174. else
  19175. ac_check_lib_save_LIBS=$LIBS
  19176. LIBS="-lnewt ${pbxlibdir} $LIBS"
  19177. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19178. /* end confdefs.h. */
  19179. /* Override any GCC internal prototype to avoid an error.
  19180. Use char because int might match the return type of a GCC
  19181. builtin and then its argument prototype would still apply. */
  19182. #ifdef __cplusplus
  19183. extern "C"
  19184. #endif
  19185. char ${pbxfuncname} ();
  19186. int
  19187. main ()
  19188. {
  19189. return ${pbxfuncname} ();
  19190. ;
  19191. return 0;
  19192. }
  19193. _ACEOF
  19194. if ac_fn_c_try_link "$LINENO"; then :
  19195. eval "$as_ac_Lib=yes"
  19196. else
  19197. eval "$as_ac_Lib=no"
  19198. fi
  19199. rm -f core conftest.err conftest.$ac_objext \
  19200. conftest$ac_exeext conftest.$ac_ext
  19201. LIBS=$ac_check_lib_save_LIBS
  19202. fi
  19203. eval ac_res=\$$as_ac_Lib
  19204. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  19205. $as_echo "$ac_res" >&6; }
  19206. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  19207. AST_NEWT_FOUND=yes
  19208. else
  19209. AST_NEWT_FOUND=no
  19210. fi
  19211. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  19212. fi
  19213. # now check for the header.
  19214. if test "${AST_NEWT_FOUND}" = "yes"; then
  19215. NEWT_LIB="${pbxlibdir} -lnewt "
  19216. # if --with-NEWT=DIR has been specified, use it.
  19217. if test "x${NEWT_DIR}" != "x"; then
  19218. NEWT_INCLUDE="-I${NEWT_DIR}/include"
  19219. fi
  19220. NEWT_INCLUDE="${NEWT_INCLUDE} "
  19221. if test "xnewt.h" = "x" ; then # no header, assume found
  19222. NEWT_HEADER_FOUND="1"
  19223. else # check for the header
  19224. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  19225. CPPFLAGS="${CPPFLAGS} ${NEWT_INCLUDE}"
  19226. ac_fn_c_check_header_mongrel "$LINENO" "newt.h" "ac_cv_header_newt_h" "$ac_includes_default"
  19227. if test "x$ac_cv_header_newt_h" = xyes; then :
  19228. NEWT_HEADER_FOUND=1
  19229. else
  19230. NEWT_HEADER_FOUND=0
  19231. fi
  19232. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  19233. fi
  19234. if test "x${NEWT_HEADER_FOUND}" = "x0" ; then
  19235. NEWT_LIB=""
  19236. NEWT_INCLUDE=""
  19237. else
  19238. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  19239. NEWT_LIB=""
  19240. fi
  19241. PBX_NEWT=1
  19242. cat >>confdefs.h <<_ACEOF
  19243. #define HAVE_NEWT 1
  19244. _ACEOF
  19245. fi
  19246. fi
  19247. fi
  19248. if test "x${PBX_UNIXODBC}" != "x1" -a "${USE_UNIXODBC}" != "no"; then
  19249. pbxlibdir=""
  19250. # if --with-UNIXODBC=DIR has been specified, use it.
  19251. if test "x${UNIXODBC_DIR}" != "x"; then
  19252. if test -d ${UNIXODBC_DIR}/lib; then
  19253. pbxlibdir="-L${UNIXODBC_DIR}/lib"
  19254. else
  19255. pbxlibdir="-L${UNIXODBC_DIR}"
  19256. fi
  19257. fi
  19258. pbxfuncname="SQLConnect"
  19259. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19260. AST_UNIXODBC_FOUND=yes
  19261. else
  19262. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19263. CFLAGS="${CFLAGS} "
  19264. as_ac_Lib=`$as_echo "ac_cv_lib_odbc_${pbxfuncname}" | $as_tr_sh`
  19265. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lodbc" >&5
  19266. $as_echo_n "checking for ${pbxfuncname} in -lodbc... " >&6; }
  19267. if eval \${$as_ac_Lib+:} false; then :
  19268. $as_echo_n "(cached) " >&6
  19269. else
  19270. ac_check_lib_save_LIBS=$LIBS
  19271. LIBS="-lodbc ${pbxlibdir} $LIBS"
  19272. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19273. /* end confdefs.h. */
  19274. /* Override any GCC internal prototype to avoid an error.
  19275. Use char because int might match the return type of a GCC
  19276. builtin and then its argument prototype would still apply. */
  19277. #ifdef __cplusplus
  19278. extern "C"
  19279. #endif
  19280. char ${pbxfuncname} ();
  19281. int
  19282. main ()
  19283. {
  19284. return ${pbxfuncname} ();
  19285. ;
  19286. return 0;
  19287. }
  19288. _ACEOF
  19289. if ac_fn_c_try_link "$LINENO"; then :
  19290. eval "$as_ac_Lib=yes"
  19291. else
  19292. eval "$as_ac_Lib=no"
  19293. fi
  19294. rm -f core conftest.err conftest.$ac_objext \
  19295. conftest$ac_exeext conftest.$ac_ext
  19296. LIBS=$ac_check_lib_save_LIBS
  19297. fi
  19298. eval ac_res=\$$as_ac_Lib
  19299. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  19300. $as_echo "$ac_res" >&6; }
  19301. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  19302. AST_UNIXODBC_FOUND=yes
  19303. else
  19304. AST_UNIXODBC_FOUND=no
  19305. fi
  19306. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  19307. fi
  19308. # now check for the header.
  19309. if test "${AST_UNIXODBC_FOUND}" = "yes"; then
  19310. UNIXODBC_LIB="${pbxlibdir} -lodbc "
  19311. # if --with-UNIXODBC=DIR has been specified, use it.
  19312. if test "x${UNIXODBC_DIR}" != "x"; then
  19313. UNIXODBC_INCLUDE="-I${UNIXODBC_DIR}/include"
  19314. fi
  19315. UNIXODBC_INCLUDE="${UNIXODBC_INCLUDE} "
  19316. if test "xsql.h" = "x" ; then # no header, assume found
  19317. UNIXODBC_HEADER_FOUND="1"
  19318. else # check for the header
  19319. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  19320. CPPFLAGS="${CPPFLAGS} ${UNIXODBC_INCLUDE}"
  19321. ac_fn_c_check_header_mongrel "$LINENO" "sql.h" "ac_cv_header_sql_h" "$ac_includes_default"
  19322. if test "x$ac_cv_header_sql_h" = xyes; then :
  19323. UNIXODBC_HEADER_FOUND=1
  19324. else
  19325. UNIXODBC_HEADER_FOUND=0
  19326. fi
  19327. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  19328. fi
  19329. if test "x${UNIXODBC_HEADER_FOUND}" = "x0" ; then
  19330. UNIXODBC_LIB=""
  19331. UNIXODBC_INCLUDE=""
  19332. else
  19333. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  19334. UNIXODBC_LIB=""
  19335. fi
  19336. PBX_UNIXODBC=1
  19337. cat >>confdefs.h <<_ACEOF
  19338. #define HAVE_UNIXODBC 1
  19339. _ACEOF
  19340. fi
  19341. fi
  19342. fi
  19343. if test "x${PBX_OGG}" != "x1" -a "${USE_OGG}" != "no"; then
  19344. pbxlibdir=""
  19345. # if --with-OGG=DIR has been specified, use it.
  19346. if test "x${OGG_DIR}" != "x"; then
  19347. if test -d ${OGG_DIR}/lib; then
  19348. pbxlibdir="-L${OGG_DIR}/lib"
  19349. else
  19350. pbxlibdir="-L${OGG_DIR}"
  19351. fi
  19352. fi
  19353. pbxfuncname="ogg_sync_init"
  19354. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19355. AST_OGG_FOUND=yes
  19356. else
  19357. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19358. CFLAGS="${CFLAGS} "
  19359. as_ac_Lib=`$as_echo "ac_cv_lib_ogg_${pbxfuncname}" | $as_tr_sh`
  19360. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -logg" >&5
  19361. $as_echo_n "checking for ${pbxfuncname} in -logg... " >&6; }
  19362. if eval \${$as_ac_Lib+:} false; then :
  19363. $as_echo_n "(cached) " >&6
  19364. else
  19365. ac_check_lib_save_LIBS=$LIBS
  19366. LIBS="-logg ${pbxlibdir} $LIBS"
  19367. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19368. /* end confdefs.h. */
  19369. /* Override any GCC internal prototype to avoid an error.
  19370. Use char because int might match the return type of a GCC
  19371. builtin and then its argument prototype would still apply. */
  19372. #ifdef __cplusplus
  19373. extern "C"
  19374. #endif
  19375. char ${pbxfuncname} ();
  19376. int
  19377. main ()
  19378. {
  19379. return ${pbxfuncname} ();
  19380. ;
  19381. return 0;
  19382. }
  19383. _ACEOF
  19384. if ac_fn_c_try_link "$LINENO"; then :
  19385. eval "$as_ac_Lib=yes"
  19386. else
  19387. eval "$as_ac_Lib=no"
  19388. fi
  19389. rm -f core conftest.err conftest.$ac_objext \
  19390. conftest$ac_exeext conftest.$ac_ext
  19391. LIBS=$ac_check_lib_save_LIBS
  19392. fi
  19393. eval ac_res=\$$as_ac_Lib
  19394. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  19395. $as_echo "$ac_res" >&6; }
  19396. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  19397. AST_OGG_FOUND=yes
  19398. else
  19399. AST_OGG_FOUND=no
  19400. fi
  19401. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  19402. fi
  19403. # now check for the header.
  19404. if test "${AST_OGG_FOUND}" = "yes"; then
  19405. OGG_LIB="${pbxlibdir} -logg "
  19406. # if --with-OGG=DIR has been specified, use it.
  19407. if test "x${OGG_DIR}" != "x"; then
  19408. OGG_INCLUDE="-I${OGG_DIR}/include"
  19409. fi
  19410. OGG_INCLUDE="${OGG_INCLUDE} "
  19411. if test "x" = "x" ; then # no header, assume found
  19412. OGG_HEADER_FOUND="1"
  19413. else # check for the header
  19414. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  19415. CPPFLAGS="${CPPFLAGS} ${OGG_INCLUDE}"
  19416. ac_fn_c_check_header_mongrel "$LINENO" "" "ac_cv_header_" "$ac_includes_default"
  19417. if test "x$ac_cv_header_" = xyes; then :
  19418. OGG_HEADER_FOUND=1
  19419. else
  19420. OGG_HEADER_FOUND=0
  19421. fi
  19422. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  19423. fi
  19424. if test "x${OGG_HEADER_FOUND}" = "x0" ; then
  19425. OGG_LIB=""
  19426. OGG_INCLUDE=""
  19427. else
  19428. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  19429. OGG_LIB=""
  19430. fi
  19431. PBX_OGG=1
  19432. cat >>confdefs.h <<_ACEOF
  19433. #define HAVE_OGG 1
  19434. _ACEOF
  19435. fi
  19436. fi
  19437. fi
  19438. # Non-glibc platforms require libexecinfo for backtrace support
  19439. if test "x${PBX_BKTR}" != "x1" -a "${USE_BKTR}" != "no"; then
  19440. pbxlibdir=""
  19441. # if --with-BKTR=DIR has been specified, use it.
  19442. if test "x${BKTR_DIR}" != "x"; then
  19443. if test -d ${BKTR_DIR}/lib; then
  19444. pbxlibdir="-L${BKTR_DIR}/lib"
  19445. else
  19446. pbxlibdir="-L${BKTR_DIR}"
  19447. fi
  19448. fi
  19449. pbxfuncname="backtrace"
  19450. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19451. AST_BKTR_FOUND=yes
  19452. else
  19453. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19454. CFLAGS="${CFLAGS} "
  19455. as_ac_Lib=`$as_echo "ac_cv_lib_execinfo_${pbxfuncname}" | $as_tr_sh`
  19456. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lexecinfo" >&5
  19457. $as_echo_n "checking for ${pbxfuncname} in -lexecinfo... " >&6; }
  19458. if eval \${$as_ac_Lib+:} false; then :
  19459. $as_echo_n "(cached) " >&6
  19460. else
  19461. ac_check_lib_save_LIBS=$LIBS
  19462. LIBS="-lexecinfo ${pbxlibdir} $LIBS"
  19463. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19464. /* end confdefs.h. */
  19465. /* Override any GCC internal prototype to avoid an error.
  19466. Use char because int might match the return type of a GCC
  19467. builtin and then its argument prototype would still apply. */
  19468. #ifdef __cplusplus
  19469. extern "C"
  19470. #endif
  19471. char ${pbxfuncname} ();
  19472. int
  19473. main ()
  19474. {
  19475. return ${pbxfuncname} ();
  19476. ;
  19477. return 0;
  19478. }
  19479. _ACEOF
  19480. if ac_fn_c_try_link "$LINENO"; then :
  19481. eval "$as_ac_Lib=yes"
  19482. else
  19483. eval "$as_ac_Lib=no"
  19484. fi
  19485. rm -f core conftest.err conftest.$ac_objext \
  19486. conftest$ac_exeext conftest.$ac_ext
  19487. LIBS=$ac_check_lib_save_LIBS
  19488. fi
  19489. eval ac_res=\$$as_ac_Lib
  19490. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  19491. $as_echo "$ac_res" >&6; }
  19492. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  19493. AST_BKTR_FOUND=yes
  19494. else
  19495. AST_BKTR_FOUND=no
  19496. fi
  19497. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  19498. fi
  19499. # now check for the header.
  19500. if test "${AST_BKTR_FOUND}" = "yes"; then
  19501. BKTR_LIB="${pbxlibdir} -lexecinfo "
  19502. # if --with-BKTR=DIR has been specified, use it.
  19503. if test "x${BKTR_DIR}" != "x"; then
  19504. BKTR_INCLUDE="-I${BKTR_DIR}/include"
  19505. fi
  19506. BKTR_INCLUDE="${BKTR_INCLUDE} "
  19507. if test "xexecinfo.h" = "x" ; then # no header, assume found
  19508. BKTR_HEADER_FOUND="1"
  19509. else # check for the header
  19510. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  19511. CPPFLAGS="${CPPFLAGS} ${BKTR_INCLUDE}"
  19512. ac_fn_c_check_header_mongrel "$LINENO" "execinfo.h" "ac_cv_header_execinfo_h" "$ac_includes_default"
  19513. if test "x$ac_cv_header_execinfo_h" = xyes; then :
  19514. BKTR_HEADER_FOUND=1
  19515. else
  19516. BKTR_HEADER_FOUND=0
  19517. fi
  19518. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  19519. fi
  19520. if test "x${BKTR_HEADER_FOUND}" = "x0" ; then
  19521. BKTR_LIB=""
  19522. BKTR_INCLUDE=""
  19523. else
  19524. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  19525. BKTR_LIB=""
  19526. fi
  19527. PBX_BKTR=1
  19528. cat >>confdefs.h <<_ACEOF
  19529. #define HAVE_BKTR 1
  19530. _ACEOF
  19531. fi
  19532. fi
  19533. fi
  19534. # Linux, however, has backtrace directly in glibc
  19535. if test "x${PBX_BKTR}" != "x1" -a "${USE_BKTR}" != "no"; then
  19536. pbxlibdir=""
  19537. # if --with-BKTR=DIR has been specified, use it.
  19538. if test "x${BKTR_DIR}" != "x"; then
  19539. if test -d ${BKTR_DIR}/lib; then
  19540. pbxlibdir="-L${BKTR_DIR}/lib"
  19541. else
  19542. pbxlibdir="-L${BKTR_DIR}"
  19543. fi
  19544. fi
  19545. pbxfuncname="backtrace"
  19546. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19547. AST_BKTR_FOUND=yes
  19548. else
  19549. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19550. CFLAGS="${CFLAGS} "
  19551. as_ac_Lib=`$as_echo "ac_cv_lib_c_${pbxfuncname}" | $as_tr_sh`
  19552. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lc" >&5
  19553. $as_echo_n "checking for ${pbxfuncname} in -lc... " >&6; }
  19554. if eval \${$as_ac_Lib+:} false; then :
  19555. $as_echo_n "(cached) " >&6
  19556. else
  19557. ac_check_lib_save_LIBS=$LIBS
  19558. LIBS="-lc ${pbxlibdir} $LIBS"
  19559. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19560. /* end confdefs.h. */
  19561. /* Override any GCC internal prototype to avoid an error.
  19562. Use char because int might match the return type of a GCC
  19563. builtin and then its argument prototype would still apply. */
  19564. #ifdef __cplusplus
  19565. extern "C"
  19566. #endif
  19567. char ${pbxfuncname} ();
  19568. int
  19569. main ()
  19570. {
  19571. return ${pbxfuncname} ();
  19572. ;
  19573. return 0;
  19574. }
  19575. _ACEOF
  19576. if ac_fn_c_try_link "$LINENO"; then :
  19577. eval "$as_ac_Lib=yes"
  19578. else
  19579. eval "$as_ac_Lib=no"
  19580. fi
  19581. rm -f core conftest.err conftest.$ac_objext \
  19582. conftest$ac_exeext conftest.$ac_ext
  19583. LIBS=$ac_check_lib_save_LIBS
  19584. fi
  19585. eval ac_res=\$$as_ac_Lib
  19586. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  19587. $as_echo "$ac_res" >&6; }
  19588. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  19589. AST_BKTR_FOUND=yes
  19590. else
  19591. AST_BKTR_FOUND=no
  19592. fi
  19593. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  19594. fi
  19595. # now check for the header.
  19596. if test "${AST_BKTR_FOUND}" = "yes"; then
  19597. BKTR_LIB="${pbxlibdir} -lc "
  19598. # if --with-BKTR=DIR has been specified, use it.
  19599. if test "x${BKTR_DIR}" != "x"; then
  19600. BKTR_INCLUDE="-I${BKTR_DIR}/include"
  19601. fi
  19602. BKTR_INCLUDE="${BKTR_INCLUDE} "
  19603. if test "xexecinfo.h" = "x" ; then # no header, assume found
  19604. BKTR_HEADER_FOUND="1"
  19605. else # check for the header
  19606. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  19607. CPPFLAGS="${CPPFLAGS} ${BKTR_INCLUDE}"
  19608. ac_fn_c_check_header_mongrel "$LINENO" "execinfo.h" "ac_cv_header_execinfo_h" "$ac_includes_default"
  19609. if test "x$ac_cv_header_execinfo_h" = xyes; then :
  19610. BKTR_HEADER_FOUND=1
  19611. else
  19612. BKTR_HEADER_FOUND=0
  19613. fi
  19614. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  19615. fi
  19616. if test "x${BKTR_HEADER_FOUND}" = "x0" ; then
  19617. BKTR_LIB=""
  19618. BKTR_INCLUDE=""
  19619. else
  19620. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  19621. BKTR_LIB=""
  19622. fi
  19623. PBX_BKTR=1
  19624. cat >>confdefs.h <<_ACEOF
  19625. #define HAVE_BKTR 1
  19626. _ACEOF
  19627. fi
  19628. fi
  19629. fi
  19630. if test "x${PBX_BLUETOOTH}" != "x1" -a "${USE_BLUETOOTH}" != "no"; then
  19631. pbxlibdir=""
  19632. # if --with-BLUETOOTH=DIR has been specified, use it.
  19633. if test "x${BLUETOOTH_DIR}" != "x"; then
  19634. if test -d ${BLUETOOTH_DIR}/lib; then
  19635. pbxlibdir="-L${BLUETOOTH_DIR}/lib"
  19636. else
  19637. pbxlibdir="-L${BLUETOOTH_DIR}"
  19638. fi
  19639. fi
  19640. pbxfuncname="ba2str"
  19641. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19642. AST_BLUETOOTH_FOUND=yes
  19643. else
  19644. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19645. CFLAGS="${CFLAGS} "
  19646. as_ac_Lib=`$as_echo "ac_cv_lib_bluetooth_${pbxfuncname}" | $as_tr_sh`
  19647. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lbluetooth" >&5
  19648. $as_echo_n "checking for ${pbxfuncname} in -lbluetooth... " >&6; }
  19649. if eval \${$as_ac_Lib+:} false; then :
  19650. $as_echo_n "(cached) " >&6
  19651. else
  19652. ac_check_lib_save_LIBS=$LIBS
  19653. LIBS="-lbluetooth ${pbxlibdir} $LIBS"
  19654. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19655. /* end confdefs.h. */
  19656. /* Override any GCC internal prototype to avoid an error.
  19657. Use char because int might match the return type of a GCC
  19658. builtin and then its argument prototype would still apply. */
  19659. #ifdef __cplusplus
  19660. extern "C"
  19661. #endif
  19662. char ${pbxfuncname} ();
  19663. int
  19664. main ()
  19665. {
  19666. return ${pbxfuncname} ();
  19667. ;
  19668. return 0;
  19669. }
  19670. _ACEOF
  19671. if ac_fn_c_try_link "$LINENO"; then :
  19672. eval "$as_ac_Lib=yes"
  19673. else
  19674. eval "$as_ac_Lib=no"
  19675. fi
  19676. rm -f core conftest.err conftest.$ac_objext \
  19677. conftest$ac_exeext conftest.$ac_ext
  19678. LIBS=$ac_check_lib_save_LIBS
  19679. fi
  19680. eval ac_res=\$$as_ac_Lib
  19681. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  19682. $as_echo "$ac_res" >&6; }
  19683. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  19684. AST_BLUETOOTH_FOUND=yes
  19685. else
  19686. AST_BLUETOOTH_FOUND=no
  19687. fi
  19688. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  19689. fi
  19690. # now check for the header.
  19691. if test "${AST_BLUETOOTH_FOUND}" = "yes"; then
  19692. BLUETOOTH_LIB="${pbxlibdir} -lbluetooth "
  19693. # if --with-BLUETOOTH=DIR has been specified, use it.
  19694. if test "x${BLUETOOTH_DIR}" != "x"; then
  19695. BLUETOOTH_INCLUDE="-I${BLUETOOTH_DIR}/include"
  19696. fi
  19697. BLUETOOTH_INCLUDE="${BLUETOOTH_INCLUDE} "
  19698. if test "xbluetooth/bluetooth.h" = "x" ; then # no header, assume found
  19699. BLUETOOTH_HEADER_FOUND="1"
  19700. else # check for the header
  19701. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  19702. CPPFLAGS="${CPPFLAGS} ${BLUETOOTH_INCLUDE}"
  19703. ac_fn_c_check_header_mongrel "$LINENO" "bluetooth/bluetooth.h" "ac_cv_header_bluetooth_bluetooth_h" "$ac_includes_default"
  19704. if test "x$ac_cv_header_bluetooth_bluetooth_h" = xyes; then :
  19705. BLUETOOTH_HEADER_FOUND=1
  19706. else
  19707. BLUETOOTH_HEADER_FOUND=0
  19708. fi
  19709. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  19710. fi
  19711. if test "x${BLUETOOTH_HEADER_FOUND}" = "x0" ; then
  19712. BLUETOOTH_LIB=""
  19713. BLUETOOTH_INCLUDE=""
  19714. else
  19715. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  19716. BLUETOOTH_LIB=""
  19717. fi
  19718. PBX_BLUETOOTH=1
  19719. cat >>confdefs.h <<_ACEOF
  19720. #define HAVE_BLUETOOTH 1
  19721. _ACEOF
  19722. fi
  19723. fi
  19724. fi
  19725. # possible places for oss definitions
  19726. if test "x${PBX_OSS}" != "x1" -a "${USE_OSS}" != "no"; then
  19727. pbxlibdir=""
  19728. # if --with-OSS=DIR has been specified, use it.
  19729. if test "x${OSS_DIR}" != "x"; then
  19730. if test -d ${OSS_DIR}/lib; then
  19731. pbxlibdir="-L${OSS_DIR}/lib"
  19732. else
  19733. pbxlibdir="-L${OSS_DIR}"
  19734. fi
  19735. fi
  19736. pbxfuncname=""
  19737. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19738. AST_OSS_FOUND=yes
  19739. else
  19740. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19741. CFLAGS="${CFLAGS} "
  19742. as_ac_Lib=`$as_echo "ac_cv_lib_ossaudio_${pbxfuncname}" | $as_tr_sh`
  19743. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lossaudio" >&5
  19744. $as_echo_n "checking for ${pbxfuncname} in -lossaudio... " >&6; }
  19745. if eval \${$as_ac_Lib+:} false; then :
  19746. $as_echo_n "(cached) " >&6
  19747. else
  19748. ac_check_lib_save_LIBS=$LIBS
  19749. LIBS="-lossaudio ${pbxlibdir} $LIBS"
  19750. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19751. /* end confdefs.h. */
  19752. /* Override any GCC internal prototype to avoid an error.
  19753. Use char because int might match the return type of a GCC
  19754. builtin and then its argument prototype would still apply. */
  19755. #ifdef __cplusplus
  19756. extern "C"
  19757. #endif
  19758. char ${pbxfuncname} ();
  19759. int
  19760. main ()
  19761. {
  19762. return ${pbxfuncname} ();
  19763. ;
  19764. return 0;
  19765. }
  19766. _ACEOF
  19767. if ac_fn_c_try_link "$LINENO"; then :
  19768. eval "$as_ac_Lib=yes"
  19769. else
  19770. eval "$as_ac_Lib=no"
  19771. fi
  19772. rm -f core conftest.err conftest.$ac_objext \
  19773. conftest$ac_exeext conftest.$ac_ext
  19774. LIBS=$ac_check_lib_save_LIBS
  19775. fi
  19776. eval ac_res=\$$as_ac_Lib
  19777. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  19778. $as_echo "$ac_res" >&6; }
  19779. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  19780. AST_OSS_FOUND=yes
  19781. else
  19782. AST_OSS_FOUND=no
  19783. fi
  19784. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  19785. fi
  19786. # now check for the header.
  19787. if test "${AST_OSS_FOUND}" = "yes"; then
  19788. OSS_LIB="${pbxlibdir} -lossaudio "
  19789. # if --with-OSS=DIR has been specified, use it.
  19790. if test "x${OSS_DIR}" != "x"; then
  19791. OSS_INCLUDE="-I${OSS_DIR}/include"
  19792. fi
  19793. OSS_INCLUDE="${OSS_INCLUDE} "
  19794. if test "xlinux/soundcard.h" = "x" ; then # no header, assume found
  19795. OSS_HEADER_FOUND="1"
  19796. else # check for the header
  19797. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  19798. CPPFLAGS="${CPPFLAGS} ${OSS_INCLUDE}"
  19799. ac_fn_c_check_header_mongrel "$LINENO" "linux/soundcard.h" "ac_cv_header_linux_soundcard_h" "$ac_includes_default"
  19800. if test "x$ac_cv_header_linux_soundcard_h" = xyes; then :
  19801. OSS_HEADER_FOUND=1
  19802. else
  19803. OSS_HEADER_FOUND=0
  19804. fi
  19805. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  19806. fi
  19807. if test "x${OSS_HEADER_FOUND}" = "x0" ; then
  19808. OSS_LIB=""
  19809. OSS_INCLUDE=""
  19810. else
  19811. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  19812. OSS_LIB=""
  19813. fi
  19814. PBX_OSS=1
  19815. cat >>confdefs.h <<_ACEOF
  19816. #define HAVE_OSS 1
  19817. _ACEOF
  19818. fi
  19819. fi
  19820. fi
  19821. if test "x${PBX_OSS}" != "x1" -a "${USE_OSS}" != "no"; then
  19822. pbxlibdir=""
  19823. # if --with-OSS=DIR has been specified, use it.
  19824. if test "x${OSS_DIR}" != "x"; then
  19825. if test -d ${OSS_DIR}/lib; then
  19826. pbxlibdir="-L${OSS_DIR}/lib"
  19827. else
  19828. pbxlibdir="-L${OSS_DIR}"
  19829. fi
  19830. fi
  19831. pbxfuncname=""
  19832. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19833. AST_OSS_FOUND=yes
  19834. else
  19835. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19836. CFLAGS="${CFLAGS} "
  19837. as_ac_Lib=`$as_echo "ac_cv_lib_ossaudio_${pbxfuncname}" | $as_tr_sh`
  19838. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lossaudio" >&5
  19839. $as_echo_n "checking for ${pbxfuncname} in -lossaudio... " >&6; }
  19840. if eval \${$as_ac_Lib+:} false; then :
  19841. $as_echo_n "(cached) " >&6
  19842. else
  19843. ac_check_lib_save_LIBS=$LIBS
  19844. LIBS="-lossaudio ${pbxlibdir} $LIBS"
  19845. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19846. /* end confdefs.h. */
  19847. /* Override any GCC internal prototype to avoid an error.
  19848. Use char because int might match the return type of a GCC
  19849. builtin and then its argument prototype would still apply. */
  19850. #ifdef __cplusplus
  19851. extern "C"
  19852. #endif
  19853. char ${pbxfuncname} ();
  19854. int
  19855. main ()
  19856. {
  19857. return ${pbxfuncname} ();
  19858. ;
  19859. return 0;
  19860. }
  19861. _ACEOF
  19862. if ac_fn_c_try_link "$LINENO"; then :
  19863. eval "$as_ac_Lib=yes"
  19864. else
  19865. eval "$as_ac_Lib=no"
  19866. fi
  19867. rm -f core conftest.err conftest.$ac_objext \
  19868. conftest$ac_exeext conftest.$ac_ext
  19869. LIBS=$ac_check_lib_save_LIBS
  19870. fi
  19871. eval ac_res=\$$as_ac_Lib
  19872. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  19873. $as_echo "$ac_res" >&6; }
  19874. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  19875. AST_OSS_FOUND=yes
  19876. else
  19877. AST_OSS_FOUND=no
  19878. fi
  19879. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  19880. fi
  19881. # now check for the header.
  19882. if test "${AST_OSS_FOUND}" = "yes"; then
  19883. OSS_LIB="${pbxlibdir} -lossaudio "
  19884. # if --with-OSS=DIR has been specified, use it.
  19885. if test "x${OSS_DIR}" != "x"; then
  19886. OSS_INCLUDE="-I${OSS_DIR}/include"
  19887. fi
  19888. OSS_INCLUDE="${OSS_INCLUDE} "
  19889. if test "xsys/soundcard.h" = "x" ; then # no header, assume found
  19890. OSS_HEADER_FOUND="1"
  19891. else # check for the header
  19892. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  19893. CPPFLAGS="${CPPFLAGS} ${OSS_INCLUDE}"
  19894. ac_fn_c_check_header_mongrel "$LINENO" "sys/soundcard.h" "ac_cv_header_sys_soundcard_h" "$ac_includes_default"
  19895. if test "x$ac_cv_header_sys_soundcard_h" = xyes; then :
  19896. OSS_HEADER_FOUND=1
  19897. else
  19898. OSS_HEADER_FOUND=0
  19899. fi
  19900. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  19901. fi
  19902. if test "x${OSS_HEADER_FOUND}" = "x0" ; then
  19903. OSS_LIB=""
  19904. OSS_INCLUDE=""
  19905. else
  19906. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  19907. OSS_LIB=""
  19908. fi
  19909. PBX_OSS=1
  19910. cat >>confdefs.h <<_ACEOF
  19911. #define HAVE_OSS 1
  19912. _ACEOF
  19913. fi
  19914. fi
  19915. fi
  19916. if test "x${PBX_OSS}" != "x1" -a "${USE_OSS}" != "no"; then
  19917. pbxlibdir=""
  19918. # if --with-OSS=DIR has been specified, use it.
  19919. if test "x${OSS_DIR}" != "x"; then
  19920. if test -d ${OSS_DIR}/lib; then
  19921. pbxlibdir="-L${OSS_DIR}/lib"
  19922. else
  19923. pbxlibdir="-L${OSS_DIR}"
  19924. fi
  19925. fi
  19926. pbxfuncname="oss_ioctl_mixer"
  19927. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19928. AST_OSS_FOUND=yes
  19929. else
  19930. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19931. CFLAGS="${CFLAGS} "
  19932. as_ac_Lib=`$as_echo "ac_cv_lib_ossaudio_${pbxfuncname}" | $as_tr_sh`
  19933. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lossaudio" >&5
  19934. $as_echo_n "checking for ${pbxfuncname} in -lossaudio... " >&6; }
  19935. if eval \${$as_ac_Lib+:} false; then :
  19936. $as_echo_n "(cached) " >&6
  19937. else
  19938. ac_check_lib_save_LIBS=$LIBS
  19939. LIBS="-lossaudio ${pbxlibdir} $LIBS"
  19940. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19941. /* end confdefs.h. */
  19942. /* Override any GCC internal prototype to avoid an error.
  19943. Use char because int might match the return type of a GCC
  19944. builtin and then its argument prototype would still apply. */
  19945. #ifdef __cplusplus
  19946. extern "C"
  19947. #endif
  19948. char ${pbxfuncname} ();
  19949. int
  19950. main ()
  19951. {
  19952. return ${pbxfuncname} ();
  19953. ;
  19954. return 0;
  19955. }
  19956. _ACEOF
  19957. if ac_fn_c_try_link "$LINENO"; then :
  19958. eval "$as_ac_Lib=yes"
  19959. else
  19960. eval "$as_ac_Lib=no"
  19961. fi
  19962. rm -f core conftest.err conftest.$ac_objext \
  19963. conftest$ac_exeext conftest.$ac_ext
  19964. LIBS=$ac_check_lib_save_LIBS
  19965. fi
  19966. eval ac_res=\$$as_ac_Lib
  19967. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  19968. $as_echo "$ac_res" >&6; }
  19969. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  19970. AST_OSS_FOUND=yes
  19971. else
  19972. AST_OSS_FOUND=no
  19973. fi
  19974. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  19975. fi
  19976. # now check for the header.
  19977. if test "${AST_OSS_FOUND}" = "yes"; then
  19978. OSS_LIB="${pbxlibdir} -lossaudio "
  19979. # if --with-OSS=DIR has been specified, use it.
  19980. if test "x${OSS_DIR}" != "x"; then
  19981. OSS_INCLUDE="-I${OSS_DIR}/include"
  19982. fi
  19983. OSS_INCLUDE="${OSS_INCLUDE} "
  19984. if test "xsoundcard.h" = "x" ; then # no header, assume found
  19985. OSS_HEADER_FOUND="1"
  19986. else # check for the header
  19987. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  19988. CPPFLAGS="${CPPFLAGS} ${OSS_INCLUDE}"
  19989. ac_fn_c_check_header_mongrel "$LINENO" "soundcard.h" "ac_cv_header_soundcard_h" "$ac_includes_default"
  19990. if test "x$ac_cv_header_soundcard_h" = xyes; then :
  19991. OSS_HEADER_FOUND=1
  19992. else
  19993. OSS_HEADER_FOUND=0
  19994. fi
  19995. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  19996. fi
  19997. if test "x${OSS_HEADER_FOUND}" = "x0" ; then
  19998. OSS_LIB=""
  19999. OSS_INCLUDE=""
  20000. else
  20001. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  20002. OSS_LIB=""
  20003. fi
  20004. PBX_OSS=1
  20005. cat >>confdefs.h <<_ACEOF
  20006. #define HAVE_OSS 1
  20007. _ACEOF
  20008. fi
  20009. fi
  20010. fi
  20011. PG_CONFIG=No
  20012. if test "${USE_PGSQL}" != "no"; then
  20013. if test "x${PGSQL_DIR}" != "x"; then
  20014. if test -n "$ac_tool_prefix"; then
  20015. # Extract the first word of "${ac_tool_prefix}pg_config", so it can be a program name with args.
  20016. set dummy ${ac_tool_prefix}pg_config; ac_word=$2
  20017. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  20018. $as_echo_n "checking for $ac_word... " >&6; }
  20019. if ${ac_cv_path_PG_CONFIG+:} false; then :
  20020. $as_echo_n "(cached) " >&6
  20021. else
  20022. case $PG_CONFIG in
  20023. [\\/]* | ?:[\\/]*)
  20024. ac_cv_path_PG_CONFIG="$PG_CONFIG" # Let the user override the test with a path.
  20025. ;;
  20026. *)
  20027. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  20028. for as_dir in ${PGSQL_DIR}/bin
  20029. do
  20030. IFS=$as_save_IFS
  20031. test -z "$as_dir" && as_dir=.
  20032. for ac_exec_ext in '' $ac_executable_extensions; do
  20033. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  20034. ac_cv_path_PG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
  20035. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  20036. break 2
  20037. fi
  20038. done
  20039. done
  20040. IFS=$as_save_IFS
  20041. ;;
  20042. esac
  20043. fi
  20044. PG_CONFIG=$ac_cv_path_PG_CONFIG
  20045. if test -n "$PG_CONFIG"; then
  20046. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PG_CONFIG" >&5
  20047. $as_echo "$PG_CONFIG" >&6; }
  20048. else
  20049. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  20050. $as_echo "no" >&6; }
  20051. fi
  20052. fi
  20053. if test -z "$ac_cv_path_PG_CONFIG"; then
  20054. ac_pt_PG_CONFIG=$PG_CONFIG
  20055. # Extract the first word of "pg_config", so it can be a program name with args.
  20056. set dummy pg_config; ac_word=$2
  20057. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  20058. $as_echo_n "checking for $ac_word... " >&6; }
  20059. if ${ac_cv_path_ac_pt_PG_CONFIG+:} false; then :
  20060. $as_echo_n "(cached) " >&6
  20061. else
  20062. case $ac_pt_PG_CONFIG in
  20063. [\\/]* | ?:[\\/]*)
  20064. ac_cv_path_ac_pt_PG_CONFIG="$ac_pt_PG_CONFIG" # Let the user override the test with a path.
  20065. ;;
  20066. *)
  20067. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  20068. for as_dir in ${PGSQL_DIR}/bin
  20069. do
  20070. IFS=$as_save_IFS
  20071. test -z "$as_dir" && as_dir=.
  20072. for ac_exec_ext in '' $ac_executable_extensions; do
  20073. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  20074. ac_cv_path_ac_pt_PG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
  20075. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  20076. break 2
  20077. fi
  20078. done
  20079. done
  20080. IFS=$as_save_IFS
  20081. ;;
  20082. esac
  20083. fi
  20084. ac_pt_PG_CONFIG=$ac_cv_path_ac_pt_PG_CONFIG
  20085. if test -n "$ac_pt_PG_CONFIG"; then
  20086. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PG_CONFIG" >&5
  20087. $as_echo "$ac_pt_PG_CONFIG" >&6; }
  20088. else
  20089. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  20090. $as_echo "no" >&6; }
  20091. fi
  20092. if test "x$ac_pt_PG_CONFIG" = x; then
  20093. PG_CONFIG="No"
  20094. else
  20095. case $cross_compiling:$ac_tool_warned in
  20096. yes:)
  20097. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  20098. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  20099. ac_tool_warned=yes ;;
  20100. esac
  20101. PG_CONFIG=$ac_pt_PG_CONFIG
  20102. fi
  20103. else
  20104. PG_CONFIG="$ac_cv_path_PG_CONFIG"
  20105. fi
  20106. if test x"${PG_CONFIG}" = xNo; then
  20107. { $as_echo "$as_me:${as_lineno-$LINENO}: ***" >&5
  20108. $as_echo "$as_me: ***" >&6;}
  20109. { $as_echo "$as_me:${as_lineno-$LINENO}: *** pg_config was not found in the path you specified:" >&5
  20110. $as_echo "$as_me: *** pg_config was not found in the path you specified:" >&6;}
  20111. { $as_echo "$as_me:${as_lineno-$LINENO}: *** ${PGSQL_DIR}/bin" >&5
  20112. $as_echo "$as_me: *** ${PGSQL_DIR}/bin" >&6;}
  20113. { $as_echo "$as_me:${as_lineno-$LINENO}: *** Either correct the installation, or run configure" >&5
  20114. $as_echo "$as_me: *** Either correct the installation, or run configure" >&6;}
  20115. { $as_echo "$as_me:${as_lineno-$LINENO}: *** including --without-postgres" >&5
  20116. $as_echo "$as_me: *** including --without-postgres" >&6;}
  20117. exit 1
  20118. fi
  20119. else
  20120. if test -n "$ac_tool_prefix"; then
  20121. # Extract the first word of "${ac_tool_prefix}pg_config", so it can be a program name with args.
  20122. set dummy ${ac_tool_prefix}pg_config; ac_word=$2
  20123. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  20124. $as_echo_n "checking for $ac_word... " >&6; }
  20125. if ${ac_cv_path_PG_CONFIG+:} false; then :
  20126. $as_echo_n "(cached) " >&6
  20127. else
  20128. case $PG_CONFIG in
  20129. [\\/]* | ?:[\\/]*)
  20130. ac_cv_path_PG_CONFIG="$PG_CONFIG" # Let the user override the test with a path.
  20131. ;;
  20132. *)
  20133. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  20134. for as_dir in $PATH
  20135. do
  20136. IFS=$as_save_IFS
  20137. test -z "$as_dir" && as_dir=.
  20138. for ac_exec_ext in '' $ac_executable_extensions; do
  20139. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  20140. ac_cv_path_PG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
  20141. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  20142. break 2
  20143. fi
  20144. done
  20145. done
  20146. IFS=$as_save_IFS
  20147. ;;
  20148. esac
  20149. fi
  20150. PG_CONFIG=$ac_cv_path_PG_CONFIG
  20151. if test -n "$PG_CONFIG"; then
  20152. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PG_CONFIG" >&5
  20153. $as_echo "$PG_CONFIG" >&6; }
  20154. else
  20155. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  20156. $as_echo "no" >&6; }
  20157. fi
  20158. fi
  20159. if test -z "$ac_cv_path_PG_CONFIG"; then
  20160. ac_pt_PG_CONFIG=$PG_CONFIG
  20161. # Extract the first word of "pg_config", so it can be a program name with args.
  20162. set dummy pg_config; ac_word=$2
  20163. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  20164. $as_echo_n "checking for $ac_word... " >&6; }
  20165. if ${ac_cv_path_ac_pt_PG_CONFIG+:} false; then :
  20166. $as_echo_n "(cached) " >&6
  20167. else
  20168. case $ac_pt_PG_CONFIG in
  20169. [\\/]* | ?:[\\/]*)
  20170. ac_cv_path_ac_pt_PG_CONFIG="$ac_pt_PG_CONFIG" # Let the user override the test with a path.
  20171. ;;
  20172. *)
  20173. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  20174. for as_dir in $PATH
  20175. do
  20176. IFS=$as_save_IFS
  20177. test -z "$as_dir" && as_dir=.
  20178. for ac_exec_ext in '' $ac_executable_extensions; do
  20179. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  20180. ac_cv_path_ac_pt_PG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
  20181. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  20182. break 2
  20183. fi
  20184. done
  20185. done
  20186. IFS=$as_save_IFS
  20187. ;;
  20188. esac
  20189. fi
  20190. ac_pt_PG_CONFIG=$ac_cv_path_ac_pt_PG_CONFIG
  20191. if test -n "$ac_pt_PG_CONFIG"; then
  20192. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PG_CONFIG" >&5
  20193. $as_echo "$ac_pt_PG_CONFIG" >&6; }
  20194. else
  20195. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  20196. $as_echo "no" >&6; }
  20197. fi
  20198. if test "x$ac_pt_PG_CONFIG" = x; then
  20199. PG_CONFIG="No"
  20200. else
  20201. case $cross_compiling:$ac_tool_warned in
  20202. yes:)
  20203. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  20204. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  20205. ac_tool_warned=yes ;;
  20206. esac
  20207. PG_CONFIG=$ac_pt_PG_CONFIG
  20208. fi
  20209. else
  20210. PG_CONFIG="$ac_cv_path_PG_CONFIG"
  20211. fi
  20212. fi
  20213. fi
  20214. if test "${PG_CONFIG}" != No; then
  20215. PGSQL_libdir=`${PG_CONFIG} --libdir`
  20216. PGSQL_includedir=`${PG_CONFIG} --includedir`
  20217. if test "x$?" != "x0" ; then
  20218. if test -n "${PGSQL_MANDATORY}" ; then
  20219. { $as_echo "$as_me:${as_lineno-$LINENO}: ***" >&5
  20220. $as_echo "$as_me: ***" >&6;}
  20221. { $as_echo "$as_me:${as_lineno-$LINENO}: *** The PostgreSQL installation on this system appears to be broken." >&5
  20222. $as_echo "$as_me: *** The PostgreSQL installation on this system appears to be broken." >&6;}
  20223. { $as_echo "$as_me:${as_lineno-$LINENO}: *** Either correct the installation, or run configure" >&5
  20224. $as_echo "$as_me: *** Either correct the installation, or run configure" >&6;}
  20225. { $as_echo "$as_me:${as_lineno-$LINENO}: *** including --without-postgres" >&5
  20226. $as_echo "$as_me: *** including --without-postgres" >&6;}
  20227. exit 1
  20228. fi
  20229. else
  20230. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PQescapeStringConn in -lpq" >&5
  20231. $as_echo_n "checking for PQescapeStringConn in -lpq... " >&6; }
  20232. if ${ac_cv_lib_pq_PQescapeStringConn+:} false; then :
  20233. $as_echo_n "(cached) " >&6
  20234. else
  20235. ac_check_lib_save_LIBS=$LIBS
  20236. LIBS="-lpq -L${PGSQL_libdir} -lz $LIBS"
  20237. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20238. /* end confdefs.h. */
  20239. /* Override any GCC internal prototype to avoid an error.
  20240. Use char because int might match the return type of a GCC
  20241. builtin and then its argument prototype would still apply. */
  20242. #ifdef __cplusplus
  20243. extern "C"
  20244. #endif
  20245. char PQescapeStringConn ();
  20246. int
  20247. main ()
  20248. {
  20249. return PQescapeStringConn ();
  20250. ;
  20251. return 0;
  20252. }
  20253. _ACEOF
  20254. if ac_fn_c_try_link "$LINENO"; then :
  20255. ac_cv_lib_pq_PQescapeStringConn=yes
  20256. else
  20257. ac_cv_lib_pq_PQescapeStringConn=no
  20258. fi
  20259. rm -f core conftest.err conftest.$ac_objext \
  20260. conftest$ac_exeext conftest.$ac_ext
  20261. LIBS=$ac_check_lib_save_LIBS
  20262. fi
  20263. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pq_PQescapeStringConn" >&5
  20264. $as_echo "$ac_cv_lib_pq_PQescapeStringConn" >&6; }
  20265. if test "x$ac_cv_lib_pq_PQescapeStringConn" = xyes; then :
  20266. cat >>confdefs.h <<_ACEOF
  20267. #define HAVE_PGSQL 1
  20268. _ACEOF
  20269. fi
  20270. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pg_encoding_to_char within Postgres headers" >&5
  20271. $as_echo_n "checking for pg_encoding_to_char within Postgres headers... " >&6; }
  20272. old_CFLAGS=${CFLAGS}
  20273. CFLAGS="${CFLAGS} -I${PGSQL_includedir} -Werror"
  20274. old_LDFLAGS=${LDFLAGS}
  20275. LDFLAGS="${LDFLAGS} -L${PGSQL_libdir} -lpq -lz"
  20276. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20277. /* end confdefs.h. */
  20278. #include <libpq-fe.h>
  20279. int
  20280. main ()
  20281. {
  20282. const char *foo = pg_encoding_to_char(1)
  20283. ;
  20284. return 0;
  20285. }
  20286. _ACEOF
  20287. if ac_fn_c_try_link "$LINENO"; then :
  20288. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  20289. $as_echo "yes" >&6; }
  20290. cat >>confdefs.h <<_ACEOF
  20291. #define HAVE_PGSQL_pg_encoding_to_char 1
  20292. _ACEOF
  20293. else
  20294. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  20295. $as_echo "no" >&6; }
  20296. fi
  20297. rm -f core conftest.err conftest.$ac_objext \
  20298. conftest$ac_exeext conftest.$ac_ext
  20299. CFLAGS=${old_CFLAGS}
  20300. LDFLAGS=${old_LDFLAGS}
  20301. if test "${ac_cv_lib_pq_PQescapeStringConn}" = "yes"; then
  20302. PGSQL_LIB="-L${PGSQL_libdir} -lpq -lz"
  20303. PGSQL_INCLUDE="-I${PGSQL_includedir}"
  20304. PBX_PGSQL=1
  20305. elif test -n "${PGSQL_MANDATORY}";
  20306. then
  20307. { $as_echo "$as_me:${as_lineno-$LINENO}: ***" >&5
  20308. $as_echo "$as_me: ***" >&6;}
  20309. { $as_echo "$as_me:${as_lineno-$LINENO}: *** The PostgreSQL installation on this system appears to be broken." >&5
  20310. $as_echo "$as_me: *** The PostgreSQL installation on this system appears to be broken." >&6;}
  20311. { $as_echo "$as_me:${as_lineno-$LINENO}: *** Either correct the installation, or run configure" >&5
  20312. $as_echo "$as_me: *** Either correct the installation, or run configure" >&6;}
  20313. { $as_echo "$as_me:${as_lineno-$LINENO}: *** including --without-postgres" >&5
  20314. $as_echo "$as_me: *** including --without-postgres" >&6;}
  20315. exit 1
  20316. fi
  20317. fi
  20318. fi
  20319. if test "x${PBX_PJPROJECT}" != "x1" -a "${USE_PJPROJECT}" != "no"; then
  20320. pkg_failed=no
  20321. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PJPROJECT" >&5
  20322. $as_echo_n "checking for PJPROJECT... " >&6; }
  20323. if test -n "$PJPROJECT_CFLAGS"; then
  20324. pkg_cv_PJPROJECT_CFLAGS="$PJPROJECT_CFLAGS"
  20325. elif test -n "$PKG_CONFIG"; then
  20326. if test -n "$PKG_CONFIG" && \
  20327. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpjproject\""; } >&5
  20328. ($PKG_CONFIG --exists --print-errors "libpjproject") 2>&5
  20329. ac_status=$?
  20330. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  20331. test $ac_status = 0; }; then
  20332. pkg_cv_PJPROJECT_CFLAGS=`$PKG_CONFIG --cflags "libpjproject" 2>/dev/null`
  20333. test "x$?" != "x0" && pkg_failed=yes
  20334. else
  20335. pkg_failed=yes
  20336. fi
  20337. else
  20338. pkg_failed=untried
  20339. fi
  20340. if test -n "$PJPROJECT_LIBS"; then
  20341. pkg_cv_PJPROJECT_LIBS="$PJPROJECT_LIBS"
  20342. elif test -n "$PKG_CONFIG"; then
  20343. if test -n "$PKG_CONFIG" && \
  20344. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpjproject\""; } >&5
  20345. ($PKG_CONFIG --exists --print-errors "libpjproject") 2>&5
  20346. ac_status=$?
  20347. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  20348. test $ac_status = 0; }; then
  20349. pkg_cv_PJPROJECT_LIBS=`$PKG_CONFIG --libs "libpjproject" 2>/dev/null`
  20350. test "x$?" != "x0" && pkg_failed=yes
  20351. else
  20352. pkg_failed=yes
  20353. fi
  20354. else
  20355. pkg_failed=untried
  20356. fi
  20357. if test $pkg_failed = yes; then
  20358. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  20359. $as_echo "no" >&6; }
  20360. if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
  20361. _pkg_short_errors_supported=yes
  20362. else
  20363. _pkg_short_errors_supported=no
  20364. fi
  20365. if test $_pkg_short_errors_supported = yes; then
  20366. PJPROJECT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libpjproject" 2>&1`
  20367. else
  20368. PJPROJECT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libpjproject" 2>&1`
  20369. fi
  20370. # Put the nasty error message in config.log where it belongs
  20371. echo "$PJPROJECT_PKG_ERRORS" >&5
  20372. PBX_PJPROJECT=0
  20373. elif test $pkg_failed = untried; then
  20374. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  20375. $as_echo "no" >&6; }
  20376. PBX_PJPROJECT=0
  20377. else
  20378. PJPROJECT_CFLAGS=$pkg_cv_PJPROJECT_CFLAGS
  20379. PJPROJECT_LIBS=$pkg_cv_PJPROJECT_LIBS
  20380. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  20381. $as_echo "yes" >&6; }
  20382. PBX_PJPROJECT=1
  20383. PJPROJECT_INCLUDE="$PJPROJECT_CFLAGS"
  20384. PJPROJECT_LIB="$PJPROJECT_LIBS"
  20385. $as_echo "#define HAVE_PJPROJECT 1" >>confdefs.h
  20386. fi
  20387. fi
  20388. if test "x${PBX_PJ_TRANSACTION_GRP_LOCK}" != "x1" -a "${USE_PJ_TRANSACTION_GRP_LOCK}" != "no"; then
  20389. pbxlibdir=""
  20390. # if --with-PJ_TRANSACTION_GRP_LOCK=DIR has been specified, use it.
  20391. if test "x${PJ_TRANSACTION_GRP_LOCK_DIR}" != "x"; then
  20392. if test -d ${PJ_TRANSACTION_GRP_LOCK_DIR}/lib; then
  20393. pbxlibdir="-L${PJ_TRANSACTION_GRP_LOCK_DIR}/lib"
  20394. else
  20395. pbxlibdir="-L${PJ_TRANSACTION_GRP_LOCK_DIR}"
  20396. fi
  20397. fi
  20398. pbxfuncname="pjsip_tsx_create_uac2"
  20399. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  20400. AST_PJ_TRANSACTION_GRP_LOCK_FOUND=yes
  20401. else
  20402. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  20403. CFLAGS="${CFLAGS} "
  20404. as_ac_Lib=`$as_echo "ac_cv_lib_pjsip_${pbxfuncname}" | $as_tr_sh`
  20405. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpjsip" >&5
  20406. $as_echo_n "checking for ${pbxfuncname} in -lpjsip... " >&6; }
  20407. if eval \${$as_ac_Lib+:} false; then :
  20408. $as_echo_n "(cached) " >&6
  20409. else
  20410. ac_check_lib_save_LIBS=$LIBS
  20411. LIBS="-lpjsip ${pbxlibdir} $LIBS"
  20412. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20413. /* end confdefs.h. */
  20414. /* Override any GCC internal prototype to avoid an error.
  20415. Use char because int might match the return type of a GCC
  20416. builtin and then its argument prototype would still apply. */
  20417. #ifdef __cplusplus
  20418. extern "C"
  20419. #endif
  20420. char ${pbxfuncname} ();
  20421. int
  20422. main ()
  20423. {
  20424. return ${pbxfuncname} ();
  20425. ;
  20426. return 0;
  20427. }
  20428. _ACEOF
  20429. if ac_fn_c_try_link "$LINENO"; then :
  20430. eval "$as_ac_Lib=yes"
  20431. else
  20432. eval "$as_ac_Lib=no"
  20433. fi
  20434. rm -f core conftest.err conftest.$ac_objext \
  20435. conftest$ac_exeext conftest.$ac_ext
  20436. LIBS=$ac_check_lib_save_LIBS
  20437. fi
  20438. eval ac_res=\$$as_ac_Lib
  20439. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  20440. $as_echo "$ac_res" >&6; }
  20441. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  20442. AST_PJ_TRANSACTION_GRP_LOCK_FOUND=yes
  20443. else
  20444. AST_PJ_TRANSACTION_GRP_LOCK_FOUND=no
  20445. fi
  20446. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  20447. fi
  20448. # now check for the header.
  20449. if test "${AST_PJ_TRANSACTION_GRP_LOCK_FOUND}" = "yes"; then
  20450. PJ_TRANSACTION_GRP_LOCK_LIB="${pbxlibdir} -lpjsip "
  20451. # if --with-PJ_TRANSACTION_GRP_LOCK=DIR has been specified, use it.
  20452. if test "x${PJ_TRANSACTION_GRP_LOCK_DIR}" != "x"; then
  20453. PJ_TRANSACTION_GRP_LOCK_INCLUDE="-I${PJ_TRANSACTION_GRP_LOCK_DIR}/include"
  20454. fi
  20455. PJ_TRANSACTION_GRP_LOCK_INCLUDE="${PJ_TRANSACTION_GRP_LOCK_INCLUDE} "
  20456. if test "xpjsip.h" = "x" ; then # no header, assume found
  20457. PJ_TRANSACTION_GRP_LOCK_HEADER_FOUND="1"
  20458. else # check for the header
  20459. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  20460. CPPFLAGS="${CPPFLAGS} ${PJ_TRANSACTION_GRP_LOCK_INCLUDE}"
  20461. ac_fn_c_check_header_mongrel "$LINENO" "pjsip.h" "ac_cv_header_pjsip_h" "$ac_includes_default"
  20462. if test "x$ac_cv_header_pjsip_h" = xyes; then :
  20463. PJ_TRANSACTION_GRP_LOCK_HEADER_FOUND=1
  20464. else
  20465. PJ_TRANSACTION_GRP_LOCK_HEADER_FOUND=0
  20466. fi
  20467. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  20468. fi
  20469. if test "x${PJ_TRANSACTION_GRP_LOCK_HEADER_FOUND}" = "x0" ; then
  20470. PJ_TRANSACTION_GRP_LOCK_LIB=""
  20471. PJ_TRANSACTION_GRP_LOCK_INCLUDE=""
  20472. else
  20473. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  20474. PJ_TRANSACTION_GRP_LOCK_LIB=""
  20475. fi
  20476. PBX_PJ_TRANSACTION_GRP_LOCK=1
  20477. cat >>confdefs.h <<_ACEOF
  20478. #define HAVE_PJ_TRANSACTION_GRP_LOCK 1
  20479. _ACEOF
  20480. fi
  20481. fi
  20482. fi
  20483. if test "x${PBX_PJSIP_REPLACE_MEDIA_STREAM}" != "x1" -a "${USE_PJSIP_REPLACE_MEDIA_STREAM}" != "no"; then
  20484. if test "x" != "x"; then
  20485. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for " >&5
  20486. $as_echo_n "checking for ... " >&6; }
  20487. else
  20488. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if \"pjmedia_mod_offer_flag flag = PJMEDIA_SDP_NEG_ALLOW_MEDIA_CHANGE\" compiles using pjmedia.h" >&5
  20489. $as_echo_n "checking if \"pjmedia_mod_offer_flag flag = PJMEDIA_SDP_NEG_ALLOW_MEDIA_CHANGE\" compiles using pjmedia.h... " >&6; }
  20490. fi
  20491. saved_cppflags="${CPPFLAGS}"
  20492. if test "x${PJSIP_REPLACE_MEDIA_STREAM_DIR}" != "x"; then
  20493. PJSIP_REPLACE_MEDIA_STREAM_INCLUDE="-I${PJSIP_REPLACE_MEDIA_STREAM_DIR}/include"
  20494. fi
  20495. CPPFLAGS="${CPPFLAGS} ${PJSIP_REPLACE_MEDIA_STREAM_INCLUDE}"
  20496. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20497. /* end confdefs.h. */
  20498. #include <pjmedia.h>
  20499. int
  20500. main ()
  20501. {
  20502. pjmedia_mod_offer_flag flag = PJMEDIA_SDP_NEG_ALLOW_MEDIA_CHANGE;
  20503. ;
  20504. return 0;
  20505. }
  20506. _ACEOF
  20507. if ac_fn_c_try_compile "$LINENO"; then :
  20508. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  20509. $as_echo "yes" >&6; }
  20510. PBX_PJSIP_REPLACE_MEDIA_STREAM=1
  20511. $as_echo "#define HAVE_PJSIP_REPLACE_MEDIA_STREAM 1" >>confdefs.h
  20512. else
  20513. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  20514. $as_echo "no" >&6; }
  20515. fi
  20516. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  20517. CPPFLAGS="${saved_cppflags}"
  20518. fi
  20519. if test "x${PBX_POPT}" != "x1" -a "${USE_POPT}" != "no"; then
  20520. pbxlibdir=""
  20521. # if --with-POPT=DIR has been specified, use it.
  20522. if test "x${POPT_DIR}" != "x"; then
  20523. if test -d ${POPT_DIR}/lib; then
  20524. pbxlibdir="-L${POPT_DIR}/lib"
  20525. else
  20526. pbxlibdir="-L${POPT_DIR}"
  20527. fi
  20528. fi
  20529. pbxfuncname="poptStrerror"
  20530. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  20531. AST_POPT_FOUND=yes
  20532. else
  20533. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  20534. CFLAGS="${CFLAGS} "
  20535. as_ac_Lib=`$as_echo "ac_cv_lib_popt_${pbxfuncname}" | $as_tr_sh`
  20536. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpopt" >&5
  20537. $as_echo_n "checking for ${pbxfuncname} in -lpopt... " >&6; }
  20538. if eval \${$as_ac_Lib+:} false; then :
  20539. $as_echo_n "(cached) " >&6
  20540. else
  20541. ac_check_lib_save_LIBS=$LIBS
  20542. LIBS="-lpopt ${pbxlibdir} $LIBS"
  20543. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20544. /* end confdefs.h. */
  20545. /* Override any GCC internal prototype to avoid an error.
  20546. Use char because int might match the return type of a GCC
  20547. builtin and then its argument prototype would still apply. */
  20548. #ifdef __cplusplus
  20549. extern "C"
  20550. #endif
  20551. char ${pbxfuncname} ();
  20552. int
  20553. main ()
  20554. {
  20555. return ${pbxfuncname} ();
  20556. ;
  20557. return 0;
  20558. }
  20559. _ACEOF
  20560. if ac_fn_c_try_link "$LINENO"; then :
  20561. eval "$as_ac_Lib=yes"
  20562. else
  20563. eval "$as_ac_Lib=no"
  20564. fi
  20565. rm -f core conftest.err conftest.$ac_objext \
  20566. conftest$ac_exeext conftest.$ac_ext
  20567. LIBS=$ac_check_lib_save_LIBS
  20568. fi
  20569. eval ac_res=\$$as_ac_Lib
  20570. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  20571. $as_echo "$ac_res" >&6; }
  20572. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  20573. AST_POPT_FOUND=yes
  20574. else
  20575. AST_POPT_FOUND=no
  20576. fi
  20577. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  20578. fi
  20579. # now check for the header.
  20580. if test "${AST_POPT_FOUND}" = "yes"; then
  20581. POPT_LIB="${pbxlibdir} -lpopt "
  20582. # if --with-POPT=DIR has been specified, use it.
  20583. if test "x${POPT_DIR}" != "x"; then
  20584. POPT_INCLUDE="-I${POPT_DIR}/include"
  20585. fi
  20586. POPT_INCLUDE="${POPT_INCLUDE} "
  20587. if test "xpopt.h" = "x" ; then # no header, assume found
  20588. POPT_HEADER_FOUND="1"
  20589. else # check for the header
  20590. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  20591. CPPFLAGS="${CPPFLAGS} ${POPT_INCLUDE}"
  20592. ac_fn_c_check_header_mongrel "$LINENO" "popt.h" "ac_cv_header_popt_h" "$ac_includes_default"
  20593. if test "x$ac_cv_header_popt_h" = xyes; then :
  20594. POPT_HEADER_FOUND=1
  20595. else
  20596. POPT_HEADER_FOUND=0
  20597. fi
  20598. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  20599. fi
  20600. if test "x${POPT_HEADER_FOUND}" = "x0" ; then
  20601. POPT_LIB=""
  20602. POPT_INCLUDE=""
  20603. else
  20604. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  20605. POPT_LIB=""
  20606. fi
  20607. PBX_POPT=1
  20608. cat >>confdefs.h <<_ACEOF
  20609. #define HAVE_POPT 1
  20610. _ACEOF
  20611. fi
  20612. fi
  20613. fi
  20614. if test "x${PBX_PORTAUDIO}" != "x1" -a "${USE_PORTAUDIO}" != "no"; then
  20615. pbxlibdir=""
  20616. # if --with-PORTAUDIO=DIR has been specified, use it.
  20617. if test "x${PORTAUDIO_DIR}" != "x"; then
  20618. if test -d ${PORTAUDIO_DIR}/lib; then
  20619. pbxlibdir="-L${PORTAUDIO_DIR}/lib"
  20620. else
  20621. pbxlibdir="-L${PORTAUDIO_DIR}"
  20622. fi
  20623. fi
  20624. pbxfuncname="Pa_GetDeviceCount"
  20625. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  20626. AST_PORTAUDIO_FOUND=yes
  20627. else
  20628. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  20629. CFLAGS="${CFLAGS} "
  20630. as_ac_Lib=`$as_echo "ac_cv_lib_portaudio_${pbxfuncname}" | $as_tr_sh`
  20631. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lportaudio" >&5
  20632. $as_echo_n "checking for ${pbxfuncname} in -lportaudio... " >&6; }
  20633. if eval \${$as_ac_Lib+:} false; then :
  20634. $as_echo_n "(cached) " >&6
  20635. else
  20636. ac_check_lib_save_LIBS=$LIBS
  20637. LIBS="-lportaudio ${pbxlibdir} $LIBS"
  20638. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20639. /* end confdefs.h. */
  20640. /* Override any GCC internal prototype to avoid an error.
  20641. Use char because int might match the return type of a GCC
  20642. builtin and then its argument prototype would still apply. */
  20643. #ifdef __cplusplus
  20644. extern "C"
  20645. #endif
  20646. char ${pbxfuncname} ();
  20647. int
  20648. main ()
  20649. {
  20650. return ${pbxfuncname} ();
  20651. ;
  20652. return 0;
  20653. }
  20654. _ACEOF
  20655. if ac_fn_c_try_link "$LINENO"; then :
  20656. eval "$as_ac_Lib=yes"
  20657. else
  20658. eval "$as_ac_Lib=no"
  20659. fi
  20660. rm -f core conftest.err conftest.$ac_objext \
  20661. conftest$ac_exeext conftest.$ac_ext
  20662. LIBS=$ac_check_lib_save_LIBS
  20663. fi
  20664. eval ac_res=\$$as_ac_Lib
  20665. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  20666. $as_echo "$ac_res" >&6; }
  20667. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  20668. AST_PORTAUDIO_FOUND=yes
  20669. else
  20670. AST_PORTAUDIO_FOUND=no
  20671. fi
  20672. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  20673. fi
  20674. # now check for the header.
  20675. if test "${AST_PORTAUDIO_FOUND}" = "yes"; then
  20676. PORTAUDIO_LIB="${pbxlibdir} -lportaudio "
  20677. # if --with-PORTAUDIO=DIR has been specified, use it.
  20678. if test "x${PORTAUDIO_DIR}" != "x"; then
  20679. PORTAUDIO_INCLUDE="-I${PORTAUDIO_DIR}/include"
  20680. fi
  20681. PORTAUDIO_INCLUDE="${PORTAUDIO_INCLUDE} "
  20682. if test "xportaudio.h" = "x" ; then # no header, assume found
  20683. PORTAUDIO_HEADER_FOUND="1"
  20684. else # check for the header
  20685. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  20686. CPPFLAGS="${CPPFLAGS} ${PORTAUDIO_INCLUDE}"
  20687. ac_fn_c_check_header_mongrel "$LINENO" "portaudio.h" "ac_cv_header_portaudio_h" "$ac_includes_default"
  20688. if test "x$ac_cv_header_portaudio_h" = xyes; then :
  20689. PORTAUDIO_HEADER_FOUND=1
  20690. else
  20691. PORTAUDIO_HEADER_FOUND=0
  20692. fi
  20693. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  20694. fi
  20695. if test "x${PORTAUDIO_HEADER_FOUND}" = "x0" ; then
  20696. PORTAUDIO_LIB=""
  20697. PORTAUDIO_INCLUDE=""
  20698. else
  20699. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  20700. PORTAUDIO_LIB=""
  20701. fi
  20702. PBX_PORTAUDIO=1
  20703. cat >>confdefs.h <<_ACEOF
  20704. #define HAVE_PORTAUDIO 1
  20705. _ACEOF
  20706. fi
  20707. fi
  20708. fi
  20709. if test "x${PBX_PRI}" != "x1" -a "${USE_PRI}" != "no"; then
  20710. pbxlibdir=""
  20711. # if --with-PRI=DIR has been specified, use it.
  20712. if test "x${PRI_DIR}" != "x"; then
  20713. if test -d ${PRI_DIR}/lib; then
  20714. pbxlibdir="-L${PRI_DIR}/lib"
  20715. else
  20716. pbxlibdir="-L${PRI_DIR}"
  20717. fi
  20718. fi
  20719. pbxfuncname="pri_connected_line_update"
  20720. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  20721. AST_PRI_FOUND=yes
  20722. else
  20723. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  20724. CFLAGS="${CFLAGS} "
  20725. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  20726. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  20727. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  20728. if eval \${$as_ac_Lib+:} false; then :
  20729. $as_echo_n "(cached) " >&6
  20730. else
  20731. ac_check_lib_save_LIBS=$LIBS
  20732. LIBS="-lpri ${pbxlibdir} $LIBS"
  20733. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20734. /* end confdefs.h. */
  20735. /* Override any GCC internal prototype to avoid an error.
  20736. Use char because int might match the return type of a GCC
  20737. builtin and then its argument prototype would still apply. */
  20738. #ifdef __cplusplus
  20739. extern "C"
  20740. #endif
  20741. char ${pbxfuncname} ();
  20742. int
  20743. main ()
  20744. {
  20745. return ${pbxfuncname} ();
  20746. ;
  20747. return 0;
  20748. }
  20749. _ACEOF
  20750. if ac_fn_c_try_link "$LINENO"; then :
  20751. eval "$as_ac_Lib=yes"
  20752. else
  20753. eval "$as_ac_Lib=no"
  20754. fi
  20755. rm -f core conftest.err conftest.$ac_objext \
  20756. conftest$ac_exeext conftest.$ac_ext
  20757. LIBS=$ac_check_lib_save_LIBS
  20758. fi
  20759. eval ac_res=\$$as_ac_Lib
  20760. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  20761. $as_echo "$ac_res" >&6; }
  20762. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  20763. AST_PRI_FOUND=yes
  20764. else
  20765. AST_PRI_FOUND=no
  20766. fi
  20767. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  20768. fi
  20769. # now check for the header.
  20770. if test "${AST_PRI_FOUND}" = "yes"; then
  20771. PRI_LIB="${pbxlibdir} -lpri "
  20772. # if --with-PRI=DIR has been specified, use it.
  20773. if test "x${PRI_DIR}" != "x"; then
  20774. PRI_INCLUDE="-I${PRI_DIR}/include"
  20775. fi
  20776. PRI_INCLUDE="${PRI_INCLUDE} "
  20777. if test "xlibpri.h" = "x" ; then # no header, assume found
  20778. PRI_HEADER_FOUND="1"
  20779. else # check for the header
  20780. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  20781. CPPFLAGS="${CPPFLAGS} ${PRI_INCLUDE}"
  20782. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  20783. if test "x$ac_cv_header_libpri_h" = xyes; then :
  20784. PRI_HEADER_FOUND=1
  20785. else
  20786. PRI_HEADER_FOUND=0
  20787. fi
  20788. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  20789. fi
  20790. if test "x${PRI_HEADER_FOUND}" = "x0" ; then
  20791. PRI_LIB=""
  20792. PRI_INCLUDE=""
  20793. else
  20794. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  20795. PRI_LIB=""
  20796. fi
  20797. PBX_PRI=1
  20798. cat >>confdefs.h <<_ACEOF
  20799. #define HAVE_PRI 1
  20800. _ACEOF
  20801. fi
  20802. fi
  20803. fi
  20804. if test "x${PBX_PRI_SETUP_ACK_INBAND}" != "x1" -a "${USE_PRI_SETUP_ACK_INBAND}" != "no"; then
  20805. pbxlibdir=""
  20806. # if --with-PRI_SETUP_ACK_INBAND=DIR has been specified, use it.
  20807. if test "x${PRI_SETUP_ACK_INBAND_DIR}" != "x"; then
  20808. if test -d ${PRI_SETUP_ACK_INBAND_DIR}/lib; then
  20809. pbxlibdir="-L${PRI_SETUP_ACK_INBAND_DIR}/lib"
  20810. else
  20811. pbxlibdir="-L${PRI_SETUP_ACK_INBAND_DIR}"
  20812. fi
  20813. fi
  20814. pbxfuncname="pri_setup_ack"
  20815. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  20816. AST_PRI_SETUP_ACK_INBAND_FOUND=yes
  20817. else
  20818. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  20819. CFLAGS="${CFLAGS} "
  20820. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  20821. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  20822. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  20823. if eval \${$as_ac_Lib+:} false; then :
  20824. $as_echo_n "(cached) " >&6
  20825. else
  20826. ac_check_lib_save_LIBS=$LIBS
  20827. LIBS="-lpri ${pbxlibdir} $LIBS"
  20828. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20829. /* end confdefs.h. */
  20830. /* Override any GCC internal prototype to avoid an error.
  20831. Use char because int might match the return type of a GCC
  20832. builtin and then its argument prototype would still apply. */
  20833. #ifdef __cplusplus
  20834. extern "C"
  20835. #endif
  20836. char ${pbxfuncname} ();
  20837. int
  20838. main ()
  20839. {
  20840. return ${pbxfuncname} ();
  20841. ;
  20842. return 0;
  20843. }
  20844. _ACEOF
  20845. if ac_fn_c_try_link "$LINENO"; then :
  20846. eval "$as_ac_Lib=yes"
  20847. else
  20848. eval "$as_ac_Lib=no"
  20849. fi
  20850. rm -f core conftest.err conftest.$ac_objext \
  20851. conftest$ac_exeext conftest.$ac_ext
  20852. LIBS=$ac_check_lib_save_LIBS
  20853. fi
  20854. eval ac_res=\$$as_ac_Lib
  20855. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  20856. $as_echo "$ac_res" >&6; }
  20857. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  20858. AST_PRI_SETUP_ACK_INBAND_FOUND=yes
  20859. else
  20860. AST_PRI_SETUP_ACK_INBAND_FOUND=no
  20861. fi
  20862. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  20863. fi
  20864. # now check for the header.
  20865. if test "${AST_PRI_SETUP_ACK_INBAND_FOUND}" = "yes"; then
  20866. PRI_SETUP_ACK_INBAND_LIB="${pbxlibdir} -lpri "
  20867. # if --with-PRI_SETUP_ACK_INBAND=DIR has been specified, use it.
  20868. if test "x${PRI_SETUP_ACK_INBAND_DIR}" != "x"; then
  20869. PRI_SETUP_ACK_INBAND_INCLUDE="-I${PRI_SETUP_ACK_INBAND_DIR}/include"
  20870. fi
  20871. PRI_SETUP_ACK_INBAND_INCLUDE="${PRI_SETUP_ACK_INBAND_INCLUDE} "
  20872. if test "xlibpri.h" = "x" ; then # no header, assume found
  20873. PRI_SETUP_ACK_INBAND_HEADER_FOUND="1"
  20874. else # check for the header
  20875. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  20876. CPPFLAGS="${CPPFLAGS} ${PRI_SETUP_ACK_INBAND_INCLUDE}"
  20877. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  20878. if test "x$ac_cv_header_libpri_h" = xyes; then :
  20879. PRI_SETUP_ACK_INBAND_HEADER_FOUND=1
  20880. else
  20881. PRI_SETUP_ACK_INBAND_HEADER_FOUND=0
  20882. fi
  20883. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  20884. fi
  20885. if test "x${PRI_SETUP_ACK_INBAND_HEADER_FOUND}" = "x0" ; then
  20886. PRI_SETUP_ACK_INBAND_LIB=""
  20887. PRI_SETUP_ACK_INBAND_INCLUDE=""
  20888. else
  20889. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  20890. PRI_SETUP_ACK_INBAND_LIB=""
  20891. fi
  20892. PBX_PRI_SETUP_ACK_INBAND=1
  20893. cat >>confdefs.h <<_ACEOF
  20894. #define HAVE_PRI_SETUP_ACK_INBAND 1
  20895. _ACEOF
  20896. fi
  20897. fi
  20898. fi
  20899. if test "x${PBX_PRI_L2_PERSISTENCE}" != "x1" -a "${USE_PRI_L2_PERSISTENCE}" != "no"; then
  20900. pbxlibdir=""
  20901. # if --with-PRI_L2_PERSISTENCE=DIR has been specified, use it.
  20902. if test "x${PRI_L2_PERSISTENCE_DIR}" != "x"; then
  20903. if test -d ${PRI_L2_PERSISTENCE_DIR}/lib; then
  20904. pbxlibdir="-L${PRI_L2_PERSISTENCE_DIR}/lib"
  20905. else
  20906. pbxlibdir="-L${PRI_L2_PERSISTENCE_DIR}"
  20907. fi
  20908. fi
  20909. pbxfuncname="pri_persistent_layer2_option"
  20910. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  20911. AST_PRI_L2_PERSISTENCE_FOUND=yes
  20912. else
  20913. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  20914. CFLAGS="${CFLAGS} "
  20915. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  20916. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  20917. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  20918. if eval \${$as_ac_Lib+:} false; then :
  20919. $as_echo_n "(cached) " >&6
  20920. else
  20921. ac_check_lib_save_LIBS=$LIBS
  20922. LIBS="-lpri ${pbxlibdir} $LIBS"
  20923. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20924. /* end confdefs.h. */
  20925. /* Override any GCC internal prototype to avoid an error.
  20926. Use char because int might match the return type of a GCC
  20927. builtin and then its argument prototype would still apply. */
  20928. #ifdef __cplusplus
  20929. extern "C"
  20930. #endif
  20931. char ${pbxfuncname} ();
  20932. int
  20933. main ()
  20934. {
  20935. return ${pbxfuncname} ();
  20936. ;
  20937. return 0;
  20938. }
  20939. _ACEOF
  20940. if ac_fn_c_try_link "$LINENO"; then :
  20941. eval "$as_ac_Lib=yes"
  20942. else
  20943. eval "$as_ac_Lib=no"
  20944. fi
  20945. rm -f core conftest.err conftest.$ac_objext \
  20946. conftest$ac_exeext conftest.$ac_ext
  20947. LIBS=$ac_check_lib_save_LIBS
  20948. fi
  20949. eval ac_res=\$$as_ac_Lib
  20950. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  20951. $as_echo "$ac_res" >&6; }
  20952. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  20953. AST_PRI_L2_PERSISTENCE_FOUND=yes
  20954. else
  20955. AST_PRI_L2_PERSISTENCE_FOUND=no
  20956. fi
  20957. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  20958. fi
  20959. # now check for the header.
  20960. if test "${AST_PRI_L2_PERSISTENCE_FOUND}" = "yes"; then
  20961. PRI_L2_PERSISTENCE_LIB="${pbxlibdir} -lpri "
  20962. # if --with-PRI_L2_PERSISTENCE=DIR has been specified, use it.
  20963. if test "x${PRI_L2_PERSISTENCE_DIR}" != "x"; then
  20964. PRI_L2_PERSISTENCE_INCLUDE="-I${PRI_L2_PERSISTENCE_DIR}/include"
  20965. fi
  20966. PRI_L2_PERSISTENCE_INCLUDE="${PRI_L2_PERSISTENCE_INCLUDE} "
  20967. if test "xlibpri.h" = "x" ; then # no header, assume found
  20968. PRI_L2_PERSISTENCE_HEADER_FOUND="1"
  20969. else # check for the header
  20970. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  20971. CPPFLAGS="${CPPFLAGS} ${PRI_L2_PERSISTENCE_INCLUDE}"
  20972. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  20973. if test "x$ac_cv_header_libpri_h" = xyes; then :
  20974. PRI_L2_PERSISTENCE_HEADER_FOUND=1
  20975. else
  20976. PRI_L2_PERSISTENCE_HEADER_FOUND=0
  20977. fi
  20978. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  20979. fi
  20980. if test "x${PRI_L2_PERSISTENCE_HEADER_FOUND}" = "x0" ; then
  20981. PRI_L2_PERSISTENCE_LIB=""
  20982. PRI_L2_PERSISTENCE_INCLUDE=""
  20983. else
  20984. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  20985. PRI_L2_PERSISTENCE_LIB=""
  20986. fi
  20987. PBX_PRI_L2_PERSISTENCE=1
  20988. cat >>confdefs.h <<_ACEOF
  20989. #define HAVE_PRI_L2_PERSISTENCE 1
  20990. _ACEOF
  20991. fi
  20992. fi
  20993. fi
  20994. if test "x${PBX_PRI_DATETIME_SEND}" != "x1" -a "${USE_PRI_DATETIME_SEND}" != "no"; then
  20995. pbxlibdir=""
  20996. # if --with-PRI_DATETIME_SEND=DIR has been specified, use it.
  20997. if test "x${PRI_DATETIME_SEND_DIR}" != "x"; then
  20998. if test -d ${PRI_DATETIME_SEND_DIR}/lib; then
  20999. pbxlibdir="-L${PRI_DATETIME_SEND_DIR}/lib"
  21000. else
  21001. pbxlibdir="-L${PRI_DATETIME_SEND_DIR}"
  21002. fi
  21003. fi
  21004. pbxfuncname="pri_date_time_send_option"
  21005. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21006. AST_PRI_DATETIME_SEND_FOUND=yes
  21007. else
  21008. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21009. CFLAGS="${CFLAGS} "
  21010. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21011. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21012. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21013. if eval \${$as_ac_Lib+:} false; then :
  21014. $as_echo_n "(cached) " >&6
  21015. else
  21016. ac_check_lib_save_LIBS=$LIBS
  21017. LIBS="-lpri ${pbxlibdir} $LIBS"
  21018. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21019. /* end confdefs.h. */
  21020. /* Override any GCC internal prototype to avoid an error.
  21021. Use char because int might match the return type of a GCC
  21022. builtin and then its argument prototype would still apply. */
  21023. #ifdef __cplusplus
  21024. extern "C"
  21025. #endif
  21026. char ${pbxfuncname} ();
  21027. int
  21028. main ()
  21029. {
  21030. return ${pbxfuncname} ();
  21031. ;
  21032. return 0;
  21033. }
  21034. _ACEOF
  21035. if ac_fn_c_try_link "$LINENO"; then :
  21036. eval "$as_ac_Lib=yes"
  21037. else
  21038. eval "$as_ac_Lib=no"
  21039. fi
  21040. rm -f core conftest.err conftest.$ac_objext \
  21041. conftest$ac_exeext conftest.$ac_ext
  21042. LIBS=$ac_check_lib_save_LIBS
  21043. fi
  21044. eval ac_res=\$$as_ac_Lib
  21045. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21046. $as_echo "$ac_res" >&6; }
  21047. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21048. AST_PRI_DATETIME_SEND_FOUND=yes
  21049. else
  21050. AST_PRI_DATETIME_SEND_FOUND=no
  21051. fi
  21052. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21053. fi
  21054. # now check for the header.
  21055. if test "${AST_PRI_DATETIME_SEND_FOUND}" = "yes"; then
  21056. PRI_DATETIME_SEND_LIB="${pbxlibdir} -lpri "
  21057. # if --with-PRI_DATETIME_SEND=DIR has been specified, use it.
  21058. if test "x${PRI_DATETIME_SEND_DIR}" != "x"; then
  21059. PRI_DATETIME_SEND_INCLUDE="-I${PRI_DATETIME_SEND_DIR}/include"
  21060. fi
  21061. PRI_DATETIME_SEND_INCLUDE="${PRI_DATETIME_SEND_INCLUDE} "
  21062. if test "xlibpri.h" = "x" ; then # no header, assume found
  21063. PRI_DATETIME_SEND_HEADER_FOUND="1"
  21064. else # check for the header
  21065. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21066. CPPFLAGS="${CPPFLAGS} ${PRI_DATETIME_SEND_INCLUDE}"
  21067. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21068. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21069. PRI_DATETIME_SEND_HEADER_FOUND=1
  21070. else
  21071. PRI_DATETIME_SEND_HEADER_FOUND=0
  21072. fi
  21073. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21074. fi
  21075. if test "x${PRI_DATETIME_SEND_HEADER_FOUND}" = "x0" ; then
  21076. PRI_DATETIME_SEND_LIB=""
  21077. PRI_DATETIME_SEND_INCLUDE=""
  21078. else
  21079. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21080. PRI_DATETIME_SEND_LIB=""
  21081. fi
  21082. PBX_PRI_DATETIME_SEND=1
  21083. cat >>confdefs.h <<_ACEOF
  21084. #define HAVE_PRI_DATETIME_SEND 1
  21085. _ACEOF
  21086. fi
  21087. fi
  21088. fi
  21089. if test "x${PBX_PRI_MWI_V2}" != "x1" -a "${USE_PRI_MWI_V2}" != "no"; then
  21090. pbxlibdir=""
  21091. # if --with-PRI_MWI_V2=DIR has been specified, use it.
  21092. if test "x${PRI_MWI_V2_DIR}" != "x"; then
  21093. if test -d ${PRI_MWI_V2_DIR}/lib; then
  21094. pbxlibdir="-L${PRI_MWI_V2_DIR}/lib"
  21095. else
  21096. pbxlibdir="-L${PRI_MWI_V2_DIR}"
  21097. fi
  21098. fi
  21099. pbxfuncname="pri_mwi_indicate_v2"
  21100. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21101. AST_PRI_MWI_V2_FOUND=yes
  21102. else
  21103. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21104. CFLAGS="${CFLAGS} "
  21105. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21106. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21107. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21108. if eval \${$as_ac_Lib+:} false; then :
  21109. $as_echo_n "(cached) " >&6
  21110. else
  21111. ac_check_lib_save_LIBS=$LIBS
  21112. LIBS="-lpri ${pbxlibdir} $LIBS"
  21113. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21114. /* end confdefs.h. */
  21115. /* Override any GCC internal prototype to avoid an error.
  21116. Use char because int might match the return type of a GCC
  21117. builtin and then its argument prototype would still apply. */
  21118. #ifdef __cplusplus
  21119. extern "C"
  21120. #endif
  21121. char ${pbxfuncname} ();
  21122. int
  21123. main ()
  21124. {
  21125. return ${pbxfuncname} ();
  21126. ;
  21127. return 0;
  21128. }
  21129. _ACEOF
  21130. if ac_fn_c_try_link "$LINENO"; then :
  21131. eval "$as_ac_Lib=yes"
  21132. else
  21133. eval "$as_ac_Lib=no"
  21134. fi
  21135. rm -f core conftest.err conftest.$ac_objext \
  21136. conftest$ac_exeext conftest.$ac_ext
  21137. LIBS=$ac_check_lib_save_LIBS
  21138. fi
  21139. eval ac_res=\$$as_ac_Lib
  21140. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21141. $as_echo "$ac_res" >&6; }
  21142. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21143. AST_PRI_MWI_V2_FOUND=yes
  21144. else
  21145. AST_PRI_MWI_V2_FOUND=no
  21146. fi
  21147. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21148. fi
  21149. # now check for the header.
  21150. if test "${AST_PRI_MWI_V2_FOUND}" = "yes"; then
  21151. PRI_MWI_V2_LIB="${pbxlibdir} -lpri "
  21152. # if --with-PRI_MWI_V2=DIR has been specified, use it.
  21153. if test "x${PRI_MWI_V2_DIR}" != "x"; then
  21154. PRI_MWI_V2_INCLUDE="-I${PRI_MWI_V2_DIR}/include"
  21155. fi
  21156. PRI_MWI_V2_INCLUDE="${PRI_MWI_V2_INCLUDE} "
  21157. if test "xlibpri.h" = "x" ; then # no header, assume found
  21158. PRI_MWI_V2_HEADER_FOUND="1"
  21159. else # check for the header
  21160. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21161. CPPFLAGS="${CPPFLAGS} ${PRI_MWI_V2_INCLUDE}"
  21162. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21163. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21164. PRI_MWI_V2_HEADER_FOUND=1
  21165. else
  21166. PRI_MWI_V2_HEADER_FOUND=0
  21167. fi
  21168. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21169. fi
  21170. if test "x${PRI_MWI_V2_HEADER_FOUND}" = "x0" ; then
  21171. PRI_MWI_V2_LIB=""
  21172. PRI_MWI_V2_INCLUDE=""
  21173. else
  21174. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21175. PRI_MWI_V2_LIB=""
  21176. fi
  21177. PBX_PRI_MWI_V2=1
  21178. cat >>confdefs.h <<_ACEOF
  21179. #define HAVE_PRI_MWI_V2 1
  21180. _ACEOF
  21181. fi
  21182. fi
  21183. fi
  21184. if test "x${PBX_PRI_DISPLAY_TEXT}" != "x1" -a "${USE_PRI_DISPLAY_TEXT}" != "no"; then
  21185. pbxlibdir=""
  21186. # if --with-PRI_DISPLAY_TEXT=DIR has been specified, use it.
  21187. if test "x${PRI_DISPLAY_TEXT_DIR}" != "x"; then
  21188. if test -d ${PRI_DISPLAY_TEXT_DIR}/lib; then
  21189. pbxlibdir="-L${PRI_DISPLAY_TEXT_DIR}/lib"
  21190. else
  21191. pbxlibdir="-L${PRI_DISPLAY_TEXT_DIR}"
  21192. fi
  21193. fi
  21194. pbxfuncname="pri_display_text"
  21195. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21196. AST_PRI_DISPLAY_TEXT_FOUND=yes
  21197. else
  21198. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21199. CFLAGS="${CFLAGS} "
  21200. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21201. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21202. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21203. if eval \${$as_ac_Lib+:} false; then :
  21204. $as_echo_n "(cached) " >&6
  21205. else
  21206. ac_check_lib_save_LIBS=$LIBS
  21207. LIBS="-lpri ${pbxlibdir} $LIBS"
  21208. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21209. /* end confdefs.h. */
  21210. /* Override any GCC internal prototype to avoid an error.
  21211. Use char because int might match the return type of a GCC
  21212. builtin and then its argument prototype would still apply. */
  21213. #ifdef __cplusplus
  21214. extern "C"
  21215. #endif
  21216. char ${pbxfuncname} ();
  21217. int
  21218. main ()
  21219. {
  21220. return ${pbxfuncname} ();
  21221. ;
  21222. return 0;
  21223. }
  21224. _ACEOF
  21225. if ac_fn_c_try_link "$LINENO"; then :
  21226. eval "$as_ac_Lib=yes"
  21227. else
  21228. eval "$as_ac_Lib=no"
  21229. fi
  21230. rm -f core conftest.err conftest.$ac_objext \
  21231. conftest$ac_exeext conftest.$ac_ext
  21232. LIBS=$ac_check_lib_save_LIBS
  21233. fi
  21234. eval ac_res=\$$as_ac_Lib
  21235. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21236. $as_echo "$ac_res" >&6; }
  21237. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21238. AST_PRI_DISPLAY_TEXT_FOUND=yes
  21239. else
  21240. AST_PRI_DISPLAY_TEXT_FOUND=no
  21241. fi
  21242. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21243. fi
  21244. # now check for the header.
  21245. if test "${AST_PRI_DISPLAY_TEXT_FOUND}" = "yes"; then
  21246. PRI_DISPLAY_TEXT_LIB="${pbxlibdir} -lpri "
  21247. # if --with-PRI_DISPLAY_TEXT=DIR has been specified, use it.
  21248. if test "x${PRI_DISPLAY_TEXT_DIR}" != "x"; then
  21249. PRI_DISPLAY_TEXT_INCLUDE="-I${PRI_DISPLAY_TEXT_DIR}/include"
  21250. fi
  21251. PRI_DISPLAY_TEXT_INCLUDE="${PRI_DISPLAY_TEXT_INCLUDE} "
  21252. if test "xlibpri.h" = "x" ; then # no header, assume found
  21253. PRI_DISPLAY_TEXT_HEADER_FOUND="1"
  21254. else # check for the header
  21255. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21256. CPPFLAGS="${CPPFLAGS} ${PRI_DISPLAY_TEXT_INCLUDE}"
  21257. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21258. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21259. PRI_DISPLAY_TEXT_HEADER_FOUND=1
  21260. else
  21261. PRI_DISPLAY_TEXT_HEADER_FOUND=0
  21262. fi
  21263. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21264. fi
  21265. if test "x${PRI_DISPLAY_TEXT_HEADER_FOUND}" = "x0" ; then
  21266. PRI_DISPLAY_TEXT_LIB=""
  21267. PRI_DISPLAY_TEXT_INCLUDE=""
  21268. else
  21269. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21270. PRI_DISPLAY_TEXT_LIB=""
  21271. fi
  21272. PBX_PRI_DISPLAY_TEXT=1
  21273. cat >>confdefs.h <<_ACEOF
  21274. #define HAVE_PRI_DISPLAY_TEXT 1
  21275. _ACEOF
  21276. fi
  21277. fi
  21278. fi
  21279. if test "x${PBX_PRI_MWI}" != "x1" -a "${USE_PRI_MWI}" != "no"; then
  21280. pbxlibdir=""
  21281. # if --with-PRI_MWI=DIR has been specified, use it.
  21282. if test "x${PRI_MWI_DIR}" != "x"; then
  21283. if test -d ${PRI_MWI_DIR}/lib; then
  21284. pbxlibdir="-L${PRI_MWI_DIR}/lib"
  21285. else
  21286. pbxlibdir="-L${PRI_MWI_DIR}"
  21287. fi
  21288. fi
  21289. pbxfuncname="pri_mwi_indicate"
  21290. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21291. AST_PRI_MWI_FOUND=yes
  21292. else
  21293. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21294. CFLAGS="${CFLAGS} "
  21295. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21296. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21297. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21298. if eval \${$as_ac_Lib+:} false; then :
  21299. $as_echo_n "(cached) " >&6
  21300. else
  21301. ac_check_lib_save_LIBS=$LIBS
  21302. LIBS="-lpri ${pbxlibdir} $LIBS"
  21303. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21304. /* end confdefs.h. */
  21305. /* Override any GCC internal prototype to avoid an error.
  21306. Use char because int might match the return type of a GCC
  21307. builtin and then its argument prototype would still apply. */
  21308. #ifdef __cplusplus
  21309. extern "C"
  21310. #endif
  21311. char ${pbxfuncname} ();
  21312. int
  21313. main ()
  21314. {
  21315. return ${pbxfuncname} ();
  21316. ;
  21317. return 0;
  21318. }
  21319. _ACEOF
  21320. if ac_fn_c_try_link "$LINENO"; then :
  21321. eval "$as_ac_Lib=yes"
  21322. else
  21323. eval "$as_ac_Lib=no"
  21324. fi
  21325. rm -f core conftest.err conftest.$ac_objext \
  21326. conftest$ac_exeext conftest.$ac_ext
  21327. LIBS=$ac_check_lib_save_LIBS
  21328. fi
  21329. eval ac_res=\$$as_ac_Lib
  21330. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21331. $as_echo "$ac_res" >&6; }
  21332. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21333. AST_PRI_MWI_FOUND=yes
  21334. else
  21335. AST_PRI_MWI_FOUND=no
  21336. fi
  21337. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21338. fi
  21339. # now check for the header.
  21340. if test "${AST_PRI_MWI_FOUND}" = "yes"; then
  21341. PRI_MWI_LIB="${pbxlibdir} -lpri "
  21342. # if --with-PRI_MWI=DIR has been specified, use it.
  21343. if test "x${PRI_MWI_DIR}" != "x"; then
  21344. PRI_MWI_INCLUDE="-I${PRI_MWI_DIR}/include"
  21345. fi
  21346. PRI_MWI_INCLUDE="${PRI_MWI_INCLUDE} "
  21347. if test "xlibpri.h" = "x" ; then # no header, assume found
  21348. PRI_MWI_HEADER_FOUND="1"
  21349. else # check for the header
  21350. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21351. CPPFLAGS="${CPPFLAGS} ${PRI_MWI_INCLUDE}"
  21352. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21353. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21354. PRI_MWI_HEADER_FOUND=1
  21355. else
  21356. PRI_MWI_HEADER_FOUND=0
  21357. fi
  21358. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21359. fi
  21360. if test "x${PRI_MWI_HEADER_FOUND}" = "x0" ; then
  21361. PRI_MWI_LIB=""
  21362. PRI_MWI_INCLUDE=""
  21363. else
  21364. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21365. PRI_MWI_LIB=""
  21366. fi
  21367. PBX_PRI_MWI=1
  21368. cat >>confdefs.h <<_ACEOF
  21369. #define HAVE_PRI_MWI 1
  21370. _ACEOF
  21371. fi
  21372. fi
  21373. fi
  21374. if test "x${PBX_PRI_MCID}" != "x1" -a "${USE_PRI_MCID}" != "no"; then
  21375. pbxlibdir=""
  21376. # if --with-PRI_MCID=DIR has been specified, use it.
  21377. if test "x${PRI_MCID_DIR}" != "x"; then
  21378. if test -d ${PRI_MCID_DIR}/lib; then
  21379. pbxlibdir="-L${PRI_MCID_DIR}/lib"
  21380. else
  21381. pbxlibdir="-L${PRI_MCID_DIR}"
  21382. fi
  21383. fi
  21384. pbxfuncname="pri_mcid_enable"
  21385. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21386. AST_PRI_MCID_FOUND=yes
  21387. else
  21388. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21389. CFLAGS="${CFLAGS} "
  21390. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21391. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21392. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21393. if eval \${$as_ac_Lib+:} false; then :
  21394. $as_echo_n "(cached) " >&6
  21395. else
  21396. ac_check_lib_save_LIBS=$LIBS
  21397. LIBS="-lpri ${pbxlibdir} $LIBS"
  21398. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21399. /* end confdefs.h. */
  21400. /* Override any GCC internal prototype to avoid an error.
  21401. Use char because int might match the return type of a GCC
  21402. builtin and then its argument prototype would still apply. */
  21403. #ifdef __cplusplus
  21404. extern "C"
  21405. #endif
  21406. char ${pbxfuncname} ();
  21407. int
  21408. main ()
  21409. {
  21410. return ${pbxfuncname} ();
  21411. ;
  21412. return 0;
  21413. }
  21414. _ACEOF
  21415. if ac_fn_c_try_link "$LINENO"; then :
  21416. eval "$as_ac_Lib=yes"
  21417. else
  21418. eval "$as_ac_Lib=no"
  21419. fi
  21420. rm -f core conftest.err conftest.$ac_objext \
  21421. conftest$ac_exeext conftest.$ac_ext
  21422. LIBS=$ac_check_lib_save_LIBS
  21423. fi
  21424. eval ac_res=\$$as_ac_Lib
  21425. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21426. $as_echo "$ac_res" >&6; }
  21427. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21428. AST_PRI_MCID_FOUND=yes
  21429. else
  21430. AST_PRI_MCID_FOUND=no
  21431. fi
  21432. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21433. fi
  21434. # now check for the header.
  21435. if test "${AST_PRI_MCID_FOUND}" = "yes"; then
  21436. PRI_MCID_LIB="${pbxlibdir} -lpri "
  21437. # if --with-PRI_MCID=DIR has been specified, use it.
  21438. if test "x${PRI_MCID_DIR}" != "x"; then
  21439. PRI_MCID_INCLUDE="-I${PRI_MCID_DIR}/include"
  21440. fi
  21441. PRI_MCID_INCLUDE="${PRI_MCID_INCLUDE} "
  21442. if test "xlibpri.h" = "x" ; then # no header, assume found
  21443. PRI_MCID_HEADER_FOUND="1"
  21444. else # check for the header
  21445. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21446. CPPFLAGS="${CPPFLAGS} ${PRI_MCID_INCLUDE}"
  21447. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21448. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21449. PRI_MCID_HEADER_FOUND=1
  21450. else
  21451. PRI_MCID_HEADER_FOUND=0
  21452. fi
  21453. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21454. fi
  21455. if test "x${PRI_MCID_HEADER_FOUND}" = "x0" ; then
  21456. PRI_MCID_LIB=""
  21457. PRI_MCID_INCLUDE=""
  21458. else
  21459. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21460. PRI_MCID_LIB=""
  21461. fi
  21462. PBX_PRI_MCID=1
  21463. cat >>confdefs.h <<_ACEOF
  21464. #define HAVE_PRI_MCID 1
  21465. _ACEOF
  21466. fi
  21467. fi
  21468. fi
  21469. if test "x${PBX_PRI_CALL_WAITING}" != "x1" -a "${USE_PRI_CALL_WAITING}" != "no"; then
  21470. pbxlibdir=""
  21471. # if --with-PRI_CALL_WAITING=DIR has been specified, use it.
  21472. if test "x${PRI_CALL_WAITING_DIR}" != "x"; then
  21473. if test -d ${PRI_CALL_WAITING_DIR}/lib; then
  21474. pbxlibdir="-L${PRI_CALL_WAITING_DIR}/lib"
  21475. else
  21476. pbxlibdir="-L${PRI_CALL_WAITING_DIR}"
  21477. fi
  21478. fi
  21479. pbxfuncname="pri_connect_ack_enable"
  21480. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21481. AST_PRI_CALL_WAITING_FOUND=yes
  21482. else
  21483. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21484. CFLAGS="${CFLAGS} "
  21485. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21486. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21487. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21488. if eval \${$as_ac_Lib+:} false; then :
  21489. $as_echo_n "(cached) " >&6
  21490. else
  21491. ac_check_lib_save_LIBS=$LIBS
  21492. LIBS="-lpri ${pbxlibdir} $LIBS"
  21493. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21494. /* end confdefs.h. */
  21495. /* Override any GCC internal prototype to avoid an error.
  21496. Use char because int might match the return type of a GCC
  21497. builtin and then its argument prototype would still apply. */
  21498. #ifdef __cplusplus
  21499. extern "C"
  21500. #endif
  21501. char ${pbxfuncname} ();
  21502. int
  21503. main ()
  21504. {
  21505. return ${pbxfuncname} ();
  21506. ;
  21507. return 0;
  21508. }
  21509. _ACEOF
  21510. if ac_fn_c_try_link "$LINENO"; then :
  21511. eval "$as_ac_Lib=yes"
  21512. else
  21513. eval "$as_ac_Lib=no"
  21514. fi
  21515. rm -f core conftest.err conftest.$ac_objext \
  21516. conftest$ac_exeext conftest.$ac_ext
  21517. LIBS=$ac_check_lib_save_LIBS
  21518. fi
  21519. eval ac_res=\$$as_ac_Lib
  21520. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21521. $as_echo "$ac_res" >&6; }
  21522. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21523. AST_PRI_CALL_WAITING_FOUND=yes
  21524. else
  21525. AST_PRI_CALL_WAITING_FOUND=no
  21526. fi
  21527. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21528. fi
  21529. # now check for the header.
  21530. if test "${AST_PRI_CALL_WAITING_FOUND}" = "yes"; then
  21531. PRI_CALL_WAITING_LIB="${pbxlibdir} -lpri "
  21532. # if --with-PRI_CALL_WAITING=DIR has been specified, use it.
  21533. if test "x${PRI_CALL_WAITING_DIR}" != "x"; then
  21534. PRI_CALL_WAITING_INCLUDE="-I${PRI_CALL_WAITING_DIR}/include"
  21535. fi
  21536. PRI_CALL_WAITING_INCLUDE="${PRI_CALL_WAITING_INCLUDE} "
  21537. if test "xlibpri.h" = "x" ; then # no header, assume found
  21538. PRI_CALL_WAITING_HEADER_FOUND="1"
  21539. else # check for the header
  21540. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21541. CPPFLAGS="${CPPFLAGS} ${PRI_CALL_WAITING_INCLUDE}"
  21542. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21543. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21544. PRI_CALL_WAITING_HEADER_FOUND=1
  21545. else
  21546. PRI_CALL_WAITING_HEADER_FOUND=0
  21547. fi
  21548. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21549. fi
  21550. if test "x${PRI_CALL_WAITING_HEADER_FOUND}" = "x0" ; then
  21551. PRI_CALL_WAITING_LIB=""
  21552. PRI_CALL_WAITING_INCLUDE=""
  21553. else
  21554. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21555. PRI_CALL_WAITING_LIB=""
  21556. fi
  21557. PBX_PRI_CALL_WAITING=1
  21558. cat >>confdefs.h <<_ACEOF
  21559. #define HAVE_PRI_CALL_WAITING 1
  21560. _ACEOF
  21561. fi
  21562. fi
  21563. fi
  21564. if test "x${PBX_PRI_AOC_EVENTS}" != "x1" -a "${USE_PRI_AOC_EVENTS}" != "no"; then
  21565. pbxlibdir=""
  21566. # if --with-PRI_AOC_EVENTS=DIR has been specified, use it.
  21567. if test "x${PRI_AOC_EVENTS_DIR}" != "x"; then
  21568. if test -d ${PRI_AOC_EVENTS_DIR}/lib; then
  21569. pbxlibdir="-L${PRI_AOC_EVENTS_DIR}/lib"
  21570. else
  21571. pbxlibdir="-L${PRI_AOC_EVENTS_DIR}"
  21572. fi
  21573. fi
  21574. pbxfuncname="pri_aoc_events_enable"
  21575. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21576. AST_PRI_AOC_EVENTS_FOUND=yes
  21577. else
  21578. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21579. CFLAGS="${CFLAGS} "
  21580. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21581. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21582. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21583. if eval \${$as_ac_Lib+:} false; then :
  21584. $as_echo_n "(cached) " >&6
  21585. else
  21586. ac_check_lib_save_LIBS=$LIBS
  21587. LIBS="-lpri ${pbxlibdir} $LIBS"
  21588. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21589. /* end confdefs.h. */
  21590. /* Override any GCC internal prototype to avoid an error.
  21591. Use char because int might match the return type of a GCC
  21592. builtin and then its argument prototype would still apply. */
  21593. #ifdef __cplusplus
  21594. extern "C"
  21595. #endif
  21596. char ${pbxfuncname} ();
  21597. int
  21598. main ()
  21599. {
  21600. return ${pbxfuncname} ();
  21601. ;
  21602. return 0;
  21603. }
  21604. _ACEOF
  21605. if ac_fn_c_try_link "$LINENO"; then :
  21606. eval "$as_ac_Lib=yes"
  21607. else
  21608. eval "$as_ac_Lib=no"
  21609. fi
  21610. rm -f core conftest.err conftest.$ac_objext \
  21611. conftest$ac_exeext conftest.$ac_ext
  21612. LIBS=$ac_check_lib_save_LIBS
  21613. fi
  21614. eval ac_res=\$$as_ac_Lib
  21615. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21616. $as_echo "$ac_res" >&6; }
  21617. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21618. AST_PRI_AOC_EVENTS_FOUND=yes
  21619. else
  21620. AST_PRI_AOC_EVENTS_FOUND=no
  21621. fi
  21622. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21623. fi
  21624. # now check for the header.
  21625. if test "${AST_PRI_AOC_EVENTS_FOUND}" = "yes"; then
  21626. PRI_AOC_EVENTS_LIB="${pbxlibdir} -lpri "
  21627. # if --with-PRI_AOC_EVENTS=DIR has been specified, use it.
  21628. if test "x${PRI_AOC_EVENTS_DIR}" != "x"; then
  21629. PRI_AOC_EVENTS_INCLUDE="-I${PRI_AOC_EVENTS_DIR}/include"
  21630. fi
  21631. PRI_AOC_EVENTS_INCLUDE="${PRI_AOC_EVENTS_INCLUDE} "
  21632. if test "xlibpri.h" = "x" ; then # no header, assume found
  21633. PRI_AOC_EVENTS_HEADER_FOUND="1"
  21634. else # check for the header
  21635. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21636. CPPFLAGS="${CPPFLAGS} ${PRI_AOC_EVENTS_INCLUDE}"
  21637. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21638. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21639. PRI_AOC_EVENTS_HEADER_FOUND=1
  21640. else
  21641. PRI_AOC_EVENTS_HEADER_FOUND=0
  21642. fi
  21643. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21644. fi
  21645. if test "x${PRI_AOC_EVENTS_HEADER_FOUND}" = "x0" ; then
  21646. PRI_AOC_EVENTS_LIB=""
  21647. PRI_AOC_EVENTS_INCLUDE=""
  21648. else
  21649. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21650. PRI_AOC_EVENTS_LIB=""
  21651. fi
  21652. PBX_PRI_AOC_EVENTS=1
  21653. cat >>confdefs.h <<_ACEOF
  21654. #define HAVE_PRI_AOC_EVENTS 1
  21655. _ACEOF
  21656. fi
  21657. fi
  21658. fi
  21659. if test "x${PBX_PRI_TRANSFER}" != "x1" -a "${USE_PRI_TRANSFER}" != "no"; then
  21660. pbxlibdir=""
  21661. # if --with-PRI_TRANSFER=DIR has been specified, use it.
  21662. if test "x${PRI_TRANSFER_DIR}" != "x"; then
  21663. if test -d ${PRI_TRANSFER_DIR}/lib; then
  21664. pbxlibdir="-L${PRI_TRANSFER_DIR}/lib"
  21665. else
  21666. pbxlibdir="-L${PRI_TRANSFER_DIR}"
  21667. fi
  21668. fi
  21669. pbxfuncname="pri_transfer_enable"
  21670. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21671. AST_PRI_TRANSFER_FOUND=yes
  21672. else
  21673. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21674. CFLAGS="${CFLAGS} "
  21675. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21676. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21677. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21678. if eval \${$as_ac_Lib+:} false; then :
  21679. $as_echo_n "(cached) " >&6
  21680. else
  21681. ac_check_lib_save_LIBS=$LIBS
  21682. LIBS="-lpri ${pbxlibdir} $LIBS"
  21683. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21684. /* end confdefs.h. */
  21685. /* Override any GCC internal prototype to avoid an error.
  21686. Use char because int might match the return type of a GCC
  21687. builtin and then its argument prototype would still apply. */
  21688. #ifdef __cplusplus
  21689. extern "C"
  21690. #endif
  21691. char ${pbxfuncname} ();
  21692. int
  21693. main ()
  21694. {
  21695. return ${pbxfuncname} ();
  21696. ;
  21697. return 0;
  21698. }
  21699. _ACEOF
  21700. if ac_fn_c_try_link "$LINENO"; then :
  21701. eval "$as_ac_Lib=yes"
  21702. else
  21703. eval "$as_ac_Lib=no"
  21704. fi
  21705. rm -f core conftest.err conftest.$ac_objext \
  21706. conftest$ac_exeext conftest.$ac_ext
  21707. LIBS=$ac_check_lib_save_LIBS
  21708. fi
  21709. eval ac_res=\$$as_ac_Lib
  21710. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21711. $as_echo "$ac_res" >&6; }
  21712. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21713. AST_PRI_TRANSFER_FOUND=yes
  21714. else
  21715. AST_PRI_TRANSFER_FOUND=no
  21716. fi
  21717. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21718. fi
  21719. # now check for the header.
  21720. if test "${AST_PRI_TRANSFER_FOUND}" = "yes"; then
  21721. PRI_TRANSFER_LIB="${pbxlibdir} -lpri "
  21722. # if --with-PRI_TRANSFER=DIR has been specified, use it.
  21723. if test "x${PRI_TRANSFER_DIR}" != "x"; then
  21724. PRI_TRANSFER_INCLUDE="-I${PRI_TRANSFER_DIR}/include"
  21725. fi
  21726. PRI_TRANSFER_INCLUDE="${PRI_TRANSFER_INCLUDE} "
  21727. if test "xlibpri.h" = "x" ; then # no header, assume found
  21728. PRI_TRANSFER_HEADER_FOUND="1"
  21729. else # check for the header
  21730. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21731. CPPFLAGS="${CPPFLAGS} ${PRI_TRANSFER_INCLUDE}"
  21732. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21733. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21734. PRI_TRANSFER_HEADER_FOUND=1
  21735. else
  21736. PRI_TRANSFER_HEADER_FOUND=0
  21737. fi
  21738. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21739. fi
  21740. if test "x${PRI_TRANSFER_HEADER_FOUND}" = "x0" ; then
  21741. PRI_TRANSFER_LIB=""
  21742. PRI_TRANSFER_INCLUDE=""
  21743. else
  21744. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21745. PRI_TRANSFER_LIB=""
  21746. fi
  21747. PBX_PRI_TRANSFER=1
  21748. cat >>confdefs.h <<_ACEOF
  21749. #define HAVE_PRI_TRANSFER 1
  21750. _ACEOF
  21751. fi
  21752. fi
  21753. fi
  21754. if test "x${PBX_PRI_CCSS}" != "x1" -a "${USE_PRI_CCSS}" != "no"; then
  21755. pbxlibdir=""
  21756. # if --with-PRI_CCSS=DIR has been specified, use it.
  21757. if test "x${PRI_CCSS_DIR}" != "x"; then
  21758. if test -d ${PRI_CCSS_DIR}/lib; then
  21759. pbxlibdir="-L${PRI_CCSS_DIR}/lib"
  21760. else
  21761. pbxlibdir="-L${PRI_CCSS_DIR}"
  21762. fi
  21763. fi
  21764. pbxfuncname="pri_cc_enable"
  21765. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21766. AST_PRI_CCSS_FOUND=yes
  21767. else
  21768. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21769. CFLAGS="${CFLAGS} "
  21770. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21771. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21772. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21773. if eval \${$as_ac_Lib+:} false; then :
  21774. $as_echo_n "(cached) " >&6
  21775. else
  21776. ac_check_lib_save_LIBS=$LIBS
  21777. LIBS="-lpri ${pbxlibdir} $LIBS"
  21778. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21779. /* end confdefs.h. */
  21780. /* Override any GCC internal prototype to avoid an error.
  21781. Use char because int might match the return type of a GCC
  21782. builtin and then its argument prototype would still apply. */
  21783. #ifdef __cplusplus
  21784. extern "C"
  21785. #endif
  21786. char ${pbxfuncname} ();
  21787. int
  21788. main ()
  21789. {
  21790. return ${pbxfuncname} ();
  21791. ;
  21792. return 0;
  21793. }
  21794. _ACEOF
  21795. if ac_fn_c_try_link "$LINENO"; then :
  21796. eval "$as_ac_Lib=yes"
  21797. else
  21798. eval "$as_ac_Lib=no"
  21799. fi
  21800. rm -f core conftest.err conftest.$ac_objext \
  21801. conftest$ac_exeext conftest.$ac_ext
  21802. LIBS=$ac_check_lib_save_LIBS
  21803. fi
  21804. eval ac_res=\$$as_ac_Lib
  21805. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21806. $as_echo "$ac_res" >&6; }
  21807. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21808. AST_PRI_CCSS_FOUND=yes
  21809. else
  21810. AST_PRI_CCSS_FOUND=no
  21811. fi
  21812. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21813. fi
  21814. # now check for the header.
  21815. if test "${AST_PRI_CCSS_FOUND}" = "yes"; then
  21816. PRI_CCSS_LIB="${pbxlibdir} -lpri "
  21817. # if --with-PRI_CCSS=DIR has been specified, use it.
  21818. if test "x${PRI_CCSS_DIR}" != "x"; then
  21819. PRI_CCSS_INCLUDE="-I${PRI_CCSS_DIR}/include"
  21820. fi
  21821. PRI_CCSS_INCLUDE="${PRI_CCSS_INCLUDE} "
  21822. if test "xlibpri.h" = "x" ; then # no header, assume found
  21823. PRI_CCSS_HEADER_FOUND="1"
  21824. else # check for the header
  21825. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21826. CPPFLAGS="${CPPFLAGS} ${PRI_CCSS_INCLUDE}"
  21827. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21828. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21829. PRI_CCSS_HEADER_FOUND=1
  21830. else
  21831. PRI_CCSS_HEADER_FOUND=0
  21832. fi
  21833. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21834. fi
  21835. if test "x${PRI_CCSS_HEADER_FOUND}" = "x0" ; then
  21836. PRI_CCSS_LIB=""
  21837. PRI_CCSS_INCLUDE=""
  21838. else
  21839. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21840. PRI_CCSS_LIB=""
  21841. fi
  21842. PBX_PRI_CCSS=1
  21843. cat >>confdefs.h <<_ACEOF
  21844. #define HAVE_PRI_CCSS 1
  21845. _ACEOF
  21846. fi
  21847. fi
  21848. fi
  21849. if test "x${PBX_PRI_HANGUP_FIX}" != "x1" -a "${USE_PRI_HANGUP_FIX}" != "no"; then
  21850. pbxlibdir=""
  21851. # if --with-PRI_HANGUP_FIX=DIR has been specified, use it.
  21852. if test "x${PRI_HANGUP_FIX_DIR}" != "x"; then
  21853. if test -d ${PRI_HANGUP_FIX_DIR}/lib; then
  21854. pbxlibdir="-L${PRI_HANGUP_FIX_DIR}/lib"
  21855. else
  21856. pbxlibdir="-L${PRI_HANGUP_FIX_DIR}"
  21857. fi
  21858. fi
  21859. pbxfuncname="pri_hangup_fix_enable"
  21860. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21861. AST_PRI_HANGUP_FIX_FOUND=yes
  21862. else
  21863. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21864. CFLAGS="${CFLAGS} "
  21865. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21866. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21867. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21868. if eval \${$as_ac_Lib+:} false; then :
  21869. $as_echo_n "(cached) " >&6
  21870. else
  21871. ac_check_lib_save_LIBS=$LIBS
  21872. LIBS="-lpri ${pbxlibdir} $LIBS"
  21873. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21874. /* end confdefs.h. */
  21875. /* Override any GCC internal prototype to avoid an error.
  21876. Use char because int might match the return type of a GCC
  21877. builtin and then its argument prototype would still apply. */
  21878. #ifdef __cplusplus
  21879. extern "C"
  21880. #endif
  21881. char ${pbxfuncname} ();
  21882. int
  21883. main ()
  21884. {
  21885. return ${pbxfuncname} ();
  21886. ;
  21887. return 0;
  21888. }
  21889. _ACEOF
  21890. if ac_fn_c_try_link "$LINENO"; then :
  21891. eval "$as_ac_Lib=yes"
  21892. else
  21893. eval "$as_ac_Lib=no"
  21894. fi
  21895. rm -f core conftest.err conftest.$ac_objext \
  21896. conftest$ac_exeext conftest.$ac_ext
  21897. LIBS=$ac_check_lib_save_LIBS
  21898. fi
  21899. eval ac_res=\$$as_ac_Lib
  21900. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21901. $as_echo "$ac_res" >&6; }
  21902. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21903. AST_PRI_HANGUP_FIX_FOUND=yes
  21904. else
  21905. AST_PRI_HANGUP_FIX_FOUND=no
  21906. fi
  21907. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21908. fi
  21909. # now check for the header.
  21910. if test "${AST_PRI_HANGUP_FIX_FOUND}" = "yes"; then
  21911. PRI_HANGUP_FIX_LIB="${pbxlibdir} -lpri "
  21912. # if --with-PRI_HANGUP_FIX=DIR has been specified, use it.
  21913. if test "x${PRI_HANGUP_FIX_DIR}" != "x"; then
  21914. PRI_HANGUP_FIX_INCLUDE="-I${PRI_HANGUP_FIX_DIR}/include"
  21915. fi
  21916. PRI_HANGUP_FIX_INCLUDE="${PRI_HANGUP_FIX_INCLUDE} "
  21917. if test "xlibpri.h" = "x" ; then # no header, assume found
  21918. PRI_HANGUP_FIX_HEADER_FOUND="1"
  21919. else # check for the header
  21920. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21921. CPPFLAGS="${CPPFLAGS} ${PRI_HANGUP_FIX_INCLUDE}"
  21922. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21923. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21924. PRI_HANGUP_FIX_HEADER_FOUND=1
  21925. else
  21926. PRI_HANGUP_FIX_HEADER_FOUND=0
  21927. fi
  21928. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21929. fi
  21930. if test "x${PRI_HANGUP_FIX_HEADER_FOUND}" = "x0" ; then
  21931. PRI_HANGUP_FIX_LIB=""
  21932. PRI_HANGUP_FIX_INCLUDE=""
  21933. else
  21934. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21935. PRI_HANGUP_FIX_LIB=""
  21936. fi
  21937. PBX_PRI_HANGUP_FIX=1
  21938. cat >>confdefs.h <<_ACEOF
  21939. #define HAVE_PRI_HANGUP_FIX 1
  21940. _ACEOF
  21941. fi
  21942. fi
  21943. fi
  21944. if test "x${PBX_PRI_SUBADDR}" != "x1" -a "${USE_PRI_SUBADDR}" != "no"; then
  21945. pbxlibdir=""
  21946. # if --with-PRI_SUBADDR=DIR has been specified, use it.
  21947. if test "x${PRI_SUBADDR_DIR}" != "x"; then
  21948. if test -d ${PRI_SUBADDR_DIR}/lib; then
  21949. pbxlibdir="-L${PRI_SUBADDR_DIR}/lib"
  21950. else
  21951. pbxlibdir="-L${PRI_SUBADDR_DIR}"
  21952. fi
  21953. fi
  21954. pbxfuncname="pri_sr_set_called_subaddress"
  21955. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21956. AST_PRI_SUBADDR_FOUND=yes
  21957. else
  21958. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21959. CFLAGS="${CFLAGS} "
  21960. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21961. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21962. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21963. if eval \${$as_ac_Lib+:} false; then :
  21964. $as_echo_n "(cached) " >&6
  21965. else
  21966. ac_check_lib_save_LIBS=$LIBS
  21967. LIBS="-lpri ${pbxlibdir} $LIBS"
  21968. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21969. /* end confdefs.h. */
  21970. /* Override any GCC internal prototype to avoid an error.
  21971. Use char because int might match the return type of a GCC
  21972. builtin and then its argument prototype would still apply. */
  21973. #ifdef __cplusplus
  21974. extern "C"
  21975. #endif
  21976. char ${pbxfuncname} ();
  21977. int
  21978. main ()
  21979. {
  21980. return ${pbxfuncname} ();
  21981. ;
  21982. return 0;
  21983. }
  21984. _ACEOF
  21985. if ac_fn_c_try_link "$LINENO"; then :
  21986. eval "$as_ac_Lib=yes"
  21987. else
  21988. eval "$as_ac_Lib=no"
  21989. fi
  21990. rm -f core conftest.err conftest.$ac_objext \
  21991. conftest$ac_exeext conftest.$ac_ext
  21992. LIBS=$ac_check_lib_save_LIBS
  21993. fi
  21994. eval ac_res=\$$as_ac_Lib
  21995. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21996. $as_echo "$ac_res" >&6; }
  21997. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21998. AST_PRI_SUBADDR_FOUND=yes
  21999. else
  22000. AST_PRI_SUBADDR_FOUND=no
  22001. fi
  22002. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22003. fi
  22004. # now check for the header.
  22005. if test "${AST_PRI_SUBADDR_FOUND}" = "yes"; then
  22006. PRI_SUBADDR_LIB="${pbxlibdir} -lpri "
  22007. # if --with-PRI_SUBADDR=DIR has been specified, use it.
  22008. if test "x${PRI_SUBADDR_DIR}" != "x"; then
  22009. PRI_SUBADDR_INCLUDE="-I${PRI_SUBADDR_DIR}/include"
  22010. fi
  22011. PRI_SUBADDR_INCLUDE="${PRI_SUBADDR_INCLUDE} "
  22012. if test "xlibpri.h" = "x" ; then # no header, assume found
  22013. PRI_SUBADDR_HEADER_FOUND="1"
  22014. else # check for the header
  22015. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22016. CPPFLAGS="${CPPFLAGS} ${PRI_SUBADDR_INCLUDE}"
  22017. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22018. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22019. PRI_SUBADDR_HEADER_FOUND=1
  22020. else
  22021. PRI_SUBADDR_HEADER_FOUND=0
  22022. fi
  22023. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22024. fi
  22025. if test "x${PRI_SUBADDR_HEADER_FOUND}" = "x0" ; then
  22026. PRI_SUBADDR_LIB=""
  22027. PRI_SUBADDR_INCLUDE=""
  22028. else
  22029. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22030. PRI_SUBADDR_LIB=""
  22031. fi
  22032. PBX_PRI_SUBADDR=1
  22033. cat >>confdefs.h <<_ACEOF
  22034. #define HAVE_PRI_SUBADDR 1
  22035. _ACEOF
  22036. fi
  22037. fi
  22038. fi
  22039. if test "x${PBX_PRI_CALL_HOLD}" != "x1" -a "${USE_PRI_CALL_HOLD}" != "no"; then
  22040. pbxlibdir=""
  22041. # if --with-PRI_CALL_HOLD=DIR has been specified, use it.
  22042. if test "x${PRI_CALL_HOLD_DIR}" != "x"; then
  22043. if test -d ${PRI_CALL_HOLD_DIR}/lib; then
  22044. pbxlibdir="-L${PRI_CALL_HOLD_DIR}/lib"
  22045. else
  22046. pbxlibdir="-L${PRI_CALL_HOLD_DIR}"
  22047. fi
  22048. fi
  22049. pbxfuncname="pri_hold_enable"
  22050. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22051. AST_PRI_CALL_HOLD_FOUND=yes
  22052. else
  22053. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22054. CFLAGS="${CFLAGS} "
  22055. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22056. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22057. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22058. if eval \${$as_ac_Lib+:} false; then :
  22059. $as_echo_n "(cached) " >&6
  22060. else
  22061. ac_check_lib_save_LIBS=$LIBS
  22062. LIBS="-lpri ${pbxlibdir} $LIBS"
  22063. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22064. /* end confdefs.h. */
  22065. /* Override any GCC internal prototype to avoid an error.
  22066. Use char because int might match the return type of a GCC
  22067. builtin and then its argument prototype would still apply. */
  22068. #ifdef __cplusplus
  22069. extern "C"
  22070. #endif
  22071. char ${pbxfuncname} ();
  22072. int
  22073. main ()
  22074. {
  22075. return ${pbxfuncname} ();
  22076. ;
  22077. return 0;
  22078. }
  22079. _ACEOF
  22080. if ac_fn_c_try_link "$LINENO"; then :
  22081. eval "$as_ac_Lib=yes"
  22082. else
  22083. eval "$as_ac_Lib=no"
  22084. fi
  22085. rm -f core conftest.err conftest.$ac_objext \
  22086. conftest$ac_exeext conftest.$ac_ext
  22087. LIBS=$ac_check_lib_save_LIBS
  22088. fi
  22089. eval ac_res=\$$as_ac_Lib
  22090. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22091. $as_echo "$ac_res" >&6; }
  22092. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22093. AST_PRI_CALL_HOLD_FOUND=yes
  22094. else
  22095. AST_PRI_CALL_HOLD_FOUND=no
  22096. fi
  22097. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22098. fi
  22099. # now check for the header.
  22100. if test "${AST_PRI_CALL_HOLD_FOUND}" = "yes"; then
  22101. PRI_CALL_HOLD_LIB="${pbxlibdir} -lpri "
  22102. # if --with-PRI_CALL_HOLD=DIR has been specified, use it.
  22103. if test "x${PRI_CALL_HOLD_DIR}" != "x"; then
  22104. PRI_CALL_HOLD_INCLUDE="-I${PRI_CALL_HOLD_DIR}/include"
  22105. fi
  22106. PRI_CALL_HOLD_INCLUDE="${PRI_CALL_HOLD_INCLUDE} "
  22107. if test "xlibpri.h" = "x" ; then # no header, assume found
  22108. PRI_CALL_HOLD_HEADER_FOUND="1"
  22109. else # check for the header
  22110. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22111. CPPFLAGS="${CPPFLAGS} ${PRI_CALL_HOLD_INCLUDE}"
  22112. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22113. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22114. PRI_CALL_HOLD_HEADER_FOUND=1
  22115. else
  22116. PRI_CALL_HOLD_HEADER_FOUND=0
  22117. fi
  22118. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22119. fi
  22120. if test "x${PRI_CALL_HOLD_HEADER_FOUND}" = "x0" ; then
  22121. PRI_CALL_HOLD_LIB=""
  22122. PRI_CALL_HOLD_INCLUDE=""
  22123. else
  22124. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22125. PRI_CALL_HOLD_LIB=""
  22126. fi
  22127. PBX_PRI_CALL_HOLD=1
  22128. cat >>confdefs.h <<_ACEOF
  22129. #define HAVE_PRI_CALL_HOLD 1
  22130. _ACEOF
  22131. fi
  22132. fi
  22133. fi
  22134. if test "x${PBX_PRI_CALL_REROUTING}" != "x1" -a "${USE_PRI_CALL_REROUTING}" != "no"; then
  22135. pbxlibdir=""
  22136. # if --with-PRI_CALL_REROUTING=DIR has been specified, use it.
  22137. if test "x${PRI_CALL_REROUTING_DIR}" != "x"; then
  22138. if test -d ${PRI_CALL_REROUTING_DIR}/lib; then
  22139. pbxlibdir="-L${PRI_CALL_REROUTING_DIR}/lib"
  22140. else
  22141. pbxlibdir="-L${PRI_CALL_REROUTING_DIR}"
  22142. fi
  22143. fi
  22144. pbxfuncname="pri_reroute_enable"
  22145. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22146. AST_PRI_CALL_REROUTING_FOUND=yes
  22147. else
  22148. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22149. CFLAGS="${CFLAGS} "
  22150. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22151. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22152. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22153. if eval \${$as_ac_Lib+:} false; then :
  22154. $as_echo_n "(cached) " >&6
  22155. else
  22156. ac_check_lib_save_LIBS=$LIBS
  22157. LIBS="-lpri ${pbxlibdir} $LIBS"
  22158. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22159. /* end confdefs.h. */
  22160. /* Override any GCC internal prototype to avoid an error.
  22161. Use char because int might match the return type of a GCC
  22162. builtin and then its argument prototype would still apply. */
  22163. #ifdef __cplusplus
  22164. extern "C"
  22165. #endif
  22166. char ${pbxfuncname} ();
  22167. int
  22168. main ()
  22169. {
  22170. return ${pbxfuncname} ();
  22171. ;
  22172. return 0;
  22173. }
  22174. _ACEOF
  22175. if ac_fn_c_try_link "$LINENO"; then :
  22176. eval "$as_ac_Lib=yes"
  22177. else
  22178. eval "$as_ac_Lib=no"
  22179. fi
  22180. rm -f core conftest.err conftest.$ac_objext \
  22181. conftest$ac_exeext conftest.$ac_ext
  22182. LIBS=$ac_check_lib_save_LIBS
  22183. fi
  22184. eval ac_res=\$$as_ac_Lib
  22185. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22186. $as_echo "$ac_res" >&6; }
  22187. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22188. AST_PRI_CALL_REROUTING_FOUND=yes
  22189. else
  22190. AST_PRI_CALL_REROUTING_FOUND=no
  22191. fi
  22192. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22193. fi
  22194. # now check for the header.
  22195. if test "${AST_PRI_CALL_REROUTING_FOUND}" = "yes"; then
  22196. PRI_CALL_REROUTING_LIB="${pbxlibdir} -lpri "
  22197. # if --with-PRI_CALL_REROUTING=DIR has been specified, use it.
  22198. if test "x${PRI_CALL_REROUTING_DIR}" != "x"; then
  22199. PRI_CALL_REROUTING_INCLUDE="-I${PRI_CALL_REROUTING_DIR}/include"
  22200. fi
  22201. PRI_CALL_REROUTING_INCLUDE="${PRI_CALL_REROUTING_INCLUDE} "
  22202. if test "xlibpri.h" = "x" ; then # no header, assume found
  22203. PRI_CALL_REROUTING_HEADER_FOUND="1"
  22204. else # check for the header
  22205. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22206. CPPFLAGS="${CPPFLAGS} ${PRI_CALL_REROUTING_INCLUDE}"
  22207. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22208. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22209. PRI_CALL_REROUTING_HEADER_FOUND=1
  22210. else
  22211. PRI_CALL_REROUTING_HEADER_FOUND=0
  22212. fi
  22213. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22214. fi
  22215. if test "x${PRI_CALL_REROUTING_HEADER_FOUND}" = "x0" ; then
  22216. PRI_CALL_REROUTING_LIB=""
  22217. PRI_CALL_REROUTING_INCLUDE=""
  22218. else
  22219. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22220. PRI_CALL_REROUTING_LIB=""
  22221. fi
  22222. PBX_PRI_CALL_REROUTING=1
  22223. cat >>confdefs.h <<_ACEOF
  22224. #define HAVE_PRI_CALL_REROUTING 1
  22225. _ACEOF
  22226. fi
  22227. fi
  22228. fi
  22229. if test "x${PBX_PRI_SETUP_KEYPAD}" != "x1" -a "${USE_PRI_SETUP_KEYPAD}" != "no"; then
  22230. pbxlibdir=""
  22231. # if --with-PRI_SETUP_KEYPAD=DIR has been specified, use it.
  22232. if test "x${PRI_SETUP_KEYPAD_DIR}" != "x"; then
  22233. if test -d ${PRI_SETUP_KEYPAD_DIR}/lib; then
  22234. pbxlibdir="-L${PRI_SETUP_KEYPAD_DIR}/lib"
  22235. else
  22236. pbxlibdir="-L${PRI_SETUP_KEYPAD_DIR}"
  22237. fi
  22238. fi
  22239. pbxfuncname="pri_sr_set_keypad_digits"
  22240. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22241. AST_PRI_SETUP_KEYPAD_FOUND=yes
  22242. else
  22243. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22244. CFLAGS="${CFLAGS} "
  22245. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22246. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22247. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22248. if eval \${$as_ac_Lib+:} false; then :
  22249. $as_echo_n "(cached) " >&6
  22250. else
  22251. ac_check_lib_save_LIBS=$LIBS
  22252. LIBS="-lpri ${pbxlibdir} $LIBS"
  22253. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22254. /* end confdefs.h. */
  22255. /* Override any GCC internal prototype to avoid an error.
  22256. Use char because int might match the return type of a GCC
  22257. builtin and then its argument prototype would still apply. */
  22258. #ifdef __cplusplus
  22259. extern "C"
  22260. #endif
  22261. char ${pbxfuncname} ();
  22262. int
  22263. main ()
  22264. {
  22265. return ${pbxfuncname} ();
  22266. ;
  22267. return 0;
  22268. }
  22269. _ACEOF
  22270. if ac_fn_c_try_link "$LINENO"; then :
  22271. eval "$as_ac_Lib=yes"
  22272. else
  22273. eval "$as_ac_Lib=no"
  22274. fi
  22275. rm -f core conftest.err conftest.$ac_objext \
  22276. conftest$ac_exeext conftest.$ac_ext
  22277. LIBS=$ac_check_lib_save_LIBS
  22278. fi
  22279. eval ac_res=\$$as_ac_Lib
  22280. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22281. $as_echo "$ac_res" >&6; }
  22282. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22283. AST_PRI_SETUP_KEYPAD_FOUND=yes
  22284. else
  22285. AST_PRI_SETUP_KEYPAD_FOUND=no
  22286. fi
  22287. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22288. fi
  22289. # now check for the header.
  22290. if test "${AST_PRI_SETUP_KEYPAD_FOUND}" = "yes"; then
  22291. PRI_SETUP_KEYPAD_LIB="${pbxlibdir} -lpri "
  22292. # if --with-PRI_SETUP_KEYPAD=DIR has been specified, use it.
  22293. if test "x${PRI_SETUP_KEYPAD_DIR}" != "x"; then
  22294. PRI_SETUP_KEYPAD_INCLUDE="-I${PRI_SETUP_KEYPAD_DIR}/include"
  22295. fi
  22296. PRI_SETUP_KEYPAD_INCLUDE="${PRI_SETUP_KEYPAD_INCLUDE} "
  22297. if test "xlibpri.h" = "x" ; then # no header, assume found
  22298. PRI_SETUP_KEYPAD_HEADER_FOUND="1"
  22299. else # check for the header
  22300. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22301. CPPFLAGS="${CPPFLAGS} ${PRI_SETUP_KEYPAD_INCLUDE}"
  22302. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22303. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22304. PRI_SETUP_KEYPAD_HEADER_FOUND=1
  22305. else
  22306. PRI_SETUP_KEYPAD_HEADER_FOUND=0
  22307. fi
  22308. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22309. fi
  22310. if test "x${PRI_SETUP_KEYPAD_HEADER_FOUND}" = "x0" ; then
  22311. PRI_SETUP_KEYPAD_LIB=""
  22312. PRI_SETUP_KEYPAD_INCLUDE=""
  22313. else
  22314. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22315. PRI_SETUP_KEYPAD_LIB=""
  22316. fi
  22317. PBX_PRI_SETUP_KEYPAD=1
  22318. cat >>confdefs.h <<_ACEOF
  22319. #define HAVE_PRI_SETUP_KEYPAD 1
  22320. _ACEOF
  22321. fi
  22322. fi
  22323. fi
  22324. # ------------------------------------v
  22325. # TODO: The code can be changed to always include these features now.
  22326. # These features will always be present if pri_connected_line_update is available.
  22327. if test "x${PBX_PRI_PROG_W_CAUSE}" != "x1" -a "${USE_PRI_PROG_W_CAUSE}" != "no"; then
  22328. pbxlibdir=""
  22329. # if --with-PRI_PROG_W_CAUSE=DIR has been specified, use it.
  22330. if test "x${PRI_PROG_W_CAUSE_DIR}" != "x"; then
  22331. if test -d ${PRI_PROG_W_CAUSE_DIR}/lib; then
  22332. pbxlibdir="-L${PRI_PROG_W_CAUSE_DIR}/lib"
  22333. else
  22334. pbxlibdir="-L${PRI_PROG_W_CAUSE_DIR}"
  22335. fi
  22336. fi
  22337. pbxfuncname="pri_progress_with_cause"
  22338. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22339. AST_PRI_PROG_W_CAUSE_FOUND=yes
  22340. else
  22341. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22342. CFLAGS="${CFLAGS} "
  22343. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22344. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22345. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22346. if eval \${$as_ac_Lib+:} false; then :
  22347. $as_echo_n "(cached) " >&6
  22348. else
  22349. ac_check_lib_save_LIBS=$LIBS
  22350. LIBS="-lpri ${pbxlibdir} $LIBS"
  22351. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22352. /* end confdefs.h. */
  22353. /* Override any GCC internal prototype to avoid an error.
  22354. Use char because int might match the return type of a GCC
  22355. builtin and then its argument prototype would still apply. */
  22356. #ifdef __cplusplus
  22357. extern "C"
  22358. #endif
  22359. char ${pbxfuncname} ();
  22360. int
  22361. main ()
  22362. {
  22363. return ${pbxfuncname} ();
  22364. ;
  22365. return 0;
  22366. }
  22367. _ACEOF
  22368. if ac_fn_c_try_link "$LINENO"; then :
  22369. eval "$as_ac_Lib=yes"
  22370. else
  22371. eval "$as_ac_Lib=no"
  22372. fi
  22373. rm -f core conftest.err conftest.$ac_objext \
  22374. conftest$ac_exeext conftest.$ac_ext
  22375. LIBS=$ac_check_lib_save_LIBS
  22376. fi
  22377. eval ac_res=\$$as_ac_Lib
  22378. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22379. $as_echo "$ac_res" >&6; }
  22380. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22381. AST_PRI_PROG_W_CAUSE_FOUND=yes
  22382. else
  22383. AST_PRI_PROG_W_CAUSE_FOUND=no
  22384. fi
  22385. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22386. fi
  22387. # now check for the header.
  22388. if test "${AST_PRI_PROG_W_CAUSE_FOUND}" = "yes"; then
  22389. PRI_PROG_W_CAUSE_LIB="${pbxlibdir} -lpri "
  22390. # if --with-PRI_PROG_W_CAUSE=DIR has been specified, use it.
  22391. if test "x${PRI_PROG_W_CAUSE_DIR}" != "x"; then
  22392. PRI_PROG_W_CAUSE_INCLUDE="-I${PRI_PROG_W_CAUSE_DIR}/include"
  22393. fi
  22394. PRI_PROG_W_CAUSE_INCLUDE="${PRI_PROG_W_CAUSE_INCLUDE} "
  22395. if test "xlibpri.h" = "x" ; then # no header, assume found
  22396. PRI_PROG_W_CAUSE_HEADER_FOUND="1"
  22397. else # check for the header
  22398. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22399. CPPFLAGS="${CPPFLAGS} ${PRI_PROG_W_CAUSE_INCLUDE}"
  22400. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22401. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22402. PRI_PROG_W_CAUSE_HEADER_FOUND=1
  22403. else
  22404. PRI_PROG_W_CAUSE_HEADER_FOUND=0
  22405. fi
  22406. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22407. fi
  22408. if test "x${PRI_PROG_W_CAUSE_HEADER_FOUND}" = "x0" ; then
  22409. PRI_PROG_W_CAUSE_LIB=""
  22410. PRI_PROG_W_CAUSE_INCLUDE=""
  22411. else
  22412. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22413. PRI_PROG_W_CAUSE_LIB=""
  22414. fi
  22415. PBX_PRI_PROG_W_CAUSE=1
  22416. cat >>confdefs.h <<_ACEOF
  22417. #define HAVE_PRI_PROG_W_CAUSE 1
  22418. _ACEOF
  22419. fi
  22420. fi
  22421. fi
  22422. if test "x${PBX_PRI_INBANDDISCONNECT}" != "x1" -a "${USE_PRI_INBANDDISCONNECT}" != "no"; then
  22423. pbxlibdir=""
  22424. # if --with-PRI_INBANDDISCONNECT=DIR has been specified, use it.
  22425. if test "x${PRI_INBANDDISCONNECT_DIR}" != "x"; then
  22426. if test -d ${PRI_INBANDDISCONNECT_DIR}/lib; then
  22427. pbxlibdir="-L${PRI_INBANDDISCONNECT_DIR}/lib"
  22428. else
  22429. pbxlibdir="-L${PRI_INBANDDISCONNECT_DIR}"
  22430. fi
  22431. fi
  22432. pbxfuncname="pri_set_inbanddisconnect"
  22433. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22434. AST_PRI_INBANDDISCONNECT_FOUND=yes
  22435. else
  22436. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22437. CFLAGS="${CFLAGS} "
  22438. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22439. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22440. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22441. if eval \${$as_ac_Lib+:} false; then :
  22442. $as_echo_n "(cached) " >&6
  22443. else
  22444. ac_check_lib_save_LIBS=$LIBS
  22445. LIBS="-lpri ${pbxlibdir} $LIBS"
  22446. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22447. /* end confdefs.h. */
  22448. /* Override any GCC internal prototype to avoid an error.
  22449. Use char because int might match the return type of a GCC
  22450. builtin and then its argument prototype would still apply. */
  22451. #ifdef __cplusplus
  22452. extern "C"
  22453. #endif
  22454. char ${pbxfuncname} ();
  22455. int
  22456. main ()
  22457. {
  22458. return ${pbxfuncname} ();
  22459. ;
  22460. return 0;
  22461. }
  22462. _ACEOF
  22463. if ac_fn_c_try_link "$LINENO"; then :
  22464. eval "$as_ac_Lib=yes"
  22465. else
  22466. eval "$as_ac_Lib=no"
  22467. fi
  22468. rm -f core conftest.err conftest.$ac_objext \
  22469. conftest$ac_exeext conftest.$ac_ext
  22470. LIBS=$ac_check_lib_save_LIBS
  22471. fi
  22472. eval ac_res=\$$as_ac_Lib
  22473. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22474. $as_echo "$ac_res" >&6; }
  22475. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22476. AST_PRI_INBANDDISCONNECT_FOUND=yes
  22477. else
  22478. AST_PRI_INBANDDISCONNECT_FOUND=no
  22479. fi
  22480. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22481. fi
  22482. # now check for the header.
  22483. if test "${AST_PRI_INBANDDISCONNECT_FOUND}" = "yes"; then
  22484. PRI_INBANDDISCONNECT_LIB="${pbxlibdir} -lpri "
  22485. # if --with-PRI_INBANDDISCONNECT=DIR has been specified, use it.
  22486. if test "x${PRI_INBANDDISCONNECT_DIR}" != "x"; then
  22487. PRI_INBANDDISCONNECT_INCLUDE="-I${PRI_INBANDDISCONNECT_DIR}/include"
  22488. fi
  22489. PRI_INBANDDISCONNECT_INCLUDE="${PRI_INBANDDISCONNECT_INCLUDE} "
  22490. if test "xlibpri.h" = "x" ; then # no header, assume found
  22491. PRI_INBANDDISCONNECT_HEADER_FOUND="1"
  22492. else # check for the header
  22493. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22494. CPPFLAGS="${CPPFLAGS} ${PRI_INBANDDISCONNECT_INCLUDE}"
  22495. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22496. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22497. PRI_INBANDDISCONNECT_HEADER_FOUND=1
  22498. else
  22499. PRI_INBANDDISCONNECT_HEADER_FOUND=0
  22500. fi
  22501. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22502. fi
  22503. if test "x${PRI_INBANDDISCONNECT_HEADER_FOUND}" = "x0" ; then
  22504. PRI_INBANDDISCONNECT_LIB=""
  22505. PRI_INBANDDISCONNECT_INCLUDE=""
  22506. else
  22507. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22508. PRI_INBANDDISCONNECT_LIB=""
  22509. fi
  22510. PBX_PRI_INBANDDISCONNECT=1
  22511. cat >>confdefs.h <<_ACEOF
  22512. #define HAVE_PRI_INBANDDISCONNECT 1
  22513. _ACEOF
  22514. fi
  22515. fi
  22516. fi
  22517. if test "x${PBX_PRI_SERVICE_MESSAGES}" != "x1" -a "${USE_PRI_SERVICE_MESSAGES}" != "no"; then
  22518. pbxlibdir=""
  22519. # if --with-PRI_SERVICE_MESSAGES=DIR has been specified, use it.
  22520. if test "x${PRI_SERVICE_MESSAGES_DIR}" != "x"; then
  22521. if test -d ${PRI_SERVICE_MESSAGES_DIR}/lib; then
  22522. pbxlibdir="-L${PRI_SERVICE_MESSAGES_DIR}/lib"
  22523. else
  22524. pbxlibdir="-L${PRI_SERVICE_MESSAGES_DIR}"
  22525. fi
  22526. fi
  22527. pbxfuncname="pri_maintenance_service"
  22528. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22529. AST_PRI_SERVICE_MESSAGES_FOUND=yes
  22530. else
  22531. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22532. CFLAGS="${CFLAGS} "
  22533. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22534. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22535. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22536. if eval \${$as_ac_Lib+:} false; then :
  22537. $as_echo_n "(cached) " >&6
  22538. else
  22539. ac_check_lib_save_LIBS=$LIBS
  22540. LIBS="-lpri ${pbxlibdir} $LIBS"
  22541. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22542. /* end confdefs.h. */
  22543. /* Override any GCC internal prototype to avoid an error.
  22544. Use char because int might match the return type of a GCC
  22545. builtin and then its argument prototype would still apply. */
  22546. #ifdef __cplusplus
  22547. extern "C"
  22548. #endif
  22549. char ${pbxfuncname} ();
  22550. int
  22551. main ()
  22552. {
  22553. return ${pbxfuncname} ();
  22554. ;
  22555. return 0;
  22556. }
  22557. _ACEOF
  22558. if ac_fn_c_try_link "$LINENO"; then :
  22559. eval "$as_ac_Lib=yes"
  22560. else
  22561. eval "$as_ac_Lib=no"
  22562. fi
  22563. rm -f core conftest.err conftest.$ac_objext \
  22564. conftest$ac_exeext conftest.$ac_ext
  22565. LIBS=$ac_check_lib_save_LIBS
  22566. fi
  22567. eval ac_res=\$$as_ac_Lib
  22568. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22569. $as_echo "$ac_res" >&6; }
  22570. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22571. AST_PRI_SERVICE_MESSAGES_FOUND=yes
  22572. else
  22573. AST_PRI_SERVICE_MESSAGES_FOUND=no
  22574. fi
  22575. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22576. fi
  22577. # now check for the header.
  22578. if test "${AST_PRI_SERVICE_MESSAGES_FOUND}" = "yes"; then
  22579. PRI_SERVICE_MESSAGES_LIB="${pbxlibdir} -lpri "
  22580. # if --with-PRI_SERVICE_MESSAGES=DIR has been specified, use it.
  22581. if test "x${PRI_SERVICE_MESSAGES_DIR}" != "x"; then
  22582. PRI_SERVICE_MESSAGES_INCLUDE="-I${PRI_SERVICE_MESSAGES_DIR}/include"
  22583. fi
  22584. PRI_SERVICE_MESSAGES_INCLUDE="${PRI_SERVICE_MESSAGES_INCLUDE} "
  22585. if test "xlibpri.h" = "x" ; then # no header, assume found
  22586. PRI_SERVICE_MESSAGES_HEADER_FOUND="1"
  22587. else # check for the header
  22588. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22589. CPPFLAGS="${CPPFLAGS} ${PRI_SERVICE_MESSAGES_INCLUDE}"
  22590. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22591. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22592. PRI_SERVICE_MESSAGES_HEADER_FOUND=1
  22593. else
  22594. PRI_SERVICE_MESSAGES_HEADER_FOUND=0
  22595. fi
  22596. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22597. fi
  22598. if test "x${PRI_SERVICE_MESSAGES_HEADER_FOUND}" = "x0" ; then
  22599. PRI_SERVICE_MESSAGES_LIB=""
  22600. PRI_SERVICE_MESSAGES_INCLUDE=""
  22601. else
  22602. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22603. PRI_SERVICE_MESSAGES_LIB=""
  22604. fi
  22605. PBX_PRI_SERVICE_MESSAGES=1
  22606. cat >>confdefs.h <<_ACEOF
  22607. #define HAVE_PRI_SERVICE_MESSAGES 1
  22608. _ACEOF
  22609. fi
  22610. fi
  22611. fi
  22612. if test "x${PBX_PRI_REVERSE_CHARGE}" != "x1" -a "${USE_PRI_REVERSE_CHARGE}" != "no"; then
  22613. pbxlibdir=""
  22614. # if --with-PRI_REVERSE_CHARGE=DIR has been specified, use it.
  22615. if test "x${PRI_REVERSE_CHARGE_DIR}" != "x"; then
  22616. if test -d ${PRI_REVERSE_CHARGE_DIR}/lib; then
  22617. pbxlibdir="-L${PRI_REVERSE_CHARGE_DIR}/lib"
  22618. else
  22619. pbxlibdir="-L${PRI_REVERSE_CHARGE_DIR}"
  22620. fi
  22621. fi
  22622. pbxfuncname="pri_sr_set_reversecharge"
  22623. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22624. AST_PRI_REVERSE_CHARGE_FOUND=yes
  22625. else
  22626. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22627. CFLAGS="${CFLAGS} "
  22628. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22629. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22630. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22631. if eval \${$as_ac_Lib+:} false; then :
  22632. $as_echo_n "(cached) " >&6
  22633. else
  22634. ac_check_lib_save_LIBS=$LIBS
  22635. LIBS="-lpri ${pbxlibdir} $LIBS"
  22636. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22637. /* end confdefs.h. */
  22638. /* Override any GCC internal prototype to avoid an error.
  22639. Use char because int might match the return type of a GCC
  22640. builtin and then its argument prototype would still apply. */
  22641. #ifdef __cplusplus
  22642. extern "C"
  22643. #endif
  22644. char ${pbxfuncname} ();
  22645. int
  22646. main ()
  22647. {
  22648. return ${pbxfuncname} ();
  22649. ;
  22650. return 0;
  22651. }
  22652. _ACEOF
  22653. if ac_fn_c_try_link "$LINENO"; then :
  22654. eval "$as_ac_Lib=yes"
  22655. else
  22656. eval "$as_ac_Lib=no"
  22657. fi
  22658. rm -f core conftest.err conftest.$ac_objext \
  22659. conftest$ac_exeext conftest.$ac_ext
  22660. LIBS=$ac_check_lib_save_LIBS
  22661. fi
  22662. eval ac_res=\$$as_ac_Lib
  22663. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22664. $as_echo "$ac_res" >&6; }
  22665. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22666. AST_PRI_REVERSE_CHARGE_FOUND=yes
  22667. else
  22668. AST_PRI_REVERSE_CHARGE_FOUND=no
  22669. fi
  22670. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22671. fi
  22672. # now check for the header.
  22673. if test "${AST_PRI_REVERSE_CHARGE_FOUND}" = "yes"; then
  22674. PRI_REVERSE_CHARGE_LIB="${pbxlibdir} -lpri "
  22675. # if --with-PRI_REVERSE_CHARGE=DIR has been specified, use it.
  22676. if test "x${PRI_REVERSE_CHARGE_DIR}" != "x"; then
  22677. PRI_REVERSE_CHARGE_INCLUDE="-I${PRI_REVERSE_CHARGE_DIR}/include"
  22678. fi
  22679. PRI_REVERSE_CHARGE_INCLUDE="${PRI_REVERSE_CHARGE_INCLUDE} "
  22680. if test "xlibpri.h" = "x" ; then # no header, assume found
  22681. PRI_REVERSE_CHARGE_HEADER_FOUND="1"
  22682. else # check for the header
  22683. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22684. CPPFLAGS="${CPPFLAGS} ${PRI_REVERSE_CHARGE_INCLUDE}"
  22685. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22686. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22687. PRI_REVERSE_CHARGE_HEADER_FOUND=1
  22688. else
  22689. PRI_REVERSE_CHARGE_HEADER_FOUND=0
  22690. fi
  22691. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22692. fi
  22693. if test "x${PRI_REVERSE_CHARGE_HEADER_FOUND}" = "x0" ; then
  22694. PRI_REVERSE_CHARGE_LIB=""
  22695. PRI_REVERSE_CHARGE_INCLUDE=""
  22696. else
  22697. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22698. PRI_REVERSE_CHARGE_LIB=""
  22699. fi
  22700. PBX_PRI_REVERSE_CHARGE=1
  22701. cat >>confdefs.h <<_ACEOF
  22702. #define HAVE_PRI_REVERSE_CHARGE 1
  22703. _ACEOF
  22704. fi
  22705. fi
  22706. fi
  22707. # ------------------------------------^
  22708. if test "x${PBX_RESAMPLE}" != "x1" -a "${USE_RESAMPLE}" != "no"; then
  22709. pbxlibdir=""
  22710. # if --with-RESAMPLE=DIR has been specified, use it.
  22711. if test "x${RESAMPLE_DIR}" != "x"; then
  22712. if test -d ${RESAMPLE_DIR}/lib; then
  22713. pbxlibdir="-L${RESAMPLE_DIR}/lib"
  22714. else
  22715. pbxlibdir="-L${RESAMPLE_DIR}"
  22716. fi
  22717. fi
  22718. pbxfuncname="resample_open"
  22719. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22720. AST_RESAMPLE_FOUND=yes
  22721. else
  22722. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22723. CFLAGS="${CFLAGS} "
  22724. as_ac_Lib=`$as_echo "ac_cv_lib_resample_${pbxfuncname}" | $as_tr_sh`
  22725. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lresample" >&5
  22726. $as_echo_n "checking for ${pbxfuncname} in -lresample... " >&6; }
  22727. if eval \${$as_ac_Lib+:} false; then :
  22728. $as_echo_n "(cached) " >&6
  22729. else
  22730. ac_check_lib_save_LIBS=$LIBS
  22731. LIBS="-lresample ${pbxlibdir} -lm $LIBS"
  22732. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22733. /* end confdefs.h. */
  22734. /* Override any GCC internal prototype to avoid an error.
  22735. Use char because int might match the return type of a GCC
  22736. builtin and then its argument prototype would still apply. */
  22737. #ifdef __cplusplus
  22738. extern "C"
  22739. #endif
  22740. char ${pbxfuncname} ();
  22741. int
  22742. main ()
  22743. {
  22744. return ${pbxfuncname} ();
  22745. ;
  22746. return 0;
  22747. }
  22748. _ACEOF
  22749. if ac_fn_c_try_link "$LINENO"; then :
  22750. eval "$as_ac_Lib=yes"
  22751. else
  22752. eval "$as_ac_Lib=no"
  22753. fi
  22754. rm -f core conftest.err conftest.$ac_objext \
  22755. conftest$ac_exeext conftest.$ac_ext
  22756. LIBS=$ac_check_lib_save_LIBS
  22757. fi
  22758. eval ac_res=\$$as_ac_Lib
  22759. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22760. $as_echo "$ac_res" >&6; }
  22761. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22762. AST_RESAMPLE_FOUND=yes
  22763. else
  22764. AST_RESAMPLE_FOUND=no
  22765. fi
  22766. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22767. fi
  22768. # now check for the header.
  22769. if test "${AST_RESAMPLE_FOUND}" = "yes"; then
  22770. RESAMPLE_LIB="${pbxlibdir} -lresample -lm"
  22771. # if --with-RESAMPLE=DIR has been specified, use it.
  22772. if test "x${RESAMPLE_DIR}" != "x"; then
  22773. RESAMPLE_INCLUDE="-I${RESAMPLE_DIR}/include"
  22774. fi
  22775. RESAMPLE_INCLUDE="${RESAMPLE_INCLUDE} "
  22776. if test "xlibresample.h" = "x" ; then # no header, assume found
  22777. RESAMPLE_HEADER_FOUND="1"
  22778. else # check for the header
  22779. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22780. CPPFLAGS="${CPPFLAGS} ${RESAMPLE_INCLUDE}"
  22781. ac_fn_c_check_header_mongrel "$LINENO" "libresample.h" "ac_cv_header_libresample_h" "$ac_includes_default"
  22782. if test "x$ac_cv_header_libresample_h" = xyes; then :
  22783. RESAMPLE_HEADER_FOUND=1
  22784. else
  22785. RESAMPLE_HEADER_FOUND=0
  22786. fi
  22787. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22788. fi
  22789. if test "x${RESAMPLE_HEADER_FOUND}" = "x0" ; then
  22790. RESAMPLE_LIB=""
  22791. RESAMPLE_INCLUDE=""
  22792. else
  22793. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22794. RESAMPLE_LIB=""
  22795. fi
  22796. PBX_RESAMPLE=1
  22797. cat >>confdefs.h <<_ACEOF
  22798. #define HAVE_RESAMPLE 1
  22799. _ACEOF
  22800. fi
  22801. fi
  22802. fi
  22803. if test "x${PBX_SPANDSP}" != "x1" -a "${USE_SPANDSP}" != "no"; then
  22804. if test "xminimum version of SpanDSP" != "x"; then
  22805. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for minimum version of SpanDSP" >&5
  22806. $as_echo_n "checking for minimum version of SpanDSP... " >&6; }
  22807. else
  22808. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if \"
  22809. #if SPANDSP_RELEASE_DATE < 20080516
  22810. #error \"spandsp 0.0.5 or greater is required\"
  22811. #endif
  22812. \" compiles using spandsp/version.h" >&5
  22813. $as_echo_n "checking if \"
  22814. #if SPANDSP_RELEASE_DATE < 20080516
  22815. #error \"spandsp 0.0.5 or greater is required\"
  22816. #endif
  22817. \" compiles using spandsp/version.h... " >&6; }
  22818. fi
  22819. saved_cppflags="${CPPFLAGS}"
  22820. if test "x${SPANDSP_DIR}" != "x"; then
  22821. SPANDSP_INCLUDE="-I${SPANDSP_DIR}/include"
  22822. fi
  22823. CPPFLAGS="${CPPFLAGS} ${SPANDSP_INCLUDE}"
  22824. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22825. /* end confdefs.h. */
  22826. #include <spandsp/version.h>
  22827. int
  22828. main ()
  22829. {
  22830. #if SPANDSP_RELEASE_DATE < 20080516
  22831. #error "spandsp 0.0.5 or greater is required"
  22832. #endif
  22833. ;
  22834. ;
  22835. return 0;
  22836. }
  22837. _ACEOF
  22838. if ac_fn_c_try_compile "$LINENO"; then :
  22839. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  22840. $as_echo "yes" >&6; }
  22841. PBX_SPANDSP=1
  22842. $as_echo "#define HAVE_SPANDSP 1" >>confdefs.h
  22843. else
  22844. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  22845. $as_echo "no" >&6; }
  22846. fi
  22847. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  22848. CPPFLAGS="${saved_cppflags}"
  22849. fi
  22850. if test "x${PBX_SPANDSP}" = "x1" ; then
  22851. # We found the correct version in the header, now let's make sure it links
  22852. # properly, and that libtiff is available
  22853. PBX_SPANDSP=0
  22854. if test "x${PBX_SPANDSP}" != "x1" -a "${USE_SPANDSP}" != "no"; then
  22855. pbxlibdir=""
  22856. # if --with-SPANDSP=DIR has been specified, use it.
  22857. if test "x${SPANDSP_DIR}" != "x"; then
  22858. if test -d ${SPANDSP_DIR}/lib; then
  22859. pbxlibdir="-L${SPANDSP_DIR}/lib"
  22860. else
  22861. pbxlibdir="-L${SPANDSP_DIR}"
  22862. fi
  22863. fi
  22864. pbxfuncname="span_set_message_handler"
  22865. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22866. AST_SPANDSP_FOUND=yes
  22867. else
  22868. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22869. CFLAGS="${CFLAGS} "
  22870. as_ac_Lib=`$as_echo "ac_cv_lib_spandsp_${pbxfuncname}" | $as_tr_sh`
  22871. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lspandsp" >&5
  22872. $as_echo_n "checking for ${pbxfuncname} in -lspandsp... " >&6; }
  22873. if eval \${$as_ac_Lib+:} false; then :
  22874. $as_echo_n "(cached) " >&6
  22875. else
  22876. ac_check_lib_save_LIBS=$LIBS
  22877. LIBS="-lspandsp ${pbxlibdir} -ltiff $LIBS"
  22878. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22879. /* end confdefs.h. */
  22880. /* Override any GCC internal prototype to avoid an error.
  22881. Use char because int might match the return type of a GCC
  22882. builtin and then its argument prototype would still apply. */
  22883. #ifdef __cplusplus
  22884. extern "C"
  22885. #endif
  22886. char ${pbxfuncname} ();
  22887. int
  22888. main ()
  22889. {
  22890. return ${pbxfuncname} ();
  22891. ;
  22892. return 0;
  22893. }
  22894. _ACEOF
  22895. if ac_fn_c_try_link "$LINENO"; then :
  22896. eval "$as_ac_Lib=yes"
  22897. else
  22898. eval "$as_ac_Lib=no"
  22899. fi
  22900. rm -f core conftest.err conftest.$ac_objext \
  22901. conftest$ac_exeext conftest.$ac_ext
  22902. LIBS=$ac_check_lib_save_LIBS
  22903. fi
  22904. eval ac_res=\$$as_ac_Lib
  22905. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22906. $as_echo "$ac_res" >&6; }
  22907. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22908. AST_SPANDSP_FOUND=yes
  22909. else
  22910. AST_SPANDSP_FOUND=no
  22911. fi
  22912. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22913. fi
  22914. # now check for the header.
  22915. if test "${AST_SPANDSP_FOUND}" = "yes"; then
  22916. SPANDSP_LIB="${pbxlibdir} -lspandsp -ltiff"
  22917. # if --with-SPANDSP=DIR has been specified, use it.
  22918. if test "x${SPANDSP_DIR}" != "x"; then
  22919. SPANDSP_INCLUDE="-I${SPANDSP_DIR}/include"
  22920. fi
  22921. SPANDSP_INCLUDE="${SPANDSP_INCLUDE} "
  22922. if test "xspandsp.h" = "x" ; then # no header, assume found
  22923. SPANDSP_HEADER_FOUND="1"
  22924. else # check for the header
  22925. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22926. CPPFLAGS="${CPPFLAGS} ${SPANDSP_INCLUDE}"
  22927. ac_fn_c_check_header_mongrel "$LINENO" "spandsp.h" "ac_cv_header_spandsp_h" "$ac_includes_default"
  22928. if test "x$ac_cv_header_spandsp_h" = xyes; then :
  22929. SPANDSP_HEADER_FOUND=1
  22930. else
  22931. SPANDSP_HEADER_FOUND=0
  22932. fi
  22933. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22934. fi
  22935. if test "x${SPANDSP_HEADER_FOUND}" = "x0" ; then
  22936. SPANDSP_LIB=""
  22937. SPANDSP_INCLUDE=""
  22938. else
  22939. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22940. SPANDSP_LIB=""
  22941. fi
  22942. PBX_SPANDSP=1
  22943. cat >>confdefs.h <<_ACEOF
  22944. #define HAVE_SPANDSP 1
  22945. _ACEOF
  22946. fi
  22947. fi
  22948. fi
  22949. fi
  22950. if test "x${PBX_SPANDSP}" = "x1" ; then
  22951. # We also need t38_terminal_init()
  22952. PBX_SPANDSP=0
  22953. if test "x${PBX_SPANDSP}" != "x1" -a "${USE_SPANDSP}" != "no"; then
  22954. pbxlibdir=""
  22955. # if --with-SPANDSP=DIR has been specified, use it.
  22956. if test "x${SPANDSP_DIR}" != "x"; then
  22957. if test -d ${SPANDSP_DIR}/lib; then
  22958. pbxlibdir="-L${SPANDSP_DIR}/lib"
  22959. else
  22960. pbxlibdir="-L${SPANDSP_DIR}"
  22961. fi
  22962. fi
  22963. pbxfuncname="t38_terminal_init"
  22964. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22965. AST_SPANDSP_FOUND=yes
  22966. else
  22967. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22968. CFLAGS="${CFLAGS} "
  22969. as_ac_Lib=`$as_echo "ac_cv_lib_spandsp_${pbxfuncname}" | $as_tr_sh`
  22970. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lspandsp" >&5
  22971. $as_echo_n "checking for ${pbxfuncname} in -lspandsp... " >&6; }
  22972. if eval \${$as_ac_Lib+:} false; then :
  22973. $as_echo_n "(cached) " >&6
  22974. else
  22975. ac_check_lib_save_LIBS=$LIBS
  22976. LIBS="-lspandsp ${pbxlibdir} -ltiff $LIBS"
  22977. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22978. /* end confdefs.h. */
  22979. /* Override any GCC internal prototype to avoid an error.
  22980. Use char because int might match the return type of a GCC
  22981. builtin and then its argument prototype would still apply. */
  22982. #ifdef __cplusplus
  22983. extern "C"
  22984. #endif
  22985. char ${pbxfuncname} ();
  22986. int
  22987. main ()
  22988. {
  22989. return ${pbxfuncname} ();
  22990. ;
  22991. return 0;
  22992. }
  22993. _ACEOF
  22994. if ac_fn_c_try_link "$LINENO"; then :
  22995. eval "$as_ac_Lib=yes"
  22996. else
  22997. eval "$as_ac_Lib=no"
  22998. fi
  22999. rm -f core conftest.err conftest.$ac_objext \
  23000. conftest$ac_exeext conftest.$ac_ext
  23001. LIBS=$ac_check_lib_save_LIBS
  23002. fi
  23003. eval ac_res=\$$as_ac_Lib
  23004. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  23005. $as_echo "$ac_res" >&6; }
  23006. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  23007. AST_SPANDSP_FOUND=yes
  23008. else
  23009. AST_SPANDSP_FOUND=no
  23010. fi
  23011. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  23012. fi
  23013. # now check for the header.
  23014. if test "${AST_SPANDSP_FOUND}" = "yes"; then
  23015. SPANDSP_LIB="${pbxlibdir} -lspandsp -ltiff"
  23016. # if --with-SPANDSP=DIR has been specified, use it.
  23017. if test "x${SPANDSP_DIR}" != "x"; then
  23018. SPANDSP_INCLUDE="-I${SPANDSP_DIR}/include"
  23019. fi
  23020. SPANDSP_INCLUDE="${SPANDSP_INCLUDE} "
  23021. if test "xspandsp.h" = "x" ; then # no header, assume found
  23022. SPANDSP_HEADER_FOUND="1"
  23023. else # check for the header
  23024. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  23025. CPPFLAGS="${CPPFLAGS} ${SPANDSP_INCLUDE}"
  23026. ac_fn_c_check_header_mongrel "$LINENO" "spandsp.h" "ac_cv_header_spandsp_h" "$ac_includes_default"
  23027. if test "x$ac_cv_header_spandsp_h" = xyes; then :
  23028. SPANDSP_HEADER_FOUND=1
  23029. else
  23030. SPANDSP_HEADER_FOUND=0
  23031. fi
  23032. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  23033. fi
  23034. if test "x${SPANDSP_HEADER_FOUND}" = "x0" ; then
  23035. SPANDSP_LIB=""
  23036. SPANDSP_INCLUDE=""
  23037. else
  23038. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  23039. SPANDSP_LIB=""
  23040. fi
  23041. PBX_SPANDSP=1
  23042. cat >>confdefs.h <<_ACEOF
  23043. #define HAVE_SPANDSP 1
  23044. _ACEOF
  23045. fi
  23046. fi
  23047. fi
  23048. fi
  23049. # Check for libss7 v1.0 branch compatible version.
  23050. if test "x${PBX_SS7}" != "x1" -a "${USE_SS7}" != "no"; then
  23051. pbxlibdir=""
  23052. # if --with-SS7=DIR has been specified, use it.
  23053. if test "x${SS7_DIR}" != "x"; then
  23054. if test -d ${SS7_DIR}/lib; then
  23055. pbxlibdir="-L${SS7_DIR}/lib"
  23056. else
  23057. pbxlibdir="-L${SS7_DIR}"
  23058. fi
  23059. fi
  23060. pbxfuncname="ss7_set_adjpc"
  23061. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  23062. AST_SS7_FOUND=yes
  23063. else
  23064. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  23065. CFLAGS="${CFLAGS} "
  23066. as_ac_Lib=`$as_echo "ac_cv_lib_ss7_${pbxfuncname}" | $as_tr_sh`
  23067. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lss7" >&5
  23068. $as_echo_n "checking for ${pbxfuncname} in -lss7... " >&6; }
  23069. if eval \${$as_ac_Lib+:} false; then :
  23070. $as_echo_n "(cached) " >&6
  23071. else
  23072. ac_check_lib_save_LIBS=$LIBS
  23073. LIBS="-lss7 ${pbxlibdir} $LIBS"
  23074. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  23075. /* end confdefs.h. */
  23076. /* Override any GCC internal prototype to avoid an error.
  23077. Use char because int might match the return type of a GCC
  23078. builtin and then its argument prototype would still apply. */
  23079. #ifdef __cplusplus
  23080. extern "C"
  23081. #endif
  23082. char ${pbxfuncname} ();
  23083. int
  23084. main ()
  23085. {
  23086. return ${pbxfuncname} ();
  23087. ;
  23088. return 0;
  23089. }
  23090. _ACEOF
  23091. if ac_fn_c_try_link "$LINENO"; then :
  23092. eval "$as_ac_Lib=yes"
  23093. else
  23094. eval "$as_ac_Lib=no"
  23095. fi
  23096. rm -f core conftest.err conftest.$ac_objext \
  23097. conftest$ac_exeext conftest.$ac_ext
  23098. LIBS=$ac_check_lib_save_LIBS
  23099. fi
  23100. eval ac_res=\$$as_ac_Lib
  23101. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  23102. $as_echo "$ac_res" >&6; }
  23103. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  23104. AST_SS7_FOUND=yes
  23105. else
  23106. AST_SS7_FOUND=no
  23107. fi
  23108. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  23109. fi
  23110. # now check for the header.
  23111. if test "${AST_SS7_FOUND}" = "yes"; then
  23112. SS7_LIB="${pbxlibdir} -lss7 "
  23113. # if --with-SS7=DIR has been specified, use it.
  23114. if test "x${SS7_DIR}" != "x"; then
  23115. SS7_INCLUDE="-I${SS7_DIR}/include"
  23116. fi
  23117. SS7_INCLUDE="${SS7_INCLUDE} "
  23118. if test "xlibss7.h" = "x" ; then # no header, assume found
  23119. SS7_HEADER_FOUND="1"
  23120. else # check for the header
  23121. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  23122. CPPFLAGS="${CPPFLAGS} ${SS7_INCLUDE}"
  23123. ac_fn_c_check_header_mongrel "$LINENO" "libss7.h" "ac_cv_header_libss7_h" "$ac_includes_default"
  23124. if test "x$ac_cv_header_libss7_h" = xyes; then :
  23125. SS7_HEADER_FOUND=1
  23126. else
  23127. SS7_HEADER_FOUND=0
  23128. fi
  23129. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  23130. fi
  23131. if test "x${SS7_HEADER_FOUND}" = "x0" ; then
  23132. SS7_LIB=""
  23133. SS7_INCLUDE=""
  23134. else
  23135. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  23136. SS7_LIB=""
  23137. fi
  23138. PBX_SS7=1
  23139. cat >>confdefs.h <<_ACEOF
  23140. #define HAVE_SS7 1
  23141. _ACEOF
  23142. fi
  23143. fi
  23144. fi
  23145. if test "x${PBX_OPENR2}" != "x1" -a "${USE_OPENR2}" != "no"; then
  23146. pbxlibdir=""
  23147. # if --with-OPENR2=DIR has been specified, use it.
  23148. if test "x${OPENR2_DIR}" != "x"; then
  23149. if test -d ${OPENR2_DIR}/lib; then
  23150. pbxlibdir="-L${OPENR2_DIR}/lib"
  23151. else
  23152. pbxlibdir="-L${OPENR2_DIR}"
  23153. fi
  23154. fi
  23155. pbxfuncname="openr2_chan_new"
  23156. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  23157. AST_OPENR2_FOUND=yes
  23158. else
  23159. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  23160. CFLAGS="${CFLAGS} "
  23161. as_ac_Lib=`$as_echo "ac_cv_lib_openr2_${pbxfuncname}" | $as_tr_sh`
  23162. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lopenr2" >&5
  23163. $as_echo_n "checking for ${pbxfuncname} in -lopenr2... " >&6; }
  23164. if eval \${$as_ac_Lib+:} false; then :
  23165. $as_echo_n "(cached) " >&6
  23166. else
  23167. ac_check_lib_save_LIBS=$LIBS
  23168. LIBS="-lopenr2 ${pbxlibdir} $LIBS"
  23169. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  23170. /* end confdefs.h. */
  23171. /* Override any GCC internal prototype to avoid an error.
  23172. Use char because int might match the return type of a GCC
  23173. builtin and then its argument prototype would still apply. */
  23174. #ifdef __cplusplus
  23175. extern "C"
  23176. #endif
  23177. char ${pbxfuncname} ();
  23178. int
  23179. main ()
  23180. {
  23181. return ${pbxfuncname} ();
  23182. ;
  23183. return 0;
  23184. }
  23185. _ACEOF
  23186. if ac_fn_c_try_link "$LINENO"; then :
  23187. eval "$as_ac_Lib=yes"
  23188. else
  23189. eval "$as_ac_Lib=no"
  23190. fi
  23191. rm -f core conftest.err conftest.$ac_objext \
  23192. conftest$ac_exeext conftest.$ac_ext
  23193. LIBS=$ac_check_lib_save_LIBS
  23194. fi
  23195. eval ac_res=\$$as_ac_Lib
  23196. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  23197. $as_echo "$ac_res" >&6; }
  23198. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  23199. AST_OPENR2_FOUND=yes
  23200. else
  23201. AST_OPENR2_FOUND=no
  23202. fi
  23203. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  23204. fi
  23205. # now check for the header.
  23206. if test "${AST_OPENR2_FOUND}" = "yes"; then
  23207. OPENR2_LIB="${pbxlibdir} -lopenr2 "
  23208. # if --with-OPENR2=DIR has been specified, use it.
  23209. if test "x${OPENR2_DIR}" != "x"; then
  23210. OPENR2_INCLUDE="-I${OPENR2_DIR}/include"
  23211. fi
  23212. OPENR2_INCLUDE="${OPENR2_INCLUDE} "
  23213. if test "xopenr2.h" = "x" ; then # no header, assume found
  23214. OPENR2_HEADER_FOUND="1"
  23215. else # check for the header
  23216. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  23217. CPPFLAGS="${CPPFLAGS} ${OPENR2_INCLUDE}"
  23218. ac_fn_c_check_header_mongrel "$LINENO" "openr2.h" "ac_cv_header_openr2_h" "$ac_includes_default"
  23219. if test "x$ac_cv_header_openr2_h" = xyes; then :
  23220. OPENR2_HEADER_FOUND=1
  23221. else
  23222. OPENR2_HEADER_FOUND=0
  23223. fi
  23224. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  23225. fi
  23226. if test "x${OPENR2_HEADER_FOUND}" = "x0" ; then
  23227. OPENR2_LIB=""
  23228. OPENR2_INCLUDE=""
  23229. else
  23230. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  23231. OPENR2_LIB=""
  23232. fi
  23233. PBX_OPENR2=1
  23234. cat >>confdefs.h <<_ACEOF
  23235. #define HAVE_OPENR2 1
  23236. _ACEOF
  23237. fi
  23238. fi
  23239. fi
  23240. if test "${USE_PWLIB}" != "no"; then
  23241. if test -n "${PWLIB_DIR}"; then
  23242. PWLIBDIR="${PWLIB_DIR}"
  23243. fi
  23244. PWLIB_INCDIR=
  23245. PWLIB_LIBDIR=
  23246. ac_ext=cpp
  23247. ac_cpp='$CXXCPP $CPPFLAGS'
  23248. ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  23249. ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  23250. ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
  23251. if test "${PWLIBDIR:-unset}" != "unset" ; then
  23252. as_ac_Header=`$as_echo "ac_cv_header_${PWLIBDIR}/version.h" | $as_tr_sh`
  23253. ac_fn_cxx_check_header_mongrel "$LINENO" "${PWLIBDIR}/version.h" "$as_ac_Header" "$ac_includes_default"
  23254. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  23255. HAS_PWLIB=1
  23256. fi
  23257. fi
  23258. if test "${HAS_PWLIB:-unset}" = "unset" ; then
  23259. if test "${OPENH323DIR:-unset}" != "unset"; then
  23260. as_ac_Header=`$as_echo "ac_cv_header_${OPENH323DIR}/../pwlib/version.h" | $as_tr_sh`
  23261. ac_fn_cxx_check_header_mongrel "$LINENO" "${OPENH323DIR}/../pwlib/version.h" "$as_ac_Header" "$ac_includes_default"
  23262. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  23263. HAS_PWLIB=1
  23264. fi
  23265. fi
  23266. if test "${HAS_PWLIB:-unset}" != "unset" ; then
  23267. PWLIBDIR="${OPENH323DIR}/../pwlib"
  23268. else
  23269. as_ac_Header=`$as_echo "ac_cv_header_${HOME}/pwlib/include/ptlib.h" | $as_tr_sh`
  23270. ac_fn_cxx_check_header_mongrel "$LINENO" "${HOME}/pwlib/include/ptlib.h" "$as_ac_Header" "$ac_includes_default"
  23271. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  23272. HAS_PWLIB=1
  23273. fi
  23274. if test "${HAS_PWLIB:-unset}" != "unset" ; then
  23275. PWLIBDIR="${HOME}/pwlib"
  23276. else
  23277. ac_fn_cxx_check_header_mongrel "$LINENO" "/usr/local/include/ptlib.h" "ac_cv_header__usr_local_include_ptlib_h" "$ac_includes_default"
  23278. if test "x$ac_cv_header__usr_local_include_ptlib_h" = xyes; then :
  23279. HAS_PWLIB=1
  23280. fi
  23281. if test "${HAS_PWLIB:-unset}" != "unset" ; then
  23282. # Extract the first word of "ptlib-config", so it can be a program name with args.
  23283. set dummy ptlib-config; ac_word=$2
  23284. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  23285. $as_echo_n "checking for $ac_word... " >&6; }
  23286. if ${ac_cv_path_PTLIB_CONFIG+:} false; then :
  23287. $as_echo_n "(cached) " >&6
  23288. else
  23289. case $PTLIB_CONFIG in
  23290. [\\/]* | ?:[\\/]*)
  23291. ac_cv_path_PTLIB_CONFIG="$PTLIB_CONFIG" # Let the user override the test with a path.
  23292. ;;
  23293. *)
  23294. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  23295. for as_dir in /usr/local/bin$PATH_SEPARATOR/usr/local/share/pwlib/make
  23296. do
  23297. IFS=$as_save_IFS
  23298. test -z "$as_dir" && as_dir=.
  23299. for ac_exec_ext in '' $ac_executable_extensions; do
  23300. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  23301. ac_cv_path_PTLIB_CONFIG="$as_dir/$ac_word$ac_exec_ext"
  23302. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  23303. break 2
  23304. fi
  23305. done
  23306. done
  23307. IFS=$as_save_IFS
  23308. ;;
  23309. esac
  23310. fi
  23311. PTLIB_CONFIG=$ac_cv_path_PTLIB_CONFIG
  23312. if test -n "$PTLIB_CONFIG"; then
  23313. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTLIB_CONFIG" >&5
  23314. $as_echo "$PTLIB_CONFIG" >&6; }
  23315. else
  23316. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  23317. $as_echo "no" >&6; }
  23318. fi
  23319. PWLIB_INCDIR="/usr/local/include"
  23320. PWLIB_LIBDIR=`${PTLIB_CONFIG} --pwlibdir 2>/dev/null`
  23321. if test "${PWLIB_LIBDIR:-unset}" = "unset"; then
  23322. PWLIB_LIBDIR=`${PTLIB_CONFIG} --ptlibdir 2>/dev/null`
  23323. fi
  23324. if test "${PWLIB_LIBDIR:-unset}" = "unset"; then
  23325. if test "x$LIB64" != "x"; then
  23326. PWLIB_LIBDIR="/usr/local/lib64"
  23327. else
  23328. PWLIB_LIBDIR="/usr/local/lib"
  23329. fi
  23330. fi
  23331. PWLIB_LIB=`${PTLIB_CONFIG} --ldflags --libs`
  23332. PWLIB_LIB="-L${PWLIB_LIBDIR} `echo ${PWLIB_LIB}`"
  23333. else
  23334. ac_fn_cxx_check_header_mongrel "$LINENO" "/usr/include/ptlib.h" "ac_cv_header__usr_include_ptlib_h" "$ac_includes_default"
  23335. if test "x$ac_cv_header__usr_include_ptlib_h" = xyes; then :
  23336. HAS_PWLIB=1
  23337. fi
  23338. if test "${HAS_PWLIB:-unset}" != "unset" ; then
  23339. # Extract the first word of "ptlib-config", so it can be a program name with args.
  23340. set dummy ptlib-config; ac_word=$2
  23341. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  23342. $as_echo_n "checking for $ac_word... " >&6; }
  23343. if ${ac_cv_path_PTLIB_CONFIG+:} false; then :
  23344. $as_echo_n "(cached) " >&6
  23345. else
  23346. case $PTLIB_CONFIG in
  23347. [\\/]* | ?:[\\/]*)
  23348. ac_cv_path_PTLIB_CONFIG="$PTLIB_CONFIG" # Let the user override the test with a path.
  23349. ;;
  23350. *)
  23351. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  23352. for as_dir in /usr/bin$PATH_SEPARATOR/usr/share/pwlib/make
  23353. do
  23354. IFS=$as_save_IFS
  23355. test -z "$as_dir" && as_dir=.
  23356. for ac_exec_ext in '' $ac_executable_extensions; do
  23357. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  23358. ac_cv_path_PTLIB_CONFIG="$as_dir/$ac_word$ac_exec_ext"
  23359. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  23360. break 2
  23361. fi
  23362. done
  23363. done
  23364. IFS=$as_save_IFS
  23365. ;;
  23366. esac
  23367. fi
  23368. PTLIB_CONFIG=$ac_cv_path_PTLIB_CONFIG
  23369. if test -n "$PTLIB_CONFIG"; then
  23370. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTLIB_CONFIG" >&5
  23371. $as_echo "$PTLIB_CONFIG" >&6; }
  23372. else
  23373. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  23374. $as_echo "no" >&6; }
  23375. fi
  23376. PWLIB_INCDIR="/usr/include"
  23377. PWLIB_LIBDIR=`${PTLIB_CONFIG} --pwlibdir 2>/dev/null`
  23378. if test "${PWLIB_LIBDIR:-unset}" = "unset"; then
  23379. PWLIB_LIBDIR=`${PTLIB_CONFIG} --ptlibdir 2>/dev/null`
  23380. fi
  23381. if test "${PWLIB_LIBDIR:-unset}" = "unset"; then
  23382. if test "x$LIB64" != "x"; then
  23383. PWLIB_LIBDIR="/usr/lib64"
  23384. else
  23385. PWLIB_LIBDIR="/usr/lib"
  23386. fi
  23387. fi
  23388. PWLIB_LIB=`${PTLIB_CONFIG} --ldflags --libs`
  23389. PWLIB_LIB="-L${PWLIB_LIBDIR} `echo ${PWLIB_LIB}`"
  23390. fi
  23391. fi
  23392. fi
  23393. fi
  23394. fi
  23395. #if test "${HAS_PWLIB:-unset}" = "unset" ; then
  23396. # echo "Cannot find pwlib - please install or set PWLIBDIR and try again"
  23397. # exit
  23398. #fi
  23399. if test "${HAS_PWLIB:-unset}" != "unset" ; then
  23400. if test "${PWLIBDIR:-unset}" = "unset" ; then
  23401. if test "${PTLIB_CONFIG:-unset}" != "unset" ; then
  23402. PWLIBDIR=`$PTLIB_CONFIG --prefix`
  23403. else
  23404. echo "Cannot find ptlib-config - please install and try again"
  23405. exit
  23406. fi
  23407. fi
  23408. if test "x$PWLIBDIR" = "x/usr" -o "x$PWLIBDIR" = "x/usr/"; then
  23409. PWLIBDIR="/usr/share/pwlib"
  23410. PWLIB_INCDIR="/usr/include"
  23411. if test "x$LIB64" != "x"; then
  23412. PWLIB_LIBDIR="/usr/lib64"
  23413. else
  23414. PWLIB_LIBDIR="/usr/lib"
  23415. fi
  23416. fi
  23417. if test "x$PWLIBDIR" = "x/usr/local" -o "x$PWLIBDIR" = "x/usr/"; then
  23418. PWLIBDIR="/usr/local/share/pwlib"
  23419. PWLIB_INCDIR="/usr/local/include"
  23420. if test "x$LIB64" != "x"; then
  23421. PWLIB_LIBDIR="/usr/local/lib64"
  23422. else
  23423. PWLIB_LIBDIR="/usr/local/lib"
  23424. fi
  23425. fi
  23426. if test "${PWLIB_INCDIR:-unset}" = "unset"; then
  23427. PWLIB_INCDIR="${PWLIBDIR}/include"
  23428. fi
  23429. if test "${PWLIB_LIBDIR:-unset}" = "unset"; then
  23430. PWLIB_LIBDIR="${PWLIBDIR}/lib"
  23431. fi
  23432. fi
  23433. ac_ext=c
  23434. ac_cpp='$CPP $CPPFLAGS'
  23435. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  23436. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  23437. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  23438. if test "xP[WT]LIB_VERSION" != "x"; then
  23439. VNAME="P[WT]LIB_VERSION"
  23440. else
  23441. VNAME="PWLIB_VERSION"
  23442. fi
  23443. if test "${HAS_PWLIB:-unset}" != "unset"; then
  23444. PWLIB_VERSION=`grep "$VNAME \"" ${PWLIB_INCDIR}/ptbuildopts.h | sed -e 's/[[:space:]]\{1,\}/ /g' | cut -f3 -d ' ' | sed -e 's/"//g'`
  23445. PWLIB_MAJOR_VERSION=`echo ${PWLIB_VERSION} | cut -f1 -d.`
  23446. PWLIB_MINOR_VERSION=`echo ${PWLIB_VERSION} | cut -f2 -d.`
  23447. PWLIB_BUILD_NUMBER=`echo ${PWLIB_VERSION} | cut -f3 -d.`
  23448. PWLIB_VER=$((${PWLIB_MAJOR_VERSION}*10000+${PWLIB_MINOR_VERSION}*100+${PWLIB_BUILD_NUMBER}))
  23449. PWLIB_REQ=$((1*10000+9*100+2))
  23450. if test "x" = "x"; then
  23451. PWLIB_MAX=9999999
  23452. else
  23453. PWLIB_MAX=$((*10000+*100+))
  23454. fi
  23455. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if PWLib version ${PWLIB_VERSION} is compatible with chan_h323" >&5
  23456. $as_echo_n "checking if PWLib version ${PWLIB_VERSION} is compatible with chan_h323... " >&6; }
  23457. if test ${PWLIB_VER} -lt ${PWLIB_REQ}; then
  23458. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  23459. $as_echo "no" >&6; }
  23460. unset HAS_PWLIB
  23461. else
  23462. if test ${PWLIB_VER} -gt ${PWLIB_MAX}; then
  23463. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  23464. $as_echo "no" >&6; }
  23465. unset HAS_PWLIB
  23466. else
  23467. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  23468. $as_echo "yes" >&6; }
  23469. fi
  23470. fi
  23471. fi
  23472. if test "${HAS_PWLIB:-unset}" != "unset"; then
  23473. PWLIB_OSTYPE=
  23474. case "$host_os" in
  23475. linux*) PWLIB_OSTYPE=linux ;
  23476. ;;
  23477. freebsd* ) PWLIB_OSTYPE=FreeBSD ;
  23478. ;;
  23479. openbsd* ) PWLIB_OSTYPE=OpenBSD ;
  23480. ENDLDLIBS="-lossaudio" ;
  23481. ;;
  23482. netbsd* ) PWLIB_OSTYPE=NetBSD ;
  23483. ENDLDLIBS="-lossaudio" ;
  23484. ;;
  23485. solaris* | sunos* ) PWLIB_OSTYPE=solaris ;
  23486. ;;
  23487. darwin* ) PWLIB_OSTYPE=Darwin ;
  23488. ;;
  23489. beos*) PWLIB_OSTYPE=beos ;
  23490. STDCCFLAGS="$STDCCFLAGS -D__BEOS__"
  23491. ;;
  23492. cygwin*) PWLIB_OSTYPE=cygwin ;
  23493. ;;
  23494. mingw*) PWLIB_OSTYPE=mingw ;
  23495. STDCCFLAGS="$STDCCFLAGS -mms-bitfields" ;
  23496. ENDLDLIBS="-lwinmm -lwsock32 -lsnmpapi -lmpr -lcomdlg32 -lgdi32 -lavicap32" ;
  23497. ;;
  23498. * ) PWLIB_OSTYPE="$host_os" ;
  23499. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \"OS $PWLIB_OSTYPE not recognized - proceed with caution!\"" >&5
  23500. $as_echo "$as_me: WARNING: \"OS $PWLIB_OSTYPE not recognized - proceed with caution!\"" >&2;} ;
  23501. ;;
  23502. esac
  23503. PWLIB_MACHTYPE=
  23504. case "$host_cpu" in
  23505. x86 | i686 | i586 | i486 | i386 ) PWLIB_MACHTYPE=x86
  23506. ;;
  23507. x86_64) PWLIB_MACHTYPE=x86_64 ;
  23508. P_64BIT=1 ;
  23509. LIB64=1 ;
  23510. ;;
  23511. alpha | alphaev56 | alphaev6 | alphaev67 | alphaev7) PWLIB_MACHTYPE=alpha ;
  23512. P_64BIT=1 ;
  23513. ;;
  23514. sparc ) PWLIB_MACHTYPE=sparc ;
  23515. ;;
  23516. powerpc ) PWLIB_MACHTYPE=ppc ;
  23517. ;;
  23518. ppc ) PWLIB_MACHTYPE=ppc ;
  23519. ;;
  23520. powerpc64 ) PWLIB_MACHTYPE=ppc64 ;
  23521. P_64BIT=1 ;
  23522. LIB64=1 ;
  23523. ;;
  23524. ppc64 ) PWLIB_MACHTYPE=ppc64 ;
  23525. P_64BIT=1 ;
  23526. LIB64=1 ;
  23527. ;;
  23528. ia64) PWLIB_MACHTYPE=ia64 ;
  23529. P_64BIT=1 ;
  23530. ;;
  23531. s390x) PWLIB_MACHTYPE=s390x ;
  23532. P_64BIT=1 ;
  23533. LIB64=1 ;
  23534. ;;
  23535. s390) PWLIB_MACHTYPE=s390 ;
  23536. ;;
  23537. * ) PWLIB_MACHTYPE="$host_cpu";
  23538. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \"CPU $PWLIB_MACHTYPE not recognized - proceed with caution!\"" >&5
  23539. $as_echo "$as_me: WARNING: \"CPU $PWLIB_MACHTYPE not recognized - proceed with caution!\"" >&2;} ;;
  23540. esac
  23541. PWLIB_PLATFORM="${PWLIB_OSTYPE}_${PWLIB_MACHTYPE}"
  23542. PLATFORM_PWLIB="pt_${PWLIB_PLATFORM}_r"
  23543. if test "${HAS_PWLIB:-unset}" != "unset"; then
  23544. { $as_echo "$as_me:${as_lineno-$LINENO}: checking PWLib installation validity" >&5
  23545. $as_echo_n "checking PWLib installation validity... " >&6; }
  23546. saved_cppflags="${CPPFLAGS}"
  23547. saved_libs="${LIBS}"
  23548. if test "${PWLIB_LIB:-unset}" != "unset"; then
  23549. LIBS="${LIBS} ${PWLIB_LIB} "
  23550. else
  23551. LIBS="${LIBS} -L${PWLIB_LIBDIR} -l${PLATFORM_PWLIB} "
  23552. fi
  23553. CPPFLAGS="${CPPFLAGS} -I${PWLIB_INCDIR} "
  23554. ac_ext=cpp
  23555. ac_cpp='$CXXCPP $CPPFLAGS'
  23556. ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  23557. ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  23558. ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
  23559. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  23560. /* end confdefs.h. */
  23561. #include "ptlib.h"
  23562. int
  23563. main ()
  23564. {
  23565. int q = (int) PTime::IsDaylightSavings();
  23566. ;
  23567. return 0;
  23568. }
  23569. _ACEOF
  23570. if ac_fn_cxx_try_link "$LINENO"; then :
  23571. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  23572. $as_echo "yes" >&6; }
  23573. ac_cv_lib_PWLIB="yes"
  23574. else
  23575. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  23576. $as_echo "no" >&6; }
  23577. ac_cv_lib_PWLIB="no"
  23578. fi
  23579. rm -f core conftest.err conftest.$ac_objext \
  23580. conftest$ac_exeext conftest.$ac_ext
  23581. ac_ext=c
  23582. ac_cpp='$CPP $CPPFLAGS'
  23583. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  23584. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  23585. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  23586. LIBS="${saved_libs}"
  23587. CPPFLAGS="${saved_cppflags}"
  23588. if test "${ac_cv_lib_PWLIB}" = "yes"; then
  23589. if test "${PWLIB_LIB:-undef}" = "undef"; then
  23590. if test "${PWLIB_LIBDIR}" != "" -a "${PWLIB_LIBDIR}" != "/usr/lib"; then
  23591. PWLIB_LIB="-L${PWLIB_LIBDIR} -l${PLATFORM_PWLIB}"
  23592. else
  23593. PWLIB_LIB="-l${PLATFORM_PWLIB}"
  23594. fi
  23595. fi
  23596. if test "${PWLIB_INCDIR}" != "" -a "${PWLIB_INCDIR}" != "/usr/include"; then
  23597. PWLIB_INCLUDE="-I${PWLIB_INCDIR}"
  23598. fi
  23599. PBX_PWLIB=1
  23600. $as_echo "#define HAVE_PWLIB 1" >>confdefs.h
  23601. fi
  23602. fi
  23603. fi
  23604. fi
  23605. if test "${PBX_PWLIB}" = "1" -a "${USE_OPENH323}" != "no" ; then
  23606. if test -n "${OPENH323_DIR}"; then
  23607. OPENH323DIR="${OPENH323_DIR}"
  23608. fi
  23609. OPENH323_INCDIR=
  23610. OPENH323_LIBDIR=
  23611. ac_ext=cpp
  23612. ac_cpp='$CXXCPP $CPPFLAGS'
  23613. ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  23614. ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  23615. ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
  23616. if test "${OPENH323DIR:-unset}" != "unset" ; then
  23617. as_ac_Header=`$as_echo "ac_cv_header_${OPENH323DIR}/version.h" | $as_tr_sh`
  23618. ac_fn_cxx_check_header_mongrel "$LINENO" "${OPENH323DIR}/version.h" "$as_ac_Header" "$ac_includes_default"
  23619. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  23620. HAS_OPENH323=1
  23621. fi
  23622. fi
  23623. if test "${HAS_OPENH323:-unset}" = "unset" ; then
  23624. as_ac_Header=`$as_echo "ac_cv_header_${PWLIBDIR}/../openh323/version.h" | $as_tr_sh`
  23625. ac_fn_cxx_check_header_mongrel "$LINENO" "${PWLIBDIR}/../openh323/version.h" "$as_ac_Header" "$ac_includes_default"
  23626. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  23627. OPENH323DIR="${PWLIBDIR}/../openh323"; HAS_OPENH323=1
  23628. fi
  23629. if test "${HAS_OPENH323:-unset}" != "unset" ; then
  23630. OPENH323DIR="${PWLIBDIR}/../openh323"
  23631. saved_cppflags="${CPPFLAGS}"
  23632. CPPFLAGS="${CPPFLAGS} -I${PWLIB_INCDIR}/openh323 -I${PWLIB_INCDIR}"
  23633. as_ac_Header=`$as_echo "ac_cv_header_${OPENH323DIR}/include/h323.h" | $as_tr_sh`
  23634. ac_fn_cxx_check_header_compile "$LINENO" "${OPENH323DIR}/include/h323.h" "$as_ac_Header" "#include <ptlib.h>
  23635. "
  23636. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  23637. else
  23638. OPENH323_INCDIR="${PWLIB_INCDIR}/openh323"; OPENH323_LIBDIR="${PWLIB_LIBDIR}"
  23639. fi
  23640. CPPFLAGS="${saved_cppflags}"
  23641. else
  23642. saved_cppflags="${CPPFLAGS}"
  23643. CPPFLAGS="${CPPFLAGS} -I${HOME}/openh323/include -I${PWLIB_INCDIR}"
  23644. as_ac_Header=`$as_echo "ac_cv_header_${HOME}/openh323/include/h323.h" | $as_tr_sh`
  23645. ac_fn_cxx_check_header_compile "$LINENO" "${HOME}/openh323/include/h323.h" "$as_ac_Header" "#include <ptlib.h>
  23646. "
  23647. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  23648. HAS_OPENH323=1
  23649. fi
  23650. CPPFLAGS="${saved_cppflags}"
  23651. if test "${HAS_OPENH323:-unset}" != "unset" ; then
  23652. OPENH323DIR="${HOME}/openh323"
  23653. else
  23654. saved_cppflags="${CPPFLAGS}"
  23655. CPPFLAGS="${CPPFLAGS} -I/usr/local/include/openh323 -I${PWLIB_INCDIR}"
  23656. ac_fn_cxx_check_header_compile "$LINENO" "/usr/local/include/openh323/h323.h" "ac_cv_header__usr_local_include_openh323_h323_h" "#include <ptlib.h>
  23657. "
  23658. if test "x$ac_cv_header__usr_local_include_openh323_h323_h" = xyes; then :
  23659. HAS_OPENH323=1
  23660. fi
  23661. CPPFLAGS="${saved_cppflags}"
  23662. if test "${HAS_OPENH323:-unset}" != "unset" ; then
  23663. OPENH323DIR="/usr/local/share/openh323"
  23664. OPENH323_INCDIR="/usr/local/include/openh323"
  23665. if test "x$LIB64" != "x" && test -d "/usr/local/lib64"; then
  23666. OPENH323_LIBDIR="/usr/local/lib64"
  23667. else
  23668. OPENH323_LIBDIR="/usr/local/lib"
  23669. fi
  23670. else
  23671. saved_cppflags="${CPPFLAGS}"
  23672. CPPFLAGS="${CPPFLAGS} -I/usr/include/openh323 -I${PWLIB_INCDIR}"
  23673. ac_fn_cxx_check_header_compile "$LINENO" "/usr/include/openh323/h323.h" "ac_cv_header__usr_include_openh323_h323_h" "#include <ptlib.h>
  23674. "
  23675. if test "x$ac_cv_header__usr_include_openh323_h323_h" = xyes; then :
  23676. HAS_OPENH323=1
  23677. fi
  23678. CPPFLAGS="${saved_cppflags}"
  23679. if test "${HAS_OPENH323:-unset}" != "unset" ; then
  23680. OPENH323DIR="/usr/share/openh323"
  23681. OPENH323_INCDIR="/usr/include/openh323"
  23682. if test "x$LIB64" != "x" && test -d "/usr/local/lib64"; then
  23683. OPENH323_LIBDIR="/usr/lib64"
  23684. else
  23685. OPENH323_LIBDIR="/usr/lib"
  23686. fi
  23687. fi
  23688. fi
  23689. fi
  23690. fi
  23691. fi
  23692. if test "${HAS_OPENH323:-unset}" != "unset" ; then
  23693. if test "${OPENH323_INCDIR:-unset}" = "unset"; then
  23694. OPENH323_INCDIR="${OPENH323DIR}/include"
  23695. fi
  23696. if test "${OPENH323_LIBDIR:-unset}" = "unset"; then
  23697. OPENH323_LIBDIR="${OPENH323DIR}/lib"
  23698. fi
  23699. OPENH323_LIBDIR="`cd ${OPENH323_LIBDIR}; pwd`"
  23700. OPENH323_INCDIR="`cd ${OPENH323_INCDIR}; pwd`"
  23701. OPENH323DIR="`cd ${OPENH323DIR}; pwd`"
  23702. fi
  23703. ac_ext=c
  23704. ac_cpp='$CPP $CPPFLAGS'
  23705. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  23706. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  23707. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  23708. if test "x" != "x"; then
  23709. VNAME=""
  23710. else
  23711. VNAME="OPENH323_VERSION"
  23712. fi
  23713. if test "${HAS_OPENH323:-unset}" != "unset"; then
  23714. OPENH323_VERSION=`grep "$VNAME \"" ${OPENH323_INCDIR}/openh323buildopts.h | sed -e 's/[[:space:]]\{1,\}/ /g' | cut -f3 -d ' ' | sed -e 's/"//g'`
  23715. OPENH323_MAJOR_VERSION=`echo ${OPENH323_VERSION} | cut -f1 -d.`
  23716. OPENH323_MINOR_VERSION=`echo ${OPENH323_VERSION} | cut -f2 -d.`
  23717. OPENH323_BUILD_NUMBER=`echo ${OPENH323_VERSION} | cut -f3 -d.`
  23718. OPENH323_VER=$((${OPENH323_MAJOR_VERSION}*10000+${OPENH323_MINOR_VERSION}*100+${OPENH323_BUILD_NUMBER}))
  23719. OPENH323_REQ=$((1*10000+17*100+3))
  23720. if test "x0" = "x"; then
  23721. OPENH323_MAX=9999999
  23722. else
  23723. OPENH323_MAX=$((1*10000+19*100+0))
  23724. fi
  23725. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if OpenH323 version ${OPENH323_VERSION} is compatible with chan_h323" >&5
  23726. $as_echo_n "checking if OpenH323 version ${OPENH323_VERSION} is compatible with chan_h323... " >&6; }
  23727. if test ${OPENH323_VER} -lt ${OPENH323_REQ}; then
  23728. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  23729. $as_echo "no" >&6; }
  23730. unset HAS_OPENH323
  23731. else
  23732. if test ${OPENH323_VER} -gt ${OPENH323_MAX}; then
  23733. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  23734. $as_echo "no" >&6; }
  23735. unset HAS_OPENH323
  23736. else
  23737. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  23738. $as_echo "yes" >&6; }
  23739. fi
  23740. fi
  23741. fi
  23742. if test "${HAS_OPENH323:-unset}" != "unset"; then
  23743. { $as_echo "$as_me:${as_lineno-$LINENO}: checking OpenH323 build option" >&5
  23744. $as_echo_n "checking OpenH323 build option... " >&6; }
  23745. OPENH323_SUFFIX=
  23746. prefixes="h323_${PWLIB_PLATFORM}_ h323_ openh323"
  23747. for pfx in $prefixes; do
  23748. #files=`ls -l /usr/local/lib/lib${pfx}*.so* 2>/dev/null`
  23749. files=`ls -l ${OPENH323_LIBDIR}/lib${pfx}*.so* 2>/dev/null`
  23750. if test -z "$files"; then
  23751. # check the default location
  23752. files=`ls -l /usr/local/lib/lib${pfx}*.so* 2>/dev/null`
  23753. fi
  23754. libfile=
  23755. if test -n "$files"; then
  23756. for f in $files; do
  23757. if test -f $f -a ! -L $f; then
  23758. libfile=`basename $f`
  23759. break;
  23760. fi
  23761. done
  23762. fi
  23763. if test -n "$libfile"; then
  23764. OPENH323_PREFIX=$pfx
  23765. break;
  23766. fi
  23767. done
  23768. if test "${libfile:-unset}" != "unset"; then
  23769. OPENH323_SUFFIX=`eval "echo ${libfile} | sed -e 's/lib${OPENH323_PREFIX}\([^.]*\)\..*/\1/'"`
  23770. fi
  23771. case "${OPENH323_SUFFIX}" in
  23772. n)
  23773. OPENH323_BUILD="notrace";;
  23774. r)
  23775. OPENH323_BUILD="opt";;
  23776. d)
  23777. OPENH323_BUILD="debug";;
  23778. *)
  23779. if test "${OPENH323_PREFIX:-undef}" = "openh323"; then
  23780. notrace=`eval "grep NOTRACE ${OPENH323DIR}/openh323u.mak | grep = | sed -e 's/[A-Z0-9_]*[ ]*=[ ]*//'"`
  23781. if test "x$notrace" = "x"; then
  23782. notrace="0"
  23783. fi
  23784. if test "$notrace" -ne 0; then
  23785. OPENH323_BUILD="notrace"
  23786. else
  23787. OPENH323_BUILD="opt"
  23788. fi
  23789. OPENH323_LIB="-l${OPENH323_PREFIX}"
  23790. else
  23791. OPENH323_BUILD="notrace"
  23792. fi
  23793. ;;
  23794. esac
  23795. { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${OPENH323_BUILD}" >&5
  23796. $as_echo "${OPENH323_BUILD}" >&6; }
  23797. fi
  23798. PLATFORM_OPENH323="h323_${PWLIB_PLATFORM}_${OPENH323_SUFFIX}"
  23799. if test "${HAS_OPENH323:-unset}" != "unset"; then
  23800. { $as_echo "$as_me:${as_lineno-$LINENO}: checking OpenH323 installation validity" >&5
  23801. $as_echo_n "checking OpenH323 installation validity... " >&6; }
  23802. saved_cppflags="${CPPFLAGS}"
  23803. saved_libs="${LIBS}"
  23804. if test "${OPENH323_LIB:-unset}" != "unset"; then
  23805. LIBS="${LIBS} ${OPENH323_LIB} ${PWLIB_LIB}"
  23806. else
  23807. LIBS="${LIBS} -L${OPENH323_LIBDIR} -l${PLATFORM_OPENH323} ${PWLIB_LIB}"
  23808. fi
  23809. CPPFLAGS="${CPPFLAGS} -I${OPENH323_INCDIR} ${PWLIB_INCLUDE}"
  23810. ac_ext=cpp
  23811. ac_cpp='$CXXCPP $CPPFLAGS'
  23812. ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  23813. ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  23814. ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
  23815. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  23816. /* end confdefs.h. */
  23817. #include "ptlib.h"
  23818. #include "h323.h"
  23819. #include "h323ep.h"
  23820. int
  23821. main ()
  23822. {
  23823. H323EndPoint ep = H323EndPoint();
  23824. ;
  23825. return 0;
  23826. }
  23827. _ACEOF
  23828. if ac_fn_cxx_try_link "$LINENO"; then :
  23829. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  23830. $as_echo "yes" >&6; }
  23831. ac_cv_lib_OPENH323="yes"
  23832. else
  23833. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  23834. $as_echo "no" >&6; }
  23835. ac_cv_lib_OPENH323="no"
  23836. fi
  23837. rm -f core conftest.err conftest.$ac_objext \
  23838. conftest$ac_exeext conftest.$ac_ext
  23839. ac_ext=c
  23840. ac_cpp='$CPP $CPPFLAGS'
  23841. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  23842. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  23843. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  23844. LIBS="${saved_libs}"
  23845. CPPFLAGS="${saved_cppflags}"
  23846. if test "${ac_cv_lib_OPENH323}" = "yes"; then
  23847. if test "${OPENH323_LIB:-undef}" = "undef"; then
  23848. if test "${OPENH323_LIBDIR}" != "" -a "${OPENH323_LIBDIR}" != "/usr/lib"; then
  23849. OPENH323_LIB="-L${OPENH323_LIBDIR} -l${PLATFORM_OPENH323}"
  23850. else
  23851. OPENH323_LIB="-l${PLATFORM_OPENH323}"
  23852. fi
  23853. fi
  23854. if test "${OPENH323_INCDIR}" != "" -a "${OPENH323_INCDIR}" != "/usr/include"; then
  23855. OPENH323_INCLUDE="-I${OPENH323_INCDIR}"
  23856. fi
  23857. PBX_OPENH323=1
  23858. $as_echo "#define HAVE_OPENH323 1" >>confdefs.h
  23859. fi
  23860. fi
  23861. fi
  23862. if test "x${PBX_LUA}" != "x1" -a "${USE_LUA}" != "no"; then
  23863. pbxlibdir=""
  23864. # if --with-LUA=DIR has been specified, use it.
  23865. if test "x${LUA_DIR}" != "x"; then
  23866. if test -d ${LUA_DIR}/lib; then
  23867. pbxlibdir="-L${LUA_DIR}/lib"
  23868. else
  23869. pbxlibdir="-L${LUA_DIR}"
  23870. fi
  23871. fi
  23872. pbxfuncname="luaL_newstate"
  23873. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  23874. AST_LUA_FOUND=yes
  23875. else
  23876. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  23877. CFLAGS="${CFLAGS} "
  23878. as_ac_Lib=`$as_echo "ac_cv_lib_lua5.2_${pbxfuncname}" | $as_tr_sh`
  23879. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -llua5.2" >&5
  23880. $as_echo_n "checking for ${pbxfuncname} in -llua5.2... " >&6; }
  23881. if eval \${$as_ac_Lib+:} false; then :
  23882. $as_echo_n "(cached) " >&6
  23883. else
  23884. ac_check_lib_save_LIBS=$LIBS
  23885. LIBS="-llua5.2 ${pbxlibdir} -lm $LIBS"
  23886. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  23887. /* end confdefs.h. */
  23888. /* Override any GCC internal prototype to avoid an error.
  23889. Use char because int might match the return type of a GCC
  23890. builtin and then its argument prototype would still apply. */
  23891. #ifdef __cplusplus
  23892. extern "C"
  23893. #endif
  23894. char ${pbxfuncname} ();
  23895. int
  23896. main ()
  23897. {
  23898. return ${pbxfuncname} ();
  23899. ;
  23900. return 0;
  23901. }
  23902. _ACEOF
  23903. if ac_fn_c_try_link "$LINENO"; then :
  23904. eval "$as_ac_Lib=yes"
  23905. else
  23906. eval "$as_ac_Lib=no"
  23907. fi
  23908. rm -f core conftest.err conftest.$ac_objext \
  23909. conftest$ac_exeext conftest.$ac_ext
  23910. LIBS=$ac_check_lib_save_LIBS
  23911. fi
  23912. eval ac_res=\$$as_ac_Lib
  23913. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  23914. $as_echo "$ac_res" >&6; }
  23915. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  23916. AST_LUA_FOUND=yes
  23917. else
  23918. AST_LUA_FOUND=no
  23919. fi
  23920. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  23921. fi
  23922. # now check for the header.
  23923. if test "${AST_LUA_FOUND}" = "yes"; then
  23924. LUA_LIB="${pbxlibdir} -llua5.2 -lm"
  23925. # if --with-LUA=DIR has been specified, use it.
  23926. if test "x${LUA_DIR}" != "x"; then
  23927. LUA_INCLUDE="-I${LUA_DIR}/include"
  23928. fi
  23929. LUA_INCLUDE="${LUA_INCLUDE} "
  23930. if test "xlua5.2/lua.h" = "x" ; then # no header, assume found
  23931. LUA_HEADER_FOUND="1"
  23932. else # check for the header
  23933. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  23934. CPPFLAGS="${CPPFLAGS} ${LUA_INCLUDE}"
  23935. ac_fn_c_check_header_mongrel "$LINENO" "lua5.2/lua.h" "ac_cv_header_lua5_2_lua_h" "$ac_includes_default"
  23936. if test "x$ac_cv_header_lua5_2_lua_h" = xyes; then :
  23937. LUA_HEADER_FOUND=1
  23938. else
  23939. LUA_HEADER_FOUND=0
  23940. fi
  23941. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  23942. fi
  23943. if test "x${LUA_HEADER_FOUND}" = "x0" ; then
  23944. LUA_LIB=""
  23945. LUA_INCLUDE=""
  23946. else
  23947. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  23948. LUA_LIB=""
  23949. fi
  23950. PBX_LUA=1
  23951. cat >>confdefs.h <<_ACEOF
  23952. #define HAVE_LUA 1
  23953. _ACEOF
  23954. fi
  23955. fi
  23956. fi
  23957. if test "x${PBX_LUA}" = "x1" ; then
  23958. if test x"${LUA_DIR}" = x; then
  23959. LUA_INCLUDE="${LUA_INCLUDE} -I/usr/include/lua5.2"
  23960. else
  23961. LUA_INCLUDE="${LUA_INCLUDE} -I${LUA_DIR}/lua5.2"
  23962. fi
  23963. fi
  23964. if test "x${PBX_LUA}" != "x1" -a "${USE_LUA}" != "no"; then
  23965. pbxlibdir=""
  23966. # if --with-LUA=DIR has been specified, use it.
  23967. if test "x${LUA_DIR}" != "x"; then
  23968. if test -d ${LUA_DIR}/lib; then
  23969. pbxlibdir="-L${LUA_DIR}/lib"
  23970. else
  23971. pbxlibdir="-L${LUA_DIR}"
  23972. fi
  23973. fi
  23974. pbxfuncname="luaL_newstate"
  23975. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  23976. AST_LUA_FOUND=yes
  23977. else
  23978. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  23979. CFLAGS="${CFLAGS} "
  23980. as_ac_Lib=`$as_echo "ac_cv_lib_lua5.1_${pbxfuncname}" | $as_tr_sh`
  23981. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -llua5.1" >&5
  23982. $as_echo_n "checking for ${pbxfuncname} in -llua5.1... " >&6; }
  23983. if eval \${$as_ac_Lib+:} false; then :
  23984. $as_echo_n "(cached) " >&6
  23985. else
  23986. ac_check_lib_save_LIBS=$LIBS
  23987. LIBS="-llua5.1 ${pbxlibdir} -lm $LIBS"
  23988. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  23989. /* end confdefs.h. */
  23990. /* Override any GCC internal prototype to avoid an error.
  23991. Use char because int might match the return type of a GCC
  23992. builtin and then its argument prototype would still apply. */
  23993. #ifdef __cplusplus
  23994. extern "C"
  23995. #endif
  23996. char ${pbxfuncname} ();
  23997. int
  23998. main ()
  23999. {
  24000. return ${pbxfuncname} ();
  24001. ;
  24002. return 0;
  24003. }
  24004. _ACEOF
  24005. if ac_fn_c_try_link "$LINENO"; then :
  24006. eval "$as_ac_Lib=yes"
  24007. else
  24008. eval "$as_ac_Lib=no"
  24009. fi
  24010. rm -f core conftest.err conftest.$ac_objext \
  24011. conftest$ac_exeext conftest.$ac_ext
  24012. LIBS=$ac_check_lib_save_LIBS
  24013. fi
  24014. eval ac_res=\$$as_ac_Lib
  24015. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24016. $as_echo "$ac_res" >&6; }
  24017. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24018. AST_LUA_FOUND=yes
  24019. else
  24020. AST_LUA_FOUND=no
  24021. fi
  24022. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24023. fi
  24024. # now check for the header.
  24025. if test "${AST_LUA_FOUND}" = "yes"; then
  24026. LUA_LIB="${pbxlibdir} -llua5.1 -lm"
  24027. # if --with-LUA=DIR has been specified, use it.
  24028. if test "x${LUA_DIR}" != "x"; then
  24029. LUA_INCLUDE="-I${LUA_DIR}/include"
  24030. fi
  24031. LUA_INCLUDE="${LUA_INCLUDE} "
  24032. if test "xlua5.1/lua.h" = "x" ; then # no header, assume found
  24033. LUA_HEADER_FOUND="1"
  24034. else # check for the header
  24035. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  24036. CPPFLAGS="${CPPFLAGS} ${LUA_INCLUDE}"
  24037. ac_fn_c_check_header_mongrel "$LINENO" "lua5.1/lua.h" "ac_cv_header_lua5_1_lua_h" "$ac_includes_default"
  24038. if test "x$ac_cv_header_lua5_1_lua_h" = xyes; then :
  24039. LUA_HEADER_FOUND=1
  24040. else
  24041. LUA_HEADER_FOUND=0
  24042. fi
  24043. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  24044. fi
  24045. if test "x${LUA_HEADER_FOUND}" = "x0" ; then
  24046. LUA_LIB=""
  24047. LUA_INCLUDE=""
  24048. else
  24049. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  24050. LUA_LIB=""
  24051. fi
  24052. PBX_LUA=1
  24053. cat >>confdefs.h <<_ACEOF
  24054. #define HAVE_LUA 1
  24055. _ACEOF
  24056. fi
  24057. fi
  24058. fi
  24059. if test "x${PBX_LUA}" = "x1" ; then
  24060. if test x"${LUA_DIR}" = x; then
  24061. LUA_INCLUDE="${LUA_INCLUDE} -I/usr/include/lua5.1"
  24062. else
  24063. LUA_INCLUDE="${LUA_INCLUDE} -I${LUA_DIR}/lua5.1"
  24064. fi
  24065. fi
  24066. # Some distributions (like SuSE) remove the 5.1 suffix.
  24067. if test "x${PBX_LUA}" != "x1" -a "${USE_LUA}" != "no"; then
  24068. pbxlibdir=""
  24069. # if --with-LUA=DIR has been specified, use it.
  24070. if test "x${LUA_DIR}" != "x"; then
  24071. if test -d ${LUA_DIR}/lib; then
  24072. pbxlibdir="-L${LUA_DIR}/lib"
  24073. else
  24074. pbxlibdir="-L${LUA_DIR}"
  24075. fi
  24076. fi
  24077. pbxfuncname="luaL_openlib"
  24078. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  24079. AST_LUA_FOUND=yes
  24080. else
  24081. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  24082. CFLAGS="${CFLAGS} "
  24083. as_ac_Lib=`$as_echo "ac_cv_lib_lua_${pbxfuncname}" | $as_tr_sh`
  24084. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -llua" >&5
  24085. $as_echo_n "checking for ${pbxfuncname} in -llua... " >&6; }
  24086. if eval \${$as_ac_Lib+:} false; then :
  24087. $as_echo_n "(cached) " >&6
  24088. else
  24089. ac_check_lib_save_LIBS=$LIBS
  24090. LIBS="-llua ${pbxlibdir} -lm $LIBS"
  24091. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24092. /* end confdefs.h. */
  24093. /* Override any GCC internal prototype to avoid an error.
  24094. Use char because int might match the return type of a GCC
  24095. builtin and then its argument prototype would still apply. */
  24096. #ifdef __cplusplus
  24097. extern "C"
  24098. #endif
  24099. char ${pbxfuncname} ();
  24100. int
  24101. main ()
  24102. {
  24103. return ${pbxfuncname} ();
  24104. ;
  24105. return 0;
  24106. }
  24107. _ACEOF
  24108. if ac_fn_c_try_link "$LINENO"; then :
  24109. eval "$as_ac_Lib=yes"
  24110. else
  24111. eval "$as_ac_Lib=no"
  24112. fi
  24113. rm -f core conftest.err conftest.$ac_objext \
  24114. conftest$ac_exeext conftest.$ac_ext
  24115. LIBS=$ac_check_lib_save_LIBS
  24116. fi
  24117. eval ac_res=\$$as_ac_Lib
  24118. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24119. $as_echo "$ac_res" >&6; }
  24120. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24121. AST_LUA_FOUND=yes
  24122. else
  24123. AST_LUA_FOUND=no
  24124. fi
  24125. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24126. fi
  24127. # now check for the header.
  24128. if test "${AST_LUA_FOUND}" = "yes"; then
  24129. LUA_LIB="${pbxlibdir} -llua -lm"
  24130. # if --with-LUA=DIR has been specified, use it.
  24131. if test "x${LUA_DIR}" != "x"; then
  24132. LUA_INCLUDE="-I${LUA_DIR}/include"
  24133. fi
  24134. LUA_INCLUDE="${LUA_INCLUDE} "
  24135. if test "xlua.h" = "x" ; then # no header, assume found
  24136. LUA_HEADER_FOUND="1"
  24137. else # check for the header
  24138. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  24139. CPPFLAGS="${CPPFLAGS} ${LUA_INCLUDE}"
  24140. ac_fn_c_check_header_mongrel "$LINENO" "lua.h" "ac_cv_header_lua_h" "$ac_includes_default"
  24141. if test "x$ac_cv_header_lua_h" = xyes; then :
  24142. LUA_HEADER_FOUND=1
  24143. else
  24144. LUA_HEADER_FOUND=0
  24145. fi
  24146. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  24147. fi
  24148. if test "x${LUA_HEADER_FOUND}" = "x0" ; then
  24149. LUA_LIB=""
  24150. LUA_INCLUDE=""
  24151. else
  24152. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  24153. LUA_LIB=""
  24154. fi
  24155. PBX_LUA=1
  24156. cat >>confdefs.h <<_ACEOF
  24157. #define HAVE_LUA 1
  24158. _ACEOF
  24159. fi
  24160. fi
  24161. fi
  24162. # Accept either RADIUS client library, their APIs are fully compatible,
  24163. # just different header filenames and different SONAMEs
  24164. if test "x${PBX_RADIUS}" != "x1" -a "${USE_RADIUS}" != "no"; then
  24165. pbxlibdir=""
  24166. # if --with-RADIUS=DIR has been specified, use it.
  24167. if test "x${RADIUS_DIR}" != "x"; then
  24168. if test -d ${RADIUS_DIR}/lib; then
  24169. pbxlibdir="-L${RADIUS_DIR}/lib"
  24170. else
  24171. pbxlibdir="-L${RADIUS_DIR}"
  24172. fi
  24173. fi
  24174. pbxfuncname="rc_read_config"
  24175. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  24176. AST_RADIUS_FOUND=yes
  24177. else
  24178. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  24179. CFLAGS="${CFLAGS} "
  24180. as_ac_Lib=`$as_echo "ac_cv_lib_freeradius-client_${pbxfuncname}" | $as_tr_sh`
  24181. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lfreeradius-client" >&5
  24182. $as_echo_n "checking for ${pbxfuncname} in -lfreeradius-client... " >&6; }
  24183. if eval \${$as_ac_Lib+:} false; then :
  24184. $as_echo_n "(cached) " >&6
  24185. else
  24186. ac_check_lib_save_LIBS=$LIBS
  24187. LIBS="-lfreeradius-client ${pbxlibdir} $LIBS"
  24188. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24189. /* end confdefs.h. */
  24190. /* Override any GCC internal prototype to avoid an error.
  24191. Use char because int might match the return type of a GCC
  24192. builtin and then its argument prototype would still apply. */
  24193. #ifdef __cplusplus
  24194. extern "C"
  24195. #endif
  24196. char ${pbxfuncname} ();
  24197. int
  24198. main ()
  24199. {
  24200. return ${pbxfuncname} ();
  24201. ;
  24202. return 0;
  24203. }
  24204. _ACEOF
  24205. if ac_fn_c_try_link "$LINENO"; then :
  24206. eval "$as_ac_Lib=yes"
  24207. else
  24208. eval "$as_ac_Lib=no"
  24209. fi
  24210. rm -f core conftest.err conftest.$ac_objext \
  24211. conftest$ac_exeext conftest.$ac_ext
  24212. LIBS=$ac_check_lib_save_LIBS
  24213. fi
  24214. eval ac_res=\$$as_ac_Lib
  24215. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24216. $as_echo "$ac_res" >&6; }
  24217. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24218. AST_RADIUS_FOUND=yes
  24219. else
  24220. AST_RADIUS_FOUND=no
  24221. fi
  24222. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24223. fi
  24224. # now check for the header.
  24225. if test "${AST_RADIUS_FOUND}" = "yes"; then
  24226. RADIUS_LIB="${pbxlibdir} -lfreeradius-client "
  24227. # if --with-RADIUS=DIR has been specified, use it.
  24228. if test "x${RADIUS_DIR}" != "x"; then
  24229. RADIUS_INCLUDE="-I${RADIUS_DIR}/include"
  24230. fi
  24231. RADIUS_INCLUDE="${RADIUS_INCLUDE} "
  24232. if test "xfreeradius-client.h" = "x" ; then # no header, assume found
  24233. RADIUS_HEADER_FOUND="1"
  24234. else # check for the header
  24235. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  24236. CPPFLAGS="${CPPFLAGS} ${RADIUS_INCLUDE}"
  24237. ac_fn_c_check_header_mongrel "$LINENO" "freeradius-client.h" "ac_cv_header_freeradius_client_h" "$ac_includes_default"
  24238. if test "x$ac_cv_header_freeradius_client_h" = xyes; then :
  24239. RADIUS_HEADER_FOUND=1
  24240. else
  24241. RADIUS_HEADER_FOUND=0
  24242. fi
  24243. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  24244. fi
  24245. if test "x${RADIUS_HEADER_FOUND}" = "x0" ; then
  24246. RADIUS_LIB=""
  24247. RADIUS_INCLUDE=""
  24248. else
  24249. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  24250. RADIUS_LIB=""
  24251. fi
  24252. PBX_RADIUS=1
  24253. cat >>confdefs.h <<_ACEOF
  24254. #define HAVE_RADIUS 1
  24255. _ACEOF
  24256. fi
  24257. fi
  24258. fi
  24259. if test "x${PBX_RADIUS}" = "x1"; then
  24260. $as_echo "#define FREERADIUS_CLIENT /**/" >>confdefs.h
  24261. else
  24262. if test "x${PBX_RADIUS}" != "x1" -a "${USE_RADIUS}" != "no"; then
  24263. pbxlibdir=""
  24264. # if --with-RADIUS=DIR has been specified, use it.
  24265. if test "x${RADIUS_DIR}" != "x"; then
  24266. if test -d ${RADIUS_DIR}/lib; then
  24267. pbxlibdir="-L${RADIUS_DIR}/lib"
  24268. else
  24269. pbxlibdir="-L${RADIUS_DIR}"
  24270. fi
  24271. fi
  24272. pbxfuncname="rc_read_config"
  24273. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  24274. AST_RADIUS_FOUND=yes
  24275. else
  24276. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  24277. CFLAGS="${CFLAGS} "
  24278. as_ac_Lib=`$as_echo "ac_cv_lib_radiusclient-ng_${pbxfuncname}" | $as_tr_sh`
  24279. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lradiusclient-ng" >&5
  24280. $as_echo_n "checking for ${pbxfuncname} in -lradiusclient-ng... " >&6; }
  24281. if eval \${$as_ac_Lib+:} false; then :
  24282. $as_echo_n "(cached) " >&6
  24283. else
  24284. ac_check_lib_save_LIBS=$LIBS
  24285. LIBS="-lradiusclient-ng ${pbxlibdir} $LIBS"
  24286. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24287. /* end confdefs.h. */
  24288. /* Override any GCC internal prototype to avoid an error.
  24289. Use char because int might match the return type of a GCC
  24290. builtin and then its argument prototype would still apply. */
  24291. #ifdef __cplusplus
  24292. extern "C"
  24293. #endif
  24294. char ${pbxfuncname} ();
  24295. int
  24296. main ()
  24297. {
  24298. return ${pbxfuncname} ();
  24299. ;
  24300. return 0;
  24301. }
  24302. _ACEOF
  24303. if ac_fn_c_try_link "$LINENO"; then :
  24304. eval "$as_ac_Lib=yes"
  24305. else
  24306. eval "$as_ac_Lib=no"
  24307. fi
  24308. rm -f core conftest.err conftest.$ac_objext \
  24309. conftest$ac_exeext conftest.$ac_ext
  24310. LIBS=$ac_check_lib_save_LIBS
  24311. fi
  24312. eval ac_res=\$$as_ac_Lib
  24313. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24314. $as_echo "$ac_res" >&6; }
  24315. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24316. AST_RADIUS_FOUND=yes
  24317. else
  24318. AST_RADIUS_FOUND=no
  24319. fi
  24320. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24321. fi
  24322. # now check for the header.
  24323. if test "${AST_RADIUS_FOUND}" = "yes"; then
  24324. RADIUS_LIB="${pbxlibdir} -lradiusclient-ng "
  24325. # if --with-RADIUS=DIR has been specified, use it.
  24326. if test "x${RADIUS_DIR}" != "x"; then
  24327. RADIUS_INCLUDE="-I${RADIUS_DIR}/include"
  24328. fi
  24329. RADIUS_INCLUDE="${RADIUS_INCLUDE} "
  24330. if test "xradiusclient-ng.h" = "x" ; then # no header, assume found
  24331. RADIUS_HEADER_FOUND="1"
  24332. else # check for the header
  24333. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  24334. CPPFLAGS="${CPPFLAGS} ${RADIUS_INCLUDE}"
  24335. ac_fn_c_check_header_mongrel "$LINENO" "radiusclient-ng.h" "ac_cv_header_radiusclient_ng_h" "$ac_includes_default"
  24336. if test "x$ac_cv_header_radiusclient_ng_h" = xyes; then :
  24337. RADIUS_HEADER_FOUND=1
  24338. else
  24339. RADIUS_HEADER_FOUND=0
  24340. fi
  24341. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  24342. fi
  24343. if test "x${RADIUS_HEADER_FOUND}" = "x0" ; then
  24344. RADIUS_LIB=""
  24345. RADIUS_INCLUDE=""
  24346. else
  24347. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  24348. RADIUS_LIB=""
  24349. fi
  24350. PBX_RADIUS=1
  24351. cat >>confdefs.h <<_ACEOF
  24352. #define HAVE_RADIUS 1
  24353. _ACEOF
  24354. fi
  24355. fi
  24356. fi
  24357. fi
  24358. if test "x${PBX_COROSYNC}" != "x1" -a "${USE_COROSYNC}" != "no"; then
  24359. pbxlibdir=""
  24360. # if --with-COROSYNC=DIR has been specified, use it.
  24361. if test "x${COROSYNC_DIR}" != "x"; then
  24362. if test -d ${COROSYNC_DIR}/lib; then
  24363. pbxlibdir="-L${COROSYNC_DIR}/lib"
  24364. else
  24365. pbxlibdir="-L${COROSYNC_DIR}"
  24366. fi
  24367. fi
  24368. pbxfuncname="cpg_join"
  24369. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  24370. AST_COROSYNC_FOUND=yes
  24371. else
  24372. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  24373. CFLAGS="${CFLAGS} "
  24374. as_ac_Lib=`$as_echo "ac_cv_lib_cpg_${pbxfuncname}" | $as_tr_sh`
  24375. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lcpg" >&5
  24376. $as_echo_n "checking for ${pbxfuncname} in -lcpg... " >&6; }
  24377. if eval \${$as_ac_Lib+:} false; then :
  24378. $as_echo_n "(cached) " >&6
  24379. else
  24380. ac_check_lib_save_LIBS=$LIBS
  24381. LIBS="-lcpg ${pbxlibdir} -lcfg $LIBS"
  24382. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24383. /* end confdefs.h. */
  24384. /* Override any GCC internal prototype to avoid an error.
  24385. Use char because int might match the return type of a GCC
  24386. builtin and then its argument prototype would still apply. */
  24387. #ifdef __cplusplus
  24388. extern "C"
  24389. #endif
  24390. char ${pbxfuncname} ();
  24391. int
  24392. main ()
  24393. {
  24394. return ${pbxfuncname} ();
  24395. ;
  24396. return 0;
  24397. }
  24398. _ACEOF
  24399. if ac_fn_c_try_link "$LINENO"; then :
  24400. eval "$as_ac_Lib=yes"
  24401. else
  24402. eval "$as_ac_Lib=no"
  24403. fi
  24404. rm -f core conftest.err conftest.$ac_objext \
  24405. conftest$ac_exeext conftest.$ac_ext
  24406. LIBS=$ac_check_lib_save_LIBS
  24407. fi
  24408. eval ac_res=\$$as_ac_Lib
  24409. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24410. $as_echo "$ac_res" >&6; }
  24411. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24412. AST_COROSYNC_FOUND=yes
  24413. else
  24414. AST_COROSYNC_FOUND=no
  24415. fi
  24416. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24417. fi
  24418. # now check for the header.
  24419. if test "${AST_COROSYNC_FOUND}" = "yes"; then
  24420. COROSYNC_LIB="${pbxlibdir} -lcpg -lcfg"
  24421. # if --with-COROSYNC=DIR has been specified, use it.
  24422. if test "x${COROSYNC_DIR}" != "x"; then
  24423. COROSYNC_INCLUDE="-I${COROSYNC_DIR}/include"
  24424. fi
  24425. COROSYNC_INCLUDE="${COROSYNC_INCLUDE} "
  24426. if test "xcorosync/cpg.h" = "x" ; then # no header, assume found
  24427. COROSYNC_HEADER_FOUND="1"
  24428. else # check for the header
  24429. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  24430. CPPFLAGS="${CPPFLAGS} ${COROSYNC_INCLUDE}"
  24431. ac_fn_c_check_header_mongrel "$LINENO" "corosync/cpg.h" "ac_cv_header_corosync_cpg_h" "$ac_includes_default"
  24432. if test "x$ac_cv_header_corosync_cpg_h" = xyes; then :
  24433. COROSYNC_HEADER_FOUND=1
  24434. else
  24435. COROSYNC_HEADER_FOUND=0
  24436. fi
  24437. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  24438. fi
  24439. if test "x${COROSYNC_HEADER_FOUND}" = "x0" ; then
  24440. COROSYNC_LIB=""
  24441. COROSYNC_INCLUDE=""
  24442. else
  24443. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  24444. COROSYNC_LIB=""
  24445. fi
  24446. PBX_COROSYNC=1
  24447. cat >>confdefs.h <<_ACEOF
  24448. #define HAVE_COROSYNC 1
  24449. _ACEOF
  24450. fi
  24451. fi
  24452. fi
  24453. if test "x${PBX_COROSYNC_CFG_STATE_TRACK}" != "x1" -a "${USE_COROSYNC_CFG_STATE_TRACK}" != "no"; then
  24454. pbxlibdir=""
  24455. # if --with-COROSYNC_CFG_STATE_TRACK=DIR has been specified, use it.
  24456. if test "x${COROSYNC_CFG_STATE_TRACK_DIR}" != "x"; then
  24457. if test -d ${COROSYNC_CFG_STATE_TRACK_DIR}/lib; then
  24458. pbxlibdir="-L${COROSYNC_CFG_STATE_TRACK_DIR}/lib"
  24459. else
  24460. pbxlibdir="-L${COROSYNC_CFG_STATE_TRACK_DIR}"
  24461. fi
  24462. fi
  24463. pbxfuncname="corosync_cfg_state_track"
  24464. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  24465. AST_COROSYNC_CFG_STATE_TRACK_FOUND=yes
  24466. else
  24467. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  24468. CFLAGS="${CFLAGS} "
  24469. as_ac_Lib=`$as_echo "ac_cv_lib_cfg_${pbxfuncname}" | $as_tr_sh`
  24470. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lcfg" >&5
  24471. $as_echo_n "checking for ${pbxfuncname} in -lcfg... " >&6; }
  24472. if eval \${$as_ac_Lib+:} false; then :
  24473. $as_echo_n "(cached) " >&6
  24474. else
  24475. ac_check_lib_save_LIBS=$LIBS
  24476. LIBS="-lcfg ${pbxlibdir} -lcfg $LIBS"
  24477. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24478. /* end confdefs.h. */
  24479. /* Override any GCC internal prototype to avoid an error.
  24480. Use char because int might match the return type of a GCC
  24481. builtin and then its argument prototype would still apply. */
  24482. #ifdef __cplusplus
  24483. extern "C"
  24484. #endif
  24485. char ${pbxfuncname} ();
  24486. int
  24487. main ()
  24488. {
  24489. return ${pbxfuncname} ();
  24490. ;
  24491. return 0;
  24492. }
  24493. _ACEOF
  24494. if ac_fn_c_try_link "$LINENO"; then :
  24495. eval "$as_ac_Lib=yes"
  24496. else
  24497. eval "$as_ac_Lib=no"
  24498. fi
  24499. rm -f core conftest.err conftest.$ac_objext \
  24500. conftest$ac_exeext conftest.$ac_ext
  24501. LIBS=$ac_check_lib_save_LIBS
  24502. fi
  24503. eval ac_res=\$$as_ac_Lib
  24504. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24505. $as_echo "$ac_res" >&6; }
  24506. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24507. AST_COROSYNC_CFG_STATE_TRACK_FOUND=yes
  24508. else
  24509. AST_COROSYNC_CFG_STATE_TRACK_FOUND=no
  24510. fi
  24511. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24512. fi
  24513. # now check for the header.
  24514. if test "${AST_COROSYNC_CFG_STATE_TRACK_FOUND}" = "yes"; then
  24515. COROSYNC_CFG_STATE_TRACK_LIB="${pbxlibdir} -lcfg -lcfg"
  24516. # if --with-COROSYNC_CFG_STATE_TRACK=DIR has been specified, use it.
  24517. if test "x${COROSYNC_CFG_STATE_TRACK_DIR}" != "x"; then
  24518. COROSYNC_CFG_STATE_TRACK_INCLUDE="-I${COROSYNC_CFG_STATE_TRACK_DIR}/include"
  24519. fi
  24520. COROSYNC_CFG_STATE_TRACK_INCLUDE="${COROSYNC_CFG_STATE_TRACK_INCLUDE} "
  24521. if test "xcorosync/cfg.h" = "x" ; then # no header, assume found
  24522. COROSYNC_CFG_STATE_TRACK_HEADER_FOUND="1"
  24523. else # check for the header
  24524. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  24525. CPPFLAGS="${CPPFLAGS} ${COROSYNC_CFG_STATE_TRACK_INCLUDE}"
  24526. ac_fn_c_check_header_mongrel "$LINENO" "corosync/cfg.h" "ac_cv_header_corosync_cfg_h" "$ac_includes_default"
  24527. if test "x$ac_cv_header_corosync_cfg_h" = xyes; then :
  24528. COROSYNC_CFG_STATE_TRACK_HEADER_FOUND=1
  24529. else
  24530. COROSYNC_CFG_STATE_TRACK_HEADER_FOUND=0
  24531. fi
  24532. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  24533. fi
  24534. if test "x${COROSYNC_CFG_STATE_TRACK_HEADER_FOUND}" = "x0" ; then
  24535. COROSYNC_CFG_STATE_TRACK_LIB=""
  24536. COROSYNC_CFG_STATE_TRACK_INCLUDE=""
  24537. else
  24538. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  24539. COROSYNC_CFG_STATE_TRACK_LIB=""
  24540. fi
  24541. PBX_COROSYNC_CFG_STATE_TRACK=1
  24542. cat >>confdefs.h <<_ACEOF
  24543. #define HAVE_COROSYNC_CFG_STATE_TRACK 1
  24544. _ACEOF
  24545. fi
  24546. fi
  24547. fi
  24548. if test "x${PBX_SPEEX}" != "x1" -a "${USE_SPEEX}" != "no"; then
  24549. pbxlibdir=""
  24550. # if --with-SPEEX=DIR has been specified, use it.
  24551. if test "x${SPEEX_DIR}" != "x"; then
  24552. if test -d ${SPEEX_DIR}/lib; then
  24553. pbxlibdir="-L${SPEEX_DIR}/lib"
  24554. else
  24555. pbxlibdir="-L${SPEEX_DIR}"
  24556. fi
  24557. fi
  24558. pbxfuncname="speex_encode"
  24559. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  24560. AST_SPEEX_FOUND=yes
  24561. else
  24562. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  24563. CFLAGS="${CFLAGS} "
  24564. as_ac_Lib=`$as_echo "ac_cv_lib_speex_${pbxfuncname}" | $as_tr_sh`
  24565. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lspeex" >&5
  24566. $as_echo_n "checking for ${pbxfuncname} in -lspeex... " >&6; }
  24567. if eval \${$as_ac_Lib+:} false; then :
  24568. $as_echo_n "(cached) " >&6
  24569. else
  24570. ac_check_lib_save_LIBS=$LIBS
  24571. LIBS="-lspeex ${pbxlibdir} -lm $LIBS"
  24572. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24573. /* end confdefs.h. */
  24574. /* Override any GCC internal prototype to avoid an error.
  24575. Use char because int might match the return type of a GCC
  24576. builtin and then its argument prototype would still apply. */
  24577. #ifdef __cplusplus
  24578. extern "C"
  24579. #endif
  24580. char ${pbxfuncname} ();
  24581. int
  24582. main ()
  24583. {
  24584. return ${pbxfuncname} ();
  24585. ;
  24586. return 0;
  24587. }
  24588. _ACEOF
  24589. if ac_fn_c_try_link "$LINENO"; then :
  24590. eval "$as_ac_Lib=yes"
  24591. else
  24592. eval "$as_ac_Lib=no"
  24593. fi
  24594. rm -f core conftest.err conftest.$ac_objext \
  24595. conftest$ac_exeext conftest.$ac_ext
  24596. LIBS=$ac_check_lib_save_LIBS
  24597. fi
  24598. eval ac_res=\$$as_ac_Lib
  24599. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24600. $as_echo "$ac_res" >&6; }
  24601. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24602. AST_SPEEX_FOUND=yes
  24603. else
  24604. AST_SPEEX_FOUND=no
  24605. fi
  24606. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24607. fi
  24608. # now check for the header.
  24609. if test "${AST_SPEEX_FOUND}" = "yes"; then
  24610. SPEEX_LIB="${pbxlibdir} -lspeex -lm"
  24611. # if --with-SPEEX=DIR has been specified, use it.
  24612. if test "x${SPEEX_DIR}" != "x"; then
  24613. SPEEX_INCLUDE="-I${SPEEX_DIR}/include"
  24614. fi
  24615. SPEEX_INCLUDE="${SPEEX_INCLUDE} "
  24616. if test "xspeex/speex.h" = "x" ; then # no header, assume found
  24617. SPEEX_HEADER_FOUND="1"
  24618. else # check for the header
  24619. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  24620. CPPFLAGS="${CPPFLAGS} ${SPEEX_INCLUDE}"
  24621. ac_fn_c_check_header_mongrel "$LINENO" "speex/speex.h" "ac_cv_header_speex_speex_h" "$ac_includes_default"
  24622. if test "x$ac_cv_header_speex_speex_h" = xyes; then :
  24623. SPEEX_HEADER_FOUND=1
  24624. else
  24625. SPEEX_HEADER_FOUND=0
  24626. fi
  24627. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  24628. fi
  24629. if test "x${SPEEX_HEADER_FOUND}" = "x0" ; then
  24630. SPEEX_LIB=""
  24631. SPEEX_INCLUDE=""
  24632. else
  24633. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  24634. SPEEX_LIB=""
  24635. fi
  24636. PBX_SPEEX=1
  24637. cat >>confdefs.h <<_ACEOF
  24638. #define HAVE_SPEEX 1
  24639. _ACEOF
  24640. fi
  24641. fi
  24642. fi
  24643. # See if the main speex library contains the preprocess functions
  24644. if test "x${PBX_SPEEX_PREPROCESS}" != "x1" -a "${USE_SPEEX_PREPROCESS}" != "no"; then
  24645. pbxlibdir=""
  24646. # if --with-SPEEX_PREPROCESS=DIR has been specified, use it.
  24647. if test "x${SPEEX_PREPROCESS_DIR}" != "x"; then
  24648. if test -d ${SPEEX_PREPROCESS_DIR}/lib; then
  24649. pbxlibdir="-L${SPEEX_PREPROCESS_DIR}/lib"
  24650. else
  24651. pbxlibdir="-L${SPEEX_PREPROCESS_DIR}"
  24652. fi
  24653. fi
  24654. pbxfuncname="speex_preprocess_ctl"
  24655. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  24656. AST_SPEEX_PREPROCESS_FOUND=yes
  24657. else
  24658. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  24659. CFLAGS="${CFLAGS} "
  24660. as_ac_Lib=`$as_echo "ac_cv_lib_speex_${pbxfuncname}" | $as_tr_sh`
  24661. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lspeex" >&5
  24662. $as_echo_n "checking for ${pbxfuncname} in -lspeex... " >&6; }
  24663. if eval \${$as_ac_Lib+:} false; then :
  24664. $as_echo_n "(cached) " >&6
  24665. else
  24666. ac_check_lib_save_LIBS=$LIBS
  24667. LIBS="-lspeex ${pbxlibdir} -lm $LIBS"
  24668. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24669. /* end confdefs.h. */
  24670. /* Override any GCC internal prototype to avoid an error.
  24671. Use char because int might match the return type of a GCC
  24672. builtin and then its argument prototype would still apply. */
  24673. #ifdef __cplusplus
  24674. extern "C"
  24675. #endif
  24676. char ${pbxfuncname} ();
  24677. int
  24678. main ()
  24679. {
  24680. return ${pbxfuncname} ();
  24681. ;
  24682. return 0;
  24683. }
  24684. _ACEOF
  24685. if ac_fn_c_try_link "$LINENO"; then :
  24686. eval "$as_ac_Lib=yes"
  24687. else
  24688. eval "$as_ac_Lib=no"
  24689. fi
  24690. rm -f core conftest.err conftest.$ac_objext \
  24691. conftest$ac_exeext conftest.$ac_ext
  24692. LIBS=$ac_check_lib_save_LIBS
  24693. fi
  24694. eval ac_res=\$$as_ac_Lib
  24695. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24696. $as_echo "$ac_res" >&6; }
  24697. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24698. AST_SPEEX_PREPROCESS_FOUND=yes
  24699. else
  24700. AST_SPEEX_PREPROCESS_FOUND=no
  24701. fi
  24702. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24703. fi
  24704. # now check for the header.
  24705. if test "${AST_SPEEX_PREPROCESS_FOUND}" = "yes"; then
  24706. SPEEX_PREPROCESS_LIB="${pbxlibdir} -lspeex -lm"
  24707. # if --with-SPEEX_PREPROCESS=DIR has been specified, use it.
  24708. if test "x${SPEEX_PREPROCESS_DIR}" != "x"; then
  24709. SPEEX_PREPROCESS_INCLUDE="-I${SPEEX_PREPROCESS_DIR}/include"
  24710. fi
  24711. SPEEX_PREPROCESS_INCLUDE="${SPEEX_PREPROCESS_INCLUDE} "
  24712. if test "xspeex/speex.h" = "x" ; then # no header, assume found
  24713. SPEEX_PREPROCESS_HEADER_FOUND="1"
  24714. else # check for the header
  24715. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  24716. CPPFLAGS="${CPPFLAGS} ${SPEEX_PREPROCESS_INCLUDE}"
  24717. ac_fn_c_check_header_mongrel "$LINENO" "speex/speex.h" "ac_cv_header_speex_speex_h" "$ac_includes_default"
  24718. if test "x$ac_cv_header_speex_speex_h" = xyes; then :
  24719. SPEEX_PREPROCESS_HEADER_FOUND=1
  24720. else
  24721. SPEEX_PREPROCESS_HEADER_FOUND=0
  24722. fi
  24723. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  24724. fi
  24725. if test "x${SPEEX_PREPROCESS_HEADER_FOUND}" = "x0" ; then
  24726. SPEEX_PREPROCESS_LIB=""
  24727. SPEEX_PREPROCESS_INCLUDE=""
  24728. else
  24729. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  24730. SPEEX_PREPROCESS_LIB=""
  24731. fi
  24732. PBX_SPEEX_PREPROCESS=1
  24733. cat >>confdefs.h <<_ACEOF
  24734. #define HAVE_SPEEX_PREPROCESS 1
  24735. _ACEOF
  24736. fi
  24737. fi
  24738. fi
  24739. if test "${PBX_SPEEX_PREPROCESS}" = 1; then
  24740. PBX_SPEEX_PREPROCESS=1
  24741. fi
  24742. if test "x${PBX_SPEEXDSP}" != "x1" -a "${USE_SPEEXDSP}" != "no"; then
  24743. pbxlibdir=""
  24744. # if --with-SPEEXDSP=DIR has been specified, use it.
  24745. if test "x${SPEEXDSP_DIR}" != "x"; then
  24746. if test -d ${SPEEXDSP_DIR}/lib; then
  24747. pbxlibdir="-L${SPEEXDSP_DIR}/lib"
  24748. else
  24749. pbxlibdir="-L${SPEEXDSP_DIR}"
  24750. fi
  24751. fi
  24752. pbxfuncname="speex_preprocess_ctl"
  24753. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  24754. AST_SPEEXDSP_FOUND=yes
  24755. else
  24756. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  24757. CFLAGS="${CFLAGS} "
  24758. as_ac_Lib=`$as_echo "ac_cv_lib_speexdsp_${pbxfuncname}" | $as_tr_sh`
  24759. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lspeexdsp" >&5
  24760. $as_echo_n "checking for ${pbxfuncname} in -lspeexdsp... " >&6; }
  24761. if eval \${$as_ac_Lib+:} false; then :
  24762. $as_echo_n "(cached) " >&6
  24763. else
  24764. ac_check_lib_save_LIBS=$LIBS
  24765. LIBS="-lspeexdsp ${pbxlibdir} -lm $LIBS"
  24766. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24767. /* end confdefs.h. */
  24768. /* Override any GCC internal prototype to avoid an error.
  24769. Use char because int might match the return type of a GCC
  24770. builtin and then its argument prototype would still apply. */
  24771. #ifdef __cplusplus
  24772. extern "C"
  24773. #endif
  24774. char ${pbxfuncname} ();
  24775. int
  24776. main ()
  24777. {
  24778. return ${pbxfuncname} ();
  24779. ;
  24780. return 0;
  24781. }
  24782. _ACEOF
  24783. if ac_fn_c_try_link "$LINENO"; then :
  24784. eval "$as_ac_Lib=yes"
  24785. else
  24786. eval "$as_ac_Lib=no"
  24787. fi
  24788. rm -f core conftest.err conftest.$ac_objext \
  24789. conftest$ac_exeext conftest.$ac_ext
  24790. LIBS=$ac_check_lib_save_LIBS
  24791. fi
  24792. eval ac_res=\$$as_ac_Lib
  24793. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24794. $as_echo "$ac_res" >&6; }
  24795. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24796. AST_SPEEXDSP_FOUND=yes
  24797. else
  24798. AST_SPEEXDSP_FOUND=no
  24799. fi
  24800. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24801. fi
  24802. # now check for the header.
  24803. if test "${AST_SPEEXDSP_FOUND}" = "yes"; then
  24804. SPEEXDSP_LIB="${pbxlibdir} -lspeexdsp -lm"
  24805. # if --with-SPEEXDSP=DIR has been specified, use it.
  24806. if test "x${SPEEXDSP_DIR}" != "x"; then
  24807. SPEEXDSP_INCLUDE="-I${SPEEXDSP_DIR}/include"
  24808. fi
  24809. SPEEXDSP_INCLUDE="${SPEEXDSP_INCLUDE} "
  24810. if test "xspeex/speex.h" = "x" ; then # no header, assume found
  24811. SPEEXDSP_HEADER_FOUND="1"
  24812. else # check for the header
  24813. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  24814. CPPFLAGS="${CPPFLAGS} ${SPEEXDSP_INCLUDE}"
  24815. ac_fn_c_check_header_mongrel "$LINENO" "speex/speex.h" "ac_cv_header_speex_speex_h" "$ac_includes_default"
  24816. if test "x$ac_cv_header_speex_speex_h" = xyes; then :
  24817. SPEEXDSP_HEADER_FOUND=1
  24818. else
  24819. SPEEXDSP_HEADER_FOUND=0
  24820. fi
  24821. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  24822. fi
  24823. if test "x${SPEEXDSP_HEADER_FOUND}" = "x0" ; then
  24824. SPEEXDSP_LIB=""
  24825. SPEEXDSP_INCLUDE=""
  24826. else
  24827. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  24828. SPEEXDSP_LIB=""
  24829. fi
  24830. PBX_SPEEXDSP=1
  24831. cat >>confdefs.h <<_ACEOF
  24832. #define HAVE_SPEEXDSP 1
  24833. _ACEOF
  24834. fi
  24835. fi
  24836. fi
  24837. if test "${PBX_SPEEXDSP}" = 1; then
  24838. PBX_SPEEX_PREPROCESS=1
  24839. fi
  24840. if test "x${PBX_SQLITE}" != "x1" -a "${USE_SQLITE}" != "no"; then
  24841. pbxlibdir=""
  24842. # if --with-SQLITE=DIR has been specified, use it.
  24843. if test "x${SQLITE_DIR}" != "x"; then
  24844. if test -d ${SQLITE_DIR}/lib; then
  24845. pbxlibdir="-L${SQLITE_DIR}/lib"
  24846. else
  24847. pbxlibdir="-L${SQLITE_DIR}"
  24848. fi
  24849. fi
  24850. pbxfuncname="sqlite_exec"
  24851. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  24852. AST_SQLITE_FOUND=yes
  24853. else
  24854. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  24855. CFLAGS="${CFLAGS} "
  24856. as_ac_Lib=`$as_echo "ac_cv_lib_sqlite_${pbxfuncname}" | $as_tr_sh`
  24857. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lsqlite" >&5
  24858. $as_echo_n "checking for ${pbxfuncname} in -lsqlite... " >&6; }
  24859. if eval \${$as_ac_Lib+:} false; then :
  24860. $as_echo_n "(cached) " >&6
  24861. else
  24862. ac_check_lib_save_LIBS=$LIBS
  24863. LIBS="-lsqlite ${pbxlibdir} $LIBS"
  24864. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24865. /* end confdefs.h. */
  24866. /* Override any GCC internal prototype to avoid an error.
  24867. Use char because int might match the return type of a GCC
  24868. builtin and then its argument prototype would still apply. */
  24869. #ifdef __cplusplus
  24870. extern "C"
  24871. #endif
  24872. char ${pbxfuncname} ();
  24873. int
  24874. main ()
  24875. {
  24876. return ${pbxfuncname} ();
  24877. ;
  24878. return 0;
  24879. }
  24880. _ACEOF
  24881. if ac_fn_c_try_link "$LINENO"; then :
  24882. eval "$as_ac_Lib=yes"
  24883. else
  24884. eval "$as_ac_Lib=no"
  24885. fi
  24886. rm -f core conftest.err conftest.$ac_objext \
  24887. conftest$ac_exeext conftest.$ac_ext
  24888. LIBS=$ac_check_lib_save_LIBS
  24889. fi
  24890. eval ac_res=\$$as_ac_Lib
  24891. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24892. $as_echo "$ac_res" >&6; }
  24893. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24894. AST_SQLITE_FOUND=yes
  24895. else
  24896. AST_SQLITE_FOUND=no
  24897. fi
  24898. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24899. fi
  24900. # now check for the header.
  24901. if test "${AST_SQLITE_FOUND}" = "yes"; then
  24902. SQLITE_LIB="${pbxlibdir} -lsqlite "
  24903. # if --with-SQLITE=DIR has been specified, use it.
  24904. if test "x${SQLITE_DIR}" != "x"; then
  24905. SQLITE_INCLUDE="-I${SQLITE_DIR}/include"
  24906. fi
  24907. SQLITE_INCLUDE="${SQLITE_INCLUDE} "
  24908. if test "xsqlite.h" = "x" ; then # no header, assume found
  24909. SQLITE_HEADER_FOUND="1"
  24910. else # check for the header
  24911. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  24912. CPPFLAGS="${CPPFLAGS} ${SQLITE_INCLUDE}"
  24913. ac_fn_c_check_header_mongrel "$LINENO" "sqlite.h" "ac_cv_header_sqlite_h" "$ac_includes_default"
  24914. if test "x$ac_cv_header_sqlite_h" = xyes; then :
  24915. SQLITE_HEADER_FOUND=1
  24916. else
  24917. SQLITE_HEADER_FOUND=0
  24918. fi
  24919. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  24920. fi
  24921. if test "x${SQLITE_HEADER_FOUND}" = "x0" ; then
  24922. SQLITE_LIB=""
  24923. SQLITE_INCLUDE=""
  24924. else
  24925. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  24926. SQLITE_LIB=""
  24927. fi
  24928. PBX_SQLITE=1
  24929. cat >>confdefs.h <<_ACEOF
  24930. #define HAVE_SQLITE 1
  24931. _ACEOF
  24932. fi
  24933. fi
  24934. fi
  24935. if test "x${PBX_SQLITE3}" != "x1" -a "${USE_SQLITE3}" != "no"; then
  24936. pbxlibdir=""
  24937. # if --with-SQLITE3=DIR has been specified, use it.
  24938. if test "x${SQLITE3_DIR}" != "x"; then
  24939. if test -d ${SQLITE3_DIR}/lib; then
  24940. pbxlibdir="-L${SQLITE3_DIR}/lib"
  24941. else
  24942. pbxlibdir="-L${SQLITE3_DIR}"
  24943. fi
  24944. fi
  24945. pbxfuncname="sqlite3_open"
  24946. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  24947. AST_SQLITE3_FOUND=yes
  24948. else
  24949. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  24950. CFLAGS="${CFLAGS} ${PTHREAD_CFLAGS}"
  24951. as_ac_Lib=`$as_echo "ac_cv_lib_sqlite3_${pbxfuncname}" | $as_tr_sh`
  24952. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lsqlite3" >&5
  24953. $as_echo_n "checking for ${pbxfuncname} in -lsqlite3... " >&6; }
  24954. if eval \${$as_ac_Lib+:} false; then :
  24955. $as_echo_n "(cached) " >&6
  24956. else
  24957. ac_check_lib_save_LIBS=$LIBS
  24958. LIBS="-lsqlite3 ${pbxlibdir} ${PTHREAD_LIBS} $LIBS"
  24959. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24960. /* end confdefs.h. */
  24961. /* Override any GCC internal prototype to avoid an error.
  24962. Use char because int might match the return type of a GCC
  24963. builtin and then its argument prototype would still apply. */
  24964. #ifdef __cplusplus
  24965. extern "C"
  24966. #endif
  24967. char ${pbxfuncname} ();
  24968. int
  24969. main ()
  24970. {
  24971. return ${pbxfuncname} ();
  24972. ;
  24973. return 0;
  24974. }
  24975. _ACEOF
  24976. if ac_fn_c_try_link "$LINENO"; then :
  24977. eval "$as_ac_Lib=yes"
  24978. else
  24979. eval "$as_ac_Lib=no"
  24980. fi
  24981. rm -f core conftest.err conftest.$ac_objext \
  24982. conftest$ac_exeext conftest.$ac_ext
  24983. LIBS=$ac_check_lib_save_LIBS
  24984. fi
  24985. eval ac_res=\$$as_ac_Lib
  24986. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24987. $as_echo "$ac_res" >&6; }
  24988. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24989. AST_SQLITE3_FOUND=yes
  24990. else
  24991. AST_SQLITE3_FOUND=no
  24992. fi
  24993. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24994. fi
  24995. # now check for the header.
  24996. if test "${AST_SQLITE3_FOUND}" = "yes"; then
  24997. SQLITE3_LIB="${pbxlibdir} -lsqlite3 ${PTHREAD_LIBS}"
  24998. # if --with-SQLITE3=DIR has been specified, use it.
  24999. if test "x${SQLITE3_DIR}" != "x"; then
  25000. SQLITE3_INCLUDE="-I${SQLITE3_DIR}/include"
  25001. fi
  25002. SQLITE3_INCLUDE="${SQLITE3_INCLUDE} ${PTHREAD_CFLAGS}"
  25003. if test "xsqlite3.h" = "x" ; then # no header, assume found
  25004. SQLITE3_HEADER_FOUND="1"
  25005. else # check for the header
  25006. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25007. CPPFLAGS="${CPPFLAGS} ${SQLITE3_INCLUDE}"
  25008. ac_fn_c_check_header_mongrel "$LINENO" "sqlite3.h" "ac_cv_header_sqlite3_h" "$ac_includes_default"
  25009. if test "x$ac_cv_header_sqlite3_h" = xyes; then :
  25010. SQLITE3_HEADER_FOUND=1
  25011. else
  25012. SQLITE3_HEADER_FOUND=0
  25013. fi
  25014. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25015. fi
  25016. if test "x${SQLITE3_HEADER_FOUND}" = "x0" ; then
  25017. SQLITE3_LIB=""
  25018. SQLITE3_INCLUDE=""
  25019. else
  25020. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25021. SQLITE3_LIB=""
  25022. fi
  25023. PBX_SQLITE3=1
  25024. cat >>confdefs.h <<_ACEOF
  25025. #define HAVE_SQLITE3 1
  25026. _ACEOF
  25027. fi
  25028. fi
  25029. fi
  25030. if test "${PBX_SQLITE3}" != 1; then
  25031. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** Asterisk now uses SQLite3 for the internal Asterisk database." >&5
  25032. $as_echo "$as_me: WARNING: *** Asterisk now uses SQLite3 for the internal Asterisk database." >&2;}
  25033. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** Please install the SQLite3 development package." >&5
  25034. $as_echo "$as_me: WARNING: *** Please install the SQLite3 development package." >&2;}
  25035. exit 1
  25036. fi
  25037. # Find crypt support
  25038. # * -lcrypt on *NIX
  25039. # * in libsystem on OS X
  25040. if test "x${PBX_LIBCRYPT}" != "x1" -a "${USE_LIBCRYPT}" != "no"; then
  25041. pbxlibdir=""
  25042. # if --with-LIBCRYPT=DIR has been specified, use it.
  25043. if test "x${LIBCRYPT_DIR}" != "x"; then
  25044. if test -d ${LIBCRYPT_DIR}/lib; then
  25045. pbxlibdir="-L${LIBCRYPT_DIR}/lib"
  25046. else
  25047. pbxlibdir="-L${LIBCRYPT_DIR}"
  25048. fi
  25049. fi
  25050. pbxfuncname="crypt"
  25051. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  25052. AST_LIBCRYPT_FOUND=yes
  25053. else
  25054. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  25055. CFLAGS="${CFLAGS} "
  25056. as_ac_Lib=`$as_echo "ac_cv_lib_crypt_${pbxfuncname}" | $as_tr_sh`
  25057. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lcrypt" >&5
  25058. $as_echo_n "checking for ${pbxfuncname} in -lcrypt... " >&6; }
  25059. if eval \${$as_ac_Lib+:} false; then :
  25060. $as_echo_n "(cached) " >&6
  25061. else
  25062. ac_check_lib_save_LIBS=$LIBS
  25063. LIBS="-lcrypt ${pbxlibdir} $LIBS"
  25064. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25065. /* end confdefs.h. */
  25066. /* Override any GCC internal prototype to avoid an error.
  25067. Use char because int might match the return type of a GCC
  25068. builtin and then its argument prototype would still apply. */
  25069. #ifdef __cplusplus
  25070. extern "C"
  25071. #endif
  25072. char ${pbxfuncname} ();
  25073. int
  25074. main ()
  25075. {
  25076. return ${pbxfuncname} ();
  25077. ;
  25078. return 0;
  25079. }
  25080. _ACEOF
  25081. if ac_fn_c_try_link "$LINENO"; then :
  25082. eval "$as_ac_Lib=yes"
  25083. else
  25084. eval "$as_ac_Lib=no"
  25085. fi
  25086. rm -f core conftest.err conftest.$ac_objext \
  25087. conftest$ac_exeext conftest.$ac_ext
  25088. LIBS=$ac_check_lib_save_LIBS
  25089. fi
  25090. eval ac_res=\$$as_ac_Lib
  25091. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  25092. $as_echo "$ac_res" >&6; }
  25093. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  25094. AST_LIBCRYPT_FOUND=yes
  25095. else
  25096. AST_LIBCRYPT_FOUND=no
  25097. fi
  25098. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  25099. fi
  25100. # now check for the header.
  25101. if test "${AST_LIBCRYPT_FOUND}" = "yes"; then
  25102. LIBCRYPT_LIB="${pbxlibdir} -lcrypt "
  25103. # if --with-LIBCRYPT=DIR has been specified, use it.
  25104. if test "x${LIBCRYPT_DIR}" != "x"; then
  25105. LIBCRYPT_INCLUDE="-I${LIBCRYPT_DIR}/include"
  25106. fi
  25107. LIBCRYPT_INCLUDE="${LIBCRYPT_INCLUDE} "
  25108. if test "xcrypt.h" = "x" ; then # no header, assume found
  25109. LIBCRYPT_HEADER_FOUND="1"
  25110. else # check for the header
  25111. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25112. CPPFLAGS="${CPPFLAGS} ${LIBCRYPT_INCLUDE}"
  25113. ac_fn_c_check_header_mongrel "$LINENO" "crypt.h" "ac_cv_header_crypt_h" "$ac_includes_default"
  25114. if test "x$ac_cv_header_crypt_h" = xyes; then :
  25115. LIBCRYPT_HEADER_FOUND=1
  25116. else
  25117. LIBCRYPT_HEADER_FOUND=0
  25118. fi
  25119. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25120. fi
  25121. if test "x${LIBCRYPT_HEADER_FOUND}" = "x0" ; then
  25122. LIBCRYPT_LIB=""
  25123. LIBCRYPT_INCLUDE=""
  25124. else
  25125. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25126. LIBCRYPT_LIB=""
  25127. fi
  25128. PBX_LIBCRYPT=1
  25129. cat >>confdefs.h <<_ACEOF
  25130. #define HAVE_LIBCRYPT 1
  25131. _ACEOF
  25132. fi
  25133. fi
  25134. fi
  25135. ac_fn_c_check_func "$LINENO" "crypt" "ac_cv_func_crypt"
  25136. if test "x$ac_cv_func_crypt" = xyes; then :
  25137. SYSCRYPT=true
  25138. else
  25139. SYSCRYPT=""
  25140. fi
  25141. if test "x$LIBCRYPT_LIB" != "x" ; then
  25142. CRYPT_LIB="$LIBCRYPT_LIB"
  25143. CRYPT_INCLUDE="$LIBCRYPT_INCLUDE"
  25144. $as_echo "#define HAVE_CRYPT 1" >>confdefs.h
  25145. elif test "x$SYSCRYPT" != "x" ; then
  25146. CRYPT_LIB=""
  25147. CRYPT_INCLUDE=""
  25148. $as_echo "#define HAVE_CRYPT 1" >>confdefs.h
  25149. fi
  25150. # Find crypt_r support
  25151. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for crypt_r in -lcrypt" >&5
  25152. $as_echo_n "checking for crypt_r in -lcrypt... " >&6; }
  25153. if ${ac_cv_lib_crypt_crypt_r+:} false; then :
  25154. $as_echo_n "(cached) " >&6
  25155. else
  25156. ac_check_lib_save_LIBS=$LIBS
  25157. LIBS="-lcrypt $LIBS"
  25158. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25159. /* end confdefs.h. */
  25160. /* Override any GCC internal prototype to avoid an error.
  25161. Use char because int might match the return type of a GCC
  25162. builtin and then its argument prototype would still apply. */
  25163. #ifdef __cplusplus
  25164. extern "C"
  25165. #endif
  25166. char crypt_r ();
  25167. int
  25168. main ()
  25169. {
  25170. return crypt_r ();
  25171. ;
  25172. return 0;
  25173. }
  25174. _ACEOF
  25175. if ac_fn_c_try_link "$LINENO"; then :
  25176. ac_cv_lib_crypt_crypt_r=yes
  25177. else
  25178. ac_cv_lib_crypt_crypt_r=no
  25179. fi
  25180. rm -f core conftest.err conftest.$ac_objext \
  25181. conftest$ac_exeext conftest.$ac_ext
  25182. LIBS=$ac_check_lib_save_LIBS
  25183. fi
  25184. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypt_crypt_r" >&5
  25185. $as_echo "$ac_cv_lib_crypt_crypt_r" >&6; }
  25186. if test "x$ac_cv_lib_crypt_crypt_r" = xyes; then :
  25187. $as_echo "#define HAVE_CRYPT_R 1" >>confdefs.h
  25188. fi
  25189. if test "x${PBX_CRYPTO}" != "x1" -a "${USE_CRYPTO}" != "no"; then
  25190. pbxlibdir=""
  25191. # if --with-CRYPTO=DIR has been specified, use it.
  25192. if test "x${CRYPTO_DIR}" != "x"; then
  25193. if test -d ${CRYPTO_DIR}/lib; then
  25194. pbxlibdir="-L${CRYPTO_DIR}/lib"
  25195. else
  25196. pbxlibdir="-L${CRYPTO_DIR}"
  25197. fi
  25198. fi
  25199. pbxfuncname="AES_encrypt"
  25200. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  25201. AST_CRYPTO_FOUND=yes
  25202. else
  25203. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  25204. CFLAGS="${CFLAGS} "
  25205. as_ac_Lib=`$as_echo "ac_cv_lib_crypto_${pbxfuncname}" | $as_tr_sh`
  25206. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lcrypto" >&5
  25207. $as_echo_n "checking for ${pbxfuncname} in -lcrypto... " >&6; }
  25208. if eval \${$as_ac_Lib+:} false; then :
  25209. $as_echo_n "(cached) " >&6
  25210. else
  25211. ac_check_lib_save_LIBS=$LIBS
  25212. LIBS="-lcrypto ${pbxlibdir} $LIBS"
  25213. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25214. /* end confdefs.h. */
  25215. /* Override any GCC internal prototype to avoid an error.
  25216. Use char because int might match the return type of a GCC
  25217. builtin and then its argument prototype would still apply. */
  25218. #ifdef __cplusplus
  25219. extern "C"
  25220. #endif
  25221. char ${pbxfuncname} ();
  25222. int
  25223. main ()
  25224. {
  25225. return ${pbxfuncname} ();
  25226. ;
  25227. return 0;
  25228. }
  25229. _ACEOF
  25230. if ac_fn_c_try_link "$LINENO"; then :
  25231. eval "$as_ac_Lib=yes"
  25232. else
  25233. eval "$as_ac_Lib=no"
  25234. fi
  25235. rm -f core conftest.err conftest.$ac_objext \
  25236. conftest$ac_exeext conftest.$ac_ext
  25237. LIBS=$ac_check_lib_save_LIBS
  25238. fi
  25239. eval ac_res=\$$as_ac_Lib
  25240. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  25241. $as_echo "$ac_res" >&6; }
  25242. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  25243. AST_CRYPTO_FOUND=yes
  25244. else
  25245. AST_CRYPTO_FOUND=no
  25246. fi
  25247. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  25248. fi
  25249. # now check for the header.
  25250. if test "${AST_CRYPTO_FOUND}" = "yes"; then
  25251. CRYPTO_LIB="${pbxlibdir} -lcrypto "
  25252. # if --with-CRYPTO=DIR has been specified, use it.
  25253. if test "x${CRYPTO_DIR}" != "x"; then
  25254. CRYPTO_INCLUDE="-I${CRYPTO_DIR}/include"
  25255. fi
  25256. CRYPTO_INCLUDE="${CRYPTO_INCLUDE} "
  25257. if test "xopenssl/aes.h" = "x" ; then # no header, assume found
  25258. CRYPTO_HEADER_FOUND="1"
  25259. else # check for the header
  25260. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25261. CPPFLAGS="${CPPFLAGS} ${CRYPTO_INCLUDE}"
  25262. ac_fn_c_check_header_mongrel "$LINENO" "openssl/aes.h" "ac_cv_header_openssl_aes_h" "$ac_includes_default"
  25263. if test "x$ac_cv_header_openssl_aes_h" = xyes; then :
  25264. CRYPTO_HEADER_FOUND=1
  25265. else
  25266. CRYPTO_HEADER_FOUND=0
  25267. fi
  25268. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25269. fi
  25270. if test "x${CRYPTO_HEADER_FOUND}" = "x0" ; then
  25271. CRYPTO_LIB=""
  25272. CRYPTO_INCLUDE=""
  25273. else
  25274. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25275. CRYPTO_LIB=""
  25276. fi
  25277. PBX_CRYPTO=1
  25278. cat >>confdefs.h <<_ACEOF
  25279. #define HAVE_CRYPTO 1
  25280. _ACEOF
  25281. fi
  25282. fi
  25283. fi
  25284. if test "$PBX_CRYPTO" = "1";
  25285. then
  25286. if test "x${PBX_OPENSSL}" != "x1" -a "${USE_OPENSSL}" != "no"; then
  25287. pbxlibdir=""
  25288. # if --with-OPENSSL=DIR has been specified, use it.
  25289. if test "x${OPENSSL_DIR}" != "x"; then
  25290. if test -d ${OPENSSL_DIR}/lib; then
  25291. pbxlibdir="-L${OPENSSL_DIR}/lib"
  25292. else
  25293. pbxlibdir="-L${OPENSSL_DIR}"
  25294. fi
  25295. fi
  25296. pbxfuncname="SSL_connect"
  25297. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  25298. AST_OPENSSL_FOUND=yes
  25299. else
  25300. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  25301. CFLAGS="${CFLAGS} "
  25302. as_ac_Lib=`$as_echo "ac_cv_lib_ssl_${pbxfuncname}" | $as_tr_sh`
  25303. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lssl" >&5
  25304. $as_echo_n "checking for ${pbxfuncname} in -lssl... " >&6; }
  25305. if eval \${$as_ac_Lib+:} false; then :
  25306. $as_echo_n "(cached) " >&6
  25307. else
  25308. ac_check_lib_save_LIBS=$LIBS
  25309. LIBS="-lssl ${pbxlibdir} -lcrypto $LIBS"
  25310. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25311. /* end confdefs.h. */
  25312. /* Override any GCC internal prototype to avoid an error.
  25313. Use char because int might match the return type of a GCC
  25314. builtin and then its argument prototype would still apply. */
  25315. #ifdef __cplusplus
  25316. extern "C"
  25317. #endif
  25318. char ${pbxfuncname} ();
  25319. int
  25320. main ()
  25321. {
  25322. return ${pbxfuncname} ();
  25323. ;
  25324. return 0;
  25325. }
  25326. _ACEOF
  25327. if ac_fn_c_try_link "$LINENO"; then :
  25328. eval "$as_ac_Lib=yes"
  25329. else
  25330. eval "$as_ac_Lib=no"
  25331. fi
  25332. rm -f core conftest.err conftest.$ac_objext \
  25333. conftest$ac_exeext conftest.$ac_ext
  25334. LIBS=$ac_check_lib_save_LIBS
  25335. fi
  25336. eval ac_res=\$$as_ac_Lib
  25337. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  25338. $as_echo "$ac_res" >&6; }
  25339. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  25340. AST_OPENSSL_FOUND=yes
  25341. else
  25342. AST_OPENSSL_FOUND=no
  25343. fi
  25344. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  25345. fi
  25346. # now check for the header.
  25347. if test "${AST_OPENSSL_FOUND}" = "yes"; then
  25348. OPENSSL_LIB="${pbxlibdir} -lssl -lcrypto"
  25349. # if --with-OPENSSL=DIR has been specified, use it.
  25350. if test "x${OPENSSL_DIR}" != "x"; then
  25351. OPENSSL_INCLUDE="-I${OPENSSL_DIR}/include"
  25352. fi
  25353. OPENSSL_INCLUDE="${OPENSSL_INCLUDE} "
  25354. if test "xopenssl/ssl.h" = "x" ; then # no header, assume found
  25355. OPENSSL_HEADER_FOUND="1"
  25356. else # check for the header
  25357. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25358. CPPFLAGS="${CPPFLAGS} ${OPENSSL_INCLUDE}"
  25359. ac_fn_c_check_header_mongrel "$LINENO" "openssl/ssl.h" "ac_cv_header_openssl_ssl_h" "$ac_includes_default"
  25360. if test "x$ac_cv_header_openssl_ssl_h" = xyes; then :
  25361. OPENSSL_HEADER_FOUND=1
  25362. else
  25363. OPENSSL_HEADER_FOUND=0
  25364. fi
  25365. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25366. fi
  25367. if test "x${OPENSSL_HEADER_FOUND}" = "x0" ; then
  25368. OPENSSL_LIB=""
  25369. OPENSSL_INCLUDE=""
  25370. else
  25371. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25372. OPENSSL_LIB=""
  25373. fi
  25374. PBX_OPENSSL=1
  25375. cat >>confdefs.h <<_ACEOF
  25376. #define HAVE_OPENSSL 1
  25377. _ACEOF
  25378. fi
  25379. fi
  25380. fi
  25381. fi
  25382. if test "$PBX_OPENSSL" = "1";
  25383. then
  25384. # if OSPTK has not been checked and is not excluded
  25385. if test "x${PBX_OSPTK}" != "x1" -a "${USE_OSPTK}" != "no"; then
  25386. # if --with-osptk=DIR has been specified, use it.
  25387. if test "x${OSPTK_DIR}" != "x"; then
  25388. osptk_cflags="-I${OSPTK_DIR}/include"
  25389. osptk_ldflags="-L${OSPTK_DIR}/lib"
  25390. else
  25391. osptk_cflags=""
  25392. osptk_ldflags=""
  25393. fi
  25394. # check for the header
  25395. osptk_saved_cppflags="${CPPFLAGS}"
  25396. CPPFLAGS="${CPPFLAGS} ${osptk_cflags}"
  25397. ac_fn_c_check_header_mongrel "$LINENO" "osp/osp.h" "ac_cv_header_osp_osp_h" "$ac_includes_default"
  25398. if test "x$ac_cv_header_osp_osp_h" = xyes; then :
  25399. osptk_header_found=yes
  25400. else
  25401. osptk_header_found=no
  25402. fi
  25403. CPPFLAGS="${osptk_saved_cppflags}"
  25404. # check for the library
  25405. if test "${osptk_header_found}" = "yes"; then
  25406. osptk_extralibs="-lssl -lcrypto"
  25407. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OSPPInit in -losptk" >&5
  25408. $as_echo_n "checking for OSPPInit in -losptk... " >&6; }
  25409. if ${ac_cv_lib_osptk_OSPPInit+:} false; then :
  25410. $as_echo_n "(cached) " >&6
  25411. else
  25412. ac_check_lib_save_LIBS=$LIBS
  25413. LIBS="-losptk ${osptk_ldflags} ${osptk_extralibs} $LIBS"
  25414. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25415. /* end confdefs.h. */
  25416. /* Override any GCC internal prototype to avoid an error.
  25417. Use char because int might match the return type of a GCC
  25418. builtin and then its argument prototype would still apply. */
  25419. #ifdef __cplusplus
  25420. extern "C"
  25421. #endif
  25422. char OSPPInit ();
  25423. int
  25424. main ()
  25425. {
  25426. return OSPPInit ();
  25427. ;
  25428. return 0;
  25429. }
  25430. _ACEOF
  25431. if ac_fn_c_try_link "$LINENO"; then :
  25432. ac_cv_lib_osptk_OSPPInit=yes
  25433. else
  25434. ac_cv_lib_osptk_OSPPInit=no
  25435. fi
  25436. rm -f core conftest.err conftest.$ac_objext \
  25437. conftest$ac_exeext conftest.$ac_ext
  25438. LIBS=$ac_check_lib_save_LIBS
  25439. fi
  25440. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_osptk_OSPPInit" >&5
  25441. $as_echo "$ac_cv_lib_osptk_OSPPInit" >&6; }
  25442. if test "x$ac_cv_lib_osptk_OSPPInit" = xyes; then :
  25443. osptk_library_found=yes
  25444. else
  25445. osptk_library_found=no
  25446. fi
  25447. # check OSP Toolkit version
  25448. if test "${osptk_library_found}" = "yes"; then
  25449. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if OSP Toolkit version is compatible with app_osplookup" >&5
  25450. $as_echo_n "checking if OSP Toolkit version is compatible with app_osplookup... " >&6; }
  25451. osptk_saved_cppflags="${CPPFLAGS}"
  25452. CPPFLAGS="${CPPFLAGS} ${osptk_cflags}"
  25453. if test "$cross_compiling" = yes; then :
  25454. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  25455. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  25456. as_fn_error $? "cannot run test program while cross compiling
  25457. See \`config.log' for more details" "$LINENO" 5; }
  25458. else
  25459. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25460. /* end confdefs.h. */
  25461. #include <osp/osp.h>
  25462. int main(void) {
  25463. int ver = OSP_CLIENT_TOOLKIT_VERSION_MAJOR * 10000 + OSP_CLIENT_TOOLKIT_VERSION_MINOR * 100 + OSP_CLIENT_TOOLKIT_VERSION_BUGFIX;
  25464. int req = 4 * 10000 + 0 * 100 + 0;
  25465. return (ver < req) ? 1 : 0;
  25466. }
  25467. _ACEOF
  25468. if ac_fn_c_try_run "$LINENO"; then :
  25469. osptk_compatible=yes
  25470. else
  25471. osptk_compatible=no
  25472. fi
  25473. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  25474. conftest.$ac_objext conftest.beam conftest.$ac_ext
  25475. fi
  25476. CPPFLAGS="${osptk_saved_cppflags}"
  25477. if test "${osptk_compatible}" = "yes"; then
  25478. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  25479. $as_echo "yes" >&6; }
  25480. PBX_OSPTK=1
  25481. OSPTK_INCLUDE="${osptk_cflags}"
  25482. OSPTK_LIB="${osptk_ldflags} -losptk ${osptk_extralibs}"
  25483. cat >>confdefs.h <<_ACEOF
  25484. #define HAVE_OSPTK 1
  25485. _ACEOF
  25486. else
  25487. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  25488. $as_echo "no" >&6; }
  25489. fi
  25490. fi
  25491. fi
  25492. fi
  25493. if test "x${PBX_OPENSSL_SRTP}" != "x1" -a "${USE_OPENSSL_SRTP}" != "no"; then
  25494. pbxlibdir=""
  25495. # if --with-OPENSSL_SRTP=DIR has been specified, use it.
  25496. if test "x${OPENSSL_SRTP_DIR}" != "x"; then
  25497. if test -d ${OPENSSL_SRTP_DIR}/lib; then
  25498. pbxlibdir="-L${OPENSSL_SRTP_DIR}/lib"
  25499. else
  25500. pbxlibdir="-L${OPENSSL_SRTP_DIR}"
  25501. fi
  25502. fi
  25503. pbxfuncname="SSL_CTX_set_tlsext_use_srtp"
  25504. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  25505. AST_OPENSSL_SRTP_FOUND=yes
  25506. else
  25507. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  25508. CFLAGS="${CFLAGS} "
  25509. as_ac_Lib=`$as_echo "ac_cv_lib_ssl_${pbxfuncname}" | $as_tr_sh`
  25510. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lssl" >&5
  25511. $as_echo_n "checking for ${pbxfuncname} in -lssl... " >&6; }
  25512. if eval \${$as_ac_Lib+:} false; then :
  25513. $as_echo_n "(cached) " >&6
  25514. else
  25515. ac_check_lib_save_LIBS=$LIBS
  25516. LIBS="-lssl ${pbxlibdir} -lcrypto $LIBS"
  25517. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25518. /* end confdefs.h. */
  25519. /* Override any GCC internal prototype to avoid an error.
  25520. Use char because int might match the return type of a GCC
  25521. builtin and then its argument prototype would still apply. */
  25522. #ifdef __cplusplus
  25523. extern "C"
  25524. #endif
  25525. char ${pbxfuncname} ();
  25526. int
  25527. main ()
  25528. {
  25529. return ${pbxfuncname} ();
  25530. ;
  25531. return 0;
  25532. }
  25533. _ACEOF
  25534. if ac_fn_c_try_link "$LINENO"; then :
  25535. eval "$as_ac_Lib=yes"
  25536. else
  25537. eval "$as_ac_Lib=no"
  25538. fi
  25539. rm -f core conftest.err conftest.$ac_objext \
  25540. conftest$ac_exeext conftest.$ac_ext
  25541. LIBS=$ac_check_lib_save_LIBS
  25542. fi
  25543. eval ac_res=\$$as_ac_Lib
  25544. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  25545. $as_echo "$ac_res" >&6; }
  25546. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  25547. AST_OPENSSL_SRTP_FOUND=yes
  25548. else
  25549. AST_OPENSSL_SRTP_FOUND=no
  25550. fi
  25551. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  25552. fi
  25553. # now check for the header.
  25554. if test "${AST_OPENSSL_SRTP_FOUND}" = "yes"; then
  25555. OPENSSL_SRTP_LIB="${pbxlibdir} -lssl -lcrypto"
  25556. # if --with-OPENSSL_SRTP=DIR has been specified, use it.
  25557. if test "x${OPENSSL_SRTP_DIR}" != "x"; then
  25558. OPENSSL_SRTP_INCLUDE="-I${OPENSSL_SRTP_DIR}/include"
  25559. fi
  25560. OPENSSL_SRTP_INCLUDE="${OPENSSL_SRTP_INCLUDE} "
  25561. if test "xopenssl/ssl.h" = "x" ; then # no header, assume found
  25562. OPENSSL_SRTP_HEADER_FOUND="1"
  25563. else # check for the header
  25564. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25565. CPPFLAGS="${CPPFLAGS} ${OPENSSL_SRTP_INCLUDE}"
  25566. ac_fn_c_check_header_mongrel "$LINENO" "openssl/ssl.h" "ac_cv_header_openssl_ssl_h" "$ac_includes_default"
  25567. if test "x$ac_cv_header_openssl_ssl_h" = xyes; then :
  25568. OPENSSL_SRTP_HEADER_FOUND=1
  25569. else
  25570. OPENSSL_SRTP_HEADER_FOUND=0
  25571. fi
  25572. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25573. fi
  25574. if test "x${OPENSSL_SRTP_HEADER_FOUND}" = "x0" ; then
  25575. OPENSSL_SRTP_LIB=""
  25576. OPENSSL_SRTP_INCLUDE=""
  25577. else
  25578. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25579. OPENSSL_SRTP_LIB=""
  25580. fi
  25581. PBX_OPENSSL_SRTP=1
  25582. cat >>confdefs.h <<_ACEOF
  25583. #define HAVE_OPENSSL_SRTP 1
  25584. _ACEOF
  25585. fi
  25586. fi
  25587. fi
  25588. fi
  25589. if test "x${PBX_SRTP}" != "x1" -a "${USE_SRTP}" != "no"; then
  25590. pbxlibdir=""
  25591. # if --with-SRTP=DIR has been specified, use it.
  25592. if test "x${SRTP_DIR}" != "x"; then
  25593. if test -d ${SRTP_DIR}/lib; then
  25594. pbxlibdir="-L${SRTP_DIR}/lib"
  25595. else
  25596. pbxlibdir="-L${SRTP_DIR}"
  25597. fi
  25598. fi
  25599. pbxfuncname="srtp_init"
  25600. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  25601. AST_SRTP_FOUND=yes
  25602. else
  25603. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  25604. CFLAGS="${CFLAGS} "
  25605. as_ac_Lib=`$as_echo "ac_cv_lib_srtp_${pbxfuncname}" | $as_tr_sh`
  25606. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lsrtp" >&5
  25607. $as_echo_n "checking for ${pbxfuncname} in -lsrtp... " >&6; }
  25608. if eval \${$as_ac_Lib+:} false; then :
  25609. $as_echo_n "(cached) " >&6
  25610. else
  25611. ac_check_lib_save_LIBS=$LIBS
  25612. LIBS="-lsrtp ${pbxlibdir} $LIBS"
  25613. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25614. /* end confdefs.h. */
  25615. /* Override any GCC internal prototype to avoid an error.
  25616. Use char because int might match the return type of a GCC
  25617. builtin and then its argument prototype would still apply. */
  25618. #ifdef __cplusplus
  25619. extern "C"
  25620. #endif
  25621. char ${pbxfuncname} ();
  25622. int
  25623. main ()
  25624. {
  25625. return ${pbxfuncname} ();
  25626. ;
  25627. return 0;
  25628. }
  25629. _ACEOF
  25630. if ac_fn_c_try_link "$LINENO"; then :
  25631. eval "$as_ac_Lib=yes"
  25632. else
  25633. eval "$as_ac_Lib=no"
  25634. fi
  25635. rm -f core conftest.err conftest.$ac_objext \
  25636. conftest$ac_exeext conftest.$ac_ext
  25637. LIBS=$ac_check_lib_save_LIBS
  25638. fi
  25639. eval ac_res=\$$as_ac_Lib
  25640. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  25641. $as_echo "$ac_res" >&6; }
  25642. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  25643. AST_SRTP_FOUND=yes
  25644. else
  25645. AST_SRTP_FOUND=no
  25646. fi
  25647. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  25648. fi
  25649. # now check for the header.
  25650. if test "${AST_SRTP_FOUND}" = "yes"; then
  25651. SRTP_LIB="${pbxlibdir} -lsrtp "
  25652. # if --with-SRTP=DIR has been specified, use it.
  25653. if test "x${SRTP_DIR}" != "x"; then
  25654. SRTP_INCLUDE="-I${SRTP_DIR}/include"
  25655. fi
  25656. SRTP_INCLUDE="${SRTP_INCLUDE} "
  25657. if test "xsrtp/srtp.h" = "x" ; then # no header, assume found
  25658. SRTP_HEADER_FOUND="1"
  25659. else # check for the header
  25660. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25661. CPPFLAGS="${CPPFLAGS} ${SRTP_INCLUDE}"
  25662. ac_fn_c_check_header_mongrel "$LINENO" "srtp/srtp.h" "ac_cv_header_srtp_srtp_h" "$ac_includes_default"
  25663. if test "x$ac_cv_header_srtp_srtp_h" = xyes; then :
  25664. SRTP_HEADER_FOUND=1
  25665. else
  25666. SRTP_HEADER_FOUND=0
  25667. fi
  25668. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25669. fi
  25670. if test "x${SRTP_HEADER_FOUND}" = "x0" ; then
  25671. SRTP_LIB=""
  25672. SRTP_INCLUDE=""
  25673. else
  25674. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25675. SRTP_LIB=""
  25676. fi
  25677. PBX_SRTP=1
  25678. cat >>confdefs.h <<_ACEOF
  25679. #define HAVE_SRTP 1
  25680. _ACEOF
  25681. fi
  25682. fi
  25683. fi
  25684. if test "$PBX_SRTP" = "1";
  25685. then
  25686. saved_libs="${LIBS}"
  25687. saved_ldflags="${LDFLAGS}"
  25688. saved_cflags="${CFLAGS}"
  25689. LIBS="${LIBS} ${SRTP_LIB}"
  25690. LDFLAGS="${LDFLAGS} -shared -fPIC"
  25691. CFLAGS="${CFLAGS} ${SRTP_INCLUDE}"
  25692. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the ability of -lsrtp to be linked in a shared object" >&5
  25693. $as_echo_n "checking for the ability of -lsrtp to be linked in a shared object... " >&6; }
  25694. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25695. /* end confdefs.h. */
  25696. #include <srtp/srtp.h>
  25697. int
  25698. main ()
  25699. {
  25700. srtp_init();
  25701. ;
  25702. return 0;
  25703. }
  25704. _ACEOF
  25705. if ac_fn_c_try_link "$LINENO"; then :
  25706. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  25707. $as_echo "yes" >&6; }
  25708. else
  25709. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  25710. $as_echo "no" >&6; }
  25711. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ***" >&5
  25712. $as_echo "$as_me: WARNING: ***" >&2;}
  25713. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** libsrtp could not be linked as a shared object." >&5
  25714. $as_echo "$as_me: WARNING: *** libsrtp could not be linked as a shared object." >&2;}
  25715. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** Try compiling libsrtp manually. Configure libsrtp" >&5
  25716. $as_echo "$as_me: WARNING: *** Try compiling libsrtp manually. Configure libsrtp" >&2;}
  25717. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** with ./configure CFLAGS=-fPIC --prefix=/usr" >&5
  25718. $as_echo "$as_me: WARNING: *** with ./configure CFLAGS=-fPIC --prefix=/usr" >&2;}
  25719. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** replacing /usr with the prefix of your choice." >&5
  25720. $as_echo "$as_me: WARNING: *** replacing /usr with the prefix of your choice." >&2;}
  25721. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** After re-installing libsrtp" >&5
  25722. $as_echo "$as_me: WARNING: *** After re-installing libsrtp" >&2;}
  25723. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** configure script." >&5
  25724. $as_echo "$as_me: WARNING: *** configure script." >&2;}
  25725. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ***" >&5
  25726. $as_echo "$as_me: WARNING: ***" >&2;}
  25727. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** If you do not need SRTP support re-run configure" >&5
  25728. $as_echo "$as_me: WARNING: *** If you do not need SRTP support re-run configure" >&2;}
  25729. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** with the --without-srtp option." >&5
  25730. $as_echo "$as_me: WARNING: *** with the --without-srtp option." >&2;}
  25731. exit 1
  25732. fi
  25733. rm -f core conftest.err conftest.$ac_objext \
  25734. conftest$ac_exeext conftest.$ac_ext
  25735. LIBS="${saved_libs}"
  25736. LDFLAGS="${saved_ldflags}"
  25737. CFLAGS="${saved_cflags}"
  25738. fi
  25739. if test "x${PBX_SRTP_SHUTDOWN}" != "x1" -a "${USE_SRTP_SHUTDOWN}" != "no"; then
  25740. pbxlibdir=""
  25741. # if --with-SRTP_SHUTDOWN=DIR has been specified, use it.
  25742. if test "x${SRTP_SHUTDOWN_DIR}" != "x"; then
  25743. if test -d ${SRTP_SHUTDOWN_DIR}/lib; then
  25744. pbxlibdir="-L${SRTP_SHUTDOWN_DIR}/lib"
  25745. else
  25746. pbxlibdir="-L${SRTP_SHUTDOWN_DIR}"
  25747. fi
  25748. fi
  25749. pbxfuncname="srtp_shutdown"
  25750. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  25751. AST_SRTP_SHUTDOWN_FOUND=yes
  25752. else
  25753. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  25754. CFLAGS="${CFLAGS} "
  25755. as_ac_Lib=`$as_echo "ac_cv_lib_srtp_${pbxfuncname}" | $as_tr_sh`
  25756. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lsrtp" >&5
  25757. $as_echo_n "checking for ${pbxfuncname} in -lsrtp... " >&6; }
  25758. if eval \${$as_ac_Lib+:} false; then :
  25759. $as_echo_n "(cached) " >&6
  25760. else
  25761. ac_check_lib_save_LIBS=$LIBS
  25762. LIBS="-lsrtp ${pbxlibdir} $LIBS"
  25763. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25764. /* end confdefs.h. */
  25765. /* Override any GCC internal prototype to avoid an error.
  25766. Use char because int might match the return type of a GCC
  25767. builtin and then its argument prototype would still apply. */
  25768. #ifdef __cplusplus
  25769. extern "C"
  25770. #endif
  25771. char ${pbxfuncname} ();
  25772. int
  25773. main ()
  25774. {
  25775. return ${pbxfuncname} ();
  25776. ;
  25777. return 0;
  25778. }
  25779. _ACEOF
  25780. if ac_fn_c_try_link "$LINENO"; then :
  25781. eval "$as_ac_Lib=yes"
  25782. else
  25783. eval "$as_ac_Lib=no"
  25784. fi
  25785. rm -f core conftest.err conftest.$ac_objext \
  25786. conftest$ac_exeext conftest.$ac_ext
  25787. LIBS=$ac_check_lib_save_LIBS
  25788. fi
  25789. eval ac_res=\$$as_ac_Lib
  25790. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  25791. $as_echo "$ac_res" >&6; }
  25792. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  25793. AST_SRTP_SHUTDOWN_FOUND=yes
  25794. else
  25795. AST_SRTP_SHUTDOWN_FOUND=no
  25796. fi
  25797. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  25798. fi
  25799. # now check for the header.
  25800. if test "${AST_SRTP_SHUTDOWN_FOUND}" = "yes"; then
  25801. SRTP_SHUTDOWN_LIB="${pbxlibdir} -lsrtp "
  25802. # if --with-SRTP_SHUTDOWN=DIR has been specified, use it.
  25803. if test "x${SRTP_SHUTDOWN_DIR}" != "x"; then
  25804. SRTP_SHUTDOWN_INCLUDE="-I${SRTP_SHUTDOWN_DIR}/include"
  25805. fi
  25806. SRTP_SHUTDOWN_INCLUDE="${SRTP_SHUTDOWN_INCLUDE} "
  25807. if test "xsrtp/srtp.h" = "x" ; then # no header, assume found
  25808. SRTP_SHUTDOWN_HEADER_FOUND="1"
  25809. else # check for the header
  25810. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25811. CPPFLAGS="${CPPFLAGS} ${SRTP_SHUTDOWN_INCLUDE}"
  25812. ac_fn_c_check_header_mongrel "$LINENO" "srtp/srtp.h" "ac_cv_header_srtp_srtp_h" "$ac_includes_default"
  25813. if test "x$ac_cv_header_srtp_srtp_h" = xyes; then :
  25814. SRTP_SHUTDOWN_HEADER_FOUND=1
  25815. else
  25816. SRTP_SHUTDOWN_HEADER_FOUND=0
  25817. fi
  25818. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25819. fi
  25820. if test "x${SRTP_SHUTDOWN_HEADER_FOUND}" = "x0" ; then
  25821. SRTP_SHUTDOWN_LIB=""
  25822. SRTP_SHUTDOWN_INCLUDE=""
  25823. else
  25824. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25825. SRTP_SHUTDOWN_LIB=""
  25826. fi
  25827. PBX_SRTP_SHUTDOWN=1
  25828. cat >>confdefs.h <<_ACEOF
  25829. #define HAVE_SRTP_SHUTDOWN 1
  25830. _ACEOF
  25831. fi
  25832. fi
  25833. fi
  25834. for ver in 2.0 2.2 2.4 2.6; do
  25835. if test "x${PBX_GMIME}" != "x1" -a "${USE_GMIME}" != "no"; then
  25836. pkg_failed=no
  25837. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GMIME" >&5
  25838. $as_echo_n "checking for GMIME... " >&6; }
  25839. if test -n "$GMIME_CFLAGS"; then
  25840. pkg_cv_GMIME_CFLAGS="$GMIME_CFLAGS"
  25841. elif test -n "$PKG_CONFIG"; then
  25842. if test -n "$PKG_CONFIG" && \
  25843. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gmime-\$ver\""; } >&5
  25844. ($PKG_CONFIG --exists --print-errors "gmime-$ver") 2>&5
  25845. ac_status=$?
  25846. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  25847. test $ac_status = 0; }; then
  25848. pkg_cv_GMIME_CFLAGS=`$PKG_CONFIG --cflags "gmime-$ver" 2>/dev/null`
  25849. test "x$?" != "x0" && pkg_failed=yes
  25850. else
  25851. pkg_failed=yes
  25852. fi
  25853. else
  25854. pkg_failed=untried
  25855. fi
  25856. if test -n "$GMIME_LIBS"; then
  25857. pkg_cv_GMIME_LIBS="$GMIME_LIBS"
  25858. elif test -n "$PKG_CONFIG"; then
  25859. if test -n "$PKG_CONFIG" && \
  25860. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gmime-\$ver\""; } >&5
  25861. ($PKG_CONFIG --exists --print-errors "gmime-$ver") 2>&5
  25862. ac_status=$?
  25863. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  25864. test $ac_status = 0; }; then
  25865. pkg_cv_GMIME_LIBS=`$PKG_CONFIG --libs "gmime-$ver" 2>/dev/null`
  25866. test "x$?" != "x0" && pkg_failed=yes
  25867. else
  25868. pkg_failed=yes
  25869. fi
  25870. else
  25871. pkg_failed=untried
  25872. fi
  25873. if test $pkg_failed = yes; then
  25874. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  25875. $as_echo "no" >&6; }
  25876. if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
  25877. _pkg_short_errors_supported=yes
  25878. else
  25879. _pkg_short_errors_supported=no
  25880. fi
  25881. if test $_pkg_short_errors_supported = yes; then
  25882. GMIME_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gmime-$ver" 2>&1`
  25883. else
  25884. GMIME_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gmime-$ver" 2>&1`
  25885. fi
  25886. # Put the nasty error message in config.log where it belongs
  25887. echo "$GMIME_PKG_ERRORS" >&5
  25888. PBX_GMIME=0
  25889. elif test $pkg_failed = untried; then
  25890. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  25891. $as_echo "no" >&6; }
  25892. PBX_GMIME=0
  25893. else
  25894. GMIME_CFLAGS=$pkg_cv_GMIME_CFLAGS
  25895. GMIME_LIBS=$pkg_cv_GMIME_LIBS
  25896. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  25897. $as_echo "yes" >&6; }
  25898. PBX_GMIME=1
  25899. GMIME_INCLUDE="$GMIME_CFLAGS"
  25900. GMIME_LIB="$GMIME_LIBS"
  25901. $as_echo "#define HAVE_GMIME 1" >>confdefs.h
  25902. fi
  25903. fi
  25904. if test "$PBX_GMIME" = 1; then
  25905. break;
  25906. fi
  25907. done
  25908. if test "x${PBX_HOARD}" != "x1" -a "${USE_HOARD}" != "no"; then
  25909. pbxlibdir=""
  25910. # if --with-HOARD=DIR has been specified, use it.
  25911. if test "x${HOARD_DIR}" != "x"; then
  25912. if test -d ${HOARD_DIR}/lib; then
  25913. pbxlibdir="-L${HOARD_DIR}/lib"
  25914. else
  25915. pbxlibdir="-L${HOARD_DIR}"
  25916. fi
  25917. fi
  25918. pbxfuncname="malloc"
  25919. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  25920. AST_HOARD_FOUND=yes
  25921. else
  25922. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  25923. CFLAGS="${CFLAGS} "
  25924. as_ac_Lib=`$as_echo "ac_cv_lib_hoard_${pbxfuncname}" | $as_tr_sh`
  25925. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lhoard" >&5
  25926. $as_echo_n "checking for ${pbxfuncname} in -lhoard... " >&6; }
  25927. if eval \${$as_ac_Lib+:} false; then :
  25928. $as_echo_n "(cached) " >&6
  25929. else
  25930. ac_check_lib_save_LIBS=$LIBS
  25931. LIBS="-lhoard ${pbxlibdir} $LIBS"
  25932. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25933. /* end confdefs.h. */
  25934. /* Override any GCC internal prototype to avoid an error.
  25935. Use char because int might match the return type of a GCC
  25936. builtin and then its argument prototype would still apply. */
  25937. #ifdef __cplusplus
  25938. extern "C"
  25939. #endif
  25940. char ${pbxfuncname} ();
  25941. int
  25942. main ()
  25943. {
  25944. return ${pbxfuncname} ();
  25945. ;
  25946. return 0;
  25947. }
  25948. _ACEOF
  25949. if ac_fn_c_try_link "$LINENO"; then :
  25950. eval "$as_ac_Lib=yes"
  25951. else
  25952. eval "$as_ac_Lib=no"
  25953. fi
  25954. rm -f core conftest.err conftest.$ac_objext \
  25955. conftest$ac_exeext conftest.$ac_ext
  25956. LIBS=$ac_check_lib_save_LIBS
  25957. fi
  25958. eval ac_res=\$$as_ac_Lib
  25959. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  25960. $as_echo "$ac_res" >&6; }
  25961. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  25962. AST_HOARD_FOUND=yes
  25963. else
  25964. AST_HOARD_FOUND=no
  25965. fi
  25966. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  25967. fi
  25968. # now check for the header.
  25969. if test "${AST_HOARD_FOUND}" = "yes"; then
  25970. HOARD_LIB="${pbxlibdir} -lhoard "
  25971. # if --with-HOARD=DIR has been specified, use it.
  25972. if test "x${HOARD_DIR}" != "x"; then
  25973. HOARD_INCLUDE="-I${HOARD_DIR}/include"
  25974. fi
  25975. HOARD_INCLUDE="${HOARD_INCLUDE} "
  25976. if test "x" = "x" ; then # no header, assume found
  25977. HOARD_HEADER_FOUND="1"
  25978. else # check for the header
  25979. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25980. CPPFLAGS="${CPPFLAGS} ${HOARD_INCLUDE}"
  25981. ac_fn_c_check_header_mongrel "$LINENO" "" "ac_cv_header_" "$ac_includes_default"
  25982. if test "x$ac_cv_header_" = xyes; then :
  25983. HOARD_HEADER_FOUND=1
  25984. else
  25985. HOARD_HEADER_FOUND=0
  25986. fi
  25987. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25988. fi
  25989. if test "x${HOARD_HEADER_FOUND}" = "x0" ; then
  25990. HOARD_LIB=""
  25991. HOARD_INCLUDE=""
  25992. else
  25993. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25994. HOARD_LIB=""
  25995. fi
  25996. PBX_HOARD=1
  25997. cat >>confdefs.h <<_ACEOF
  25998. #define HAVE_HOARD 1
  25999. _ACEOF
  26000. fi
  26001. fi
  26002. fi
  26003. if test "x${PBX_FREETDS}" != "x1" -a "${USE_FREETDS}" != "no"; then
  26004. pbxlibdir=""
  26005. # if --with-FREETDS=DIR has been specified, use it.
  26006. if test "x${FREETDS_DIR}" != "x"; then
  26007. if test -d ${FREETDS_DIR}/lib; then
  26008. pbxlibdir="-L${FREETDS_DIR}/lib"
  26009. else
  26010. pbxlibdir="-L${FREETDS_DIR}"
  26011. fi
  26012. fi
  26013. pbxfuncname="dbinit"
  26014. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  26015. AST_FREETDS_FOUND=yes
  26016. else
  26017. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  26018. CFLAGS="${CFLAGS} "
  26019. as_ac_Lib=`$as_echo "ac_cv_lib_sybdb_${pbxfuncname}" | $as_tr_sh`
  26020. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lsybdb" >&5
  26021. $as_echo_n "checking for ${pbxfuncname} in -lsybdb... " >&6; }
  26022. if eval \${$as_ac_Lib+:} false; then :
  26023. $as_echo_n "(cached) " >&6
  26024. else
  26025. ac_check_lib_save_LIBS=$LIBS
  26026. LIBS="-lsybdb ${pbxlibdir} $LIBS"
  26027. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26028. /* end confdefs.h. */
  26029. /* Override any GCC internal prototype to avoid an error.
  26030. Use char because int might match the return type of a GCC
  26031. builtin and then its argument prototype would still apply. */
  26032. #ifdef __cplusplus
  26033. extern "C"
  26034. #endif
  26035. char ${pbxfuncname} ();
  26036. int
  26037. main ()
  26038. {
  26039. return ${pbxfuncname} ();
  26040. ;
  26041. return 0;
  26042. }
  26043. _ACEOF
  26044. if ac_fn_c_try_link "$LINENO"; then :
  26045. eval "$as_ac_Lib=yes"
  26046. else
  26047. eval "$as_ac_Lib=no"
  26048. fi
  26049. rm -f core conftest.err conftest.$ac_objext \
  26050. conftest$ac_exeext conftest.$ac_ext
  26051. LIBS=$ac_check_lib_save_LIBS
  26052. fi
  26053. eval ac_res=\$$as_ac_Lib
  26054. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  26055. $as_echo "$ac_res" >&6; }
  26056. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  26057. AST_FREETDS_FOUND=yes
  26058. else
  26059. AST_FREETDS_FOUND=no
  26060. fi
  26061. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  26062. fi
  26063. # now check for the header.
  26064. if test "${AST_FREETDS_FOUND}" = "yes"; then
  26065. FREETDS_LIB="${pbxlibdir} -lsybdb "
  26066. # if --with-FREETDS=DIR has been specified, use it.
  26067. if test "x${FREETDS_DIR}" != "x"; then
  26068. FREETDS_INCLUDE="-I${FREETDS_DIR}/include"
  26069. fi
  26070. FREETDS_INCLUDE="${FREETDS_INCLUDE} "
  26071. if test "xsybdb.h" = "x" ; then # no header, assume found
  26072. FREETDS_HEADER_FOUND="1"
  26073. else # check for the header
  26074. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  26075. CPPFLAGS="${CPPFLAGS} ${FREETDS_INCLUDE}"
  26076. ac_fn_c_check_header_mongrel "$LINENO" "sybdb.h" "ac_cv_header_sybdb_h" "$ac_includes_default"
  26077. if test "x$ac_cv_header_sybdb_h" = xyes; then :
  26078. FREETDS_HEADER_FOUND=1
  26079. else
  26080. FREETDS_HEADER_FOUND=0
  26081. fi
  26082. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  26083. fi
  26084. if test "x${FREETDS_HEADER_FOUND}" = "x0" ; then
  26085. FREETDS_LIB=""
  26086. FREETDS_INCLUDE=""
  26087. else
  26088. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  26089. FREETDS_LIB=""
  26090. fi
  26091. PBX_FREETDS=1
  26092. cat >>confdefs.h <<_ACEOF
  26093. #define HAVE_FREETDS 1
  26094. _ACEOF
  26095. fi
  26096. fi
  26097. fi
  26098. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tone_zone_find_by_num in -ltonezone" >&5
  26099. $as_echo_n "checking for tone_zone_find_by_num in -ltonezone... " >&6; }
  26100. if ${ac_cv_lib_tonezone_tone_zone_find_by_num+:} false; then :
  26101. $as_echo_n "(cached) " >&6
  26102. else
  26103. ac_check_lib_save_LIBS=$LIBS
  26104. LIBS="-ltonezone $LIBS"
  26105. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26106. /* end confdefs.h. */
  26107. /* Override any GCC internal prototype to avoid an error.
  26108. Use char because int might match the return type of a GCC
  26109. builtin and then its argument prototype would still apply. */
  26110. #ifdef __cplusplus
  26111. extern "C"
  26112. #endif
  26113. char tone_zone_find_by_num ();
  26114. int
  26115. main ()
  26116. {
  26117. return tone_zone_find_by_num ();
  26118. ;
  26119. return 0;
  26120. }
  26121. _ACEOF
  26122. if ac_fn_c_try_link "$LINENO"; then :
  26123. ac_cv_lib_tonezone_tone_zone_find_by_num=yes
  26124. else
  26125. ac_cv_lib_tonezone_tone_zone_find_by_num=no
  26126. fi
  26127. rm -f core conftest.err conftest.$ac_objext \
  26128. conftest$ac_exeext conftest.$ac_ext
  26129. LIBS=$ac_check_lib_save_LIBS
  26130. fi
  26131. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tonezone_tone_zone_find_by_num" >&5
  26132. $as_echo "$ac_cv_lib_tonezone_tone_zone_find_by_num" >&6; }
  26133. if test "x$ac_cv_lib_tonezone_tone_zone_find_by_num" = xyes; then :
  26134. tonezone_does_not_need_lm=yes
  26135. else
  26136. tonezone_does_not_need_lm=no
  26137. fi
  26138. if test "${tonezone_does_not_need_lm}" = "no" ; then
  26139. tonezone_extra="-lm"
  26140. fi
  26141. if test "x${PBX_TONEZONE}" != "x1" -a "${USE_TONEZONE}" != "no"; then
  26142. pbxlibdir=""
  26143. # if --with-TONEZONE=DIR has been specified, use it.
  26144. if test "x${TONEZONE_DIR}" != "x"; then
  26145. if test -d ${TONEZONE_DIR}/lib; then
  26146. pbxlibdir="-L${TONEZONE_DIR}/lib"
  26147. else
  26148. pbxlibdir="-L${TONEZONE_DIR}"
  26149. fi
  26150. fi
  26151. pbxfuncname="tone_zone_find"
  26152. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  26153. AST_TONEZONE_FOUND=yes
  26154. else
  26155. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  26156. CFLAGS="${CFLAGS} "
  26157. as_ac_Lib=`$as_echo "ac_cv_lib_tonezone_${pbxfuncname}" | $as_tr_sh`
  26158. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -ltonezone" >&5
  26159. $as_echo_n "checking for ${pbxfuncname} in -ltonezone... " >&6; }
  26160. if eval \${$as_ac_Lib+:} false; then :
  26161. $as_echo_n "(cached) " >&6
  26162. else
  26163. ac_check_lib_save_LIBS=$LIBS
  26164. LIBS="-ltonezone ${pbxlibdir} ${tonezone_extra} ${DAHDI_INCLUDE} $LIBS"
  26165. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26166. /* end confdefs.h. */
  26167. /* Override any GCC internal prototype to avoid an error.
  26168. Use char because int might match the return type of a GCC
  26169. builtin and then its argument prototype would still apply. */
  26170. #ifdef __cplusplus
  26171. extern "C"
  26172. #endif
  26173. char ${pbxfuncname} ();
  26174. int
  26175. main ()
  26176. {
  26177. return ${pbxfuncname} ();
  26178. ;
  26179. return 0;
  26180. }
  26181. _ACEOF
  26182. if ac_fn_c_try_link "$LINENO"; then :
  26183. eval "$as_ac_Lib=yes"
  26184. else
  26185. eval "$as_ac_Lib=no"
  26186. fi
  26187. rm -f core conftest.err conftest.$ac_objext \
  26188. conftest$ac_exeext conftest.$ac_ext
  26189. LIBS=$ac_check_lib_save_LIBS
  26190. fi
  26191. eval ac_res=\$$as_ac_Lib
  26192. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  26193. $as_echo "$ac_res" >&6; }
  26194. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  26195. AST_TONEZONE_FOUND=yes
  26196. else
  26197. AST_TONEZONE_FOUND=no
  26198. fi
  26199. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  26200. fi
  26201. # now check for the header.
  26202. if test "${AST_TONEZONE_FOUND}" = "yes"; then
  26203. TONEZONE_LIB="${pbxlibdir} -ltonezone ${tonezone_extra} ${DAHDI_INCLUDE}"
  26204. # if --with-TONEZONE=DIR has been specified, use it.
  26205. if test "x${TONEZONE_DIR}" != "x"; then
  26206. TONEZONE_INCLUDE="-I${TONEZONE_DIR}/include"
  26207. fi
  26208. TONEZONE_INCLUDE="${TONEZONE_INCLUDE} "
  26209. if test "xdahdi/tonezone.h" = "x" ; then # no header, assume found
  26210. TONEZONE_HEADER_FOUND="1"
  26211. else # check for the header
  26212. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  26213. CPPFLAGS="${CPPFLAGS} ${TONEZONE_INCLUDE}"
  26214. ac_fn_c_check_header_mongrel "$LINENO" "dahdi/tonezone.h" "ac_cv_header_dahdi_tonezone_h" "$ac_includes_default"
  26215. if test "x$ac_cv_header_dahdi_tonezone_h" = xyes; then :
  26216. TONEZONE_HEADER_FOUND=1
  26217. else
  26218. TONEZONE_HEADER_FOUND=0
  26219. fi
  26220. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  26221. fi
  26222. if test "x${TONEZONE_HEADER_FOUND}" = "x0" ; then
  26223. TONEZONE_LIB=""
  26224. TONEZONE_INCLUDE=""
  26225. else
  26226. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  26227. TONEZONE_LIB=""
  26228. fi
  26229. PBX_TONEZONE=1
  26230. cat >>confdefs.h <<_ACEOF
  26231. #define HAVE_TONEZONE 1
  26232. _ACEOF
  26233. fi
  26234. fi
  26235. fi
  26236. if test "${OSARCH}" = "OpenBSD";
  26237. then
  26238. if test "x${PBX_VORBIS}" != "x1" -a "${USE_VORBIS}" != "no"; then
  26239. pbxlibdir=""
  26240. # if --with-VORBIS=DIR has been specified, use it.
  26241. if test "x${VORBIS_DIR}" != "x"; then
  26242. if test -d ${VORBIS_DIR}/lib; then
  26243. pbxlibdir="-L${VORBIS_DIR}/lib"
  26244. else
  26245. pbxlibdir="-L${VORBIS_DIR}"
  26246. fi
  26247. fi
  26248. pbxfuncname="vorbis_info_init"
  26249. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  26250. AST_VORBIS_FOUND=yes
  26251. else
  26252. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  26253. CFLAGS="${CFLAGS} "
  26254. as_ac_Lib=`$as_echo "ac_cv_lib_vorbis_${pbxfuncname}" | $as_tr_sh`
  26255. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lvorbis" >&5
  26256. $as_echo_n "checking for ${pbxfuncname} in -lvorbis... " >&6; }
  26257. if eval \${$as_ac_Lib+:} false; then :
  26258. $as_echo_n "(cached) " >&6
  26259. else
  26260. ac_check_lib_save_LIBS=$LIBS
  26261. LIBS="-lvorbis ${pbxlibdir} -lm -lvorbisenc -lvorbisfile -logg $LIBS"
  26262. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26263. /* end confdefs.h. */
  26264. /* Override any GCC internal prototype to avoid an error.
  26265. Use char because int might match the return type of a GCC
  26266. builtin and then its argument prototype would still apply. */
  26267. #ifdef __cplusplus
  26268. extern "C"
  26269. #endif
  26270. char ${pbxfuncname} ();
  26271. int
  26272. main ()
  26273. {
  26274. return ${pbxfuncname} ();
  26275. ;
  26276. return 0;
  26277. }
  26278. _ACEOF
  26279. if ac_fn_c_try_link "$LINENO"; then :
  26280. eval "$as_ac_Lib=yes"
  26281. else
  26282. eval "$as_ac_Lib=no"
  26283. fi
  26284. rm -f core conftest.err conftest.$ac_objext \
  26285. conftest$ac_exeext conftest.$ac_ext
  26286. LIBS=$ac_check_lib_save_LIBS
  26287. fi
  26288. eval ac_res=\$$as_ac_Lib
  26289. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  26290. $as_echo "$ac_res" >&6; }
  26291. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  26292. AST_VORBIS_FOUND=yes
  26293. else
  26294. AST_VORBIS_FOUND=no
  26295. fi
  26296. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  26297. fi
  26298. # now check for the header.
  26299. if test "${AST_VORBIS_FOUND}" = "yes"; then
  26300. VORBIS_LIB="${pbxlibdir} -lvorbis -lm -lvorbisenc -lvorbisfile -logg"
  26301. # if --with-VORBIS=DIR has been specified, use it.
  26302. if test "x${VORBIS_DIR}" != "x"; then
  26303. VORBIS_INCLUDE="-I${VORBIS_DIR}/include"
  26304. fi
  26305. VORBIS_INCLUDE="${VORBIS_INCLUDE} "
  26306. if test "xvorbis/codec.h" = "x" ; then # no header, assume found
  26307. VORBIS_HEADER_FOUND="1"
  26308. else # check for the header
  26309. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  26310. CPPFLAGS="${CPPFLAGS} ${VORBIS_INCLUDE}"
  26311. ac_fn_c_check_header_mongrel "$LINENO" "vorbis/codec.h" "ac_cv_header_vorbis_codec_h" "$ac_includes_default"
  26312. if test "x$ac_cv_header_vorbis_codec_h" = xyes; then :
  26313. VORBIS_HEADER_FOUND=1
  26314. else
  26315. VORBIS_HEADER_FOUND=0
  26316. fi
  26317. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  26318. fi
  26319. if test "x${VORBIS_HEADER_FOUND}" = "x0" ; then
  26320. VORBIS_LIB=""
  26321. VORBIS_INCLUDE=""
  26322. else
  26323. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  26324. VORBIS_LIB=""
  26325. fi
  26326. PBX_VORBIS=1
  26327. cat >>confdefs.h <<_ACEOF
  26328. #define HAVE_VORBIS 1
  26329. _ACEOF
  26330. fi
  26331. fi
  26332. fi
  26333. else
  26334. if test "x${PBX_VORBIS}" != "x1" -a "${USE_VORBIS}" != "no"; then
  26335. pbxlibdir=""
  26336. # if --with-VORBIS=DIR has been specified, use it.
  26337. if test "x${VORBIS_DIR}" != "x"; then
  26338. if test -d ${VORBIS_DIR}/lib; then
  26339. pbxlibdir="-L${VORBIS_DIR}/lib"
  26340. else
  26341. pbxlibdir="-L${VORBIS_DIR}"
  26342. fi
  26343. fi
  26344. pbxfuncname="vorbis_info_init"
  26345. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  26346. AST_VORBIS_FOUND=yes
  26347. else
  26348. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  26349. CFLAGS="${CFLAGS} "
  26350. as_ac_Lib=`$as_echo "ac_cv_lib_vorbis_${pbxfuncname}" | $as_tr_sh`
  26351. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lvorbis" >&5
  26352. $as_echo_n "checking for ${pbxfuncname} in -lvorbis... " >&6; }
  26353. if eval \${$as_ac_Lib+:} false; then :
  26354. $as_echo_n "(cached) " >&6
  26355. else
  26356. ac_check_lib_save_LIBS=$LIBS
  26357. LIBS="-lvorbis ${pbxlibdir} -lm -lvorbisenc -lvorbisfile $LIBS"
  26358. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26359. /* end confdefs.h. */
  26360. /* Override any GCC internal prototype to avoid an error.
  26361. Use char because int might match the return type of a GCC
  26362. builtin and then its argument prototype would still apply. */
  26363. #ifdef __cplusplus
  26364. extern "C"
  26365. #endif
  26366. char ${pbxfuncname} ();
  26367. int
  26368. main ()
  26369. {
  26370. return ${pbxfuncname} ();
  26371. ;
  26372. return 0;
  26373. }
  26374. _ACEOF
  26375. if ac_fn_c_try_link "$LINENO"; then :
  26376. eval "$as_ac_Lib=yes"
  26377. else
  26378. eval "$as_ac_Lib=no"
  26379. fi
  26380. rm -f core conftest.err conftest.$ac_objext \
  26381. conftest$ac_exeext conftest.$ac_ext
  26382. LIBS=$ac_check_lib_save_LIBS
  26383. fi
  26384. eval ac_res=\$$as_ac_Lib
  26385. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  26386. $as_echo "$ac_res" >&6; }
  26387. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  26388. AST_VORBIS_FOUND=yes
  26389. else
  26390. AST_VORBIS_FOUND=no
  26391. fi
  26392. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  26393. fi
  26394. # now check for the header.
  26395. if test "${AST_VORBIS_FOUND}" = "yes"; then
  26396. VORBIS_LIB="${pbxlibdir} -lvorbis -lm -lvorbisenc -lvorbisfile"
  26397. # if --with-VORBIS=DIR has been specified, use it.
  26398. if test "x${VORBIS_DIR}" != "x"; then
  26399. VORBIS_INCLUDE="-I${VORBIS_DIR}/include"
  26400. fi
  26401. VORBIS_INCLUDE="${VORBIS_INCLUDE} "
  26402. if test "xvorbis/codec.h" = "x" ; then # no header, assume found
  26403. VORBIS_HEADER_FOUND="1"
  26404. else # check for the header
  26405. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  26406. CPPFLAGS="${CPPFLAGS} ${VORBIS_INCLUDE}"
  26407. ac_fn_c_check_header_mongrel "$LINENO" "vorbis/codec.h" "ac_cv_header_vorbis_codec_h" "$ac_includes_default"
  26408. if test "x$ac_cv_header_vorbis_codec_h" = xyes; then :
  26409. VORBIS_HEADER_FOUND=1
  26410. else
  26411. VORBIS_HEADER_FOUND=0
  26412. fi
  26413. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  26414. fi
  26415. if test "x${VORBIS_HEADER_FOUND}" = "x0" ; then
  26416. VORBIS_LIB=""
  26417. VORBIS_INCLUDE=""
  26418. else
  26419. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  26420. VORBIS_LIB=""
  26421. fi
  26422. PBX_VORBIS=1
  26423. cat >>confdefs.h <<_ACEOF
  26424. #define HAVE_VORBIS 1
  26425. _ACEOF
  26426. fi
  26427. fi
  26428. fi
  26429. fi
  26430. if test "x${PBX_VORBIS_OPEN_CALLBACKS}" != "x1" -a "${USE_VORBIS_OPEN_CALLBACKS}" != "no"; then
  26431. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OV_CALLBACKS_NOCLOSE declared in vorbis/vorbisfile.h" >&5
  26432. $as_echo_n "checking for OV_CALLBACKS_NOCLOSE declared in vorbis/vorbisfile.h... " >&6; }
  26433. saved_cppflags="${CPPFLAGS}"
  26434. if test "x${VORBIS_OPEN_CALLBACKS_DIR}" != "x"; then
  26435. VORBIS_OPEN_CALLBACKS_INCLUDE="-I${VORBIS_OPEN_CALLBACKS_DIR}/include"
  26436. fi
  26437. CPPFLAGS="${CPPFLAGS} ${VORBIS_OPEN_CALLBACKS_INCLUDE}"
  26438. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26439. /* end confdefs.h. */
  26440. #include <vorbis/vorbisfile.h>
  26441. int
  26442. main ()
  26443. {
  26444. #if !defined(OV_CALLBACKS_NOCLOSE)
  26445. (void) OV_CALLBACKS_NOCLOSE;
  26446. #endif
  26447. ;
  26448. return 0;
  26449. }
  26450. _ACEOF
  26451. if ac_fn_c_try_compile "$LINENO"; then :
  26452. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  26453. $as_echo "yes" >&6; }
  26454. PBX_VORBIS_OPEN_CALLBACKS=1
  26455. $as_echo "#define HAVE_VORBIS_OPEN_CALLBACKS 1" >>confdefs.h
  26456. else
  26457. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  26458. $as_echo "no" >&6; }
  26459. fi
  26460. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  26461. CPPFLAGS="${saved_cppflags}"
  26462. fi
  26463. ac_ext=cpp
  26464. ac_cpp='$CXXCPP $CPPFLAGS'
  26465. ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  26466. ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  26467. ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
  26468. if test "${USE_VPB}" != "no"; then
  26469. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for vpb_open in -lvpb" >&5
  26470. $as_echo_n "checking for vpb_open in -lvpb... " >&6; }
  26471. saved_libs="${LIBS}"
  26472. saved_cppflags="${CPPFLAGS}"
  26473. if test "x${VPB_DIR}" != "x"; then
  26474. if test -d ${VPB_DIR}/lib; then
  26475. vpblibdir=${VPB_DIR}/lib
  26476. else
  26477. vpblibdir=${VPB_DIR}
  26478. fi
  26479. LIBS="${LIBS} -L${vpblibdir}"
  26480. CPPFLAGS="${CPPFLAGS} -I${VPB_DIR}/include"
  26481. fi
  26482. LIBS="${PTHREAD_LIBS} ${LIBS} -lvpb"
  26483. CPPFLAGS="${CPPFLAGS} ${PTHREAD_CFLAGS}"
  26484. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26485. /* end confdefs.h. */
  26486. #include <vpbapi.h>
  26487. int
  26488. main ()
  26489. {
  26490. int q = vpb_open(0,0);
  26491. ;
  26492. return 0;
  26493. }
  26494. _ACEOF
  26495. if ac_fn_cxx_try_link "$LINENO"; then :
  26496. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  26497. $as_echo "yes" >&6; }
  26498. ac_cv_lib_vpb_vpb_open="yes"
  26499. else
  26500. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  26501. $as_echo "no" >&6; }
  26502. ac_cv_lib_vpb_vpb_open="no"
  26503. fi
  26504. rm -f core conftest.err conftest.$ac_objext \
  26505. conftest$ac_exeext conftest.$ac_ext
  26506. LIBS="${saved_libs}"
  26507. CPPFLAGS="${saved_cppflags}"
  26508. if test "${ac_cv_lib_vpb_vpb_open}" = "yes"; then
  26509. VPB_LIB="-lvpb"
  26510. if test "${VPB_DIR}" != ""; then
  26511. VPB_LIB="-L${vpblibdir} ${VPB_LIB}"
  26512. VPB_INCLUDE="-I${VPB_DIR}/include"
  26513. fi
  26514. PBX_VPB=1
  26515. $as_echo "#define HAVE_VPB 1" >>confdefs.h
  26516. fi
  26517. fi
  26518. ac_ext=c
  26519. ac_cpp='$CPP $CPPFLAGS'
  26520. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  26521. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  26522. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  26523. if test "x${PBX_ZLIB}" != "x1" -a "${USE_ZLIB}" != "no"; then
  26524. pbxlibdir=""
  26525. # if --with-ZLIB=DIR has been specified, use it.
  26526. if test "x${ZLIB_DIR}" != "x"; then
  26527. if test -d ${ZLIB_DIR}/lib; then
  26528. pbxlibdir="-L${ZLIB_DIR}/lib"
  26529. else
  26530. pbxlibdir="-L${ZLIB_DIR}"
  26531. fi
  26532. fi
  26533. pbxfuncname="compress"
  26534. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  26535. AST_ZLIB_FOUND=yes
  26536. else
  26537. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  26538. CFLAGS="${CFLAGS} "
  26539. as_ac_Lib=`$as_echo "ac_cv_lib_z_${pbxfuncname}" | $as_tr_sh`
  26540. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lz" >&5
  26541. $as_echo_n "checking for ${pbxfuncname} in -lz... " >&6; }
  26542. if eval \${$as_ac_Lib+:} false; then :
  26543. $as_echo_n "(cached) " >&6
  26544. else
  26545. ac_check_lib_save_LIBS=$LIBS
  26546. LIBS="-lz ${pbxlibdir} $LIBS"
  26547. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26548. /* end confdefs.h. */
  26549. /* Override any GCC internal prototype to avoid an error.
  26550. Use char because int might match the return type of a GCC
  26551. builtin and then its argument prototype would still apply. */
  26552. #ifdef __cplusplus
  26553. extern "C"
  26554. #endif
  26555. char ${pbxfuncname} ();
  26556. int
  26557. main ()
  26558. {
  26559. return ${pbxfuncname} ();
  26560. ;
  26561. return 0;
  26562. }
  26563. _ACEOF
  26564. if ac_fn_c_try_link "$LINENO"; then :
  26565. eval "$as_ac_Lib=yes"
  26566. else
  26567. eval "$as_ac_Lib=no"
  26568. fi
  26569. rm -f core conftest.err conftest.$ac_objext \
  26570. conftest$ac_exeext conftest.$ac_ext
  26571. LIBS=$ac_check_lib_save_LIBS
  26572. fi
  26573. eval ac_res=\$$as_ac_Lib
  26574. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  26575. $as_echo "$ac_res" >&6; }
  26576. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  26577. AST_ZLIB_FOUND=yes
  26578. else
  26579. AST_ZLIB_FOUND=no
  26580. fi
  26581. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  26582. fi
  26583. # now check for the header.
  26584. if test "${AST_ZLIB_FOUND}" = "yes"; then
  26585. ZLIB_LIB="${pbxlibdir} -lz "
  26586. # if --with-ZLIB=DIR has been specified, use it.
  26587. if test "x${ZLIB_DIR}" != "x"; then
  26588. ZLIB_INCLUDE="-I${ZLIB_DIR}/include"
  26589. fi
  26590. ZLIB_INCLUDE="${ZLIB_INCLUDE} "
  26591. if test "xzlib.h" = "x" ; then # no header, assume found
  26592. ZLIB_HEADER_FOUND="1"
  26593. else # check for the header
  26594. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  26595. CPPFLAGS="${CPPFLAGS} ${ZLIB_INCLUDE}"
  26596. ac_fn_c_check_header_mongrel "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default"
  26597. if test "x$ac_cv_header_zlib_h" = xyes; then :
  26598. ZLIB_HEADER_FOUND=1
  26599. else
  26600. ZLIB_HEADER_FOUND=0
  26601. fi
  26602. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  26603. fi
  26604. if test "x${ZLIB_HEADER_FOUND}" = "x0" ; then
  26605. ZLIB_LIB=""
  26606. ZLIB_INCLUDE=""
  26607. else
  26608. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  26609. ZLIB_LIB=""
  26610. fi
  26611. PBX_ZLIB=1
  26612. cat >>confdefs.h <<_ACEOF
  26613. #define HAVE_ZLIB 1
  26614. _ACEOF
  26615. fi
  26616. fi
  26617. fi
  26618. if test "x${PBX_UNIXODBC}" = "x1" -o "x${PBX_IODBC}" = "x1"; then
  26619. # Does ODBC support wide characters?
  26620. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ODBC has support for Unicode types" >&5
  26621. $as_echo_n "checking whether ODBC has support for Unicode types... " >&6; }
  26622. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26623. /* end confdefs.h. */
  26624. #include <sql.h>
  26625. #include <sqlext.h>
  26626. int
  26627. main ()
  26628. {
  26629. int foo = SQL_WCHAR
  26630. ;
  26631. return 0;
  26632. }
  26633. _ACEOF
  26634. if ac_fn_c_try_link "$LINENO"; then :
  26635. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  26636. $as_echo "yes" >&6; }
  26637. $as_echo "#define HAVE_ODBC_WCHAR 1" >>confdefs.h
  26638. else
  26639. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  26640. $as_echo "no" >&6; }
  26641. fi
  26642. rm -f core conftest.err conftest.$ac_objext \
  26643. conftest$ac_exeext conftest.$ac_ext
  26644. fi
  26645. ac_fn_c_check_header_mongrel "$LINENO" "h323.h" "ac_cv_header_h323_h" "$ac_includes_default"
  26646. if test "x$ac_cv_header_h323_h" = xyes; then :
  26647. PBX_H323=1
  26648. else
  26649. PBX_H323=0
  26650. fi
  26651. ac_fn_c_check_header_mongrel "$LINENO" "linux/compiler.h" "ac_cv_header_linux_compiler_h" "$ac_includes_default"
  26652. if test "x$ac_cv_header_linux_compiler_h" = xyes; then :
  26653. cat >>confdefs.h <<_ACEOF
  26654. #define HAVE_LINUX_COMPILER_H 1
  26655. _ACEOF
  26656. fi
  26657. ac_fn_c_check_header_compile "$LINENO" "linux/ixjuser.h" "ac_cv_header_linux_ixjuser_h" "
  26658. #include <linux/version.h>
  26659. #ifdef HAVE_LINUX_COMPILER_H
  26660. #include <linux/compiler.h>
  26661. #endif
  26662. "
  26663. if test "x$ac_cv_header_linux_ixjuser_h" = xyes; then :
  26664. PBX_IXJUSER=1
  26665. else
  26666. PBX_IXJUSER=0
  26667. fi
  26668. # Used in res/res_pktccops
  26669. if test "x${PBX_MSG_NOSIGNAL}" != "x1"; then
  26670. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MSG_NOSIGNAL in sys/socket.h" >&5
  26671. $as_echo_n "checking for MSG_NOSIGNAL in sys/socket.h... " >&6; }
  26672. saved_cppflags="${CPPFLAGS}"
  26673. if test "x${MSG_NOSIGNAL_DIR}" != "x"; then
  26674. MSG_NOSIGNAL_INCLUDE="-I${MSG_NOSIGNAL_DIR}/include"
  26675. fi
  26676. CPPFLAGS="${CPPFLAGS} ${MSG_NOSIGNAL_INCLUDE}"
  26677. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26678. /* end confdefs.h. */
  26679. #include <sys/socket.h>
  26680. int
  26681. main ()
  26682. {
  26683. #if defined(MSG_NOSIGNAL)
  26684. int foo = 0;
  26685. #else
  26686. int foo = bar;
  26687. #endif
  26688. 0
  26689. ;
  26690. return 0;
  26691. }
  26692. _ACEOF
  26693. if ac_fn_c_try_compile "$LINENO"; then :
  26694. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  26695. $as_echo "yes" >&6; }
  26696. PBX_MSG_NOSIGNAL=1
  26697. $as_echo "#define HAVE_MSG_NOSIGNAL 1" >>confdefs.h
  26698. else
  26699. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  26700. $as_echo "no" >&6; }
  26701. fi
  26702. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  26703. CPPFLAGS="${saved_cppflags}"
  26704. fi
  26705. if test "x${PBX_SO_NOSIGPIPE}" != "x1"; then
  26706. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SO_NOSIGPIPE in sys/socket.h" >&5
  26707. $as_echo_n "checking for SO_NOSIGPIPE in sys/socket.h... " >&6; }
  26708. saved_cppflags="${CPPFLAGS}"
  26709. if test "x${SO_NOSIGPIPE_DIR}" != "x"; then
  26710. SO_NOSIGPIPE_INCLUDE="-I${SO_NOSIGPIPE_DIR}/include"
  26711. fi
  26712. CPPFLAGS="${CPPFLAGS} ${SO_NOSIGPIPE_INCLUDE}"
  26713. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26714. /* end confdefs.h. */
  26715. #include <sys/socket.h>
  26716. int
  26717. main ()
  26718. {
  26719. #if defined(SO_NOSIGPIPE)
  26720. int foo = 0;
  26721. #else
  26722. int foo = bar;
  26723. #endif
  26724. 0
  26725. ;
  26726. return 0;
  26727. }
  26728. _ACEOF
  26729. if ac_fn_c_try_compile "$LINENO"; then :
  26730. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  26731. $as_echo "yes" >&6; }
  26732. PBX_SO_NOSIGPIPE=1
  26733. $as_echo "#define HAVE_SO_NOSIGPIPE 1" >>confdefs.h
  26734. else
  26735. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  26736. $as_echo "no" >&6; }
  26737. fi
  26738. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  26739. CPPFLAGS="${saved_cppflags}"
  26740. fi
  26741. if test "x${PBX_SDL}" != "x1" -a "${USE_SDL}" != "no"; then
  26742. PBX_SDL=0
  26743. if test -n "$ac_tool_prefix"; then
  26744. # Extract the first word of "${ac_tool_prefix}sdl-config", so it can be a program name with args.
  26745. set dummy ${ac_tool_prefix}sdl-config; ac_word=$2
  26746. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  26747. $as_echo_n "checking for $ac_word... " >&6; }
  26748. if ${ac_cv_path_CONFIG_SDL+:} false; then :
  26749. $as_echo_n "(cached) " >&6
  26750. else
  26751. case $CONFIG_SDL in
  26752. [\\/]* | ?:[\\/]*)
  26753. ac_cv_path_CONFIG_SDL="$CONFIG_SDL" # Let the user override the test with a path.
  26754. ;;
  26755. *)
  26756. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  26757. as_dummy="${SDL_DIR}/bin:$PATH"
  26758. for as_dir in $as_dummy
  26759. do
  26760. IFS=$as_save_IFS
  26761. test -z "$as_dir" && as_dir=.
  26762. for ac_exec_ext in '' $ac_executable_extensions; do
  26763. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  26764. ac_cv_path_CONFIG_SDL="$as_dir/$ac_word$ac_exec_ext"
  26765. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  26766. break 2
  26767. fi
  26768. done
  26769. done
  26770. IFS=$as_save_IFS
  26771. ;;
  26772. esac
  26773. fi
  26774. CONFIG_SDL=$ac_cv_path_CONFIG_SDL
  26775. if test -n "$CONFIG_SDL"; then
  26776. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONFIG_SDL" >&5
  26777. $as_echo "$CONFIG_SDL" >&6; }
  26778. else
  26779. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  26780. $as_echo "no" >&6; }
  26781. fi
  26782. fi
  26783. if test -z "$ac_cv_path_CONFIG_SDL"; then
  26784. ac_pt_CONFIG_SDL=$CONFIG_SDL
  26785. # Extract the first word of "sdl-config", so it can be a program name with args.
  26786. set dummy sdl-config; ac_word=$2
  26787. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  26788. $as_echo_n "checking for $ac_word... " >&6; }
  26789. if ${ac_cv_path_ac_pt_CONFIG_SDL+:} false; then :
  26790. $as_echo_n "(cached) " >&6
  26791. else
  26792. case $ac_pt_CONFIG_SDL in
  26793. [\\/]* | ?:[\\/]*)
  26794. ac_cv_path_ac_pt_CONFIG_SDL="$ac_pt_CONFIG_SDL" # Let the user override the test with a path.
  26795. ;;
  26796. *)
  26797. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  26798. as_dummy="${SDL_DIR}/bin:$PATH"
  26799. for as_dir in $as_dummy
  26800. do
  26801. IFS=$as_save_IFS
  26802. test -z "$as_dir" && as_dir=.
  26803. for ac_exec_ext in '' $ac_executable_extensions; do
  26804. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  26805. ac_cv_path_ac_pt_CONFIG_SDL="$as_dir/$ac_word$ac_exec_ext"
  26806. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  26807. break 2
  26808. fi
  26809. done
  26810. done
  26811. IFS=$as_save_IFS
  26812. ;;
  26813. esac
  26814. fi
  26815. ac_pt_CONFIG_SDL=$ac_cv_path_ac_pt_CONFIG_SDL
  26816. if test -n "$ac_pt_CONFIG_SDL"; then
  26817. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CONFIG_SDL" >&5
  26818. $as_echo "$ac_pt_CONFIG_SDL" >&6; }
  26819. else
  26820. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  26821. $as_echo "no" >&6; }
  26822. fi
  26823. if test "x$ac_pt_CONFIG_SDL" = x; then
  26824. CONFIG_SDL="No"
  26825. else
  26826. case $cross_compiling:$ac_tool_warned in
  26827. yes:)
  26828. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  26829. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  26830. ac_tool_warned=yes ;;
  26831. esac
  26832. CONFIG_SDL=$ac_pt_CONFIG_SDL
  26833. fi
  26834. else
  26835. CONFIG_SDL="$ac_cv_path_CONFIG_SDL"
  26836. fi
  26837. if test ! "x${CONFIG_SDL}" = xNo; then
  26838. if test x"" = x ; then A=--cflags ; else A="" ; fi
  26839. SDL_INCLUDE=$(${CONFIG_SDL} $A)
  26840. SDL_INCLUDE=$(echo ${SDL_INCLUDE} | $SED -e "s|-I|-I${SDL_DIR}|g")
  26841. if test x"" = x ; then A=--libs ; else A="" ; fi
  26842. SDL_LIB=$(${CONFIG_SDL} $A)
  26843. SDL_LIB=$(echo ${SDL_LIB} | $SED -e "s|-L|-L${SDL_DIR}|g")
  26844. if test x"" != x ; then
  26845. saved_cppflags="${CPPFLAGS}"
  26846. CPPFLAGS="${CPPFLAGS} ${SDL_INCLUDE}"
  26847. saved_libs="${LIBS}"
  26848. LIBS=${SDL_LIB}
  26849. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26850. /* end confdefs.h. */
  26851. int
  26852. main ()
  26853. {
  26854. ;
  26855. ;
  26856. return 0;
  26857. }
  26858. _ACEOF
  26859. if ac_fn_c_try_link "$LINENO"; then :
  26860. PBX_SDL=1
  26861. $as_echo "#define HAVE_SDL 1" >>confdefs.h
  26862. fi
  26863. rm -f core conftest.err conftest.$ac_objext \
  26864. conftest$ac_exeext conftest.$ac_ext
  26865. CPPFLAGS="${saved_cppflags}"
  26866. LIBS="${saved_libs}"
  26867. else
  26868. PBX_SDL=1
  26869. $as_echo "#define HAVE_SDL 1" >>confdefs.h
  26870. fi
  26871. fi
  26872. fi
  26873. if test "x${PBX_SDL_IMAGE}" != "x1" -a "${USE_SDL_IMAGE}" != "no"; then
  26874. pbxlibdir=""
  26875. # if --with-SDL_IMAGE=DIR has been specified, use it.
  26876. if test "x${SDL_IMAGE_DIR}" != "x"; then
  26877. if test -d ${SDL_IMAGE_DIR}/lib; then
  26878. pbxlibdir="-L${SDL_IMAGE_DIR}/lib"
  26879. else
  26880. pbxlibdir="-L${SDL_IMAGE_DIR}"
  26881. fi
  26882. fi
  26883. pbxfuncname="IMG_Load"
  26884. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  26885. AST_SDL_IMAGE_FOUND=yes
  26886. else
  26887. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  26888. CFLAGS="${CFLAGS} ${SDL_INCLUDE}"
  26889. as_ac_Lib=`$as_echo "ac_cv_lib_SDL_image_${pbxfuncname}" | $as_tr_sh`
  26890. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lSDL_image" >&5
  26891. $as_echo_n "checking for ${pbxfuncname} in -lSDL_image... " >&6; }
  26892. if eval \${$as_ac_Lib+:} false; then :
  26893. $as_echo_n "(cached) " >&6
  26894. else
  26895. ac_check_lib_save_LIBS=$LIBS
  26896. LIBS="-lSDL_image ${pbxlibdir} ${SDL_LIB} $LIBS"
  26897. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26898. /* end confdefs.h. */
  26899. /* Override any GCC internal prototype to avoid an error.
  26900. Use char because int might match the return type of a GCC
  26901. builtin and then its argument prototype would still apply. */
  26902. #ifdef __cplusplus
  26903. extern "C"
  26904. #endif
  26905. char ${pbxfuncname} ();
  26906. int
  26907. main ()
  26908. {
  26909. return ${pbxfuncname} ();
  26910. ;
  26911. return 0;
  26912. }
  26913. _ACEOF
  26914. if ac_fn_c_try_link "$LINENO"; then :
  26915. eval "$as_ac_Lib=yes"
  26916. else
  26917. eval "$as_ac_Lib=no"
  26918. fi
  26919. rm -f core conftest.err conftest.$ac_objext \
  26920. conftest$ac_exeext conftest.$ac_ext
  26921. LIBS=$ac_check_lib_save_LIBS
  26922. fi
  26923. eval ac_res=\$$as_ac_Lib
  26924. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  26925. $as_echo "$ac_res" >&6; }
  26926. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  26927. AST_SDL_IMAGE_FOUND=yes
  26928. else
  26929. AST_SDL_IMAGE_FOUND=no
  26930. fi
  26931. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  26932. fi
  26933. # now check for the header.
  26934. if test "${AST_SDL_IMAGE_FOUND}" = "yes"; then
  26935. SDL_IMAGE_LIB="${pbxlibdir} -lSDL_image ${SDL_LIB}"
  26936. # if --with-SDL_IMAGE=DIR has been specified, use it.
  26937. if test "x${SDL_IMAGE_DIR}" != "x"; then
  26938. SDL_IMAGE_INCLUDE="-I${SDL_IMAGE_DIR}/include"
  26939. fi
  26940. SDL_IMAGE_INCLUDE="${SDL_IMAGE_INCLUDE} ${SDL_INCLUDE}"
  26941. if test "xSDL_image.h" = "x" ; then # no header, assume found
  26942. SDL_IMAGE_HEADER_FOUND="1"
  26943. else # check for the header
  26944. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  26945. CPPFLAGS="${CPPFLAGS} ${SDL_IMAGE_INCLUDE}"
  26946. ac_fn_c_check_header_mongrel "$LINENO" "SDL_image.h" "ac_cv_header_SDL_image_h" "$ac_includes_default"
  26947. if test "x$ac_cv_header_SDL_image_h" = xyes; then :
  26948. SDL_IMAGE_HEADER_FOUND=1
  26949. else
  26950. SDL_IMAGE_HEADER_FOUND=0
  26951. fi
  26952. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  26953. fi
  26954. if test "x${SDL_IMAGE_HEADER_FOUND}" = "x0" ; then
  26955. SDL_IMAGE_LIB=""
  26956. SDL_IMAGE_INCLUDE=""
  26957. else
  26958. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  26959. SDL_IMAGE_LIB=""
  26960. fi
  26961. PBX_SDL_IMAGE=1
  26962. cat >>confdefs.h <<_ACEOF
  26963. #define HAVE_SDL_IMAGE 1
  26964. _ACEOF
  26965. fi
  26966. fi
  26967. fi
  26968. if test "x${PBX_FFMPEG}" != "x1" -a "${USE_FFMPEG}" != "no"; then
  26969. pbxlibdir=""
  26970. # if --with-FFMPEG=DIR has been specified, use it.
  26971. if test "x${FFMPEG_DIR}" != "x"; then
  26972. if test -d ${FFMPEG_DIR}/lib; then
  26973. pbxlibdir="-L${FFMPEG_DIR}/lib"
  26974. else
  26975. pbxlibdir="-L${FFMPEG_DIR}"
  26976. fi
  26977. fi
  26978. pbxfuncname="sws_getContext"
  26979. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  26980. AST_FFMPEG_FOUND=yes
  26981. else
  26982. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  26983. CFLAGS="${CFLAGS} ${PTHREAD_CFLAGS}"
  26984. as_ac_Lib=`$as_echo "ac_cv_lib_avcodec_${pbxfuncname}" | $as_tr_sh`
  26985. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lavcodec" >&5
  26986. $as_echo_n "checking for ${pbxfuncname} in -lavcodec... " >&6; }
  26987. if eval \${$as_ac_Lib+:} false; then :
  26988. $as_echo_n "(cached) " >&6
  26989. else
  26990. ac_check_lib_save_LIBS=$LIBS
  26991. LIBS="-lavcodec ${pbxlibdir} ${PTHREAD_LIBS} -lz -lm $LIBS"
  26992. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26993. /* end confdefs.h. */
  26994. /* Override any GCC internal prototype to avoid an error.
  26995. Use char because int might match the return type of a GCC
  26996. builtin and then its argument prototype would still apply. */
  26997. #ifdef __cplusplus
  26998. extern "C"
  26999. #endif
  27000. char ${pbxfuncname} ();
  27001. int
  27002. main ()
  27003. {
  27004. return ${pbxfuncname} ();
  27005. ;
  27006. return 0;
  27007. }
  27008. _ACEOF
  27009. if ac_fn_c_try_link "$LINENO"; then :
  27010. eval "$as_ac_Lib=yes"
  27011. else
  27012. eval "$as_ac_Lib=no"
  27013. fi
  27014. rm -f core conftest.err conftest.$ac_objext \
  27015. conftest$ac_exeext conftest.$ac_ext
  27016. LIBS=$ac_check_lib_save_LIBS
  27017. fi
  27018. eval ac_res=\$$as_ac_Lib
  27019. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  27020. $as_echo "$ac_res" >&6; }
  27021. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  27022. AST_FFMPEG_FOUND=yes
  27023. else
  27024. AST_FFMPEG_FOUND=no
  27025. fi
  27026. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  27027. fi
  27028. # now check for the header.
  27029. if test "${AST_FFMPEG_FOUND}" = "yes"; then
  27030. FFMPEG_LIB="${pbxlibdir} -lavcodec ${PTHREAD_LIBS} -lz -lm"
  27031. # if --with-FFMPEG=DIR has been specified, use it.
  27032. if test "x${FFMPEG_DIR}" != "x"; then
  27033. FFMPEG_INCLUDE="-I${FFMPEG_DIR}/include"
  27034. fi
  27035. FFMPEG_INCLUDE="${FFMPEG_INCLUDE} ${PTHREAD_CFLAGS}"
  27036. if test "xffmpeg/avcodec.h" = "x" ; then # no header, assume found
  27037. FFMPEG_HEADER_FOUND="1"
  27038. else # check for the header
  27039. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  27040. CPPFLAGS="${CPPFLAGS} ${FFMPEG_INCLUDE}"
  27041. ac_fn_c_check_header_mongrel "$LINENO" "ffmpeg/avcodec.h" "ac_cv_header_ffmpeg_avcodec_h" "$ac_includes_default"
  27042. if test "x$ac_cv_header_ffmpeg_avcodec_h" = xyes; then :
  27043. FFMPEG_HEADER_FOUND=1
  27044. else
  27045. FFMPEG_HEADER_FOUND=0
  27046. fi
  27047. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  27048. fi
  27049. if test "x${FFMPEG_HEADER_FOUND}" = "x0" ; then
  27050. FFMPEG_LIB=""
  27051. FFMPEG_INCLUDE=""
  27052. else
  27053. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  27054. FFMPEG_LIB=""
  27055. fi
  27056. PBX_FFMPEG=1
  27057. cat >>confdefs.h <<_ACEOF
  27058. #define HAVE_FFMPEG 1
  27059. _ACEOF
  27060. fi
  27061. fi
  27062. fi
  27063. # possible places for video4linux version 1
  27064. ac_fn_c_check_header_mongrel "$LINENO" "linux/videodev.h" "ac_cv_header_linux_videodev_h" "$ac_includes_default"
  27065. if test "x$ac_cv_header_linux_videodev_h" = xyes; then :
  27066. cat >>confdefs.h <<_ACEOF
  27067. #define HAVE_VIDEODEV_H 1
  27068. _ACEOF
  27069. fi
  27070. # possible places for X11
  27071. if test "x${PBX_X11}" != "x1" -a "${USE_X11}" != "no"; then
  27072. pbxlibdir=""
  27073. # if --with-X11=DIR has been specified, use it.
  27074. if test "x${X11_DIR}" != "x"; then
  27075. if test -d ${X11_DIR}/lib; then
  27076. pbxlibdir="-L${X11_DIR}/lib"
  27077. else
  27078. pbxlibdir="-L${X11_DIR}"
  27079. fi
  27080. fi
  27081. pbxfuncname="XOpenDisplay"
  27082. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  27083. AST_X11_FOUND=yes
  27084. else
  27085. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  27086. CFLAGS="${CFLAGS} "
  27087. as_ac_Lib=`$as_echo "ac_cv_lib_X11_${pbxfuncname}" | $as_tr_sh`
  27088. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lX11" >&5
  27089. $as_echo_n "checking for ${pbxfuncname} in -lX11... " >&6; }
  27090. if eval \${$as_ac_Lib+:} false; then :
  27091. $as_echo_n "(cached) " >&6
  27092. else
  27093. ac_check_lib_save_LIBS=$LIBS
  27094. LIBS="-lX11 ${pbxlibdir} $LIBS"
  27095. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27096. /* end confdefs.h. */
  27097. /* Override any GCC internal prototype to avoid an error.
  27098. Use char because int might match the return type of a GCC
  27099. builtin and then its argument prototype would still apply. */
  27100. #ifdef __cplusplus
  27101. extern "C"
  27102. #endif
  27103. char ${pbxfuncname} ();
  27104. int
  27105. main ()
  27106. {
  27107. return ${pbxfuncname} ();
  27108. ;
  27109. return 0;
  27110. }
  27111. _ACEOF
  27112. if ac_fn_c_try_link "$LINENO"; then :
  27113. eval "$as_ac_Lib=yes"
  27114. else
  27115. eval "$as_ac_Lib=no"
  27116. fi
  27117. rm -f core conftest.err conftest.$ac_objext \
  27118. conftest$ac_exeext conftest.$ac_ext
  27119. LIBS=$ac_check_lib_save_LIBS
  27120. fi
  27121. eval ac_res=\$$as_ac_Lib
  27122. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  27123. $as_echo "$ac_res" >&6; }
  27124. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  27125. AST_X11_FOUND=yes
  27126. else
  27127. AST_X11_FOUND=no
  27128. fi
  27129. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  27130. fi
  27131. # now check for the header.
  27132. if test "${AST_X11_FOUND}" = "yes"; then
  27133. X11_LIB="${pbxlibdir} -lX11 "
  27134. # if --with-X11=DIR has been specified, use it.
  27135. if test "x${X11_DIR}" != "x"; then
  27136. X11_INCLUDE="-I${X11_DIR}/include"
  27137. fi
  27138. X11_INCLUDE="${X11_INCLUDE} "
  27139. if test "xX11/Xlib.h" = "x" ; then # no header, assume found
  27140. X11_HEADER_FOUND="1"
  27141. else # check for the header
  27142. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  27143. CPPFLAGS="${CPPFLAGS} ${X11_INCLUDE}"
  27144. ac_fn_c_check_header_mongrel "$LINENO" "X11/Xlib.h" "ac_cv_header_X11_Xlib_h" "$ac_includes_default"
  27145. if test "x$ac_cv_header_X11_Xlib_h" = xyes; then :
  27146. X11_HEADER_FOUND=1
  27147. else
  27148. X11_HEADER_FOUND=0
  27149. fi
  27150. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  27151. fi
  27152. if test "x${X11_HEADER_FOUND}" = "x0" ; then
  27153. X11_LIB=""
  27154. X11_INCLUDE=""
  27155. else
  27156. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  27157. X11_LIB=""
  27158. fi
  27159. PBX_X11=1
  27160. cat >>confdefs.h <<_ACEOF
  27161. #define HAVE_X11 1
  27162. _ACEOF
  27163. cat >>confdefs.h <<_ACEOF
  27164. #define HAVE_X11_VERSION standard_path
  27165. _ACEOF
  27166. fi
  27167. fi
  27168. fi
  27169. if test "x${PBX_X11}" != "x1" -a "${USE_X11}" != "no"; then
  27170. pbxlibdir=""
  27171. # if --with-X11=DIR has been specified, use it.
  27172. if test "x${X11_DIR}" != "x"; then
  27173. if test -d ${X11_DIR}/lib; then
  27174. pbxlibdir="-L${X11_DIR}/lib"
  27175. else
  27176. pbxlibdir="-L${X11_DIR}"
  27177. fi
  27178. fi
  27179. pbxfuncname="XOpenDisplay"
  27180. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  27181. AST_X11_FOUND=yes
  27182. else
  27183. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  27184. CFLAGS="${CFLAGS} -I/usr/X11R6/include"
  27185. as_ac_Lib=`$as_echo "ac_cv_lib_X11_${pbxfuncname}" | $as_tr_sh`
  27186. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lX11" >&5
  27187. $as_echo_n "checking for ${pbxfuncname} in -lX11... " >&6; }
  27188. if eval \${$as_ac_Lib+:} false; then :
  27189. $as_echo_n "(cached) " >&6
  27190. else
  27191. ac_check_lib_save_LIBS=$LIBS
  27192. LIBS="-lX11 ${pbxlibdir} $LIBS"
  27193. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27194. /* end confdefs.h. */
  27195. /* Override any GCC internal prototype to avoid an error.
  27196. Use char because int might match the return type of a GCC
  27197. builtin and then its argument prototype would still apply. */
  27198. #ifdef __cplusplus
  27199. extern "C"
  27200. #endif
  27201. char ${pbxfuncname} ();
  27202. int
  27203. main ()
  27204. {
  27205. return ${pbxfuncname} ();
  27206. ;
  27207. return 0;
  27208. }
  27209. _ACEOF
  27210. if ac_fn_c_try_link "$LINENO"; then :
  27211. eval "$as_ac_Lib=yes"
  27212. else
  27213. eval "$as_ac_Lib=no"
  27214. fi
  27215. rm -f core conftest.err conftest.$ac_objext \
  27216. conftest$ac_exeext conftest.$ac_ext
  27217. LIBS=$ac_check_lib_save_LIBS
  27218. fi
  27219. eval ac_res=\$$as_ac_Lib
  27220. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  27221. $as_echo "$ac_res" >&6; }
  27222. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  27223. AST_X11_FOUND=yes
  27224. else
  27225. AST_X11_FOUND=no
  27226. fi
  27227. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  27228. fi
  27229. # now check for the header.
  27230. if test "${AST_X11_FOUND}" = "yes"; then
  27231. X11_LIB="${pbxlibdir} -lX11 "
  27232. # if --with-X11=DIR has been specified, use it.
  27233. if test "x${X11_DIR}" != "x"; then
  27234. X11_INCLUDE="-I${X11_DIR}/include"
  27235. fi
  27236. X11_INCLUDE="${X11_INCLUDE} -I/usr/X11R6/include"
  27237. if test "xX11/Xlib.h" = "x" ; then # no header, assume found
  27238. X11_HEADER_FOUND="1"
  27239. else # check for the header
  27240. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  27241. CPPFLAGS="${CPPFLAGS} ${X11_INCLUDE}"
  27242. ac_fn_c_check_header_mongrel "$LINENO" "X11/Xlib.h" "ac_cv_header_X11_Xlib_h" "$ac_includes_default"
  27243. if test "x$ac_cv_header_X11_Xlib_h" = xyes; then :
  27244. X11_HEADER_FOUND=1
  27245. else
  27246. X11_HEADER_FOUND=0
  27247. fi
  27248. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  27249. fi
  27250. if test "x${X11_HEADER_FOUND}" = "x0" ; then
  27251. X11_LIB=""
  27252. X11_INCLUDE=""
  27253. else
  27254. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  27255. X11_LIB=""
  27256. fi
  27257. PBX_X11=1
  27258. cat >>confdefs.h <<_ACEOF
  27259. #define HAVE_X11 1
  27260. _ACEOF
  27261. cat >>confdefs.h <<_ACEOF
  27262. #define HAVE_X11_VERSION X11R6
  27263. _ACEOF
  27264. fi
  27265. fi
  27266. fi
  27267. PBX_LAUNCHD=0
  27268. if test "${cross_compiling}" = "no";
  27269. then
  27270. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /sbin/launchd" >&5
  27271. $as_echo_n "checking for /sbin/launchd... " >&6; }
  27272. if ${ac_cv_file__sbin_launchd+:} false; then :
  27273. $as_echo_n "(cached) " >&6
  27274. else
  27275. test "$cross_compiling" = yes &&
  27276. as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
  27277. if test -r "/sbin/launchd"; then
  27278. ac_cv_file__sbin_launchd=yes
  27279. else
  27280. ac_cv_file__sbin_launchd=no
  27281. fi
  27282. fi
  27283. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__sbin_launchd" >&5
  27284. $as_echo "$ac_cv_file__sbin_launchd" >&6; }
  27285. if test "x$ac_cv_file__sbin_launchd" = xyes; then :
  27286. $as_echo "#define HAVE_SBIN_LAUNCHD 1" >>confdefs.h
  27287. fi
  27288. if test "${HAVE_SBIN_LAUNCHD}" = 1; then
  27289. PBX_LAUNCHD=1
  27290. fi
  27291. fi
  27292. if test "x${PBX_GTK2}" != "x1" -a "${USE_GTK2}" != "no"; then
  27293. pkg_failed=no
  27294. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GTK2" >&5
  27295. $as_echo_n "checking for GTK2... " >&6; }
  27296. if test -n "$GTK2_CFLAGS"; then
  27297. pkg_cv_GTK2_CFLAGS="$GTK2_CFLAGS"
  27298. elif test -n "$PKG_CONFIG"; then
  27299. if test -n "$PKG_CONFIG" && \
  27300. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtk+-2.0\""; } >&5
  27301. ($PKG_CONFIG --exists --print-errors "gtk+-2.0") 2>&5
  27302. ac_status=$?
  27303. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  27304. test $ac_status = 0; }; then
  27305. pkg_cv_GTK2_CFLAGS=`$PKG_CONFIG --cflags "gtk+-2.0" 2>/dev/null`
  27306. test "x$?" != "x0" && pkg_failed=yes
  27307. else
  27308. pkg_failed=yes
  27309. fi
  27310. else
  27311. pkg_failed=untried
  27312. fi
  27313. if test -n "$GTK2_LIBS"; then
  27314. pkg_cv_GTK2_LIBS="$GTK2_LIBS"
  27315. elif test -n "$PKG_CONFIG"; then
  27316. if test -n "$PKG_CONFIG" && \
  27317. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtk+-2.0\""; } >&5
  27318. ($PKG_CONFIG --exists --print-errors "gtk+-2.0") 2>&5
  27319. ac_status=$?
  27320. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  27321. test $ac_status = 0; }; then
  27322. pkg_cv_GTK2_LIBS=`$PKG_CONFIG --libs "gtk+-2.0" 2>/dev/null`
  27323. test "x$?" != "x0" && pkg_failed=yes
  27324. else
  27325. pkg_failed=yes
  27326. fi
  27327. else
  27328. pkg_failed=untried
  27329. fi
  27330. if test $pkg_failed = yes; then
  27331. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27332. $as_echo "no" >&6; }
  27333. if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
  27334. _pkg_short_errors_supported=yes
  27335. else
  27336. _pkg_short_errors_supported=no
  27337. fi
  27338. if test $_pkg_short_errors_supported = yes; then
  27339. GTK2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gtk+-2.0" 2>&1`
  27340. else
  27341. GTK2_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gtk+-2.0" 2>&1`
  27342. fi
  27343. # Put the nasty error message in config.log where it belongs
  27344. echo "$GTK2_PKG_ERRORS" >&5
  27345. PBX_GTK2=0
  27346. elif test $pkg_failed = untried; then
  27347. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27348. $as_echo "no" >&6; }
  27349. PBX_GTK2=0
  27350. else
  27351. GTK2_CFLAGS=$pkg_cv_GTK2_CFLAGS
  27352. GTK2_LIBS=$pkg_cv_GTK2_LIBS
  27353. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27354. $as_echo "yes" >&6; }
  27355. PBX_GTK2=1
  27356. GTK2_INCLUDE="$GTK2_CFLAGS"
  27357. GTK2_LIB="$GTK2_LIBS"
  27358. $as_echo "#define HAVE_GTK2 1" >>confdefs.h
  27359. fi
  27360. fi
  27361. # build a GENERIC_ODBC result based on the presence of either UnixODBC (preferred)
  27362. # or iODBC
  27363. PBX_GENERIC_ODBC=0
  27364. if test "${PBX_UNIXODBC}" = 1; then
  27365. PBX_GENERIC_ODBC=1
  27366. GENERIC_ODBC_LIB="${UNIXODBC_LIB}"
  27367. GENERIC_ODBC_INCLUDE="${UNIXODBC_INCLUDE}"
  27368. elif test "${PBX_IODBC}" = 1; then
  27369. PBX_GENERIC_ODBC=1
  27370. GENERIC_ODBC_LIB="${IODBC_LIB}"
  27371. GENERIC_ODBC_INCLUDE="${IODBC_INCLUDE}"
  27372. fi
  27373. PBX_SYSLOG=0
  27374. if test "${ac_cv_header_syslog_h}" = "yes"; then
  27375. # syslog facilities
  27376. if test "x${PBX_SYSLOG_FACILITY_LOG_AUTH}" != "x1"; then
  27377. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_AUTH in syslog.h" >&5
  27378. $as_echo_n "checking for LOG_AUTH in syslog.h... " >&6; }
  27379. saved_cppflags="${CPPFLAGS}"
  27380. if test "x${SYSLOG_FACILITY_LOG_AUTH_DIR}" != "x"; then
  27381. SYSLOG_FACILITY_LOG_AUTH_INCLUDE="-I${SYSLOG_FACILITY_LOG_AUTH_DIR}/include"
  27382. fi
  27383. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_AUTH_INCLUDE}"
  27384. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27385. /* end confdefs.h. */
  27386. #include <syslog.h>
  27387. int
  27388. main ()
  27389. {
  27390. #if defined(LOG_AUTH)
  27391. int foo = 0;
  27392. #else
  27393. int foo = bar;
  27394. #endif
  27395. 0
  27396. ;
  27397. return 0;
  27398. }
  27399. _ACEOF
  27400. if ac_fn_c_try_compile "$LINENO"; then :
  27401. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27402. $as_echo "yes" >&6; }
  27403. PBX_SYSLOG_FACILITY_LOG_AUTH=1
  27404. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_AUTH 1" >>confdefs.h
  27405. else
  27406. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27407. $as_echo "no" >&6; }
  27408. fi
  27409. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  27410. CPPFLAGS="${saved_cppflags}"
  27411. fi
  27412. if test "x${PBX_SYSLOG_FACILITY_LOG_AUTHPRIV}" != "x1"; then
  27413. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_AUTHPRIV in syslog.h" >&5
  27414. $as_echo_n "checking for LOG_AUTHPRIV in syslog.h... " >&6; }
  27415. saved_cppflags="${CPPFLAGS}"
  27416. if test "x${SYSLOG_FACILITY_LOG_AUTHPRIV_DIR}" != "x"; then
  27417. SYSLOG_FACILITY_LOG_AUTHPRIV_INCLUDE="-I${SYSLOG_FACILITY_LOG_AUTHPRIV_DIR}/include"
  27418. fi
  27419. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_AUTHPRIV_INCLUDE}"
  27420. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27421. /* end confdefs.h. */
  27422. #include <syslog.h>
  27423. int
  27424. main ()
  27425. {
  27426. #if defined(LOG_AUTHPRIV)
  27427. int foo = 0;
  27428. #else
  27429. int foo = bar;
  27430. #endif
  27431. 0
  27432. ;
  27433. return 0;
  27434. }
  27435. _ACEOF
  27436. if ac_fn_c_try_compile "$LINENO"; then :
  27437. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27438. $as_echo "yes" >&6; }
  27439. PBX_SYSLOG_FACILITY_LOG_AUTHPRIV=1
  27440. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_AUTHPRIV 1" >>confdefs.h
  27441. else
  27442. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27443. $as_echo "no" >&6; }
  27444. fi
  27445. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  27446. CPPFLAGS="${saved_cppflags}"
  27447. fi
  27448. if test "x${PBX_SYSLOG_FACILITY_LOG_CRON}" != "x1"; then
  27449. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_CRON in syslog.h" >&5
  27450. $as_echo_n "checking for LOG_CRON in syslog.h... " >&6; }
  27451. saved_cppflags="${CPPFLAGS}"
  27452. if test "x${SYSLOG_FACILITY_LOG_CRON_DIR}" != "x"; then
  27453. SYSLOG_FACILITY_LOG_CRON_INCLUDE="-I${SYSLOG_FACILITY_LOG_CRON_DIR}/include"
  27454. fi
  27455. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_CRON_INCLUDE}"
  27456. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27457. /* end confdefs.h. */
  27458. #include <syslog.h>
  27459. int
  27460. main ()
  27461. {
  27462. #if defined(LOG_CRON)
  27463. int foo = 0;
  27464. #else
  27465. int foo = bar;
  27466. #endif
  27467. 0
  27468. ;
  27469. return 0;
  27470. }
  27471. _ACEOF
  27472. if ac_fn_c_try_compile "$LINENO"; then :
  27473. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27474. $as_echo "yes" >&6; }
  27475. PBX_SYSLOG_FACILITY_LOG_CRON=1
  27476. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_CRON 1" >>confdefs.h
  27477. else
  27478. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27479. $as_echo "no" >&6; }
  27480. fi
  27481. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  27482. CPPFLAGS="${saved_cppflags}"
  27483. fi
  27484. if test "x${PBX_SYSLOG_FACILITY_LOG_DAEMON}" != "x1"; then
  27485. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_DAEMON in syslog.h" >&5
  27486. $as_echo_n "checking for LOG_DAEMON in syslog.h... " >&6; }
  27487. saved_cppflags="${CPPFLAGS}"
  27488. if test "x${SYSLOG_FACILITY_LOG_DAEMON_DIR}" != "x"; then
  27489. SYSLOG_FACILITY_LOG_DAEMON_INCLUDE="-I${SYSLOG_FACILITY_LOG_DAEMON_DIR}/include"
  27490. fi
  27491. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_DAEMON_INCLUDE}"
  27492. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27493. /* end confdefs.h. */
  27494. #include <syslog.h>
  27495. int
  27496. main ()
  27497. {
  27498. #if defined(LOG_DAEMON)
  27499. int foo = 0;
  27500. #else
  27501. int foo = bar;
  27502. #endif
  27503. 0
  27504. ;
  27505. return 0;
  27506. }
  27507. _ACEOF
  27508. if ac_fn_c_try_compile "$LINENO"; then :
  27509. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27510. $as_echo "yes" >&6; }
  27511. PBX_SYSLOG_FACILITY_LOG_DAEMON=1
  27512. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_DAEMON 1" >>confdefs.h
  27513. else
  27514. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27515. $as_echo "no" >&6; }
  27516. fi
  27517. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  27518. CPPFLAGS="${saved_cppflags}"
  27519. fi
  27520. if test "x${PBX_SYSLOG_FACILITY_LOG_FTP}" != "x1"; then
  27521. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_FTP in syslog.h" >&5
  27522. $as_echo_n "checking for LOG_FTP in syslog.h... " >&6; }
  27523. saved_cppflags="${CPPFLAGS}"
  27524. if test "x${SYSLOG_FACILITY_LOG_FTP_DIR}" != "x"; then
  27525. SYSLOG_FACILITY_LOG_FTP_INCLUDE="-I${SYSLOG_FACILITY_LOG_FTP_DIR}/include"
  27526. fi
  27527. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_FTP_INCLUDE}"
  27528. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27529. /* end confdefs.h. */
  27530. #include <syslog.h>
  27531. int
  27532. main ()
  27533. {
  27534. #if defined(LOG_FTP)
  27535. int foo = 0;
  27536. #else
  27537. int foo = bar;
  27538. #endif
  27539. 0
  27540. ;
  27541. return 0;
  27542. }
  27543. _ACEOF
  27544. if ac_fn_c_try_compile "$LINENO"; then :
  27545. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27546. $as_echo "yes" >&6; }
  27547. PBX_SYSLOG_FACILITY_LOG_FTP=1
  27548. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_FTP 1" >>confdefs.h
  27549. else
  27550. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27551. $as_echo "no" >&6; }
  27552. fi
  27553. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  27554. CPPFLAGS="${saved_cppflags}"
  27555. fi
  27556. if test "x${PBX_SYSLOG_FACILITY_LOG_KERN}" != "x1"; then
  27557. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_KERN in syslog.h" >&5
  27558. $as_echo_n "checking for LOG_KERN in syslog.h... " >&6; }
  27559. saved_cppflags="${CPPFLAGS}"
  27560. if test "x${SYSLOG_FACILITY_LOG_KERN_DIR}" != "x"; then
  27561. SYSLOG_FACILITY_LOG_KERN_INCLUDE="-I${SYSLOG_FACILITY_LOG_KERN_DIR}/include"
  27562. fi
  27563. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_KERN_INCLUDE}"
  27564. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27565. /* end confdefs.h. */
  27566. #include <syslog.h>
  27567. int
  27568. main ()
  27569. {
  27570. #if defined(LOG_KERN)
  27571. int foo = 0;
  27572. #else
  27573. int foo = bar;
  27574. #endif
  27575. 0
  27576. ;
  27577. return 0;
  27578. }
  27579. _ACEOF
  27580. if ac_fn_c_try_compile "$LINENO"; then :
  27581. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27582. $as_echo "yes" >&6; }
  27583. PBX_SYSLOG_FACILITY_LOG_KERN=1
  27584. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_KERN 1" >>confdefs.h
  27585. else
  27586. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27587. $as_echo "no" >&6; }
  27588. fi
  27589. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  27590. CPPFLAGS="${saved_cppflags}"
  27591. fi
  27592. if test "x${PBX_SYSLOG_FACILITY_LOG_LPR}" != "x1"; then
  27593. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_LPR in syslog.h" >&5
  27594. $as_echo_n "checking for LOG_LPR in syslog.h... " >&6; }
  27595. saved_cppflags="${CPPFLAGS}"
  27596. if test "x${SYSLOG_FACILITY_LOG_LPR_DIR}" != "x"; then
  27597. SYSLOG_FACILITY_LOG_LPR_INCLUDE="-I${SYSLOG_FACILITY_LOG_LPR_DIR}/include"
  27598. fi
  27599. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_LPR_INCLUDE}"
  27600. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27601. /* end confdefs.h. */
  27602. #include <syslog.h>
  27603. int
  27604. main ()
  27605. {
  27606. #if defined(LOG_LPR)
  27607. int foo = 0;
  27608. #else
  27609. int foo = bar;
  27610. #endif
  27611. 0
  27612. ;
  27613. return 0;
  27614. }
  27615. _ACEOF
  27616. if ac_fn_c_try_compile "$LINENO"; then :
  27617. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27618. $as_echo "yes" >&6; }
  27619. PBX_SYSLOG_FACILITY_LOG_LPR=1
  27620. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_LPR 1" >>confdefs.h
  27621. else
  27622. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27623. $as_echo "no" >&6; }
  27624. fi
  27625. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  27626. CPPFLAGS="${saved_cppflags}"
  27627. fi
  27628. if test "x${PBX_SYSLOG_FACILITY_LOG_MAIL}" != "x1"; then
  27629. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_MAIL in syslog.h" >&5
  27630. $as_echo_n "checking for LOG_MAIL in syslog.h... " >&6; }
  27631. saved_cppflags="${CPPFLAGS}"
  27632. if test "x${SYSLOG_FACILITY_LOG_MAIL_DIR}" != "x"; then
  27633. SYSLOG_FACILITY_LOG_MAIL_INCLUDE="-I${SYSLOG_FACILITY_LOG_MAIL_DIR}/include"
  27634. fi
  27635. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_MAIL_INCLUDE}"
  27636. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27637. /* end confdefs.h. */
  27638. #include <syslog.h>
  27639. int
  27640. main ()
  27641. {
  27642. #if defined(LOG_MAIL)
  27643. int foo = 0;
  27644. #else
  27645. int foo = bar;
  27646. #endif
  27647. 0
  27648. ;
  27649. return 0;
  27650. }
  27651. _ACEOF
  27652. if ac_fn_c_try_compile "$LINENO"; then :
  27653. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27654. $as_echo "yes" >&6; }
  27655. PBX_SYSLOG_FACILITY_LOG_MAIL=1
  27656. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_MAIL 1" >>confdefs.h
  27657. else
  27658. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27659. $as_echo "no" >&6; }
  27660. fi
  27661. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  27662. CPPFLAGS="${saved_cppflags}"
  27663. fi
  27664. if test "x${PBX_SYSLOG_FACILITY_LOG_NEWS}" != "x1"; then
  27665. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_NEWS in syslog.h" >&5
  27666. $as_echo_n "checking for LOG_NEWS in syslog.h... " >&6; }
  27667. saved_cppflags="${CPPFLAGS}"
  27668. if test "x${SYSLOG_FACILITY_LOG_NEWS_DIR}" != "x"; then
  27669. SYSLOG_FACILITY_LOG_NEWS_INCLUDE="-I${SYSLOG_FACILITY_LOG_NEWS_DIR}/include"
  27670. fi
  27671. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_NEWS_INCLUDE}"
  27672. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27673. /* end confdefs.h. */
  27674. #include <syslog.h>
  27675. int
  27676. main ()
  27677. {
  27678. #if defined(LOG_NEWS)
  27679. int foo = 0;
  27680. #else
  27681. int foo = bar;
  27682. #endif
  27683. 0
  27684. ;
  27685. return 0;
  27686. }
  27687. _ACEOF
  27688. if ac_fn_c_try_compile "$LINENO"; then :
  27689. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27690. $as_echo "yes" >&6; }
  27691. PBX_SYSLOG_FACILITY_LOG_NEWS=1
  27692. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_NEWS 1" >>confdefs.h
  27693. else
  27694. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27695. $as_echo "no" >&6; }
  27696. fi
  27697. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  27698. CPPFLAGS="${saved_cppflags}"
  27699. fi
  27700. if test "x${PBX_SYSLOG_FACILITY_LOG_SYSLOG}" != "x1"; then
  27701. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_SYSLOG in syslog.h" >&5
  27702. $as_echo_n "checking for LOG_SYSLOG in syslog.h... " >&6; }
  27703. saved_cppflags="${CPPFLAGS}"
  27704. if test "x${SYSLOG_FACILITY_LOG_SYSLOG_DIR}" != "x"; then
  27705. SYSLOG_FACILITY_LOG_SYSLOG_INCLUDE="-I${SYSLOG_FACILITY_LOG_SYSLOG_DIR}/include"
  27706. fi
  27707. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_SYSLOG_INCLUDE}"
  27708. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27709. /* end confdefs.h. */
  27710. #include <syslog.h>
  27711. int
  27712. main ()
  27713. {
  27714. #if defined(LOG_SYSLOG)
  27715. int foo = 0;
  27716. #else
  27717. int foo = bar;
  27718. #endif
  27719. 0
  27720. ;
  27721. return 0;
  27722. }
  27723. _ACEOF
  27724. if ac_fn_c_try_compile "$LINENO"; then :
  27725. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27726. $as_echo "yes" >&6; }
  27727. PBX_SYSLOG_FACILITY_LOG_SYSLOG=1
  27728. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_SYSLOG 1" >>confdefs.h
  27729. else
  27730. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27731. $as_echo "no" >&6; }
  27732. fi
  27733. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  27734. CPPFLAGS="${saved_cppflags}"
  27735. fi
  27736. if test "x${PBX_SYSLOG_FACILITY_LOG_UUCP}" != "x1"; then
  27737. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_UUCP in syslog.h" >&5
  27738. $as_echo_n "checking for LOG_UUCP in syslog.h... " >&6; }
  27739. saved_cppflags="${CPPFLAGS}"
  27740. if test "x${SYSLOG_FACILITY_LOG_UUCP_DIR}" != "x"; then
  27741. SYSLOG_FACILITY_LOG_UUCP_INCLUDE="-I${SYSLOG_FACILITY_LOG_UUCP_DIR}/include"
  27742. fi
  27743. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_UUCP_INCLUDE}"
  27744. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27745. /* end confdefs.h. */
  27746. #include <syslog.h>
  27747. int
  27748. main ()
  27749. {
  27750. #if defined(LOG_UUCP)
  27751. int foo = 0;
  27752. #else
  27753. int foo = bar;
  27754. #endif
  27755. 0
  27756. ;
  27757. return 0;
  27758. }
  27759. _ACEOF
  27760. if ac_fn_c_try_compile "$LINENO"; then :
  27761. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27762. $as_echo "yes" >&6; }
  27763. PBX_SYSLOG_FACILITY_LOG_UUCP=1
  27764. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_UUCP 1" >>confdefs.h
  27765. else
  27766. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27767. $as_echo "no" >&6; }
  27768. fi
  27769. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  27770. CPPFLAGS="${saved_cppflags}"
  27771. fi
  27772. PBX_SYSLOG=1
  27773. fi
  27774. if test -f makeopts; then
  27775. ${ac_cv_path_EGREP} 'CURSES|GTK2|OSARCH|NEWT' makeopts > makeopts.acbak
  27776. else
  27777. touch makeopts.acbak
  27778. fi
  27779. ac_config_files="$ac_config_files build_tools/menuselect-deps makeopts channels/h323/Makefile"
  27780. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mandatory modules: ${ac_mandatory_list}" >&5
  27781. $as_echo_n "checking for mandatory modules: ${ac_mandatory_list}... " >&6; }
  27782. err=0;
  27783. for i in ${ac_mandatory_list}; do
  27784. eval "a=\${PBX_$i}"
  27785. if test "x${a}" = "x1" ; then continue; fi
  27786. if test ${err} = "0" ; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: fail" >&5
  27787. $as_echo "fail" >&6; } ; fi
  27788. { $as_echo "$as_me:${as_lineno-$LINENO}: result: " >&5
  27789. $as_echo "" >&6; }
  27790. eval "a=\${${i}_OPTION}"
  27791. { $as_echo "$as_me:${as_lineno-$LINENO}: ***" >&5
  27792. $as_echo "$as_me: ***" >&6;}
  27793. { $as_echo "$as_me:${as_lineno-$LINENO}: *** The $i installation appears to be missing or broken." >&5
  27794. $as_echo "$as_me: *** The $i installation appears to be missing or broken." >&6;}
  27795. { $as_echo "$as_me:${as_lineno-$LINENO}: *** Either correct the installation, or run configure" >&5
  27796. $as_echo "$as_me: *** Either correct the installation, or run configure" >&6;}
  27797. { $as_echo "$as_me:${as_lineno-$LINENO}: *** including --without-${a}." >&5
  27798. $as_echo "$as_me: *** including --without-${a}." >&6;}
  27799. err=1
  27800. done
  27801. if test $err = 1 ; then exit 1; fi
  27802. { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
  27803. $as_echo "ok" >&6; }
  27804. if test -f build_tools/menuselect-deps; then
  27805. # extract old values of all PBX_ variables from menuselect-deps
  27806. # and preserve them so that menuselect can determine whether
  27807. # any previously-met dependencies are no longer met and warn
  27808. # the user appropriately
  27809. while IFS="=:" read var val old_val; do
  27810. eval "PBX_${var}=\${PBX_${var}}:${val}"
  27811. done < build_tools/menuselect-deps
  27812. fi
  27813. cat >confcache <<\_ACEOF
  27814. # This file is a shell script that caches the results of configure
  27815. # tests run on this system so they can be shared between configure
  27816. # scripts and configure runs, see configure's option --config-cache.
  27817. # It is not useful on other systems. If it contains results you don't
  27818. # want to keep, you may remove or edit it.
  27819. #
  27820. # config.status only pays attention to the cache file if you give it
  27821. # the --recheck option to rerun configure.
  27822. #
  27823. # `ac_cv_env_foo' variables (set or unset) will be overridden when
  27824. # loading this file, other *unset* `ac_cv_foo' will be assigned the
  27825. # following values.
  27826. _ACEOF
  27827. # The following way of writing the cache mishandles newlines in values,
  27828. # but we know of no workaround that is simple, portable, and efficient.
  27829. # So, we kill variables containing newlines.
  27830. # Ultrix sh set writes to stderr and can't be redirected directly,
  27831. # and sets the high bit in the cache file unless we assign to the vars.
  27832. (
  27833. for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
  27834. eval ac_val=\$$ac_var
  27835. case $ac_val in #(
  27836. *${as_nl}*)
  27837. case $ac_var in #(
  27838. *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
  27839. $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
  27840. esac
  27841. case $ac_var in #(
  27842. _ | IFS | as_nl) ;; #(
  27843. BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
  27844. *) { eval $ac_var=; unset $ac_var;} ;;
  27845. esac ;;
  27846. esac
  27847. done
  27848. (set) 2>&1 |
  27849. case $as_nl`(ac_space=' '; set) 2>&1` in #(
  27850. *${as_nl}ac_space=\ *)
  27851. # `set' does not quote correctly, so add quotes: double-quote
  27852. # substitution turns \\\\ into \\, and sed turns \\ into \.
  27853. sed -n \
  27854. "s/'/'\\\\''/g;
  27855. s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
  27856. ;; #(
  27857. *)
  27858. # `set' quotes correctly as required by POSIX, so do not add quotes.
  27859. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
  27860. ;;
  27861. esac |
  27862. sort
  27863. ) |
  27864. sed '
  27865. /^ac_cv_env_/b end
  27866. t clear
  27867. :clear
  27868. s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
  27869. t end
  27870. s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
  27871. :end' >>confcache
  27872. if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
  27873. if test -w "$cache_file"; then
  27874. if test "x$cache_file" != "x/dev/null"; then
  27875. { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
  27876. $as_echo "$as_me: updating cache $cache_file" >&6;}
  27877. if test ! -f "$cache_file" || test -h "$cache_file"; then
  27878. cat confcache >"$cache_file"
  27879. else
  27880. case $cache_file in #(
  27881. */* | ?:*)
  27882. mv -f confcache "$cache_file"$$ &&
  27883. mv -f "$cache_file"$$ "$cache_file" ;; #(
  27884. *)
  27885. mv -f confcache "$cache_file" ;;
  27886. esac
  27887. fi
  27888. fi
  27889. else
  27890. { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
  27891. $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
  27892. fi
  27893. fi
  27894. rm -f confcache
  27895. test "x$prefix" = xNONE && prefix=$ac_default_prefix
  27896. # Let make expand exec_prefix.
  27897. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
  27898. DEFS=-DHAVE_CONFIG_H
  27899. ac_libobjs=
  27900. ac_ltlibobjs=
  27901. U=
  27902. for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
  27903. # 1. Remove the extension, and $U if already installed.
  27904. ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
  27905. ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
  27906. # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
  27907. # will be set to the directory where LIBOBJS objects are built.
  27908. as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
  27909. as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
  27910. done
  27911. LIBOBJS=$ac_libobjs
  27912. LTLIBOBJS=$ac_ltlibobjs
  27913. : "${CONFIG_STATUS=./config.status}"
  27914. ac_write_fail=0
  27915. ac_clean_files_save=$ac_clean_files
  27916. ac_clean_files="$ac_clean_files $CONFIG_STATUS"
  27917. { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
  27918. $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
  27919. as_write_fail=0
  27920. cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
  27921. #! $SHELL
  27922. # Generated by $as_me.
  27923. # Run this file to recreate the current configuration.
  27924. # Compiler output produced by configure, useful for debugging
  27925. # configure, is in config.log if it exists.
  27926. debug=false
  27927. ac_cs_recheck=false
  27928. ac_cs_silent=false
  27929. SHELL=\${CONFIG_SHELL-$SHELL}
  27930. export SHELL
  27931. _ASEOF
  27932. cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
  27933. ## -------------------- ##
  27934. ## M4sh Initialization. ##
  27935. ## -------------------- ##
  27936. # Be more Bourne compatible
  27937. DUALCASE=1; export DUALCASE # for MKS sh
  27938. if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
  27939. emulate sh
  27940. NULLCMD=:
  27941. # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
  27942. # is contrary to our usage. Disable this feature.
  27943. alias -g '${1+"$@"}'='"$@"'
  27944. setopt NO_GLOB_SUBST
  27945. else
  27946. case `(set -o) 2>/dev/null` in #(
  27947. *posix*) :
  27948. set -o posix ;; #(
  27949. *) :
  27950. ;;
  27951. esac
  27952. fi
  27953. as_nl='
  27954. '
  27955. export as_nl
  27956. # Printing a long string crashes Solaris 7 /usr/bin/printf.
  27957. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
  27958. as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
  27959. as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
  27960. # Prefer a ksh shell builtin over an external printf program on Solaris,
  27961. # but without wasting forks for bash or zsh.
  27962. if test -z "$BASH_VERSION$ZSH_VERSION" \
  27963. && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
  27964. as_echo='print -r --'
  27965. as_echo_n='print -rn --'
  27966. elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
  27967. as_echo='printf %s\n'
  27968. as_echo_n='printf %s'
  27969. else
  27970. if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
  27971. as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
  27972. as_echo_n='/usr/ucb/echo -n'
  27973. else
  27974. as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
  27975. as_echo_n_body='eval
  27976. arg=$1;
  27977. case $arg in #(
  27978. *"$as_nl"*)
  27979. expr "X$arg" : "X\\(.*\\)$as_nl";
  27980. arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
  27981. esac;
  27982. expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
  27983. '
  27984. export as_echo_n_body
  27985. as_echo_n='sh -c $as_echo_n_body as_echo'
  27986. fi
  27987. export as_echo_body
  27988. as_echo='sh -c $as_echo_body as_echo'
  27989. fi
  27990. # The user is always right.
  27991. if test "${PATH_SEPARATOR+set}" != set; then
  27992. PATH_SEPARATOR=:
  27993. (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
  27994. (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
  27995. PATH_SEPARATOR=';'
  27996. }
  27997. fi
  27998. # IFS
  27999. # We need space, tab and new line, in precisely that order. Quoting is
  28000. # there to prevent editors from complaining about space-tab.
  28001. # (If _AS_PATH_WALK were called with IFS unset, it would disable word
  28002. # splitting by setting IFS to empty value.)
  28003. IFS=" "" $as_nl"
  28004. # Find who we are. Look in the path if we contain no directory separator.
  28005. as_myself=
  28006. case $0 in #((
  28007. *[\\/]* ) as_myself=$0 ;;
  28008. *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  28009. for as_dir in $PATH
  28010. do
  28011. IFS=$as_save_IFS
  28012. test -z "$as_dir" && as_dir=.
  28013. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
  28014. done
  28015. IFS=$as_save_IFS
  28016. ;;
  28017. esac
  28018. # We did not find ourselves, most probably we were run as `sh COMMAND'
  28019. # in which case we are not to be found in the path.
  28020. if test "x$as_myself" = x; then
  28021. as_myself=$0
  28022. fi
  28023. if test ! -f "$as_myself"; then
  28024. $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
  28025. exit 1
  28026. fi
  28027. # Unset variables that we do not need and which cause bugs (e.g. in
  28028. # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
  28029. # suppresses any "Segmentation fault" message there. '((' could
  28030. # trigger a bug in pdksh 5.2.14.
  28031. for as_var in BASH_ENV ENV MAIL MAILPATH
  28032. do eval test x\${$as_var+set} = xset \
  28033. && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
  28034. done
  28035. PS1='$ '
  28036. PS2='> '
  28037. PS4='+ '
  28038. # NLS nuisances.
  28039. LC_ALL=C
  28040. export LC_ALL
  28041. LANGUAGE=C
  28042. export LANGUAGE
  28043. # CDPATH.
  28044. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
  28045. # as_fn_error STATUS ERROR [LINENO LOG_FD]
  28046. # ----------------------------------------
  28047. # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
  28048. # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
  28049. # script with STATUS, using 1 if that was 0.
  28050. as_fn_error ()
  28051. {
  28052. as_status=$1; test $as_status -eq 0 && as_status=1
  28053. if test "$4"; then
  28054. as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  28055. $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
  28056. fi
  28057. $as_echo "$as_me: error: $2" >&2
  28058. as_fn_exit $as_status
  28059. } # as_fn_error
  28060. # as_fn_set_status STATUS
  28061. # -----------------------
  28062. # Set $? to STATUS, without forking.
  28063. as_fn_set_status ()
  28064. {
  28065. return $1
  28066. } # as_fn_set_status
  28067. # as_fn_exit STATUS
  28068. # -----------------
  28069. # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
  28070. as_fn_exit ()
  28071. {
  28072. set +e
  28073. as_fn_set_status $1
  28074. exit $1
  28075. } # as_fn_exit
  28076. # as_fn_unset VAR
  28077. # ---------------
  28078. # Portably unset VAR.
  28079. as_fn_unset ()
  28080. {
  28081. { eval $1=; unset $1;}
  28082. }
  28083. as_unset=as_fn_unset
  28084. # as_fn_append VAR VALUE
  28085. # ----------------------
  28086. # Append the text in VALUE to the end of the definition contained in VAR. Take
  28087. # advantage of any shell optimizations that allow amortized linear growth over
  28088. # repeated appends, instead of the typical quadratic growth present in naive
  28089. # implementations.
  28090. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
  28091. eval 'as_fn_append ()
  28092. {
  28093. eval $1+=\$2
  28094. }'
  28095. else
  28096. as_fn_append ()
  28097. {
  28098. eval $1=\$$1\$2
  28099. }
  28100. fi # as_fn_append
  28101. # as_fn_arith ARG...
  28102. # ------------------
  28103. # Perform arithmetic evaluation on the ARGs, and store the result in the
  28104. # global $as_val. Take advantage of shells that can avoid forks. The arguments
  28105. # must be portable across $(()) and expr.
  28106. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
  28107. eval 'as_fn_arith ()
  28108. {
  28109. as_val=$(( $* ))
  28110. }'
  28111. else
  28112. as_fn_arith ()
  28113. {
  28114. as_val=`expr "$@" || test $? -eq 1`
  28115. }
  28116. fi # as_fn_arith
  28117. if expr a : '\(a\)' >/dev/null 2>&1 &&
  28118. test "X`expr 00001 : '.*\(...\)'`" = X001; then
  28119. as_expr=expr
  28120. else
  28121. as_expr=false
  28122. fi
  28123. if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
  28124. as_basename=basename
  28125. else
  28126. as_basename=false
  28127. fi
  28128. if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
  28129. as_dirname=dirname
  28130. else
  28131. as_dirname=false
  28132. fi
  28133. as_me=`$as_basename -- "$0" ||
  28134. $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
  28135. X"$0" : 'X\(//\)$' \| \
  28136. X"$0" : 'X\(/\)' \| . 2>/dev/null ||
  28137. $as_echo X/"$0" |
  28138. sed '/^.*\/\([^/][^/]*\)\/*$/{
  28139. s//\1/
  28140. q
  28141. }
  28142. /^X\/\(\/\/\)$/{
  28143. s//\1/
  28144. q
  28145. }
  28146. /^X\/\(\/\).*/{
  28147. s//\1/
  28148. q
  28149. }
  28150. s/.*/./; q'`
  28151. # Avoid depending upon Character Ranges.
  28152. as_cr_letters='abcdefghijklmnopqrstuvwxyz'
  28153. as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
  28154. as_cr_Letters=$as_cr_letters$as_cr_LETTERS
  28155. as_cr_digits='0123456789'
  28156. as_cr_alnum=$as_cr_Letters$as_cr_digits
  28157. ECHO_C= ECHO_N= ECHO_T=
  28158. case `echo -n x` in #(((((
  28159. -n*)
  28160. case `echo 'xy\c'` in
  28161. *c*) ECHO_T=' ';; # ECHO_T is single tab character.
  28162. xy) ECHO_C='\c';;
  28163. *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
  28164. ECHO_T=' ';;
  28165. esac;;
  28166. *)
  28167. ECHO_N='-n';;
  28168. esac
  28169. rm -f conf$$ conf$$.exe conf$$.file
  28170. if test -d conf$$.dir; then
  28171. rm -f conf$$.dir/conf$$.file
  28172. else
  28173. rm -f conf$$.dir
  28174. mkdir conf$$.dir 2>/dev/null
  28175. fi
  28176. if (echo >conf$$.file) 2>/dev/null; then
  28177. if ln -s conf$$.file conf$$ 2>/dev/null; then
  28178. as_ln_s='ln -s'
  28179. # ... but there are two gotchas:
  28180. # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
  28181. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
  28182. # In both cases, we have to default to `cp -pR'.
  28183. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
  28184. as_ln_s='cp -pR'
  28185. elif ln conf$$.file conf$$ 2>/dev/null; then
  28186. as_ln_s=ln
  28187. else
  28188. as_ln_s='cp -pR'
  28189. fi
  28190. else
  28191. as_ln_s='cp -pR'
  28192. fi
  28193. rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
  28194. rmdir conf$$.dir 2>/dev/null
  28195. # as_fn_mkdir_p
  28196. # -------------
  28197. # Create "$as_dir" as a directory, including parents if necessary.
  28198. as_fn_mkdir_p ()
  28199. {
  28200. case $as_dir in #(
  28201. -*) as_dir=./$as_dir;;
  28202. esac
  28203. test -d "$as_dir" || eval $as_mkdir_p || {
  28204. as_dirs=
  28205. while :; do
  28206. case $as_dir in #(
  28207. *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
  28208. *) as_qdir=$as_dir;;
  28209. esac
  28210. as_dirs="'$as_qdir' $as_dirs"
  28211. as_dir=`$as_dirname -- "$as_dir" ||
  28212. $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
  28213. X"$as_dir" : 'X\(//\)[^/]' \| \
  28214. X"$as_dir" : 'X\(//\)$' \| \
  28215. X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
  28216. $as_echo X"$as_dir" |
  28217. sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
  28218. s//\1/
  28219. q
  28220. }
  28221. /^X\(\/\/\)[^/].*/{
  28222. s//\1/
  28223. q
  28224. }
  28225. /^X\(\/\/\)$/{
  28226. s//\1/
  28227. q
  28228. }
  28229. /^X\(\/\).*/{
  28230. s//\1/
  28231. q
  28232. }
  28233. s/.*/./; q'`
  28234. test -d "$as_dir" && break
  28235. done
  28236. test -z "$as_dirs" || eval "mkdir $as_dirs"
  28237. } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
  28238. } # as_fn_mkdir_p
  28239. if mkdir -p . 2>/dev/null; then
  28240. as_mkdir_p='mkdir -p "$as_dir"'
  28241. else
  28242. test -d ./-p && rmdir ./-p
  28243. as_mkdir_p=false
  28244. fi
  28245. # as_fn_executable_p FILE
  28246. # -----------------------
  28247. # Test if FILE is an executable regular file.
  28248. as_fn_executable_p ()
  28249. {
  28250. test -f "$1" && test -x "$1"
  28251. } # as_fn_executable_p
  28252. as_test_x='test -x'
  28253. as_executable_p=as_fn_executable_p
  28254. # Sed expression to map a string onto a valid CPP name.
  28255. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
  28256. # Sed expression to map a string onto a valid variable name.
  28257. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
  28258. exec 6>&1
  28259. ## ----------------------------------- ##
  28260. ## Main body of $CONFIG_STATUS script. ##
  28261. ## ----------------------------------- ##
  28262. _ASEOF
  28263. test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
  28264. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  28265. # Save the log message, to keep $0 and so on meaningful, and to
  28266. # report actual input values of CONFIG_FILES etc. instead of their
  28267. # values after options handling.
  28268. ac_log="
  28269. This file was extended by asterisk $as_me trunk, which was
  28270. generated by GNU Autoconf 2.69. Invocation command line was
  28271. CONFIG_FILES = $CONFIG_FILES
  28272. CONFIG_HEADERS = $CONFIG_HEADERS
  28273. CONFIG_LINKS = $CONFIG_LINKS
  28274. CONFIG_COMMANDS = $CONFIG_COMMANDS
  28275. $ $0 $@
  28276. on `(hostname || uname -n) 2>/dev/null | sed 1q`
  28277. "
  28278. _ACEOF
  28279. case $ac_config_files in *"
  28280. "*) set x $ac_config_files; shift; ac_config_files=$*;;
  28281. esac
  28282. case $ac_config_headers in *"
  28283. "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
  28284. esac
  28285. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  28286. # Files that config.status was made for.
  28287. config_files="$ac_config_files"
  28288. config_headers="$ac_config_headers"
  28289. _ACEOF
  28290. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  28291. ac_cs_usage="\
  28292. \`$as_me' instantiates files and other configuration actions
  28293. from templates according to the current configuration. Unless the files
  28294. and actions are specified as TAGs, all are instantiated by default.
  28295. Usage: $0 [OPTION]... [TAG]...
  28296. -h, --help print this help, then exit
  28297. -V, --version print version number and configuration settings, then exit
  28298. --config print configuration, then exit
  28299. -q, --quiet, --silent
  28300. do not print progress messages
  28301. -d, --debug don't remove temporary files
  28302. --recheck update $as_me by reconfiguring in the same conditions
  28303. --file=FILE[:TEMPLATE]
  28304. instantiate the configuration file FILE
  28305. --header=FILE[:TEMPLATE]
  28306. instantiate the configuration header FILE
  28307. Configuration files:
  28308. $config_files
  28309. Configuration headers:
  28310. $config_headers
  28311. Report bugs to <https://issues.asterisk.org>."
  28312. _ACEOF
  28313. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  28314. ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
  28315. ac_cs_version="\\
  28316. asterisk config.status trunk
  28317. configured by $0, generated by GNU Autoconf 2.69,
  28318. with options \\"\$ac_cs_config\\"
  28319. Copyright (C) 2012 Free Software Foundation, Inc.
  28320. This config.status script is free software; the Free Software Foundation
  28321. gives unlimited permission to copy, distribute and modify it."
  28322. ac_pwd='$ac_pwd'
  28323. srcdir='$srcdir'
  28324. INSTALL='$INSTALL'
  28325. AWK='$AWK'
  28326. test -n "\$AWK" || AWK=awk
  28327. _ACEOF
  28328. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  28329. # The default lists apply if the user does not specify any file.
  28330. ac_need_defaults=:
  28331. while test $# != 0
  28332. do
  28333. case $1 in
  28334. --*=?*)
  28335. ac_option=`expr "X$1" : 'X\([^=]*\)='`
  28336. ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
  28337. ac_shift=:
  28338. ;;
  28339. --*=)
  28340. ac_option=`expr "X$1" : 'X\([^=]*\)='`
  28341. ac_optarg=
  28342. ac_shift=:
  28343. ;;
  28344. *)
  28345. ac_option=$1
  28346. ac_optarg=$2
  28347. ac_shift=shift
  28348. ;;
  28349. esac
  28350. case $ac_option in
  28351. # Handling of the options.
  28352. -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
  28353. ac_cs_recheck=: ;;
  28354. --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
  28355. $as_echo "$ac_cs_version"; exit ;;
  28356. --config | --confi | --conf | --con | --co | --c )
  28357. $as_echo "$ac_cs_config"; exit ;;
  28358. --debug | --debu | --deb | --de | --d | -d )
  28359. debug=: ;;
  28360. --file | --fil | --fi | --f )
  28361. $ac_shift
  28362. case $ac_optarg in
  28363. *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
  28364. '') as_fn_error $? "missing file argument" ;;
  28365. esac
  28366. as_fn_append CONFIG_FILES " '$ac_optarg'"
  28367. ac_need_defaults=false;;
  28368. --header | --heade | --head | --hea )
  28369. $ac_shift
  28370. case $ac_optarg in
  28371. *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
  28372. esac
  28373. as_fn_append CONFIG_HEADERS " '$ac_optarg'"
  28374. ac_need_defaults=false;;
  28375. --he | --h)
  28376. # Conflict between --help and --header
  28377. as_fn_error $? "ambiguous option: \`$1'
  28378. Try \`$0 --help' for more information.";;
  28379. --help | --hel | -h )
  28380. $as_echo "$ac_cs_usage"; exit ;;
  28381. -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  28382. | -silent | --silent | --silen | --sile | --sil | --si | --s)
  28383. ac_cs_silent=: ;;
  28384. # This is an error.
  28385. -*) as_fn_error $? "unrecognized option: \`$1'
  28386. Try \`$0 --help' for more information." ;;
  28387. *) as_fn_append ac_config_targets " $1"
  28388. ac_need_defaults=false ;;
  28389. esac
  28390. shift
  28391. done
  28392. ac_configure_extra_args=
  28393. if $ac_cs_silent; then
  28394. exec 6>/dev/null
  28395. ac_configure_extra_args="$ac_configure_extra_args --silent"
  28396. fi
  28397. _ACEOF
  28398. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  28399. if \$ac_cs_recheck; then
  28400. set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
  28401. shift
  28402. \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
  28403. CONFIG_SHELL='$SHELL'
  28404. export CONFIG_SHELL
  28405. exec "\$@"
  28406. fi
  28407. _ACEOF
  28408. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  28409. exec 5>>config.log
  28410. {
  28411. echo
  28412. sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
  28413. ## Running $as_me. ##
  28414. _ASBOX
  28415. $as_echo "$ac_log"
  28416. } >&5
  28417. _ACEOF
  28418. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  28419. _ACEOF
  28420. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  28421. # Handling of arguments.
  28422. for ac_config_target in $ac_config_targets
  28423. do
  28424. case $ac_config_target in
  28425. "include/asterisk/autoconfig.h") CONFIG_HEADERS="$CONFIG_HEADERS include/asterisk/autoconfig.h" ;;
  28426. "build_tools/menuselect-deps") CONFIG_FILES="$CONFIG_FILES build_tools/menuselect-deps" ;;
  28427. "makeopts") CONFIG_FILES="$CONFIG_FILES makeopts" ;;
  28428. "channels/h323/Makefile") CONFIG_FILES="$CONFIG_FILES channels/h323/Makefile" ;;
  28429. *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
  28430. esac
  28431. done
  28432. # If the user did not use the arguments to specify the items to instantiate,
  28433. # then the envvar interface is used. Set only those that are not.
  28434. # We use the long form for the default assignment because of an extremely
  28435. # bizarre bug on SunOS 4.1.3.
  28436. if $ac_need_defaults; then
  28437. test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
  28438. test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
  28439. fi
  28440. # Have a temporary directory for convenience. Make it in the build tree
  28441. # simply because there is no reason against having it here, and in addition,
  28442. # creating and moving files from /tmp can sometimes cause problems.
  28443. # Hook for its removal unless debugging.
  28444. # Note that there is a small window in which the directory will not be cleaned:
  28445. # after its creation but before its name has been assigned to `$tmp'.
  28446. $debug ||
  28447. {
  28448. tmp= ac_tmp=
  28449. trap 'exit_status=$?
  28450. : "${ac_tmp:=$tmp}"
  28451. { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
  28452. ' 0
  28453. trap 'as_fn_exit 1' 1 2 13 15
  28454. }
  28455. # Create a (secure) tmp directory for tmp files.
  28456. {
  28457. tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
  28458. test -d "$tmp"
  28459. } ||
  28460. {
  28461. tmp=./conf$$-$RANDOM
  28462. (umask 077 && mkdir "$tmp")
  28463. } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
  28464. ac_tmp=$tmp
  28465. # Set up the scripts for CONFIG_FILES section.
  28466. # No need to generate them if there are no CONFIG_FILES.
  28467. # This happens for instance with `./config.status config.h'.
  28468. if test -n "$CONFIG_FILES"; then
  28469. ac_cr=`echo X | tr X '\015'`
  28470. # On cygwin, bash can eat \r inside `` if the user requested igncr.
  28471. # But we know of no other shell where ac_cr would be empty at this
  28472. # point, so we can use a bashism as a fallback.
  28473. if test "x$ac_cr" = x; then
  28474. eval ac_cr=\$\'\\r\'
  28475. fi
  28476. ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
  28477. if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
  28478. ac_cs_awk_cr='\\r'
  28479. else
  28480. ac_cs_awk_cr=$ac_cr
  28481. fi
  28482. echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
  28483. _ACEOF
  28484. {
  28485. echo "cat >conf$$subs.awk <<_ACEOF" &&
  28486. echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
  28487. echo "_ACEOF"
  28488. } >conf$$subs.sh ||
  28489. as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
  28490. ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
  28491. ac_delim='%!_!# '
  28492. for ac_last_try in false false false false false :; do
  28493. . ./conf$$subs.sh ||
  28494. as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
  28495. ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
  28496. if test $ac_delim_n = $ac_delim_num; then
  28497. break
  28498. elif $ac_last_try; then
  28499. as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
  28500. else
  28501. ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
  28502. fi
  28503. done
  28504. rm -f conf$$subs.sh
  28505. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  28506. cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
  28507. _ACEOF
  28508. sed -n '
  28509. h
  28510. s/^/S["/; s/!.*/"]=/
  28511. p
  28512. g
  28513. s/^[^!]*!//
  28514. :repl
  28515. t repl
  28516. s/'"$ac_delim"'$//
  28517. t delim
  28518. :nl
  28519. h
  28520. s/\(.\{148\}\)..*/\1/
  28521. t more1
  28522. s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
  28523. p
  28524. n
  28525. b repl
  28526. :more1
  28527. s/["\\]/\\&/g; s/^/"/; s/$/"\\/
  28528. p
  28529. g
  28530. s/.\{148\}//
  28531. t nl
  28532. :delim
  28533. h
  28534. s/\(.\{148\}\)..*/\1/
  28535. t more2
  28536. s/["\\]/\\&/g; s/^/"/; s/$/"/
  28537. p
  28538. b
  28539. :more2
  28540. s/["\\]/\\&/g; s/^/"/; s/$/"\\/
  28541. p
  28542. g
  28543. s/.\{148\}//
  28544. t delim
  28545. ' <conf$$subs.awk | sed '
  28546. /^[^""]/{
  28547. N
  28548. s/\n//
  28549. }
  28550. ' >>$CONFIG_STATUS || ac_write_fail=1
  28551. rm -f conf$$subs.awk
  28552. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  28553. _ACAWK
  28554. cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
  28555. for (key in S) S_is_set[key] = 1
  28556. FS = ""
  28557. }
  28558. {
  28559. line = $ 0
  28560. nfields = split(line, field, "@")
  28561. substed = 0
  28562. len = length(field[1])
  28563. for (i = 2; i < nfields; i++) {
  28564. key = field[i]
  28565. keylen = length(key)
  28566. if (S_is_set[key]) {
  28567. value = S[key]
  28568. line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
  28569. len += length(value) + length(field[++i])
  28570. substed = 1
  28571. } else
  28572. len += 1 + keylen
  28573. }
  28574. print line
  28575. }
  28576. _ACAWK
  28577. _ACEOF
  28578. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  28579. if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
  28580. sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
  28581. else
  28582. cat
  28583. fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
  28584. || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
  28585. _ACEOF
  28586. # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
  28587. # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
  28588. # trailing colons and then remove the whole line if VPATH becomes empty
  28589. # (actually we leave an empty line to preserve line numbers).
  28590. if test "x$srcdir" = x.; then
  28591. ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
  28592. h
  28593. s///
  28594. s/^/:/
  28595. s/[ ]*$/:/
  28596. s/:\$(srcdir):/:/g
  28597. s/:\${srcdir}:/:/g
  28598. s/:@srcdir@:/:/g
  28599. s/^:*//
  28600. s/:*$//
  28601. x
  28602. s/\(=[ ]*\).*/\1/
  28603. G
  28604. s/\n//
  28605. s/^[^=]*=[ ]*$//
  28606. }'
  28607. fi
  28608. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  28609. fi # test -n "$CONFIG_FILES"
  28610. # Set up the scripts for CONFIG_HEADERS section.
  28611. # No need to generate them if there are no CONFIG_HEADERS.
  28612. # This happens for instance with `./config.status Makefile'.
  28613. if test -n "$CONFIG_HEADERS"; then
  28614. cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
  28615. BEGIN {
  28616. _ACEOF
  28617. # Transform confdefs.h into an awk script `defines.awk', embedded as
  28618. # here-document in config.status, that substitutes the proper values into
  28619. # config.h.in to produce config.h.
  28620. # Create a delimiter string that does not exist in confdefs.h, to ease
  28621. # handling of long lines.
  28622. ac_delim='%!_!# '
  28623. for ac_last_try in false false :; do
  28624. ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
  28625. if test -z "$ac_tt"; then
  28626. break
  28627. elif $ac_last_try; then
  28628. as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
  28629. else
  28630. ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
  28631. fi
  28632. done
  28633. # For the awk script, D is an array of macro values keyed by name,
  28634. # likewise P contains macro parameters if any. Preserve backslash
  28635. # newline sequences.
  28636. ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
  28637. sed -n '
  28638. s/.\{148\}/&'"$ac_delim"'/g
  28639. t rset
  28640. :rset
  28641. s/^[ ]*#[ ]*define[ ][ ]*/ /
  28642. t def
  28643. d
  28644. :def
  28645. s/\\$//
  28646. t bsnl
  28647. s/["\\]/\\&/g
  28648. s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
  28649. D["\1"]=" \3"/p
  28650. s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
  28651. d
  28652. :bsnl
  28653. s/["\\]/\\&/g
  28654. s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
  28655. D["\1"]=" \3\\\\\\n"\\/p
  28656. t cont
  28657. s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
  28658. t cont
  28659. d
  28660. :cont
  28661. n
  28662. s/.\{148\}/&'"$ac_delim"'/g
  28663. t clear
  28664. :clear
  28665. s/\\$//
  28666. t bsnlc
  28667. s/["\\]/\\&/g; s/^/"/; s/$/"/p
  28668. d
  28669. :bsnlc
  28670. s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
  28671. b cont
  28672. ' <confdefs.h | sed '
  28673. s/'"$ac_delim"'/"\\\
  28674. "/g' >>$CONFIG_STATUS || ac_write_fail=1
  28675. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  28676. for (key in D) D_is_set[key] = 1
  28677. FS = ""
  28678. }
  28679. /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
  28680. line = \$ 0
  28681. split(line, arg, " ")
  28682. if (arg[1] == "#") {
  28683. defundef = arg[2]
  28684. mac1 = arg[3]
  28685. } else {
  28686. defundef = substr(arg[1], 2)
  28687. mac1 = arg[2]
  28688. }
  28689. split(mac1, mac2, "(") #)
  28690. macro = mac2[1]
  28691. prefix = substr(line, 1, index(line, defundef) - 1)
  28692. if (D_is_set[macro]) {
  28693. # Preserve the white space surrounding the "#".
  28694. print prefix "define", macro P[macro] D[macro]
  28695. next
  28696. } else {
  28697. # Replace #undef with comments. This is necessary, for example,
  28698. # in the case of _POSIX_SOURCE, which is predefined and required
  28699. # on some systems where configure will not decide to define it.
  28700. if (defundef == "undef") {
  28701. print "/*", prefix defundef, macro, "*/"
  28702. next
  28703. }
  28704. }
  28705. }
  28706. { print }
  28707. _ACAWK
  28708. _ACEOF
  28709. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  28710. as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
  28711. fi # test -n "$CONFIG_HEADERS"
  28712. eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS "
  28713. shift
  28714. for ac_tag
  28715. do
  28716. case $ac_tag in
  28717. :[FHLC]) ac_mode=$ac_tag; continue;;
  28718. esac
  28719. case $ac_mode$ac_tag in
  28720. :[FHL]*:*);;
  28721. :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
  28722. :[FH]-) ac_tag=-:-;;
  28723. :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
  28724. esac
  28725. ac_save_IFS=$IFS
  28726. IFS=:
  28727. set x $ac_tag
  28728. IFS=$ac_save_IFS
  28729. shift
  28730. ac_file=$1
  28731. shift
  28732. case $ac_mode in
  28733. :L) ac_source=$1;;
  28734. :[FH])
  28735. ac_file_inputs=
  28736. for ac_f
  28737. do
  28738. case $ac_f in
  28739. -) ac_f="$ac_tmp/stdin";;
  28740. *) # Look for the file first in the build tree, then in the source tree
  28741. # (if the path is not absolute). The absolute path cannot be DOS-style,
  28742. # because $ac_f cannot contain `:'.
  28743. test -f "$ac_f" ||
  28744. case $ac_f in
  28745. [\\/$]*) false;;
  28746. *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
  28747. esac ||
  28748. as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
  28749. esac
  28750. case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
  28751. as_fn_append ac_file_inputs " '$ac_f'"
  28752. done
  28753. # Let's still pretend it is `configure' which instantiates (i.e., don't
  28754. # use $as_me), people would be surprised to read:
  28755. # /* config.h. Generated by config.status. */
  28756. configure_input='Generated from '`
  28757. $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
  28758. `' by configure.'
  28759. if test x"$ac_file" != x-; then
  28760. configure_input="$ac_file. $configure_input"
  28761. { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
  28762. $as_echo "$as_me: creating $ac_file" >&6;}
  28763. fi
  28764. # Neutralize special characters interpreted by sed in replacement strings.
  28765. case $configure_input in #(
  28766. *\&* | *\|* | *\\* )
  28767. ac_sed_conf_input=`$as_echo "$configure_input" |
  28768. sed 's/[\\\\&|]/\\\\&/g'`;; #(
  28769. *) ac_sed_conf_input=$configure_input;;
  28770. esac
  28771. case $ac_tag in
  28772. *:-:* | *:-) cat >"$ac_tmp/stdin" \
  28773. || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
  28774. esac
  28775. ;;
  28776. esac
  28777. ac_dir=`$as_dirname -- "$ac_file" ||
  28778. $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
  28779. X"$ac_file" : 'X\(//\)[^/]' \| \
  28780. X"$ac_file" : 'X\(//\)$' \| \
  28781. X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
  28782. $as_echo X"$ac_file" |
  28783. sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
  28784. s//\1/
  28785. q
  28786. }
  28787. /^X\(\/\/\)[^/].*/{
  28788. s//\1/
  28789. q
  28790. }
  28791. /^X\(\/\/\)$/{
  28792. s//\1/
  28793. q
  28794. }
  28795. /^X\(\/\).*/{
  28796. s//\1/
  28797. q
  28798. }
  28799. s/.*/./; q'`
  28800. as_dir="$ac_dir"; as_fn_mkdir_p
  28801. ac_builddir=.
  28802. case "$ac_dir" in
  28803. .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
  28804. *)
  28805. ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
  28806. # A ".." for each directory in $ac_dir_suffix.
  28807. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
  28808. case $ac_top_builddir_sub in
  28809. "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
  28810. *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
  28811. esac ;;
  28812. esac
  28813. ac_abs_top_builddir=$ac_pwd
  28814. ac_abs_builddir=$ac_pwd$ac_dir_suffix
  28815. # for backward compatibility:
  28816. ac_top_builddir=$ac_top_build_prefix
  28817. case $srcdir in
  28818. .) # We are building in place.
  28819. ac_srcdir=.
  28820. ac_top_srcdir=$ac_top_builddir_sub
  28821. ac_abs_top_srcdir=$ac_pwd ;;
  28822. [\\/]* | ?:[\\/]* ) # Absolute name.
  28823. ac_srcdir=$srcdir$ac_dir_suffix;
  28824. ac_top_srcdir=$srcdir
  28825. ac_abs_top_srcdir=$srcdir ;;
  28826. *) # Relative name.
  28827. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
  28828. ac_top_srcdir=$ac_top_build_prefix$srcdir
  28829. ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
  28830. esac
  28831. ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
  28832. case $ac_mode in
  28833. :F)
  28834. #
  28835. # CONFIG_FILE
  28836. #
  28837. case $INSTALL in
  28838. [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
  28839. *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
  28840. esac
  28841. _ACEOF
  28842. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  28843. # If the template does not know about datarootdir, expand it.
  28844. # FIXME: This hack should be removed a few years after 2.60.
  28845. ac_datarootdir_hack=; ac_datarootdir_seen=
  28846. ac_sed_dataroot='
  28847. /datarootdir/ {
  28848. p
  28849. q
  28850. }
  28851. /@datadir@/p
  28852. /@docdir@/p
  28853. /@infodir@/p
  28854. /@localedir@/p
  28855. /@mandir@/p'
  28856. case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
  28857. *datarootdir*) ac_datarootdir_seen=yes;;
  28858. *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
  28859. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
  28860. $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
  28861. _ACEOF
  28862. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  28863. ac_datarootdir_hack='
  28864. s&@datadir@&$datadir&g
  28865. s&@docdir@&$docdir&g
  28866. s&@infodir@&$infodir&g
  28867. s&@localedir@&$localedir&g
  28868. s&@mandir@&$mandir&g
  28869. s&\\\${datarootdir}&$datarootdir&g' ;;
  28870. esac
  28871. _ACEOF
  28872. # Neutralize VPATH when `$srcdir' = `.'.
  28873. # Shell code in configure.ac might set extrasub.
  28874. # FIXME: do we really want to maintain this feature?
  28875. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  28876. ac_sed_extra="$ac_vpsub
  28877. $extrasub
  28878. _ACEOF
  28879. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  28880. :t
  28881. /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
  28882. s|@configure_input@|$ac_sed_conf_input|;t t
  28883. s&@top_builddir@&$ac_top_builddir_sub&;t t
  28884. s&@top_build_prefix@&$ac_top_build_prefix&;t t
  28885. s&@srcdir@&$ac_srcdir&;t t
  28886. s&@abs_srcdir@&$ac_abs_srcdir&;t t
  28887. s&@top_srcdir@&$ac_top_srcdir&;t t
  28888. s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
  28889. s&@builddir@&$ac_builddir&;t t
  28890. s&@abs_builddir@&$ac_abs_builddir&;t t
  28891. s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
  28892. s&@INSTALL@&$ac_INSTALL&;t t
  28893. $ac_datarootdir_hack
  28894. "
  28895. eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
  28896. >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
  28897. test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
  28898. { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
  28899. { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
  28900. "$ac_tmp/out"`; test -z "$ac_out"; } &&
  28901. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
  28902. which seems to be undefined. Please make sure it is defined" >&5
  28903. $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
  28904. which seems to be undefined. Please make sure it is defined" >&2;}
  28905. rm -f "$ac_tmp/stdin"
  28906. case $ac_file in
  28907. -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
  28908. *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
  28909. esac \
  28910. || as_fn_error $? "could not create $ac_file" "$LINENO" 5
  28911. ;;
  28912. :H)
  28913. #
  28914. # CONFIG_HEADER
  28915. #
  28916. if test x"$ac_file" != x-; then
  28917. {
  28918. $as_echo "/* $configure_input */" \
  28919. && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
  28920. } >"$ac_tmp/config.h" \
  28921. || as_fn_error $? "could not create $ac_file" "$LINENO" 5
  28922. if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
  28923. { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
  28924. $as_echo "$as_me: $ac_file is unchanged" >&6;}
  28925. else
  28926. rm -f "$ac_file"
  28927. mv "$ac_tmp/config.h" "$ac_file" \
  28928. || as_fn_error $? "could not create $ac_file" "$LINENO" 5
  28929. fi
  28930. else
  28931. $as_echo "/* $configure_input */" \
  28932. && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
  28933. || as_fn_error $? "could not create -" "$LINENO" 5
  28934. fi
  28935. ;;
  28936. esac
  28937. done # for ac_tag
  28938. as_fn_exit 0
  28939. _ACEOF
  28940. ac_clean_files=$ac_clean_files_save
  28941. test $ac_write_fail = 0 ||
  28942. as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
  28943. # configure is writing to config.log, and then calls config.status.
  28944. # config.status does its own redirection, appending to config.log.
  28945. # Unfortunately, on DOS this fails, as config.log is still kept open
  28946. # by configure, so config.status won't be able to write to it; its
  28947. # output is simply discarded. So we exec the FD to /dev/null,
  28948. # effectively closing config.log, so it can be properly (re)opened and
  28949. # appended to by config.status. When coming back to configure, we
  28950. # need to make the FD available again.
  28951. if test "$no_create" != yes; then
  28952. ac_cs_success=:
  28953. ac_config_status_args=
  28954. test "$silent" = yes &&
  28955. ac_config_status_args="$ac_config_status_args --quiet"
  28956. exec 5>/dev/null
  28957. $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
  28958. exec 5>>config.log
  28959. # Use ||, not &&, to avoid exiting from the if with $? = 1, which
  28960. # would make configure fail if this is the last instruction.
  28961. $ac_cs_success || as_fn_exit 1
  28962. fi
  28963. if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
  28964. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
  28965. $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
  28966. fi
  28967. ${ac_cv_path_EGREP} 'CURSES|GTK2|OSARCH|NEWT' makeopts > makeopts.acbak2
  28968. if test "x${ac_cv_path_CMP}" = "x:"; then
  28969. ( cd `pwd`/menuselect && ./configure )
  28970. else if ${ac_cv_path_CMP} -s makeopts.acbak makeopts.acbak2; then : ; else
  28971. ( cd `pwd`/menuselect && ./configure )
  28972. fi ; fi
  28973. rm makeopts.acbak makeopts.acbak2
  28974. if test "x${silent}" != "xyes" ; then
  28975. echo
  28976. echo " .\$\$\$\$\$\$\$\$\$\$\$\$\$\$\$=.. "
  28977. echo " .\$7\$7.. .7\$\$7:. "
  28978. echo " .\$\$:. ,\$7.7 "
  28979. echo " .\$7. 7\$\$\$\$ .\$\$77 "
  28980. echo " ..\$\$. \$\$\$\$\$ .\$\$\$7 "
  28981. echo " ..7\$ .?. \$\$\$\$\$ .?. 7\$\$\$."
  28982. echo " \$.\$. .\$\$\$7. \$\$\$\$7 .7\$\$\$. .\$\$\$."
  28983. echo " .777. .\$\$\$\$\$\$77\$\$\$77\$\$\$\$\$7. \$\$\$,"
  28984. echo " \$\$\$~ .7\$\$\$\$\$\$\$\$\$\$\$\$\$7. .\$\$\$."
  28985. echo ".\$\$7 .7\$\$\$\$\$\$\$7: ?\$\$\$."
  28986. echo "\$\$\$ ?7\$\$\$\$\$\$\$\$\$\$I .\$\$\$7 "
  28987. echo "\$\$\$ .7\$\$\$\$\$\$\$\$\$\$\$\$\$\$\$\$ :\$\$\$. "
  28988. echo "\$\$\$ \$\$\$\$\$\$7\$\$\$\$\$\$\$\$\$\$\$\$ .\$\$\$. "
  28989. echo "\$\$\$ \$\$\$ 7\$\$\$7 .\$\$\$ .\$\$\$. "
  28990. echo "\$\$\$\$ \$\$\$\$7 .\$\$\$. "
  28991. echo "7\$\$\$7 7\$\$\$\$ 7\$\$\$ "
  28992. echo " \$\$\$\$\$ \$\$\$ "
  28993. echo " \$\$\$\$7. \$\$ (TM) "
  28994. echo " \$\$\$\$\$\$\$. .7\$\$\$\$\$\$ \$\$ "
  28995. echo " \$\$\$\$\$\$\$\$\$\$\$\$7\$\$\$\$\$\$\$\$\$.\$\$\$\$\$\$ "
  28996. echo " \$\$\$\$\$\$\$\$\$\$\$\$\$\$\$\$. "
  28997. echo
  28998. fi
  28999. if test "x${AST_IODBC_FOUND}" = "xyes"; then
  29000. echo "WARNING: iodbc libs/headers found!"
  29001. echo
  29002. echo " If you plan to use ODBC functionality, you should consider"
  29003. echo " switching to unixodbc instead."
  29004. echo " See: https://issues.asterisk.org/jira/browse/ASTERISK-22459"
  29005. echo
  29006. fi
  29007. { $as_echo "$as_me:${as_lineno-$LINENO}: Package configured for: " >&5
  29008. $as_echo "$as_me: Package configured for: " >&6;}
  29009. { $as_echo "$as_me:${as_lineno-$LINENO}: OS type : $host_os" >&5
  29010. $as_echo "$as_me: OS type : $host_os" >&6;}
  29011. { $as_echo "$as_me:${as_lineno-$LINENO}: Host CPU : $host_cpu" >&5
  29012. $as_echo "$as_me: Host CPU : $host_cpu" >&6;}
  29013. { $as_echo "$as_me:${as_lineno-$LINENO}: build-cpu:vendor:os: $build_cpu : $build_vendor : $build_os :" >&5
  29014. $as_echo "$as_me: build-cpu:vendor:os: $build_cpu : $build_vendor : $build_os :" >&6;}
  29015. { $as_echo "$as_me:${as_lineno-$LINENO}: host-cpu:vendor:os: $host_cpu : $host_vendor : $host_os :" >&5
  29016. $as_echo "$as_me: host-cpu:vendor:os: $host_cpu : $host_vendor : $host_os :" >&6;}
  29017. if test "${cross_compiling}" = "yes"; then
  29018. { $as_echo "$as_me:${as_lineno-$LINENO}: Cross Compilation = YES" >&5
  29019. $as_echo "$as_me: Cross Compilation = YES" >&6;}
  29020. fi